Преглед на файлове

stop crond during long operation

root преди 10 години
родител
ревизия
68f1f5ed1f
променени са 2 файла, в които са добавени 4 реда и са изтрити 3 реда
  1. 1 1
      BackupPC_install.sh
  2. 3 2
      rdx_manager.sh

+ 1 - 1
BackupPC_install.sh

@@ -11,7 +11,7 @@ sed -i -e "s/SELINUX=enforcing/SELINUX=disabled/g" /etc/sysconfig/selinux
 setenforce 0
 
 configure_repo() {
-	yum -y install wget vim htop nmap iftop iotop nmap screen tmux
+	yum -y install wget vim htop nmap iftop iotop nmap screen tmux nano
 	cd /tmp
 	wget -c http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
 	rpm -Uvh epel-release-6-8.noarch.rpm

+ 3 - 2
rdx_manager.sh

@@ -7,7 +7,6 @@ BPC_FILES="/root/RDX_BackupPC/rdx_init.tar.gz"
 
 init_rdx()
 {
-	/etc/init.d/crond stop
 	echo -e "[*] Unmounting RDX "
 	/bin/umount $RDX_PART 2>&1 || echo -e "[x] Error unmounting RDX partition"
 
@@ -17,7 +16,6 @@ init_rdx()
 	echo -e "[*] Creating ext4 filesystem... (this can take severals minutes)"
 	/sbin/mkfs.ext4 $RDX_PART 2>&1 || echo -e "[x] Error during mkfs.ext4"
 
-	/etc/init.d/crond start
 	/sbin/partprobe $RDX_DEVICE
 	check_rdx
 
@@ -68,10 +66,13 @@ check_rdx()
 
 
 if [ -e $BPC_DATAS_DIR/pool ]; then
+	echo -e "[*] Rien à faire"
 	exit 1
 
 else
+	/etc/init.d/crond stop
 	check_rdx
+	/etc/init.d/crond start
 fi