I have just installed owncloud server on my xubuntu and now there are atleast 10 processes of apache2 running on my machine.

when I stop apache service using

sudo service apache2 stop

All processes of apache2 disappear.

is it normal when owncloud server is installed?


Yes thats normal and does not have to do anything with OwnCloud itself but how you have configured apache. In the default installation you would use Apache MPM (Multi-Processing Module) Prefork.

From the Apache Apache MPM prefork documentation:

A single control process is responsible for launching child processes which listen for connections and serve them when they arrive. Apache always tries to maintain several spare or idle server processes, which stand ready to serve incoming requests. In this way, clients do not need to wait for a new child processes to be forked before their requests can be served.

So as more client connection you have as more processes you will get.

You can configure the module in /etc/apache2/mods-enabled/mpm_prefork.conf

# prefork MPM
# StartServers: number of server processes to start
# MinSpareServers: minimum number of server processes which are kept spare
# MaxSpareServers: maximum number of server processes which are kept spare
# MaxRequestWorkers: maximum number of server processes allowed to start
# MaxConnectionsPerChild: maximum number of requests a server process serves

<IfModule mpm_prefork_module>
        StartServers              5
        MinSpareServers           5
        MaxSpareServers          10
        MaxRequestWorkers         150
        MaxConnectionsPerChild   0

You could also use Apache MPM Worker

Check http://www.garron.me for the differences: Understanding Apache 2 MPM (worker vs prefork)

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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