3

I don't have another computer to use rufus and create a persistent USB. For that reason I used my android to make my USB bootable. Yeah, I've created a ext4 partition. I just want to use that as a persistence drive. I have 2 partitions on my usb. 1 is fat 32 which is /dev/sda1. The second one is ext4 which is /dev/sda2. I want to use my /dev/sda2 as a persistence partition. How can I do that?

5

Turn Live USB into Persistence Live USB?

You can not use a FAT32 partition for persistence, for this you need ext2, ext3 or ext4. You can however add a persistence file named writable to a FAT32 partition, but it will be limited to 4GB. A second persistence file named home-rw can also be added for a total of 8GB.

For a persistent partition:

  • Boot the USB using the toram option*.

  • Unplug then replug the USB drive.

  • Open GParted and create a second ext4 partition and label it either writable or casper-rw.

  • Open the system partition and edit /boot/grub/grub.cfg adding a space and the word persistent to the end of the first menuentry right after ---.

If system partition is not editable, ie if it's ISO9660, or an ISO file, you may need to enable persistence each boot, (similar to using toram).

If you decide to use persistence files:

sudo dd if=/dev/zero of=casper-rw bs=1M count=512
sudo mkfs.ext4 -F casper-rw
  • (Replace 512 with the "size in MB" you require, max 4000)
  • For Ubuntu 20.04 and later replace casper-rw with writable
  • For a home-rw partition replace casper-rw with home-rw

Booting toram

After turning on the computer, press Shift.

If it boots BIOS mode a language screen will come up, press Esc. Press F6 then press Esc again. At the bottom of the screen type a space and toram.

If the computer boots to a GRUB menu, type the letter e next to the first menu item. Go down to the line that starts with linux and at the end of it after ---, type a space and toram. Press F10 to boot.

8
  • If I create a persistence file, Will I have to repeat this thing everytime I boot? Aug 2 at 6:35
  • I have created the home-rw and writable file. What should I do next? Aug 2 at 6:38
  • Were you able to edit /boot/grub/grub.cfg? Aug 2 at 6:57
  • there is no grub.cfg file. It doesn't exists Aug 2 at 7:06
  • Where did you put the Ubuntu system files, The FAT32 partition or the ext4 partition? Is there a folder named boot with a folder named grub inside? Is there a folder named cdrom? look inside that. Aug 2 at 7:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.