Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 211690 - www-servers/apache-2.2.8 init script doesn't handle 'restart' as it should
Summary: www-servers/apache-2.2.8 init script doesn't handle 'restart' as it should
Status: VERIFIED DUPLICATE of bug 110556
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-28 03:35 UTC by Patrick
Modified: 2008-02-28 05:48 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Adds a 'check-if-really-stopped' loop into the stop() function of the apache2 init script (apache2.patch,381 bytes, patch)
2008-02-28 04:04 UTC, Patrick
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick 2008-02-28 03:35:12 UTC
For some time now, I run into the following problem:

# /etc/init.d/apache2 restart
 * Stopping apache2 ...                                                   [ ok ]
 * Starting apache2 ...
httpd (pid 17167) already running                                         [ ok ]

The init script says 'ok', but afterwards apache is actually NOT running.

When running the init script again, you get:

# /etc/init.d/apache2 restart
 * Stopping apache2 ...
httpd (no pid file) not running                                           [ ok ]
 * Starting apache2 ...                                                   [ ok ]

This is far from optimal and should be fixed.

Reproducible: Always

Steps to Reproduce:
1. /etc/init.d/apache2 restart

Actual Results:  
Apache stops, but doesn't get started again, although the init script claims everything worked ok.

Expected Results:  
Apache restarts.
Comment 1 Patrick 2008-02-28 04:04:04 UTC
Created attachment 144808 [details, diff]
Adds a 'check-if-really-stopped' loop into the stop() function of the apache2 init script

I'm sure this could be done better... but as roothorick@#gentoo said: "a quick fix now and an optimal solution later is better than merely an optimal solution later" ;)
Comment 2 Jakub Moc (RETIRED) gentoo-dev 2008-02-28 05:05:37 UTC
Nope, not going to happen.

*** This bug has been marked as a duplicate of bug 110556 ***
Comment 3 Patrick 2008-02-28 05:24:20 UTC
(In reply to comment #2)
> Nope, not going to happen.
> 
> *** This bug has been marked as a duplicate of bug 110556 ***
> 

Thanks for the lesson: We don't want to have workarounds that make buggy software usable. Instead we let everybody write their own workaround and give unhelpful comments to people who suggest a feasible solution in public.

Good that I know that now, so I can adjust my behaviour and be as unhelpful as possible.
Comment 4 Jakub Moc (RETIRED) gentoo-dev 2008-02-28 05:30:45 UTC
The above patch doesn't solve anything, while potentially causing serious issues like being completely unable to do reboot a box gracefully due to infinite stop loop. 

As noted on the original bug, get apache fixed properly upstream.
Comment 5 Patrick 2008-02-28 05:42:55 UTC
(In reply to comment #4)
> The above patch doesn't solve anything, while potentially causing serious
> issues like being completely unable to do reboot a box gracefully due to
> infinite stop loop. 

Ridiculous. Calling '/etc/init.d/apache2 restart' will result in having apache2 not running at all afterwards - is that your idea of something working 'gracefully'?

> As noted on the original bug, get apache fixed properly upstream.

I totally agree. But as has been written before: "a quick
fix now and an optimal solution later is better than merely an optimal solution
later".

And PLEASE oh PLEASE spare the "it's not our responsibility" crap.
Comment 6 Jakub Moc (RETIRED) gentoo-dev 2008-02-28 05:48:20 UTC
We are not interested in hacks; sorry. Since this apparently won't go anywhere in a productive way, please note that this bug is a duplicate and CLOSED.