Difference Between Apachectl and Httpd .Is apachectl -k start or httpd -k start both the same .we have a pid file by the name httpd.pid but not apachectl.pid what is the difference .
pgrep httpd|head -5
6894
7971
8439
8946
9038
$ pgrep apache|head -5
$ pgrep apachectl|head -5
$ ps -ef|grep httpd|wc -l
58
$ ps -ef|grep apache|wc -l
71
$ ps -ef|grep apachectl|wc -l
1
$ ps -ef|grep apache|head -5
root 6894 1 0 23:13 ? apache-2.2.22//bin/httpd -k start
root 6895 6894 0 23:13 ? apache-2.2.22/logs/error.log_%Y%m%d 10M
root 6896 6894 0 23:13 ? apache-2.2.22/logs/access.log_%Y%m%d 10M
root 6897 6894 0 23:13 ? apache-2.2.22/logs/access.log_%Y%m%d 10M
root 6898 6894 0 23:13 ? apache-2.2.22/logs/ssl_request.log_%Y%m%d 10M
daemon 6900 1 0 23:13 ? 00:00:00 LLAWP /apache-2.2.22/conf/WebAgent.conf -APACH
root 6906 6894 0 23:13 ? apache-2.2.22/logs/mod_jk.log_%Y%m%d 10M
daemon 8946 6894 0 23:25 ? /apache-2.2.22//bin/httpd -k start
daemon 9255 6894 0 23:27 ? apache-2.2.22//bin/httpd -k start
daemon 9617 6894 0 23:29 ? /apache-2.2.22//bin/httpd -k start
ps -ef|grep httpd|head -5
root 6894 1 0 23:13 ? apache-2.2.22//bin/httpd -k start
daemon 8439 6894 0 23:21 ? /apache-2.2.22//bin/httpd -k start
daemon 8946 6894 0 23:25 ? apache-2.2.22//bin/httpd -k start
daemon 9038 6894 0 23:26 ? apache-2.2.22//bin/httpd -k start
daemon 9255 6894 0 23:27 ? apache-2.2.22//bin/httpd -k start
daemon is user having in httpd.conf
getent passwd daemon
daemon:x:2:2:daemon:/sbin:/sbin/nologin
cat httpd.conf|grep -i daemon
# httpd daemons, you will need to change at least LockFile and PidFile.
User daemon
Group daemon
can anyone explain clearly the different outputs regarding the each command.