The script /etc/init.d/my_mount is executed during shutdown. I can show this by logging into a dedicated file ( i.e. echo >> xx )
Comparing timestamps I see that rsyslog is always terminated before my script is started.
On 02/04/2012 09:36 PM, kay dilbert wrote:
>
> I want to run a script during shutdown sequence before syslog has been
> terminated.
i believe it would help to say what version of which operating system
you are running (because if running 12.1 the answer might be different
if you are using systemv or systemd)…
and, it might be nice to know which desktop environment you are using,
if any, because it might be possible to have the DE call the script as
it shuts down…
but, i don’t know (as you have not said, where i can find it) if it is a
script you need executed as yourself (normal user) or root
user…because that will have an impact on the answer…
on the other hand, i’m not smart enough to figure out what you are
trying to do–i guess it is clear to all the previous answer givers, but
not me…
Hi,
I’m using 12.1 with systemd and KDE. Latest patches installed.
The script shall be executed by root and mount some truecrypt containers during boot. During shutdown those containers shall be unmounted.
My log shows that the script is executed in both cases, i.e. during boot with parameter start and during shutdown with parameter stop. Thus I can mount and umount. Just syslogging is not possible during shutdown.
On 2012-02-05 12:26, kay dilbert wrote:
> My log shows that the script is executed in both cases, i.e. during
> boot with parameter start and during shutdown with parameter stop. Thus
> I can mount and umount. Just syslogging is not possible during shutdown.
The problem is that few people know about systemd scripts. I could help
with systemv, but not with systemd. You could try posting on the opensuse
mail list, because one or two of the systemd maintainers read around there.
–
Cheers / Saludos,
Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)