Skip to content

Commit

Permalink
Added some sleeps to allow the disk i/o to catch up, trimmed out some…
Browse files Browse the repository at this point in the history
… more apt cache files
  • Loading branch information
rhempel committed Dec 29, 2013
1 parent 41a393c commit 658080f
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 3 deletions.
4 changes: 2 additions & 2 deletions rootfs-create
Original file line number Diff line number Diff line change
Expand Up @@ -134,11 +134,11 @@ if [ -d ${TARGET_ROOTFS_DIR} ]; then
echo

echo -n " Deleting cached entries from /var/lib/apt/lists ... "
rm `find ${TARGET_ROOTFS_DIR}/var/lib/apt/lists -maxdepth 1 -type f -not -name "lock"`
rm `find ${TARGET_ROOTFS_DIR}/var/lib/apt/lists -maxdepth 1 -type f -not -name "lock"` > /dev/null 2>&1
echo "done."

echo -n " Deleting package lists... "
rm "${TARGET_ROOTFS_DIR}/var/cache/apt/*.bin"
rm ${TARGET_ROOTFS_DIR}/var/cache/apt/*.bin > /dev/null 2>&1
echo "done."
fi
fi
Expand Down
2 changes: 2 additions & 0 deletions sdcard-img-create
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,8 @@ if [ "${YesNo}" = "Yes" ]; then
echo "done"
fi

sleep 5

echo "-------------------------------------------------------------------------------"
echo " Unmapping partitions from ev3dev.img ... "
echo
Expand Down
20 changes: 19 additions & 1 deletion sdcard-img-populate
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ eval mount "/dev/mapper/loop?-ev3dev-1" "./ev3dev-fat32"
eval mount "/dev/mapper/loop?-ev3dev-2" "./ev3dev-ext3"

echo "-------------------------------------------------------------------------------"
echo -n " Copying the uImage and ev3dev.rc.local script to the fat32 partition ... "
echo -n " Copying uImage and ev3dev.rc.local to the fat32 partition ... "

cp -dR rootfs-updates/boot_part/* ev3dev-fat32

Expand Down Expand Up @@ -106,6 +106,24 @@ mkdir ev3dev-ext3/media/mmc_p1

echo "done."

echo "-------------------------------------------------------------------------------"
echo -n " Filling unused sectors on FAT32 partition with zeros ... "

dd if=/dev/zero of=ev3dev-fat32/zero.fill > /dev/null 2>&1
sleep 3
rm ev3dev-fat32/zero.fill

echo "done."

echo "-------------------------------------------------------------------------------"
echo -n " Filling unused sectors on ext3 partition with zeros ... "

dd if=/dev/zero of=ev3dev-ext3/zero.fill > /dev/null 2>&1
sleep 3
rm ev3dev-ext3/zero.fill

echo "done."

echo "-------------------------------------------------------------------------------"
echo " Unmounting ev3dev.img partitions ... "

Expand Down

0 comments on commit 658080f

Please sign in to comment.