Friday, 11 September 2020

Ubuntu 20.04 Focal Fossa (a Madagascar wild cat) on USB and dual boot install Dell XPS 13 Windows 10

Ubuntu 20.04 Focal Fossa (a Madagascar wild cat) on USB

https://en.wikipedia.org/wiki/Fossa_(animal)

The fossa is a cat-like, carnivorous mammal endemic to Madagascar. It is a member of the Eupleridae, a family of carnivorans closely related to the mongoose family Herpestidae. Wikipedia


I have installed linux from CD(DVD?) last few times. 

USB needed this time . . . 


Create a BASIC linux bootable USB installer: 

 download Ubunto 20.04 .iso image. 

    https://releases.ubuntu.com/20.04/

    Ubuntu 20.04.1 LTS (Focal Fossa)

 Use ubuntu "startup disk creator" utility to write it to USB key.

Disadvantage: image not writable, extra space on USB key cannot be written to.

 (iso9660 NOT WRITEABLE):

https://ubuntu.com/tutorials/create-a-usb-stick-on-ubuntu#1-overview


Create a linux bootable USB with writable partition: <- much better

 download Ubunto 20.04 .iso image. 

 Install mkusb and mkusb-plug tools. (sudo apt add repository for mkusb and apt-get install). 

 Run mkusb-plug, selecting "live drive with usbdata partition" and select the .iso file and USB device. 

See detail here on different methods to create bootable linux USB keys:

https://askubuntu.com/questions/1181854/how-is-it-easier-to-make-a-persistent-live-drive-with-ubuntu-19-10


You now have Ubuntu on a USB stick, bootable and ready to go.

With a bootable Ubuntu USB stick, you can:


Install or upgrade Ubuntu

Test out the Ubuntu desktop experience without touching your PC configuration

Boot into Ubuntu on a borrowed machine or from an internet cafe

Use tools installed by default on the USB stick to repair or fix a broken configuration


Dual boot install Dell XPS 13 Windows 10. Install for kate's laptop.

"Install ubuntu alongside Windows" == Installing dual boot Ubuntu and Windows:

Backup your stuff, read many docs. 

CAVEAT! BEWARE! Installs like this could go wrong, your windows stuff would still be there. Probably. Recovering from a problem could be quite tricky. If you have pretty common computer/hardware then most likely all will be easy, fine no problem.

Disable windows Fast Boot (optional).

Disable Secure Boot (windows UEFI ~= bios settings)

Create free disk space for linux install,

  open windows "create and format hard disk partitions" and shrink disk. 

These pages have decent detailed instructions:

https://itsfoss.com/install-ubuntu-1404-dual-boot-mode-windows-8-81-uefi/

https://hackernoon.com/installing-ubuntu-18-04-along-with-windows-10-dual-boot-installation-for-deep-learning-f4cd91b58557

https://linuxconfig.org/how-to-install-ubuntu-20-04-alongside-windows-10-dual-boot

Wow. The grub menu test on the Dell XPS 13 is teeeeny tiny.

The install of linux went easy, exactly as with instructions.

Disable secure boot/fast boot was already done. 

Getting  UEFI menus to boot into bios took some fiddling.


Writeable usb boot:

https://askubuntu.com/questions/1181854/how-is-it-easier-to-make-a-persistent-live-drive-with-ubuntu-19-10

mkusb-minp - small stand-alone shellscript that can use this new feature in Ubuntu 19.10. It works with Debian 10 too.

mkusb-plug - small set of shellscripts that can use this new feature in Ubuntu 19.10. It works with Debian 10 too. I think you will find things easier with this new and very safe tool with a graphical user interface.

https://unix.stackexchange.com/questions/565250/cannot-mount-live-usb-drive-as-read-write


$ sudo mkusb-plug 

source file: '/home/xxxx/Downloads/ubuntu-20.04.1-desktop-amd64.iso'

--{vfat|exfat|ntfs}

*** usbfs ***

spawn bash -c xorriso-dd-target -plug_test -trust_lsblk_udev  | tee /tmp/tmp.WoL3W0SOhv


Caused by option -plug_test: Attempt to find the desired device

by watching it appear after being plugged in.


