(Migrated) One or two servers?

(This message has been automatically imported from the retired mailing list)

We are starting to work on a Zato solution. We have a new virtual server se=
t up at our hosting partner. Originally we planned that this just just be a=
dev/test server and then we would make a new virtual server later for prod=
uction. But since Zato can easily run several clusters on one virtual serve=
r, another option would be to run both dev/test and production on the same =
Linux instance in order to save an instance (both the money and the tome to=
administer it).

What do other Zato users do? is it OK to run both dev/test and production o=
n the same virtual Linux machine (which is Ubuntu 12/04 LTS, 4GB RAM)?

Finn Gruwier Larsen

Forbrugerr?det Taenk er en uafhaengig medlemsorganisation, der arbejder for=
et Danmark, hvor alle forbrugere kan traeffe et trygt valg.
F? nyheder, informationer om test, tilbud og gode r?d 1-2 gange om ugen. Ti=
lmeld dig vores nyhedsbreve p? taenk.dk/nyhedsbrev

On 02/03/2014 11:58 AM, Finn Gruwier Larsen wrote:

is it OK to run both dev/test and
production on the same virtual Linux machine (which is Ubuntu 12/04 LTS,
4GB RAM)?

4GB of RAM is a lot and there’s a couple of reasons I’d use separate
environments for dev/test and production spread over 3 VMs.

  • You can easily experiment on dev/test without having to worry about
    production’s stability

  • You can grant access only to required personal to each environment
    separately

  • As for how many VMs, I’d say 3 of them in your situation:

  • 1 VM for dev/test with 1-1.5 GB of RAM
  • 1 VM for production servers with 1-1.5 GB of RAM
  • 1 VM for production Redis/Postgres with 1-1.5 GB of RAM

This all depends on how much traffic there will be and how big your
JSON/XML documents are so as always, please benchmark it against your
project’s requirements.

General rules - as of today - are:

  • Each gunicorn_worker needs 50-60 MB of RAM when idle
  • Each AMQP/ZeroMQ/WebSphere MQ channel/outgoing connection needs
    150-180 MB of RAM when idle

I emphasise that it’s the current situation because it will certainly
change with its release. The more features we adde the more will each
gunicorn_worker cache locally hence more RAM will be needed.

Why keep Redis/Postgres on a separate VM? Because Redis sees spikes -
when statistics are computed in background Redis is consulted and it may
mean a couple of thousands of requests within seconds.

This results in temporarily increased CPU usage and that’s why it may be
better to keep Redis on a separate VM.

However, this on the other hand depends on what your cluster does - if
it’s never used during the day and only performs batch operations at
night such a characteristics of Redis may not be of concern, e.g. it
won’t matter if a process completes in 27 or 39 minutes as long as it’s
done by morning.

On 02/03/2014 11:58 AM, Finn Gruwier Larsen wrote:

is it OK to run both dev/test and
production on the same virtual Linux machine (which is Ubuntu 12/04 LTS,
4GB RAM)?

4GB of RAM is a lot and there’s a couple of reasons I’d use separate
environments for dev/test and production spread over 3 VMs.

  • You can easily experiment on dev/test without having to worry about
    production’s stability

  • You can grant access only to required personal to each environment
    separately

  • As for how many VMs, I’d say 3 of them in your situation:

  • 1 VM for dev/test with 1-1.5 GB of RAM
  • 1 VM for production servers with 1-1.5 GB of RAM
  • 1 VM for production Redis/Postgres with 1-1.5 GB of RAM

This all depends on how much traffic there will be and how big your
JSON/XML documents are so as always, please benchmark it against your
project’s requirements.

General rules - as of today - are:

  • Each gunicorn_worker needs 50-60 MB of RAM when idle
  • Each AMQP/ZeroMQ/WebSphere MQ channel/outgoing connection needs
    150-180 MB of RAM when idle

I emphasise that it’s the current situation because it will certainly
change with its release. The more features we adde the more will each
gunicorn_worker cache locally hence more RAM will be needed.

Why keep Redis/Postgres on a separate VM? Because Redis sees spikes -
when statistics are computed in background Redis is consulted and it may
mean a couple of thousands of requests within seconds.

This results in temporarily increased CPU usage and that’s why it may be
better to keep Redis on a separate VM.

However, this on the other hand depends on what your cluster does - if
it’s never used during the day and only performs batch operations at
night such a characteristics of Redis may not be of concern, e.g. it
won’t matter if a process completes in 27 or 39 minutes as long as it’s
done by morning.