|
@@ -562,6 +562,9 @@ function restore_database {
|
562
|
562
|
if [ -d $USB_MOUNT/backup/${restore_app_name} ]; then
|
563
|
563
|
echo $"Restoring ${restore_app_name} database"
|
564
|
564
|
local_database_dir=/root/temp${restore_app_name}data
|
|
565
|
+ if [ -d ${local_database_dir} ]; then
|
|
566
|
+ rm -rf ${local_database_dir}
|
|
567
|
+ fi
|
565
|
568
|
function_check restore_directory_from_usb
|
566
|
569
|
restore_directory_from_usb "${local_database_dir}" "${restore_app_name}data"
|
567
|
570
|
if [ ! -f /root/temp${restore_app_name}data/${RESTORE_SUBDIR}/temp${restore_app_name}data/${restore_app_name}.sql ]; then
|