fstools: fix snapshot support
authorLuka Perkov <luka@openwrt.org>
Tue, 10 May 2016 22:36:44 +0000 (22:36 +0000)
committerLuka Perkov <luka@openwrt.org>
Tue, 10 May 2016 22:36:44 +0000 (22:36 +0000)
Signed-off-by: John Crispin <john@phrozen.org>
SVN-Revision: 49337

package/system/fstools/files/snapshot

index a0e0ec0c334ca72086c3e30c62ae988c61ff1bde..c1a5b733f3c70e2bb5f2e83d3589e2f10832760f 100644 (file)
@@ -24,14 +24,14 @@ do_config_unpack() {
 }
 
 do_snapshot_push() {
-       cd /volatile
+       cd /volatile/upper
        tar czf /tmp/snapshot.tar.gz *
        snapshot_tool write
        reboot
 }
 
 do_config_push() {
-       cd /volatile
+       cd /volatile/upper
        tar czf /tmp/config.tar.gz *
        snapshot_tool config_write
 }
@@ -66,7 +66,7 @@ do_convert() {
        . /lib/upgrade/common.sh
        ubus call system upgrade
        touch /tmp/sysupgrade
-       cd /overlay
+       cd /overlay/upper
        tar czf /tmp/snapshot.tar.gz *
        kill_remaining TERM
        sleep 3
@@ -82,7 +82,7 @@ convert)
 esac
 }
 
-[ -d /volatile ] && {
+[ -d /volatile/upper ] && {
 case $1 in
 push)
        do_snapshot_push