Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Can I run Drupal on 256MB VPS hosting ?

I know it depends on many factors, but I mean... can I run few Drupal websites on such VPS.. ?

What are important configuration settings to optimize performances ?

thanks

share|improve this question
    
What kind of traffic you expect? Tens of hits a day? Hundreds? Thousands? More? –  Janne Pikkarainen Nov 5 '10 at 15:36

4 Answers 4

up vote 1 down vote accepted

I had Drupal running with MySQL on a VPS with only 64MB of RAM for about 2 years. So, 256MB will definitely work. Things that I did to get it work with 64MB of RAM:

  1. Configure MySQL to the minimum. On Debian based distributions, the example my-small.cnf provided would be a good sample to use.
  2. Use a light-weight web server like lighttpd/nginx.
  3. Limit the number of php instances running. In lighttpd/nginx, this would involve limiting the number of spawned instances. I could get 2 php-cgi instances running in 64MB.
  4. Use a light-weight MTA like minimal Exim4.
  5. Turn off everything else.

Good Luck.

Edit:

  1. Set vm.swappiness to 1 in /etc/sysctl.conf
  2. Hit the server with a simulated run (use something like siege would do).
  3. Watch the resource usage and ensure that the swap is not used.

The key is to avoid swap usage. So, tune/reduce resources to keep the server from swapping. The easiest thing to do is to reduce the number of PHP instances running.

share|improve this answer
    
One more thing: I've run free -m and I'm currently using 217M of memory and 28M are free. This is the state of my server in stand by (no requests, no traffic). is this too much? What are good values ? thnks –  Patrick Nov 5 '10 at 9:08
    
@Patrick - edited answer. –  sybreon Nov 5 '10 at 15:33

Assuming they're light duty websites and your OS has minimal requirements, I don't see why not.

share|improve this answer

For my heavy Drupal sites everything is ok with approx. 200 MB of RAM for one instance.

share|improve this answer

I'd advise you to find some other hosting where you can change your memory settings using local php.ini or .htaccess (Apache memory) e.g. HeartInternet hosting provider. If you decide to that VPS with the memory limitations, you'll have a lot of troubles, unless it's very simple website (less than 50 modules). Otherwise definitely not. If you save on the hosting, you'll waste your time on shrinking your website, instead of focusing on the functionality.

See as well following Drupal full requirements:

http://drupal.org/requirements

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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