Step 1:

Please make sure that the desired target device is plugged _out_ now.

If it is currently plugged in, make sure to unmount all its fileystems

and then unplug it.

Press the Enter key when ready.

 

Found and noted as _not_ desired:  sda nvme0n1  


Step 2:

Please plug in the desired target device and then press the Enter key.

 

Waiting up to 10 seconds for a new device to be listed .... found: sdc

Now waiting 5 seconds to let it settle .........

Found and noted as desired device:  sdc

sdc : YES : usb+ has_iso9660+ has_vfat+ : FLASH Drive_SM_USB20 
Repeating test of target device with elevated permissions:
target device: /dev/sdc
 sdc : YES : usb+ has_iso9660+ has_vfat+ : FLASH Drive_SM_USB20  
         task: '--ntfs'
  source file: '/home/james/Downloads/ubuntu-20.04.1-desktop-amd64.iso'
target device:  /dev/sdc

MODEL          NAME FSTYPE  LABEL                     SIZE
Drive_SM_USB20 sdc  iso9660 Ubuntu 20.04.1 LTS amd64  7.6G
               sdc1 iso9660 Ubuntu 20.04.1 LTS amd64  2.6G
               sdc2 vfat    Ubuntu 20.04.1 LTS amd64  3.9M
          ***** datp: live with ntfs data partition ***** 
Trying to unmount partitions if mounted on the target device
umount: /dev/sdc: not mounted.
umount: /dev/sdc2: not mounted.
--------------------------------------------------------------------------------
 Please wait until the process has finished and 'Done' is written 
..... Flash modified iso file to target ........................................
2785017856=file size
2779774976 bytes (2.8 GB, 2.6 GiB) copied, 466 s, 6.0 MB/s 
2656+0 records in
2656+0 records out
2785017856 bytes (2.8 GB, 2.6 GiB) copied, 466.784 s, 6.0 MB/s
----- cleanup after dd ------------------------------------------
18681 pts/4    00:00:00 mkusb-sedd
Warning: The driver descriptor says the physical block size is 2048 bytes, but Linux says it is 512 bytes.
/dev/sdc2 after flashing
..... Create partition .........................................................

Welcome to fdisk (util-linux 2.34).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.


Command (m for help): Partition type
   p   primary (2 primary, 0 extended, 2 free)
   e   extended (container for logical partitions)
Select (default p): Partition number (3,4, default 3): First sector (5439488-15814655, default 5439488): Last sector, +/-sectors or +/-size{K,M,G,T,P} (5439488-15814655, default 15814655): 
Created a new partition 3 of type 'Linux' and of size 5 GiB.

Command (m for help): The partition table has been altered.
Calling ioctl() to re-read partition table.
Re-reading the partition table failed.: Device or resource busy

The kernel still uses the old table. The new table will be used at the next reboot or after you run partprobe(8) or kpartx(8).

prober: /dev/sdc2 for persistence
prober: /dev/sdc2 for persistence
prober: /dev/sdc3 for persistence
..... Overwrite first mibibyte of partition ....................................
umount: /dev/sdc: not mounted.
umount: /dev/sdc1: not mounted.
umount: /dev/sdc2: not mounted.
umount: /dev/sdc3: not mounted.
1024+0 records in
1024+0 records out
1048576 bytes (1.0 MB, 1.0 MiB) copied, 0.219854 s, 4.8 MB/s
..... Create file system in usbdata partition  .................................
Cluster size has been automatically set to 4096 bytes.
Creating NTFS volume structures.
mkntfs completed successfully. Have a nice day.
Finally, please wait for a few more seconds ...
--------------------------------------------------------------------------------
NAME MODEL          FSTYPE  LABEL                    MOUNTPOINT  SIZE NAME
sdc  Drive_SM_USB20 iso9660 Ubuntu 20.04.1 LTS amd64             7.6G sdc
sdc1                iso9660 Ubuntu 20.04.1 LTS amd64             2.6G sdc1
sdc2                vfat    Ubuntu 20.04.1 LTS amd64             3.9M sdc2
sdc3                ntfs    usbdata                                5G sdc3


 Done :-) 


No comments: