0

I am trying to create a live persistent usb bootable stick. I cant figure out what is wrong and it is not working. Terminal out of mkusb is as follows:

start [mkusb 11.0.5] @ 2017-01-01 11:49:37 AM
---------------------------------------------------------------------------
Current directory=/home/gediz
main: usbonly=true
main: liveonly=true
No input file specified yet
main: source=''
TERM=xterm
ubuntu
---------------------------------------------------------------------------
menu_shell:
imagefile=/mnt/hgfs/ACTIVE_SOFTWARE/Other OS/ubuntu-16.04.1-desktop-amd64.iso
The iso file SHOULD BE loop mounted on a temporary file READ-ONLY:
mount: /dev/loop0 is write-protected, mounting read-only
disk_name_type=desktop
Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64 _found_ in iso-file
Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64 _not_ in any possible target drive
Booted from: /dev/sda
ans=u
ans=
---------------------------------------------------------------------------
menu_shell:
---------------------------------------------------------------------------
menu_shell:
imagefile=/mnt/hgfs/ACTIVE_SOFTWARE/Other OS/ubuntu-16.04.1-desktop-amd64.iso
Booted from: /dev/sda
ans=1
***** tu=/dev/sdb ****************************************************
selected target partition table: 'msdos'
mount: /dev/loop0 is write-protected, mounting read-only
 Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64 
---------------------------------------------------------------------------
chk4ubuntu_upgrades: mkusb

can set the security upgrade action (the default action of the persistent
live system when security upgrades are available). This method works for
Ubuntu family operating systems and some 're-spins'. You are installing
Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64

This can change 'Download and install automatically' to 'Display immediately'
set security upgrade action to 'Display immediately'
---------------------------------------------------------------------------
mount: /dev/loop0 is write-protected, mounting read-only
select_boot_system: [if installed, use] usb-pack_efi=false
'/mnt/hgfs/ACTIVE_SOFTWARE/Other OS/ubuntu-16.04.1-desktop-amd64.iso' is identified as the source ISO file
<pre>
MODEL            NAME   FSTYPE LABEL      MOUNTPOINT  SIZE
Cruzer Glide 3.0 sdb                                 29.8G
                 ├─sdb1 ntfs   usbdata               22.6G
                 ├─sdb2 vfat                            1M
                 ├─sdb3 vfat   ubu1604164             122M
                 ├─sdb4                               1.4G
                 └─sdb5 ext4   casper-rw              5.7G
</pre>
Using the file '/usr/share/mkusb/grub.cfg'
Clean for a GUID partition table
GPT fdisk (gdisk) version 0.8.10

Partition table scan:
  MBR: protective
  BSD: not present
  APM: not present
  GPT: present

Found valid GPT with protective MBR; using GPT.

Command (? for help): This option deletes all partitions and creates a new protective MBR.
Proceed? (Y/N): 
Command (? for help): 
Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING
PARTITIONS!!

Do you want to proceed? (Y/N): OK; writing new GUID partition table (GPT) to /dev/sdb.
Warning: The kernel is still using the old partition table.
The new table will be used at the next reboot.
The operation has completed successfully.
Wipe the first megabyte (mibibyte) to get a clean boot area
1024+0 records in
1024+0 records out
1048576 bytes (1.0 MB) copied, 1.49029 s, 704 kB/s
lsblk: /dev/mmcblk?: not a block device
---------------------------------------------------------------------------
 Selected percentage of remaining space for persistence = 20 
---------------------------------------------------------------------------

lsblk: sdb3: failed to initialize sysfs handler
preparing /dev/sdb3  ------------------------------------------------
1024+0 records in
1024+0 records out
1048576 bytes (1.0 MB) copied, 0.97066 s, 1.1 MB/s
umount: /dev/sdb3: not mounted
mkfs.fat 3.0.27 (2014-11-12)
/dev/sdb3 has 64 heads and 32 sectors per track,
hidden sectors 0x1000;
logical sector size is 512,
using 0xf8 media descriptor, with 249856 sectors;
drive number 0x80;
filesystem has 2 32-bit FATs and 1 sector per cluster.
FAT size is 1922 sectors, and provides 245980 clusters.
There are 32 reserved sectors.
Volume ID is 1430fe73, no volume label.

preparing /dev/sdb1  ------------------------------------------------
1024+0 records in
1024+0 records out
1048576 bytes (1.0 MB) copied, 0.833496 s, 1.3 MB/s
umount: /dev/sdb1: not mounted
Cluster size has been automatically set to 4096 bytes.
Creating NTFS volume structures.
Creating root directory (mft record 5)
Creating $MFT (mft record 0)
Creating $MFTMirr (mft record 1)
Creating $LogFile (mft record 2)
Creating $AttrDef (mft record 4)
Creating $Bitmap (mft record 6)
Creating $Boot (mft record 7)
Creating backup boot sector.
Creating $Volume (mft record 3)
Creating $BadClus (mft record 8)
Creating $Secure (mft record 9)
Creating $UpCase (mft record 0xa)
Creating $Extend (mft record 11)
Creating system file (mft record 0xc)
Creating system file (mft record 0xd)
Creating system file (mft record 0xe)
Creating system file (mft record 0xf)
Creating $Quota (mft record 24)
Creating $ObjId (mft record 25)
Creating $Reparse (mft record 26)
Syncing root directory index record.
Syncing $Bitmap.
Syncing $MFT.
Updating $MFTMirr.
Syncing device.
mkntfs completed successfully. Have a nice day.
preparing /dev/sdb5  ------------------------------------------------
1024+0 records in
1024+0 records out
1048576 bytes (1.0 MB) copied, 0.922333 s, 1.1 MB/s
umount: /dev/sdb5: not mounted
mke2fs 1.42.12 (29-Aug-2014)
Creating filesystem with 1481472 4k blocks and 370944 inodes
Filesystem UUID: 9b06bf50-b1ff-4a60-956b-709ae2ac3b34
Superblock backups stored on blocks: 
    32768, 98304, 163840, 229376, 294912, 819200, 884736

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done 

