Last active
August 5, 2016 06:57
-
-
Save bliz937/944aec0417669f7e495d4c94388ee996 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
UN_MOUNT="/dev/sdb" | |
IMAGE="/home/home/image.img" | |
while [ 1 ]; do | |
umount $(UN_MOUNT)* | |
if [ $? -eq 0 ]; then | |
dd if=$(IMAGE) of=$(UN_MOUNT) | |
fi | |
sleep 5 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment