Installing Magento Commerce on DreamHost – Updated for 1.6.0.0
*And Again*
Now using 1.6.0.0 stable.
*Updating Again*
Now updated for Magento 1.5.0.1 stable.
*Another Update*
I’ve gotten a few requests to get this updated for the new version of Magento. This is now done – the same instructions apply with slightly different download locations for the new version of Magento.
*One quick update*
Thanks to Ashley for mentioning that I didn’t add the prefix option as an argument. Added it to the script and updated the content below to show how to use it.
-JJ
There has apparently been quite a few people having trouble with the Magento install on DreamHost. I was among them, so I took the advice of fellow co-workers and used the command line method for installation. It worked, but I figured it could be easier so I threw together a bash script for that purpose. You can grab a copy from the following url and save it to the folder you want magento installed in.
http://files.gimmesoda.com/install_magento.sh
You can also run these commands from the folder you will be installing it to.
wget http://files.gimmesoda.com/install_magento.sh;
wget http://www.magentocommerce.com/downloads/assets/1.6.0.0/magento-1.6.0.0.tar.gz;
chmod 0744 install_magento.sh;
To make it easier you don’t need to hard code any of your variables, rather you just enter them through arguments for the script:
./install_magento.sh
In order to install Magento all the following are required.
-h: MySQL Database Hostname
-d: MySQL Database Name
-u: MySQL Database User
-p: MySQL Database Password
-x: Database Prefix
-a: Magento Shop Address (Example: http://shop.example.com/)
-f: Magento Admin First Name
-l: Magento Admin Last Name
-e: Magento Admin Email Address
-r: Magento Admin Login
-s: Magento Admin Pass (Must have letters and numbers.)
Which ends up looking like this:
./install_magento.sh -h mysql.example.com -d database -u dbuser -p dbpass -x prefix -a http://store.example.com/ -f First -l Last -e admin@example.com -r admin -s adminpass1
If everything worked as expected (running this on DreamHost it should) you’ll be prompted with something similar to this:
SUCCESS: 88dd17d566d65128b6bb9357773d269b
Which is the Magento encryption key and is rather important, so the keep a copy of that key. I’ll be adding a cleanup argument to this script which will remove all files from the install directory, which is useful in the case of errors. If you have any questions just let me know!
This entry was posted by JuanJose on November 10, 2009 at 5:16 am, and is filed under Magento Commerce, Software. Follow any responses to this post through RSS 2.0.You can leave a response or trackback from your own site.
-
#5 written by spike 1 year ago
Hi Jose,
I was wandering for how to install magento in Dreamhost for a couple of hours and found your post here. i hope this really works better then the rest. But sorry to ask this I’m quite new to this shell programming and other stuffs, so can u tell where I’m supposed to type in this command, but any way I created a shell user in my account.But can’t find where to do this. I have a shared hosting account with DH.
Thanks in Advance ! -
Thanks a lot for taking the time to post this, it looked very promising even through installation. The first time it failed because I did not have a number in my admin password. But now it is throwing an error: FAILED
ERROR: Invalid mode for clean() methodDo you have any ideas what would cause this? Is it a pear thing or is this trying to remove the magento directory?
The thing is that my homepage still loads, I was able to submit a poll in the sidebar, but when I go to the admin login page, I enter my credentials and it throws me another error: Error log record number: 391738256155
Do you know how I can view the log?
Thanks again,
Mike -
I ran the shell script exactly as described above, but I am getting the same error I got when I ran it from the code “General error: 1005 Can’t create table ‘./ki_magento/#sql-2872_c506.frm’” I can’t even figure out what table it can’t create.
I also tried installing magento on a MAMP server, that didn’t even give me an error, the installer just doesn’t work.
I have two questions:
1) Any idea what I need to do to get the software installed on dreamhost?
2) Is Magento worth it? I see people posting about other massive problems they have with the software. Is there something I am missing? -
1) Unfortunately I don’t know what caused that error, it sounds more like an SQL permissions issue then an installer problem, but it could be.
2) Personally, yeah I think Magento is worth it. It’s got a steep learning curve, and can be difficult to work with at times, but it’s the only e-commerce software I’ll recommend to clients. -
hi there…any chance that you can add the cleanup to your script? i would def. “buy you a soda” because i’ve tried and failed like 10 times to get this to install. i have followed all the instructions, yet i still get errors at the very end and it takes me about an hour to delete all the files and try again. i have been trying to install straight into the root, but i guess i can create a magento subfolder…and i’ve been using my http://www.domain.com instead of magento.domain.com (which i also tried)
so if your feeling charitable, i could *really* use the help…cheers,
james -
I’ve been trying to use this script to install without success, I think there isn’t a bug in the script but I got stuck at “Access denied for user ‘username’@'mrfantastic.dreamhost.com’ (using password: YES) even though I double checked and see that it is correct…
This may be something else on dreamhost side, but maybe just something I’ve missed. Can anything assist?
-
I’ve been trying to use this script to install without success, I think there isn’t a bug in the script but I got stuck at “Access denied for user ‘username’@’mrfantastic.dreamhost.com’ (using password: YES) even though I double checked and see that it is correct…
This may be something else on dreamhost side, but maybe just something I’ve missed. Can anything assist?
Triple check the password, if you have special characters that would normally be used in the shell, escape those. You can also try changing the MySQL password to something simple, to rule out problems with the password.
If you do find a bug in the script let me know.
Worst case scenario, you can hire me to solve the problem!
-
Thank you very much! I forgot the escape the & sign in my password, and now I’ve just finished.
BTW, I did modified the magento_install.sh file to do 1.4.1.1 install, I just changed very instances of 1.4.1.0 to 1.4.1.1. Works just fine after the change.
I’m glad you got that worked out! As for the version – I’m working on modifying the script so it always installs the latest version without downloading the full source to being with.
The way it is currently setup the script will always update you to the latest version before finishing.
-
for some unknown reason ive followed the isntructions exactly above.
and the script just seems to pause on this lineinstall ok: channel://pear.php.net/XML_Util-1.2.1
When the script hits the point of setting up the database it seems to be taking a good deal of time. Just let the script run and wait for it to finish, I’ve seen it take as long as 5m in some situations.
-
Hi Juan,
I followed your instructions and got the following message. any thoughts?“Running initial setup…
Success
Success
Successfully added: http://connect20.magentocommerce.com/communityFAILED
The URL “http:///” is not accessible.
ERROR: Invalid URI supplied
“ -
an update… I investigated creating a custom ini file as suggested here. …
http://www.magentocommerce.com/wiki/1_-_installation_and_configuration/url-not-accessible-for-dreamhost-and-others-using-custom-php.inihowever when I checked the default php.ini the parameter in question was already set to =On. so I don’t think that is the problem
:/ -
- Comment Feed for this Post
Didn't find any related posts :(
I cannot thank you enough for this script! I have a client who insisted on hosting their newly created Magento site with Dreamhost, and this is the ONLY solution I found that actually worked! You’re a life saver!