خرید بک لینک

Dear Community,

I'm trying to setup a Backup that should be done every time the Server is shutdown.
The Precondition is that the Backup requires mysql and apache to run before it shut's down.

What i've did so far was i've created a file in /etc/init.d

Code:

root@fortuna:/etc/init.d# ll backupos
-rwxr-xr-x 1 root root 1237 Mai 13 08:23 backupos*
Containing this header

Code:

#!/bin/sh
### BEGIN INIT INFO
# Provides:          backupos
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog apache2 mysql
# Should-Start:
# Should-Stop:       apache2
# Default-Start:
# Default-Stop:      6
# Short-Description: Backup of OS DB
# Description:       Will backup the Database
#  Of OS.
### END INIT INFO

echo "backup" > /home/adminuser/backup.txt
Then i've added it using

Code:

sudo update-rc.d backupos stop 0 6
and got the following message

Code:

update-rc.d: waing: start and stop actions are no longer supported; falling back to defaults
Then i've checked the /rcX.d/ folders

Code:

root@fortuna:/etc# find . -name *backupos*
./init.d/backupos
./rc6.d/K01backupos
and did just poweroff.

But the Script is never executed.

Now 2 Questions:
1.st what does the

Code:

update-rc.d: waing: start and stop actions are no longer supported; falling back to defaults
Message say and how can i prevent it
2nd Why the Script is not execute?

برچسب: نویسنده: استخدام کار تاريخ: جمعه 24 ارديبهشت 1395 ساعت: 15:14

صفحه بندی