I remember this has happened to me once. if there is SELinux, disable it and
try again
Thanks,
Charan


On Fri, Apr 2, 2010 at 9:08 PM, Ravi Roy <ravi.a...@gmail.com> wrote:

>
>
> On Sat, Apr 3, 2010 at 9:13 AM, Nilesh Govindarajan <li...@itech7.com>wrote:
>
>> On 04/03/10 07:53, Ravi Roy wrote:
>>
>>>
>>>
>>> On Fri, Apr 2, 2010 at 9:57 PM, Nilesh Govindarajan <li...@itech7.com
>>> <mailto:li...@itech7.com>> wrote:
>>>
>>>    On 04/02/10 21:52, Ravi Roy wrote:
>>>
>>>        Hi
>>>        I installed Apache/2.2.13 (Unix) on CentOS 5.4. My prolbem is
>>>        that when
>>>        I try to start and stop it using "sudo /etc/rc.d/init.d/httpd
>>>        start /
>>>        stop / restart"
>>>        It gives me the following, I googgled a lot but could not really
>>>        find a
>>>        solution.
>>>        1.Command : $ sudo /etc/rc.d/init.d/httpd start
>>>        Error Message :
>>>        Starting httpd: (98)Address already in use: make_sock: could not
>>>        bind to
>>>        address 0.0.0.0:80 <http://0.0.0.0/> <http://0.0.0.0/> <
>>> http://0.0.0.0:80 <http://0.0.0.0/>
>>>        <http://0.0.0.0/>>
>>>
>>>
>>>        no listening sockets available, shutting down
>>>        Unable to open logs
>>>
>>>  [FAILED]
>>>        2. Command : $ sudo /etc/rc.d/init.d/httpd stop
>>>        Error message :
>>>        Stopping httpd:
>>>  [FAILED]
>>>        3.Command : $sudo /etc/rc.d/init.d/httpd restart
>>>        Error message :
>>>        Stopping httpd:
>>>  [FAILED]
>>>        Starting httpd: (98)Address already in use: make_sock: could not
>>>        bind to
>>>        address 0.0.0.0:80 <http://0.0.0.0/> <http://0.0.0.0/> <
>>> http://0.0.0.0:80 <http://0.0.0.0/>
>>>        <http://0.0.0.0/>>
>>>
>>>
>>>        no listening sockets available, shutting down
>>>        Unable to open logs
>>>
>>>  [FAILED]
>>>        Can sombody help me on this please?
>>>        Thanks!
>>>        -RR
>>>
>>>
>>>    Some other process is already running at port number 80. Use netstat
>>>    -ltnp | grep ':80' to get the process name and pid.
>>>
>>>   Thanks Nilesh, netstat reveals the following :
>>>     tcp        0      0 :::80
>>> :::*                        LISTEN      2056/httpd
>>>     Strange thing I notice is that start / stop / restart fails, but
>>> service is still started, I am just curious if service is failed to
>>> start (as error message explains) how come it is started at the first
>>> place?
>>>     To my view a command 'stop / restart' should kill a started process
>>> and free the port '80' and next initialization should get the  port
>>> without any error.
>>>     My http configuration have 'Listen 80'
>>>     Not much into linux stuff. Forgive me if I am wrong somehere and
>>> correct me please.
>>>     Thanks for your help.
>>>   - RR
>>>
>>>
>> Try using the /sbin/service command instead of this.
>>
>> Also, your httpd is self compiled or installed using yum ?
>>
>> And did you make any alterations (or created) /etc/rc.d/init.d/httpd ?
>>
>>
>> Thanks Nilesh,
>
> I tried ;
>
> command : sudo /sbin/service httpd restart
>
> Error message :
>
> Stopping httpd:                                            [FAILED]
> Starting httpd: (98)Address already in use: make_sock: could not bind to
> address 0.0.0.0:80
> no listening sockets available, shutting down
> Unable to open logs
>                                                            [FAILED]
> I compiled httpd server is myself on CentOS 5.4, I did not make any
> alterations to /etc/rc.d/init.d/httpd.
>
> Thanks
>
> -RR
>
>

Reply via email to