Jun 012010
 

My WordPress host on Dreamhost share hosting, it’s superexcellence, but, you know, Dreamhost has the 7M MAX upload filesize limit, so I can’t do something. I checked the Dreamhost Discussion Forum and google www, find a real and simple way to resolve it. Here’s how:

  1. Set up your domain for FastCGI
    Login your Dreamhost, enter Manage Domains, Edit your domain setup, in Web Options->PHP mode, select ‘PHP 5 FastCGI’, as below: 

    PHP5 FastCGI

    PHP5 FastCGI

  2. Download DreamHost Custom PHP.ini from DeamHost Scripts and Tips.
  3. Extract the dh-phpini.php from dh-phpini.zip and upload it to you website root.
  4. Open dh-phpini.php in you browse. Example: http://www.yoursite.com/dh-phpini.php.
  5. Then, this result shows,

    Install Completed

    Install Completed

  6. After install, this script create ‘cgi-bin’ folder in you website root, including ‘php.ini’ files in the folder, and add this lines in you .htaccess file, AddHandler fastcgi-script fcg fcgi fpl
    AddHandler php-fastcgi .php
    Action php-fastcgi /cgi-bin/dispatch.fcgi
  7. Default, the Max upload file size increase to 20M, if you want to change to more, edit php.ini file in ‘cgi-bin’ folder like this,post_max_size = 50M
    upload_max_filesize = 50M

  52 Responses to “How to increase UPLOAD MAX FILE SIZE for DREAMHOST?”

  1. Awesome worked a treat for me – thanks

  2. Hey, thanks for posting this! It worked for me. However, I tried to change the post_max_size and upload_max_filesize to 50M and couldn’t get it to work. I changed lines 473 and 578 in the php.ini file in the cgi-bin folder. I also tried just adding those 2 lines at the end of the php.ini file. Any help you can give me would be greatly appreciated! Thanks!

  3. @Sarah
    Maybe you also should edit the memory_limit parameter in lines 317. My setup is

    memory_limit = 90M;

    good luck.

  4. It’s worth noting that, whenever you make changes to the new php.ini file, you’ll probably need to restart FastCGI for them to take effect.

    Unfortunately you can’t do this from the Dreamhost Control Panel. You need to log in via SSH, and issue the command “killall -9 php5.cgi” to restart FastCGI.

    For more info about SSH on Dreamhost, go here: http://wiki.dreamhost.com/Ssh
    For more info on custom php.ini’s and restarting FastCGI, go here: http://wiki.dreamhost.com/PHP.ini#Modified_existing_php.ini_but_not_seeing_the_changes.3F

    Hope that helps.

  5. Thanks, Zarino! I couldn’t figure out for the life of me why max filesize changes weren’t taking effect. Restarting fastcgi did it!

  6. Thanks a lot guys this is the best way to have your own. php.ini on dreamhost. I also had to do the step described by Zarino

  7. Hi there!

    Just a note regarding killing processes on DreamHost. It isn’t advisable to use the killall command as the process might actually be named differently on the server. The safe way to restart your fgci process after editing your custom php.ini file is to simply “touch” the dispatcher.

    $ touch ~/domain.com/cgi-bin/dispatch.fcgi

    After issuing the above command, Apache will see the dispatcher has changed (touch changes the file’s timestamp) and will reload the process as soon as someone loads up another PHP page on your website.

    I was always going to make a companion Live PHP.INI Editor (so that admins can alter common PHP.INI directives via their web browser) and have it automate the touch process. If I get time this weekend I’ll try get around to it.

    But first, procrastination.

    Glad you like the script!

    Regards,

    Shayne

  8. great work thanks! it works for me 🙂

  9. thank you so much! worked like a charm for me too and no restart was necessary!

  10. thank you,it works!

  11. Wow – that wasn’t really as hard as I thought it was going to be! Thank you!

  12. This really saved me alot of time. I noticed a bit of a drag in the posts import time, but that is because there was thousands of posts to import. I actually did it like 3 times but then I noticed it took. Thanks again for the useful info.

  13. Thanks!
    Your php.ini link’s broken.
    Here’s one that works http://sxi.sabrextreme.com/dh-phpini

  14. Jeebus, that dh-phpini.php is one of the ugliest pieces of code I’ve ever seen. Totally unreadable. Which sets off my sketch alarm. I would not use this. If it was even the tiniest bit legible i could say for sure, but I would never, ever use something like this on my server.
    If i find or write an alternative, i will post it here 🙂
    aaron

  15. I followed all of the instructions and when viewing the cgi-bin/test/info.php file it reflected the changes. However, the WordPress dashboard still shows a 1MB upload max and won’t allow anything larger than this. Any suggestions?

  16. It’s worth noting that file upload size is now controlled in the Network Admin section under settings. You’ll still need to change your PHP limits, but you’ll also need to change the limits in this section as well. Note: (100MB = 100 * 1024 * 1024KB = 104857600KB) No need to add KB at the end. You’ll also need to increase the upload limits you set for your network sites if you’re using multi-site.

  17. Does dreamhost gives up to 100mb?

  18. this is great and it worked perfectly for me. Thanks a lot

  19. excelent script ! it work like a charm for me !!!
    big THX !

  20. Check This Out…

    […]Here are some of the sites we recommend for our visitors[…]…

  21. The talk within the finest worn cellular phone repayment for traffic is built to be even again impetuously asserted amidst consumers. There are lots of brands from which to prefer with a lot of models. Then you scarcity capabilities to take into account, and also battery. In the end you sine qua non distinguish the rhyme that’s produce with a view you, and also fit’s your own private tolerance of style. The going round overcome three hottest employed cellular phones at one’s disposal would be the BlackBerry Bead, Your Apple IPhone, as well as the Motorola talkabout Blade. All three or more of such are imaginary candidates and each has their very own durability as articulately as frail spots. We wishes look at each solitary of these respectively so that you can decide with a view yourself which of such you have the courage of one’s convictions pretend desire be best.
    Used cellphones for sale

  22. Hello Web Admin, I noticed that your On-Page SEO is not that great, for one you do not use all three H tags in your post, also I notice that you are not using bold or italics properly in your SEO optimization. On-Page SEO means more now than ever since the new Google update: Panda. No longer are backlinks and simply pinging or sending out a RSS feed the key to getting Google PageRank or Alexa Rankings, You now NEED On-Page SEO. So what is good On-Page SEO?First your keyword must appear in the title.Then it must appear in the URL.You have to optimize your keyword and make sure that it has a nice keyword density of 3-5% in your article with relevant LSI (Latent Semantic Indexing). Then you should spread all H1,H2,H3 tags in your article.Your Keyword should appear in your first paragraph and in the last sentence of the page. You should have relevant usage of Bold and italics of your keyword.There should be one internal link to a page on your blog and you should have one image with an alt tag that has your keyword….wait there’s even more Now what if i told you there was a simple WordPress plugin that does all the On-Page SEO, and automatically for you? That’s right AUTOMATICALLY, just watch this 4minute video for more information at. WordPress Seo Plugin

  23. It’s actually a great and useful piece of info. I am happy that you just shared this useful information with us. Please keep us up to date like this. Thanks for sharing.

  24. Related.. Trackback…

    […]the time to read or visit the content or sites we have linked to below the[…]…

  25. Looking around…

    While I was surfing yesterday I noticed a great post concerning…

  26. Looking around…

    While I was surfing today I saw a excellent article about…

  27. 2012 Fashion ideas18…

    Mistakes are a part of being human. Appreciate your mistakes for what they are: precious life lessons that can only be learned the hard way. Unless it’s a fatal mistake, which, at least, others can learn from….

  28. 2012 Fashion ideas29…

    The Constitution gives every American the inalienable right to make a damn fool of himself….

  29. 2012 Fashion ideas22…

    If at first you don’t succeed, find out if the loser gets anything….

  30. decrg…

    vugunhmvy mwexz qwxrdmd riej iwojticqueblntb…

  31. Website Trackback Link…

    […]the time to read or visit the content or sites we have linked to below the[…]…

  32. Super Website…

    […] that is the end of this article. Here you’ll find some sites that we think you’ll appreciate, just click the links over[…]…

  33. herbal remedies Nice blog here! Also your web site loads up fast! What host are you using? Can I get your affiliate link to your host? I wish my website loaded up as quickly as yours lol…

    Nice blog here! Also your web site loads up fast! What host are you using? Can I get your affiliate link to your host? I wish my website loaded up as quickly as yours lol…

  34. Herbal Remedies I rattling suchlike when you plow this identify of lug part your posts. Perhaps could you preserve this?…

    I rattling suchlike when you plow this identify of lug part your posts. Perhaps could you preserve this?…

  35. 2012 Fashion ideas 27…

    Nobody in life gets exactly what they thought they were going to get. But if you work really hard and you’re kind, amazing things will happen….

  36. reverse phone number Excellent post. I was checking continuously this blog and I am impressed! Very useful info particularly the last part 🙂 I care for such information a lot. I was looking for this certain information for a very long time. Thank yo…

    Excellent post. I was checking continuously this blog and I am impressed! Very useful info particularly the last part 🙂 I care for such information a lot. I was looking for this certain information for a very long time. Thank you and best of luck….

  37. invest liberty reserve I think this is one of the most important information for me. And i am glad reading your article. But should remark on few general things, The site style is perfect, the articles is really great : D. Good job, cheers…

    I think this is one of the most important information for me. And i am glad reading your article. But should remark on few general things, The site style is perfect, the articles is really great : D. Good job, cheers…

  38. 2012 Fashion ideas bb…

    You know that children are growing up when they start asking questions that have answers….

  39. Trackback Link…

    […]Here are some of the sites we recommend for our visitors[…]…

  40. Super Website…

    […] that is the end of this article. Here you’ll find some sites that we think you’ll appreciate, just click the links over[…]…

  41. Check These Out…

    […]check below, are some totally unrelated websites to ours, however, they are most trustworthy sources that we use[…]…

  42. Websites You Should Visit…

    […]very few websites that happen to be detailed below, from our point of view are undoubtedly well worth checking out[…]…

  43. Yeast Infection Treatment…

    […]following are a couple of urls to websites which we link to seeing as we believe they will be truly worth checking out[…]…

  44. Superb website…

    […]always a big fan of linking to bloggers that I love but don’t get a lot of link love from[…]……

  45. Angry Birds Online…

    […]listed below are a handful of listings to online websites that we link to for the fact we believe these are seriously worth browsing[…]…

  46. Entry Level Mechanical Engineering Jobs…

    Entry Level Mechanical Engineering Jobs…

Sorry, the comment form is closed at this time.