Debian This forum is for the discussion of Debian Linux.
Notices
Welcome to
LinuxQuestions.org , a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free.
Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please
contact us . If you need to reset your password,
click here .
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
10-17-2009, 05:01 AM
#1
LQ Newbie
Registered: Oct 2009
Posts: 5
Rep:
Where is the httpd -S command
I have a Debian Etch distribution.
My "Apache Cookbook" (O'Reilly, December, 2007) tells me that "It is particularly instructive to run httpd -S and observe the virtual host configuration as Apache understands it"
However, when I type-in the command, I am told "-bash: httpd: command not found" which is particularly uninstructive.
I've had a good rummage around in my server but I can't pin-point exactly where this command is?
Thanks to anyone who can help.
10-17-2009, 05:11 AM
#2
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: back to Arch
Posts: 16,660
I assume that Apache is installed....
Did you try running the command as root (First do "su -", so that you get root's environment)
Try this in a terminal (as root)
Code:
find / -name "*httpd*" (may take a while)
OR
##if the command is there, then so should be the man page.
10-17-2009, 05:23 AM
#3
LQ 5k Club
Registered: May 2001
Location: Belgium
Distribution: Slackware current
Posts: 8,460
10-17-2009, 05:43 AM
#4
LQ Newbie
Registered: Oct 2009
Posts: 5
Original Poster
Rep:
Thanks for the quick responses.
find / -name "*httpd*"
Code:
/etc/apache2/httpd.conf
/usr/share/doc/apache2-doc/manual/programs/httpd.html
/usr/share/doc/apache2-doc/manual/programs/httpd.html.ko.euc-kr
/usr/share/doc/apache2-doc/manual/programs/httpd.html.en
/usr/share/doc/libnet-server-perl/examples/httpd.gz
/usr/share/doc/apache2.2-common/examples/apache2/original/httpd.conf.gz
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-multilang-errordoc.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-languages.conf.gz
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-vhosts.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-ssl.conf.gz
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-info.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-userdir.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-manual.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-dav.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-default.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-mpm.conf
/usr/share/doc/apache2.2-common/examples/apache2/original/extra/httpd-autoindex.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-multilang-errordoc.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-languages.conf.gz
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-vhosts.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-ssl.conf.gz
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-info.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-userdir.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-manual.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-dav.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-default.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-mpm.conf
/usr/share/doc/apache2.2-common/examples/apache2/extra/httpd-autoindex.conf
/usr/lib/apache2/modules/httpd.exp
man httpd
Code:
No manual entry for httpd
apache2 -V
Code:
Server version: Apache/2.2.3
Server built: Jul 29 2009 09:49:56
Server's Module Magic Number: 20051115:3
Server loaded: APR 1.2.7, APR-Util 1.2.7
Compiled using: APR 1.2.7, APR-Util 1.2.7
Architecture: 32-bit
Server MPM: Prefork
threaded: no
forked: yes (variable process count)
Server compiled with....
-D APACHE_MPM_DIR="server/mpm/prefork"
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
-D APR_USE_SYSVSEM_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D DYNAMIC_MODULE_LIMIT=128
-D HTTPD_ROOT=""
-D SUEXEC_BIN="/usr/lib/apache2/suexec"
-D DEFAULT_PIDLOG="/var/run/apache2.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_LOCKFILE="/var/run/apache2/accept.lock"
-D DEFAULT_ERRORLOG="logs/error_log"
-D AP_TYPES_CONFIG_FILE="/etc/apache2/mime.types"
-D SERVER_CONFIG_FILE="/etc/apache2/apache2.conf"
It looks like I don't have it. What should I do to get it?
My /etc/apt/sources.list looks like this (if it's of any use)
Code:
# debian etch i386 port defaults
deb http://ftp2.ca.debian.org/debian etch main contrib non-free
deb http://ftp2.ca.debian.org/debian-security etch/updates main contrib non-free
Thanks!
10-17-2009, 06:34 AM
#5
LQ Veteran
Registered: Nov 2005
Location: Annapolis, MD
Distribution: back to Arch
Posts: 16,660
http://httpd.apache.org/docs/2.2/
This describes the option you are talking about, but also says that "httpd" is not the normal way to start the daemon.
In your output from find, there seem to be some manuals. but no "httpd" command.
I've never used Apache, so we've pretty much hit the wall as far as getting help from me.......
10-17-2009, 09:58 AM
#6
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,442
RedHat changed Apache's name to "httpd". Debian didn't, so you won't find an httpd binary. I don't use Apache either, but doesn't apache2 -S work?
10-17-2009, 11:00 AM
#7
LQ Newbie
Registered: Oct 2009
Posts: 5
Original Poster
Rep:
@AlucardZero : That did the trick! Thanks
12-17-2010, 03:41 PM
#8
LQ Newbie
Registered: Dec 2010
Posts: 5
Rep:
apache2 -S wont work in Ubuntu
you will get this error:
apache2: bad user name ${APACHE_RUN_USER}
use this instead:
apache2ctl - S
12-22-2011, 10:23 AM
#9
LQ Newbie
Registered: Dec 2011
Posts: 1
Rep:
I'm using Ubuntu11.10
In Ubuntu you can use the command:
apache2 -l
to show compiled in modules.
Thread Tools
Search this Thread
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
All times are GMT -5. The time now is 07:03 AM .
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know .
Latest Threads
LQ News