mount: /mnt/hgfs/ACTIVE_SOFTWARE/Other OS/ubuntu-16.04.1-desktop-amd64.iso is already mounted
fatlabel: warning - lowercase labels might not work properly with DOS or Windows
tune2fs 1.42.12 (29-Aug-2014)
---------------------------------------------------------------------------
source=/mnt/hgfs/ACTIVE_SOFTWARE/Other OS/ubuntu-16.04.1-desktop-amd64.iso
---------------------------------------------------------------------------
item 60
umount: /dev/sdb3: mountpoint not found
mount /dev/sdb3 /tmp/tmp.tbI9gMJvTc
mount: special device /dev/sdb3 does not exist
 '/dev/sdb3' could not be mounted 
umount: /dev/loop-control: not mounted
umount: /dev/loop1: not mounted
umount: /dev/loop2: not mounted
umount: /dev/loop3: not mounted
umount: /dev/loop4: not mounted
umount: /dev/loop5: not mounted
umount: /dev/loop6: not mounted
umount: /dev/loop7: not mounted
/usr/sbin/mkusb: line 3339:  2962 Terminated              tail -f "$tailfile"
      2963                       | zenity --progress --title="$version - preparing persistent live drive ..." --percentage=0 --auto-close --no-cancel --window-icon="/usr/share/icons/hicolor/48x48/apps/mkusb.png" 2>> "/dev/null"
Cleanup after mkusb finished :-)
Zenity error log-file 'zerrlog'=/tmp/tmp.JjJD0x6y2Y

2 Answers2

1
  1. I will try to help you, and fix the bug, if there is one in the current version of mkusb. So I suggest, that you update mkusb to the current stable version, mkusb - 12.0.0-1ubuntu5 alias mkusb-dus, and try again. You were using mkusb 11.0.5. Several bugs are fixed between these two versions.

    Install and use mkusb according to the mkUSB-quick-start-manual.pdf.

    If you have the stable PPA already, ppa:mkusb/ppa, you can run the following commands

    sudo apt-get remove mkusb
    sudo apt-get update
    sudo apt-get install mkusb mkusb-nox usb-pack-efi
    
  2. What the log tells me, is that you boot from /dev/sda and there are problems with the partition /dev/sdb3 (of the target device). Could it be that the system is using /dev/sdb3 as the boot partition or EFI partition? (This might be a bug.)

  3. What happens if you boot with the target drive unplugged? Plug it in after booting the computer, and start mkusb after that. I hope it works, otherwise please post the new log file.


Edit:

Test with Lubuntu 16.04.1 LTS (a linux only test)

I tested with mkusb-dus version 12.0.2 from the unstable PPA, ppa:mkusb/unstable, and could not reproduce the bug in Lubuntu 16.04.1 LTS in BIOS mode (neither booted an installed nor a persistent live system). I tried also in UEFI mode (booting from a persistent live drive) but could not reproduce the bug. I tested with two almost identical pendrives present during boot.

Analysis of the test case of @sk1tt1sh (using LiLi in Windows)

  • I tested mkusb in a (persistent) pendrive made with LiLi running Ubuntu 15.04 (amd64).

  • There was a similar pendrive as the target drive (also made with LiLi).

  • First test: I booted with both pendrives plugged in, and there was confusion. It seemed that it booted from one of the drives and used persistence from the other drive. This created problems for mkusb (also the current mkusb-dus), because both drives were locked and it was not possible to unmount the partition(s) on any of the drives.

  • Second test: I booted with only one of the drives plugged in, and plugged in the other drive when the operating system was running. Then mkusb could create its persistent live system into the other drive. It was not necessary to delete any partitions before starting mkusb.

  • Comments: A work-around in the first test case might be to boot to RAM (with the boot option toram). Then at least one of the drives would be released and possible to use as a target device.

It is possible that there were other conditions and other things were happening for the original poster @ Gediz GÜRSU as well as for @sk1tt1sh.

Conclusion

It works for me to boot with only one drive drive plugged in, to avoid this confusion. The target drive, where you want to create a new persistent live system, can be plugged in when the operating system is running.

I need not delete any partitions before starting mkusb-dus, but there seems to be cases, that I have not tested, where it is necessary.

sudodus
  • 47,684
1

There appears to be an issue with how the DUS/mkusb tool deal with existing partitions. The route that was successful for me is as follows:

  1. Boot a live ubuntu, or if you have a full install use that
  2. Plug in the target drive and click the launcher symbol and type "Disks" (no quotes)
  3. Select the target flash drive and delete any and all partitions
  4. Use DUS/GUIDUS/mkusb and go through the normal persistent drive creation steps.

This worked for me two times, wherein the drives both experienced that issue.

-sk1t

sk1tt1sh
  • 136
  • 3