Just a try, see if this is worse than before? Yes, you're right...... the
service will be stopped during upgrade. But a temp file will be created if
the service is running and this is really an upgrade, so that this temp
file won't exist if the service is originally stopped...... and in the
%%post script this temp file's existance will be checked, and the service
will be started again accordingly.

%%post

if test $? -eq 2; then
        if test -f /var/lock/subsys/xxx; then
                rm -f /var/lock/subsys/xxx
                service xxx start
        fi
fi


%%preun

if test $? -eq 2; then
        if test -f /var/lock/subsys/xxx; then
                service xxx stop
                touch /var/lock/subsys/xxx
        fi
fi







On Thu, 22 Mar 2001, Michael Brown wrote:

> Not all services support "condrestart" (at least, not on 7.2 - don't know
> about 8.0beta).  Also, don't you stop the service before upgrading its
> files, in which case condrestart wouldn't work because the service in
> question would always be stopped?


Reply via email to