We have a t1.micro ec2 server right now. It has magento installed on it, which has been customized w various plugins and other custom development

I’ve successfully set up an elastic beanstalk LAMP environment and connected it to RDS.

I’d like to install our magento site on our elastic beanstalk environment and use it as our production environment, but am not sure how.

I know that deploys are handled on elastic beanstalk by uploading a zip file, but I have been unsuccessful so far at deploying working software. I am not sure exactly what needs to be zipped, and I am not sure if I am missing/copying config files unnecessarily.

To this point I have: Replicated the database from the t1.micro server into the RDS database. Based on a few queries and browsing the tables, it seems like I did this successfully.

Zipping everything in our t1.micro /var/www/html folder (changing params in local.xml to RDS db host,user,pw), and uploading that folder, but am getting a stack trace:

enter image description here

Also - I originally had installed the sample elastic beanstalk test software successfully, so I know that there are no security group issues between my servers and RDS.

Ultimately, I would love some help on how to deploy customized magento to elastic beanstalk - what files & directories need to be included in the zip, and guidance on what files need to be changed. Any help for a n00b would be greatly appreciated!

  • Check error in error report file : /var/report/
    – MagenX
    Apr 6, 2017 at 7:09

3 Answers 3


Check error in error report file : /var/report/error no display in screen

  • I am getting the following error: SQLSTATE[HY000] [2002] No such file or directory";i:1;s:2373:"#0 /var/app/current/html/lib/Zend/Db/Adapter/Pdo/Mysql.php(111): Zend_Db_Adapter_Pdo_Abstract->_connect(). Any ideas? I've checked local.xml and seems like I have entered everything appropriately. Apr 8, 2017 at 20:17
  • Check with changing from "localhost" to "" in local.xml, if still not working try to restart server
    – user52581
    Apr 9, 2017 at 1:07
  • After changing in local.xml file remove content of var directory.
    – user52581
    Apr 9, 2017 at 1:14
  • I'm trying to connect to a RDS database, so have the hostname pointed to my RDS endpoint. As far as removing contents of var directory, should I delete all of these files, folders and their contents? 58c054c386b55pos-magento-api-1.9.2.zip cache export importexport log package pos report resource_config.json session tmp Apr 9, 2017 at 13:50
  • You have to remove all cache directory
    – user52581
    Apr 9, 2017 at 17:03

The issue was that I had created a backup of my local.xml prior to making my changes and magento was loading both files. I deleted the backup, and everything worked. Found answer here:



First go to your magento directory using command prompt and enable developer mode using below command :

php bin/magento deploy:mode:set developer

Using this command, you can get exception on front end. No need to go to log report to check the exception again and again.

  • This question is related to Magento 1 and you have given hint based on Magento 2. Apr 6, 2017 at 4:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.