[ubuntu-uk] Shutdown mysql with cron
Daniel Case
danielcase10 at googlemail.com
Wed Aug 11 00:22:57 BST 2010
Hi Paul,
Are you sure that stops mysql? You should be stopping the daemon: "mysqld"
not mysql
Daniel
On 11 August 2010 00:13, Paul Willis <paul.willis at me.com> wrote:
> Hi
>
> I'm trying to shutdown MySQL on an Ubuntu 10.04 server for half hour
> everyday using cron but I can't get it to work
>
> Using "sudo crontab -e" I entered the line...
>
> 15 19 * * * root /etc/init.d/mysql stop
>
> In the syslog I can see it fired at the time I expected...
>
> Aug 10 19:15:01 domU-11-11-11-11-CD-11 CRON[5984]: (root) CMD (root
> /etc/init.d/mysql stop)
>
> But MySQL is still running.
>
> If I run the same /etc/init.d/mysql stop as root in the command line MySQL
> stops just fine.
>
> Any ideas why MySQL doesn't quit or where I might look for clues?
>
> Just for extra info: this server is a MySQL replication slave running on
> Ubuntu on Amazon EC2 and I want to shutdown MySQL, snapshot the volume,
> restart MySQL
>
> Cheers
>
> Paul
>
> --
> ubuntu-uk at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
> https://wiki.ubuntu.com/UKTeam/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.ubuntu.com/archives/ubuntu-uk/attachments/20100811/687a4c62/attachment.htm
More information about the ubuntu-uk
mailing list