Find The Web Server User

Find The Web Server User:

The first step to finding the web server user in Apache, go ahead and ssh to your server by using terminal and run below command:

ps aux | egrep '(apache|httpd)';

 

You should get output similar to this:

www-data 19760  0.0  4.5 349176 46152 ?        S    07:59   0:00 /usr/sbin/apache2 -k start                            
www-data 20008  0.0  0.8 342060  8912 ?        S    08:07   0:00 /usr/sbin/apache2 -k start                            
root     20120  0.0  0.0  14992   976 pts/0    S+   08:08   0:00 grep -E --color=auto (apache|httpd)

This output clearly saying that Apache is running by www-data, so you get your webserver user.

 

Was this page helpful?

Leave Comment