From 816c3b2825e88979145f12977362c1b308c60242 Mon Sep 17 00:00:00 2001 From: Tom Guerin Date: Wed, 2 Apr 2025 16:04:44 +0200 Subject: [PATCH] btsb --- sisr1/automatisation.sh | 5 +++++ sisr1/liste_a_copier | 5 +++++ sisr1/sciptsauvegarde.sh | 16 ++++++++++++++++ 3 files changed, 26 insertions(+) create mode 100644 sisr1/automatisation.sh create mode 100644 sisr1/liste_a_copier create mode 100644 sisr1/sciptsauvegarde.sh diff --git a/sisr1/automatisation.sh b/sisr1/automatisation.sh new file mode 100644 index 0000000..6670d0b --- /dev/null +++ b/sisr1/automatisation.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +files="./etc/crontab + +0 2-3 * * * root scriptsauvegarde.sh \ No newline at end of file diff --git a/sisr1/liste_a_copier b/sisr1/liste_a_copier new file mode 100644 index 0000000..489881d --- /dev/null +++ b/sisr1/liste_a_copier @@ -0,0 +1,5 @@ +root@172.16.0.254:/etc/dhcp/dhcpd.conf +root@172.16.0.254:/etc/default/isc-dhcp-server +root@172.16.0.254:/etc/bind/named.conf.local +root@172.16.0.254:/etc/bind/db.monlabo.lan +root@172.16.0.254:/etc/bind/db.monlabo.lan.rev diff --git a/sisr1/sciptsauvegarde.sh b/sisr1/sciptsauvegarde.sh new file mode 100644 index 0000000..24654a7 --- /dev/null +++ b/sisr1/sciptsauvegarde.sh @@ -0,0 +1,16 @@ +#!/bin/bash + + +backup="/root/backupsvg" +mkdir $backup +while read line +do + scp $line $backup +done < liste_a_copier + + + + +tar -zcvf /root/svg.tar.gz $backup + +