On Wed, 08 Oct 2014 11:26:26 -0500, Marek Novotny wrote:
> I am just now starting to learn it. It does boot and shut down almost
> instantly. It's pretty fast.
Just depends on what is done when.
> I've read a lot of the concerns regarding systemd and a lot of it comes
> down to two things:
>
> 1. fear that it will hang a system
> 2. A belief that it doesn't follow the spirit of UNIX
My bitch/complaint is systemd's fault logic testing seems to be pretty
poor at best.
In the past I had my mysql database corrupted on reboot.
Solution, create a script to shut down apps using database, then shut
down mysqld. Now that I have done that, I am seeing a 15 second delay
with named. FRAP, ok add named to apps to shut down. Still seeing
message shutting down.
WTF. Ok, issue a systemctl stop mysqld, then same for named, and run
new_boot_logs.
Well that works so add 18 second delay prior to issuing
the reboot or shutdown mesg.
Double FRAP, sill seeing occasional 15 second timeout on named, and
worse, now seeing 5 minute shutdown of mysqld. You know the one
already shutdown.
Snippet of code from my new_boot_logs script follow:
_cmd=reboot
#****************************
#* shutdown these apps first
#****************************
_servers="mythbackend named postfix mysqld dhcpd httpd"
for _serv in $_servers ; do
_state=$(systemctl is-active $serv.service 2> /dev/null)
if [ $? -eq 0 ] ; then
if [ "$_state" = "active" ] ; then
systemctl stop $_serv
fi
fi
done
(snipped a bunch of code deleting log files and copying /dev/null
into log files)
sleep 18
echo "
Running $_cmd"
sleep 1
$_cmd
exit
#************************ end new_boot_logs ******************************