Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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.
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.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Okay, technically this isn't a Linux question, but I have the server "running" on a Slackware 9.1 box. 24-hours ago it was serving up pages, ugly as they were, just fine. I started working on the pages, cp'd them to my server public share, mv'd them to the html docs directory and then, for some reason or another, it was late at night, I deleted the contents of the directory. Then I realized that I had, during a braindead moment, also mv'd my httpd-2.0.xxx files and directories into that same directory. Why is something I may never figure out. How to fix it is why I'm here.
I have downloaded and reinstalled Apache. Apparently, it's running. I can get to the www.myserver.com page, if it were only there. But the other, virtual hosted sites will not come up. I get an error indicating that the document could not be found.
I am including my httpd.conf file for any of you gurus to inspect and tell me where I dropped the ball on my reinstall. The httpd.conf file is pretty much as provided with apache with my virtual hosts added at the end. I have had to cut a lot of the comments out in order to get within the posting limits. I didn't really understand a lot of what's going on from the comments, anyway. If someone would like to give guidance as to what I can/need to take out to improve performance on this, I'd appreciate any lessons I can learn.
thanx in advance.
#
# Based upon the NCSA server configuration files originally by Rob McCool.
#
# This is the main Apache server configuration file.
#
### Section 1: Global Environment
#
#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# Do NOT add a slash at the end of the directory path.
#
ServerRoot "/usr/local/apache2"
#
# The accept serialization lock file MUST BE STORED ON A LOCAL DISK.
#
<IfModule !mpm_winnt.c>
<IfModule !mpm_netware.c>
#LockFile logs/accept.lock
</IfModule>
</IfModule>
#
# ScoreBoardFile: File used to store internal server process information.
#
<IfModule !mpm_netware.c>
<IfModule !perchild.c>
#ScoreBoardFile logs/apache_runtime_status
</IfModule>
</IfModule>
### Section 2: 'Main' server configuration
#
# The directives in this section set up the values used by the 'main'
# server, which responds to any requests that aren't handled by a
# <VirtualHost> definition. These values also provide defaults for
# any <VirtualHost> containers you may define later in the file.
<IfModule !mpm_winnt.c>
<IfModule !mpm_netware.c>
#
# If you wish httpd to run as a different user or group, you must run
# httpd as root initially and it will switch.
#
User gary
Group #100
</IfModule>
</IfModule>
#
# ServerAdmin: Your address, where problems with the server should be
# e-mailed. This address appears on some server-generated pages, such
# as error documents. e.g. admin@your-domain.com
#
ServerAdmin gdv@xxxxxxx.net
BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully
BrowserMatch "^WebDrive" redirect-carefully
BrowserMatch "^WebDAVFS/1.[012]" redirect-carefully
BrowserMatch "^gnome-vfs" redirect-carefully
<IfModule mod_ssl.c>
Include conf/ssl.conf
</IfModule>
### Section 3: Virtual Hosts
#
# VirtualHost: If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs-2.0/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.
#
# Use name-based virtual hosting.
#
NameVirtualHost *:80
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
#
#<VirtualHost *:80>
# ServerAdmin webmaster@dummy-host.example.com
# DocumentRoot /www/docs/dummy-host.example.com
# ServerName dummy-host.example.com
# ErrorLog logs/dummy-host.example.com-error_log
# CustomLog logs/dummy-host.example.com-access_log common
#</VirtualHost>
Originally posted by david_ross I seem to be getting forbidden messages as if apache can't read the files. You have apache running with slightly odd permissions:
User gary
Group #100
Does this user have read access to files and read/execute access to directories?
Thanks for the rapid response, david.
Initially, as in when you tried, no. the folder and files belonged to root in the root group. I have chown'd to gary and chgrp'd to users the mmtic folder, which is the one I currently have html docs in. I don't know if this will help you help me, but I still get a message stating mmtic.intelli-tek.us can not be found.
I get the error that mmtic.intelli-tek.us can't be found too but that is not an apache problem it is a dns problem. If I look up the domain there is no ip address returned:
rossy - trigger - Sat Nov 20 21:51:03
~> dig mmtic.intelli-tek.us +short
rossy - trigger - Sat Nov 20 21:52:02
~>
Cool. At least now I can rest easy that it's not my server. The original site lyme.intelli-tek.us is serving up just fine (from that same directory on the server) so now I have to figure out why mmtic.intelli-tek.us isn't working. Do I need to talk with my friendly DNS server guru to get that added? I don't recall having to do that for the other site name, but it's been a few months and that was my first effort at setting up (1) a web server and (2) virtual hosts on a web server. My second effort isn't going as smoothly.
I know this is a little delayed, but all I had to do was talk with the DNS admin and get an entry for mmtic.intelli-tek.us and wait about five minutes.
Now, to see if I can keep from crashing the server whilest I learn about Apache admin and all the joy involved in that.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.