Skip to content

Commit

Permalink
check if already mounted + noreread
Browse files Browse the repository at this point in the history
  • Loading branch information
woodp committed Feb 1, 2018
1 parent aebf695 commit 66054e3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ partprobe
# Format and mount drive
echo ';' | sfdisk /dev/sdd
partprobe
mkfs -t ext3 /dev/sdd1 --no-reread
mkfs -t ext3 /dev/sdd1
mkdir -p /data2
if grep -qs '/data2' /proc/mounts; then
echo "already mounted."
Expand Down
4 changes: 2 additions & 2 deletions virtual-machines/single-vm/extensions/linux/format-disk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ partprobe
# Format and mount drive
echo ';' | sfdisk /dev/sdc
partprobe
mkfs -t ext3 /dev/sdc1 --no-reread
mkfs -t ext3 /dev/sdc1
mkdir -p /data1
if grep -qs '/mnt/foo' /proc/mounts; then
if grep -qs '/data1' /proc/mounts; then
echo "already mounted."
else
mount /dev/sdc1 /data1
Expand Down

0 comments on commit 66054e3

Please sign in to comment.