Closed hoonetorg closed 8 years ago
This works also with systemd on el7 distries. service mysql start/stop will be redirected to systemctl start/stop mysql. should be the same for Debian, Ubuntu 16.04+
Thanks for the PR but I'm not sure if I should merge it because I think it can cause issues on older distributions.
I understand your concerns about backward compatibility. On the other hand all major distributions switched to systemd now and there restoring backups with pyxtrabackup must be broken, am I wrong? The "service" command can be used on sysv and systemd as I said. A colleague told me a Debian Lenny would not have a service command (I did not verify :) ).
Probably it's better to
For me it is fixed (I compiled an rpm for el7 with the fix and put it in a repo :) )
I've started to debate about this in #32
And from that comment https://github.com/deviantony/xtrabackup-scripts/issues/32#issuecomment-159010689
I do not want to add more code to manage service handling depending on the system.
In order to work with the majority of systems, I think that it would be better to let the user manage the service by himself. I'd accept a PR to remove the service management from the tool and let the user manage the service with an updated procedure.
In the meantime, I'll merge your PR as, as you said, most new distros should support it.
Released and pushed to pypi.
:+1:
…ons nowadays)