Solved

Errors in configuring Apache -- pls check what's wrong with my configurations.

Posted on 2001-08-25
5
234 Views
Last Modified: 2010-03-04
Hi, experts,

     I tried to configure my Apache (installed together with Linux Redhat 7.1) with the

following steps :-

1. Open the file " /etc/httpd/conf/httpd.conf " for editing
2. I edited the virtual host section with

   <VirtualHost www.owen.com>
   ServerAdmin webmaster@owen.com
   Servername www.owen.com
   DocumentRoot /home/httpd/html/owen
   ErrorLog /logs/owen_error
   CustomLog /logs/owen_access common
   </VirtualHost>

3. Next, on the terminal I typed " /etc/rc.d/init.d/httpd restart "
4. But   Stopping httpd ----- [OK]
            Starting httpd   ----- [FAILED]

Can experts pls tell me what has gone wrong ?
Pls kindly help :)
Thankx
0
Comment
Question by:shchong2
  • 2
  • 2
5 Comments
 
LVL 4

Expert Comment

by:gizmola
ID: 6427753
Sounds like you have an error in your httpd.conf file, and apache won't start up in that situation.

You VirtualHost section doesn't look right to me.  Assuming your using Host Header Name, it Looks like you should have (replace 192.168.0.10 with a valid IP for your server):

<NameVirtualHost 192.168.0.10)
<VirtualHost 192.168.0.10>
rest of your settings ok
</VirtualHost>
0
 

Author Comment

by:shchong2
ID: 6428503
Hi, I somehow manage to use Apacheconf to set a virtual host

--> 10.1.1.20 (which is also the ip for my NIC card)
it has its directory under /home/httpd/html/batigol
and manage to access the "index.html" I've created

now my question is
==================
1. when I try to create another Virtualhost say 10.1.1.99
   (I currently only activate one NIC with ip=10.1.1.20)
   when I restart httpd, it failed

   does this mean I can only have one Virtualhost with one NIC card ?

2. if not, how to make more virtual host configured ?

3. this Linux is connected to a LAN
   (this LAN consists of
     -- a Cisco 5505 switch (IP=10.1.1.1)
     -- 4 pc with windows NT (IP=10.1.1.11 to 10.1.1.14)

    But when I try to open Internet Explorer form a pc, say from the pc of 10.1.1.12. In the IE, I type http://10.1.1.20 , but I couldn't access the index.html page. What should I do ?

Pls kindly help
:)
   
0
 
LVL 4

Accepted Solution

by:
gizmola earned 100 total points
ID: 6429159
There are two types of virtual host support, either IP Based or Host Header Name based.

The answer to your question depends on what is available/what you want to do.  If you have IP's to burn, you can make the virtual hosts configuration IP based.  

In order to do that you must have the IP's bound to an interface.  I already explained how you could configure using Host Header names in my previous message.

It appears you are trying to be IP based, using internal non-routable addy's.  In that case, you should have no problem adding as many vhosts as you want, each with a seperate IP.  

However, as you explained, you only have one IP addy bound to the NIC in your Linux server.  You will need to bind additional IP addresses to that NIC before this will work.

How exactly to do this (configure multiple IP's bound to a single NIC) depends on the linux distribution you're using.



0
 

Expert Comment

by:HandyAndy
ID: 6441060
As gizmola said, it does sound like an error in httpd.conf.

You can check the httpd.conf for errors by using "apachectl" (IIRC, it's installed in somewhere like /usr/sbin from the RH RPM.) You use it by typing "apachectl configtest" (without the quotes...). It can also be used to start, stop and restart httpd.
0
 

Author Comment

by:shchong2
ID: 6460249
Sorry I was tied to the "D-link gigabit NIC" problem for sometime

also busy with the ftp problem

not touching apache for sometime, but coming to it now
i guess i should close this question now
but will post new one if I need some more help

one final question if you don't mind :-
========================================
I've switch back to "Redhat 7.0" (for the sake of the d-link gigabit card).
Previously in Redhat 7.1, I've been using "apacheconf" (a GUI Apache Configurator)
Now I couldn't find the "apacheconf" program.

(1)Pls tell me how to know if this program is installed
(2)If not installed, how to get it installed

p/s: I installed all the packages come along with Redhat 7.0 (which took up more than 2 GB of disk space).

:)

 
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Magento error 9 72
how to configure and install nginx ? 1 434
Clearing cache in word press. 3 50
Domino Website - Redirection 12 54
As Wikipedia explains 'robots.txt' as -- the robot exclusion standard, also known as the Robots Exclusion Protocol or robots.txt protocol, is a convention to prevent cooperating web spiders and other web robots from accessing all or part of a websit…
Introduction As you’re probably aware the HTTP protocol offers basic / weak authentication, which in combination with the relevant configuration on your web server, provides the ability to password protect all or part of your host.  If you were not…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now