ubuntu 19 move root to external usb drive on a Pi 4

The following link defines the procedure I used to move root on the sd card to a 32 gib flash drive.   here is the link.   Note:  the link provided has an error at the end but is corrected here as you read on.

At the end of the above link is some procedure which does not work.  It tells you to edit the /boot/cmdline.txt file and put the following in the file:  root=/dev/sda1 rootfstype=ext4 rootwait  I could not get this to work but as for the rest of the procedure at the above link it does work. It was as if the pi ignored reading the /boot/cmdline.txt file.

Here is the part that needs to change at the end:

  1.   cd /boot/firmware
  2. cp nobtcmd.txt nobtcmd.txt_save
  3. in the nobtcmd.txt file remove the entry “root=LABEL=writable rootfstype=ext4 elevator=deadline rootwait fixrtc” and replace with “root=/dev/sda1 rootfstype=ext4 rootwait<— your external usb flash drive with rooot
  4. be sure to save the file
  5. reboot your system.
  6. when up do a df and you should see:  /dev/sda1 #### #### #### 28% /
    notice /dev/sda1 mounted to mount point “/
  7. sudo vi /etc/vfstab and add the /dev/sda line to look like the following:
    1. #LABEL=writable / ext4 defaults 0 0
      /dev/sda1 / ext4 defaults,noatime 0 1
      LABEL=system-boot /boot/firmware vfat defaults 0 1

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.