summaryrefslogtreecommitdiff
path: root/script
diff options
context:
space:
mode:
authorMyoungJune Park <mj2004.park@samsung.com>2017-11-02 17:19:37 +0900
committerMyoungJune Park <mj2004.park@samsung.com>2017-11-02 17:20:43 +0900
commite6011c76ced62504364024c2bfd856deab1f65af (patch)
tree73ed785b73f410db8a0cfe654369f5a528a78ea8 /script
parenta7a5b789b81570c4cc106faaea9899403a979327 (diff)
parent3f07f2cda3e23c51979b0bbf83f4b2ca2a4de1a1 (diff)
downloadfactory-reset-submit/tizen_4.0/20171102.082126.tar.gz
factory-reset-submit/tizen_4.0/20171102.082126.tar.bz2
factory-reset-submit/tizen_4.0/20171102.082126.zip
Change-Id: Idbdf974a747664573889fc1a32e5026a9c2e4564 Signed-off-by: MyoungJune Park <mj2004.park@samsung.com>
Diffstat (limited to 'script')
-rwxr-xr-xscript/run-factory-reset.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/script/run-factory-reset.sh b/script/run-factory-reset.sh
index 800a413..5486906 100755
--- a/script/run-factory-reset.sh
+++ b/script/run-factory-reset.sh
@@ -125,7 +125,8 @@ fs_ready() {
/bin/mkdir -p $USRDATADIR
/bin/mount $USRDATADIR
mret=`/bin/grep "$USRDATADIR " /proc/mounts | /usr/bin/awk '{print $1}'`
- device=`/bin/grep "$USRDATADIR" /etc/fstab | /usr/bin/awk '{print $1}'`
+ #device=`/bin/grep "$USRDATADIR" /etc/fstab | /usr/bin/awk '{print $1}'`
+ device=`blkid --match-token PARTLABEL=user -o device`
device=`/usr/bin/readlink -f $device`
if [[ "z$mret" != "z" && "$mret" != "$device" ]]; then
echo "$mret != $device" >> $logfile
@@ -136,6 +137,7 @@ fs_ready() {
# mount failed. format and remount
echo "$USRDATADIR mount failed. format and retry to mount again" >> $logfile
fstype=`/bin/grep "$USRDATADIR " /etc/fstab | /usr/bin/awk '{print $3}'`
+ fstype=`blkid --match-token PARTLABEL=user -o device`
/sbin/mkfs.$fstype $device -F
/bin/mount -t $fstype $device $USRDATADIR
fi