diff --git a/src/usbinstall.sh b/src/usbinstall.sh index f2c7284..4d1cf56 100755 --- a/src/usbinstall.sh +++ b/src/usbinstall.sh @@ -240,17 +240,22 @@ fi set_status $"Partitioning $SELECT_USB..." echo $"Partitioning $SELECT_USB..." -sudo fdisk $SELECT_USB < /usr/share/openmamba/usbinstall/fdisk_template &>$LOGFILE +sudo parted $SELECT_USB mktable msdos -s &>>$LOGFILE if [ "$?" != "0" ]; then - errorAndExit $"Error: \"fdisk\" exit with error (see $LOGFILE)" + errorAndExit $"Error:"" \"parted\" "$"exit with error (see $LOGFILE)" fi +sudo parted -s -- $SELECT_USB mkpart primary ext4 0 -1 &>>$LOGFILE +if [ "$?" != "0" ]; then + errorAndExit $"Error:"" \"parted\" "$"exit with error (see $LOGFILE)" +fi + set_pbar 5 set_status $"Formatting $SELECT_USB..." echo $"Formatting $SELECT_USB..." -sudo mkfs.ext3 ${SELECT_USB}1 -L openmamba_live &>>$LOGFILE +sudo mkfs.ext4 ${SELECT_USB}1 -L openmamba_live &>>$LOGFILE if [ "$?" != "0" ]; then - errorAndExit $"Error:"" \"mkfs.ext3\" "$"exit with error (see $LOGFILE)" + errorAndExit $"Error:"" \"mkfs.ext4\" "$"exit with error (see $LOGFILE)" fi sleep 1