what is the fastest, stable vps configuration?

Events happening in the community are now at Drupal community events on www.drupal.org.
socialtalker's picture

hello. i have two linode accounts. the larger one will have aegir/barrucuda/octopus on it when i get it to working again. the Linode 512 vps account will have a detroit community site in drupal, it will be a large site with lots of features. i am using ubuntu 10.4, because i like the word ubuntu.
i will probably start with drupal 7 acquia, i have put two smaller sites like a radio station with voipdrupal on the account later, the linode 512 is too small for aegir, so i am looking for a good stackscript or manual nginx configuration. i am not a developer or web master, i just cant afford to hire one just now, so i have to do it myself. i am learning most
basically i am looking for the nginx configuration or stackscript that will give me the most bang with the least memory usage as of march 2012. i have come across a few stackscripts, including the ones on the home page of this group. the thing is i am not sure what if anything should be added to the scripts.
do i use
Varnish?
memchache?
apc?
boost?
what else?
do i use them all, or just two or three of them? which ones? which stackscript should i start with? if a stackscript has nginx and memcache, do i add varnish?
can i use them with a CDN?
i would like some thoughts/advice on what people are using. thanks.

Comments

My suggestions

perusio's picture

in the back of a napkin.

  1. Nginx with php-fpm.

  2. APC, using it also for drupal caching.

  3. Use the Nginx cache.

  4. No Memcache.

  5. No Varnish.

  6. Alternatively to the Nginx cache use Boost.

thanks so much. i hate when i

socialtalker's picture

thanks so much. i hate when i have too many choices, it really puts me in a tail spin!

Why nginx+php-fpm, not

chilic's picture

Why nginx+php-fpm, not nginx+apache+mod_php?

Because the OP

perusio's picture

requested the setup to be the leaner and meaner possible in resource usage. Apache doesn't qualify. Furthermore fpm has a much more features for managing the PHP processes than Apache.

apache doesn't qualify by

locuse's picture

apache doesn't qualify

by what subjective measure?

properly-configured (meaning, you tweak it system-wide for your particular usage, obviously) nginx/varnish3/apache24/mod_php/memcached/mysql/apc/drupal7 runs, in my case, on a linode 1024 without issue.

of course, less can run on less.

... fpm ... much more features ... processes

depends on what you're trying to tune, and whether you're looking at your system-wide resource utilization

e.g., apc opcode caching has great utility, particularly on low-resource sites.

using mod_php, a single apc opcode cache can be shared across all mod_php processes. using fcgid/fastcgi, apc is not shared across multiple processes -- there's one memory-using apc cache for each php/cgi process. if you tweak down to a single php process, then the mutli-process 'flexibility' is moot anyway.

php process tuning and process separation, in addition to separate apache process tuning, is certainly of value when there are multiple tenants on the webserver. but, that scenario shouldn't be on a low-resource VPS to begin with.

Not exactly so

perusio's picture

(...)
using mod_php, a single apc opcode cache can be shared across all mod_php processes. using fcgid/fastcgi, apc is not shared across multiple processes -- there's one memory-using apc cache for each php/cgi process. if you tweak down to a single php process, then the mutli-process 'flexibility' is moot anyway.

In fact php-fpm is completely compatible with an opcode cache and shared memory models.

php-fpm is compatible with

chilic's picture

php-fpm is compatible with shm model in APC only?
What about xcache and eAccelerator?

The same applies

perusio's picture

xcache and eAccelerator are both shared memory based too.

i thought nginx and apache

socialtalker's picture

i thought nginx and apache were the same thing?

now if we only had a good

gateway69's picture

now if we only had a good linode stack script for your kick ass drupal nginx setup :)

i am looking at this script

socialtalker's picture

http://vpsbible.com/vps-setup-guides/stackscripts/lemp-stack-ubuntu-32bi...
by the guv

its a memberships site. so you wont see the code in the windows..(NO that is not an affliate link) it cost 15 bucks a year, but it was soooooo worth it. let me tell you early last year i was so confused and lost on how this vps bash script, command line stuff worked, i felt like my brain was in pain. never in my life was i more confused. i felt like my ...anyway l , this site literally guided me by the hand how managing a vps works.
anyhoo i am familiar with this site, so i will try his script and incorporate Perusio's suggestions into the stackscript. mainly adding:
2.
APC, using it also for drupal caching.
3.
Use the Nginx cache.
although i have to confess i dont know how to do 2 or 3 to a script. .

You should not hate when you

joelwallis's picture

You should not hate when you have many choices, but when you have no one choice, socialtalker.

that correct, but only if you

socialtalker's picture

that correct, but only if you know what you are doing!

High performance

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: