I get no valid data send error during product export via system->import/export->export. Actually this because of time out error. How can run this export by command ssh.

  • There is no short-cut to run that utility from command-line, unless you are willing to write a whole extension to modify the default functionality. Did you try cutting down the size of import file in smaller chunks ?
    – Prateek
    Mar 29 '17 at 5:15
  • @Prateek : how can i export my all products
    – user51361
    Mar 29 '17 at 5:20
  • @Prateek : my sites consist 50k products
    – user51361
    Mar 29 '17 at 5:21
  • In that case, try Dataflow models instead. Yes, they will take time, but you'll be able to complete the task. Other option will be to go with some 3rd party extension.
    – Prateek
    Mar 29 '17 at 5:22
  • @Prateek : Dataflow models also same time out error, because of 50k products. is any possible using custom script to get download all products.
    – user51361
    Mar 29 '17 at 5:27

Use below script to export all the products. Put this script in root folder. And check your profile id. You can check your profile id from

System > Import/Export > Dataflow - Profiles.

Use profile id according to your need.


//THIS SCRIPT JUST INITIALS THE PROFILE TO BE RUN VIA MAGENTO ADMIN "RUN PROFILE IN POPUP". Its the same thing as click just via this file that you can run via cron
$profileId = 1; // SYSTEM - IMPORT/EXPORT - DATAFLOW PROFILES PROFILES <-- you need to go into your magento admin and grab the exact profile ID

require_once 'app/Mage.php';

$profile = Mage::getModel('dataflow/profile');
$userModel = Mage::getModel('admin/user');
if (!$profile->getId()) {
    Mage::getSingleton('adminhtml/session')->addError('ERROR: Incorrect profile id');

Mage::register('current_convert_profile', $profile);
$recordCount = 0;
$batchModel = Mage::getSingleton('dataflow/batch');
echo "EXPORT COMPLETE. BATCHID: " . $batchModel->getId();

You will get your csv file in var/export folder.

  • command complete,but products export not working snag.gy/N6cU4t.jpg
    – user51361
    Apr 7 '17 at 13:03
  • my $profileId is right.
    – user51361
    Apr 7 '17 at 13:03
  • Please double check your code. It's working for me. Check your var/export folder to see your exported file. Apr 10 '17 at 4:50
  • @ Dinesh Yadav : i get error snag.gy/QfNivr.jpg how can i solve this
    – user51361
    Apr 10 '17 at 6:28
  • 1
    if you are facing the memory size issue then run this command "php -dmemory_limit=50G import_export.php" Apr 10 '17 at 6:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy