simple shell script to back homeserver files and VMs to an External Hard disk.
Go to file
2025-04-04 09:52:36 +05:30
backup-server code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
backup.log code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
check-server1 simple shell script to backup home server files and VMs to external drive 2024-11-11 17:59:35 +00:00
check-server2 simple shell script to backup home server files and VMs to external drive 2024-11-11 17:59:35 +00:00
check-server3 code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
debug-usb code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
disable-usb code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
enable-usb code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
peek-backup code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30
README.md documenting crontab configuration in readme.md 2025-04-04 09:52:36 +05:30
unmount-ssd code refined to be autonomous and triggered by cronjob, with effect handeling of usb external drives and usb ports 2025-04-04 09:24:23 +05:30

crontab setup:

sudo crontab -e

select your desired text editor

then add this below line at the end of the crontab file

0 0 * * SUN /usr/bin/sudo /home/arul/back-up-script/backup-server

Explaination:

│ │ │ │ │ │ │ │ │ └── Day of the week (0 - 6) (Sunday = 0) │ │ │ └──── Month (1 - 12) │ │ └────── Day of the month (1 - 31) │ └─────── Hour (0 - 23) └───────── Minute (0 - 59)

0 0 * * SUN:

0 minute: The job runs at the 0th minute (on the hour).

0 hour: The job runs at midnight (00:00).

* day of the month: This means it can run on any day of the month (not restricted).

* month: This means it can run in any month.

SUN: The job runs only on Sundays (which are represented by 0 or SUN in cron).