summaryrefslogtreecommitdiffstats
path: root/abs/core-testing/LinHES-config/restore_km_db_chroot.sh
diff options
context:
space:
mode:
authorJames Meyer <james.meyer@operamail.com>2008-12-14 16:25:54 (GMT)
committerJames Meyer <james.meyer@operamail.com>2008-12-14 16:25:54 (GMT)
commit6526e29a9d5425c0d294f7a376956b8440cb5631 (patch)
treebdc2ea49837dceb377dda0c3e98c7e4686cc5f97 /abs/core-testing/LinHES-config/restore_km_db_chroot.sh
parent15f49f7b2cb3016c36b981641703b7a13951f28d (diff)
downloadlinhes_pkgbuild-6526e29a9d5425c0d294f7a376956b8440cb5631.zip
linhes_pkgbuild-6526e29a9d5425c0d294f7a376956b8440cb5631.tar.gz
linhes_pkgbuild-6526e29a9d5425c0d294f7a376956b8440cb5631.tar.bz2
if /myth/backup/mythconverg.sql is not present check for the file in /root/backup/
closes FS#60
Diffstat (limited to 'abs/core-testing/LinHES-config/restore_km_db_chroot.sh')
-rw-r--r--abs/core-testing/LinHES-config/restore_km_db_chroot.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/abs/core-testing/LinHES-config/restore_km_db_chroot.sh b/abs/core-testing/LinHES-config/restore_km_db_chroot.sh
index 2f5ba72..7ff6faf 100644
--- a/abs/core-testing/LinHES-config/restore_km_db_chroot.sh
+++ b/abs/core-testing/LinHES-config/restore_km_db_chroot.sh
@@ -30,11 +30,11 @@ if [ $SystemType = "Master_backend" -o $SystemType = "Standalone" ]
pacman --noconfirm -R mythdb-initial
pacman --noconfirm -S mythdb-initial
- if [ -f /myth/backup/mythconverg.sql.gz ]
+ if [ -f $DBFILE ]
then
echo "restoring old database"
- gunzip -c /myth/backup/mythconverg.sql.gz > /myth/backup/mythconverg.sql
- mysql mythconverg < /myth/backup/mythconverg.sql
+ gunzip -c $DBFILE > /tmp/mythconverg.sql
+ mysql mythconverg < /tmp/mythconverg.sql
else
echo "Could not restore old database, mythconverg.sql is missing."
touch /tmp/.upgrade_db_failed
@@ -47,7 +47,7 @@ if [ $SystemType = "Master_backend" -o $SystemType = "Standalone" ]
fi
fi
done
- rm -f /myth/backup/mythconverg.sql
+ rm -f /tmp/mythconverg.sql
else
exit 0
fi