[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#245412: preinst script does not stop apache, thus postinst fail



tags 245412 + unreproducible
tags 245412 + moreinfo
stop

Hi Clément

On Fri, 23 Apr 2004, [iso-8859-15] Clément 'nodens' Hermann wrote:

> Package: apache
> Version: 1.3.29.0.2-5
> Severity: important
>
> When upgrading from 1.3.29 (sid), apache is not stopped (only when
> upgrading from 1.3.28 or lower).
> So, when 'invoke-rc.d apache start' is called in postinst, it fails
> (apache is already running).

This is the log of my upgrade from -4 to -5:

Fetched 1457kB in 0s (7059kB/s)
Preconfiguring packages ...
(Reading database ... 108795 files and directories currently installed.)
Preparing to replace apache-utils 1.3.29.0.2-4 (using .../apache-utils_1.3.29.0.2-5_i386.deb) ...
Unpacking replacement apache-utils ...
Preparing to replace apache-common 1.3.29.0.2-4 (using .../apache-common_1.3.29.0.2-5_i386.deb) ...
Unpacking replacement apache-common ...
Preparing to replace apache 1.3.29.0.2-4 (using .../apache_1.3.29.0.2-5_i386.deb) ...
Stopping web server: apache.
Unpacking replacement apache ...
Setting up apache-utils (1.3.29.0.2-5) ...
Setting up apache-common (1.3.29.0.2-5) ...

Setting up apache (1.3.29.0.2-5) ...
Installing new version of config file /etc/init.d/apache ...
Replacing config file /etc/apache/modules.conf with new version
Starting web server: apache.

As you can see apache is stopped correctly.

> I don't understand why apache should only be stopped if version <=
> 1.3.28, so I can't provide a patch... :/

You are looking in the wrong place. Please check:

http://www.debian.org/doc/debian-policy/ch-maintainerscripts.html#s-unpackphase

The first script called is prerm. The reason why the same code is repeated
in preinst is to workaround a bug in woody packages.

Fabio

-- 
<user> fajita: step one
<fajita> Whatever the problem, step one is always to look in the error log.
<user> fajita: step two
<fajita> When in danger or in doubt, step two is to scream and shout.



Reply to: