Re: Service command

From: Odhiambo Washington <odhiambo_at_gmail.com>
Date: Fri, 14 Jul 2023 09:20:59 UTC
On Fri, Jul 14, 2023 at 10:49 AM Jos Chrispijn <bsduser@cloudzeeland.nl>
wrote:

> Before backing up my MySQL database, I stop the service with the 'service
> mysql-server' stop command
>
> ---
>
> Stopping mysql.
> cronjobs: No such file or directory.
> Waiting for PIDS: 38188.
> server stopped
>
> ---
>
> This works fine, but every time it is displaying a line, saying '
> cronjobs: No such file or directory'
> I do have a directory cronjobs from which the command is given (under sh).
> Also directly as a command under (csh) I get the same display.
>
> Can you tell what is the cause of this?
>
> Best regards,
> Jos
>

Look at the script - /usr/local/etc/rc.d/mysql-server - for clues.
It appears to be non-standard. Did you modify it?

root@svr:/usr/home/wash # service mysql-server stop
Stopping mysql.
Waiting for PIDS: 29087.
root@svr:/usr/home/wash # service mysql-server start
Starting mysql.

I don't see what you are seeing on my server.

Also, I thought that to backup MySQL DBs, you need to have the service
running, then do:

MySQL -uroot -pmypassword DBNAME > DBNAME.sql #To backup a single DB

OR

mysqldump -uroot -pmypassword --all-databases > mysql_backup.sql

If you are stopping the service and just copy over the directory that
contains the DBs files, you are doing it wrong!


-- 
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
[How to ask smart questions:
http://www.catb.org/~esr/faqs/smart-questions.html]