3

my apologies in advance if this has already been answered elsewhere (something like this has but years ago and I am still confused about the steps to take). Here is my end task:

  • Provide a bootable/persistent USB drive to a team of engineers (travelling field engineers) to use it on their laptops. By our company rules they cannot install Linux on a second partition so this is the only option.
  • The bootable USB must have all the SW tools they will need to carry out their tasks (we work on networks of proprietary industrial controllers).

I am running Ubuntu 19.10 (Eonian) in a VBM under windows 7 on my computer and so far I have successfully installed all the SW planned (including some tools that need Wine since they were developed in Windows XP and 7), sorted out whatever wasn't working, deleted applications we don't need and wrote quite some scripts to get everything in line.

Now the idea would be to make a bootable copy (and persistent since there is the necessity to save stuff -aka files- when using the customized tools) of the environment I built as-it-is.

Is it possible with ubuntu 19.10? Can anyone point me in the right step-by-step direction?

Thnx in advance.

  • 3
    Consider a Full install of Ubuntu to USB, there are advantages over Persistent install, https://askubuntu.com/questions/1222532/try-ubuntu-from-install-usb-how-to-make-it-not-erase-files-every-time/1222797#1222797. Once the first Full install USB is created as required, it can be cloned to other USB drives. Alternately an image file of the drive can be created and installed on other drives using mkusb in Linux or Win32 Disk Imager in Windows. It is all pretty simple, however I can provide a step by step answer if you are interested. – C.S.Cameron Apr 01 '20 at 12:16
  • @C.S.Cameron: great hint. I think I will go for Full Install. If you have the patience and the will to provide a step-by-step answer I'll be one of the happiest guy in the covid-19 segregated community. :) consider though that my Ubuntu VDI file, with all the shabng installed, is 16 G and I have no problems to use upto 32G USB pendrive to clone my system – Caligola Apr 01 '20 at 13:37
  • @user535733 You do not need two USB drives to make a Full install. If you boot a Live USB toram you can install to the same USB. https://askubuntu.com/questions/855039/can-ubuntu-be-installed-to-the-pendrive-it-was-booted-from – C.S.Cameron Apr 02 '20 at 03:24
  • @C.S.Cameron indeed, fair enough. – user535733 Apr 02 '20 at 03:53
  • @C.S.Cameron: so, correct me if I'm wrong. I will be actually installing Linux on a say 32/64 GB USB drive from a Live USB in the very same way as I were installing ona a HD, and to stay safe I'll get the HD of my computer out of the way. Once the Full Install is completed (on the target USB) I'll remove the Live USB and boot again from the target and start upload/install the tools/SW/scripts I need to distribute to my team of engineers onto this final drive. Once done that, I can then make an image of the USB and flash all the pendrives that I need. Is that correct? – Caligola Apr 02 '20 at 04:50
  • 1
    @Caligola Yes, your description is more concise than the instructions I was working on. I have not used VBM's before. Is it possible to restore the VBM directly to the target USB drive? This might save some work. However creating a new Full install USB ensues that it will boot in both BIOS and UEFI modes. Make your Target drive on the smallest USB drive that will hold everything you need, the larger the drive the more time it takes to backup and restore. Partition sizes can be revised later. balenaEtcher is also worth considering for flashing drives. – C.S.Cameron Apr 02 '20 at 05:25

1 Answers1

2

Clone Full install Drive to Multiple USB Drives

  • Create Full install USB drive that will boot in both BIOS and UEFI modes.

See: How to Create a Full Install of Ubuntu 19.10 to USB Device Step by Step

  • Make your Target drive on the smallest USB drive that will hold everything you need, the larger the drive the more time it takes to backup and restore.

  • Upload and install the tools, software and scripts that you need to distribute to your team of engineers.

  • Create an image file, (.img), of the Target drive using Disks in Linux. (dd may be used by experianced users).

  • Extract the image file to the engineers USB drives using Disks. or mkusb in Linux or Win32 Disk Imager or balenaEtcher in Windows.

  • After installing the image files use GParted to Resize the ext4 and or NTFS partitions to fill the drive.

  • If two or more USB drive clones are used in the same computer at the same time create new UUID's using GParted.

C.S.Cameron
  • 19,519
  • Great stuff C.S.. I asked you a question about partition sizes during the Full Install on the other thread. As usual: I'm still at the bottom of the learning curve so forgive my thickness – Caligola Apr 03 '20 at 05:51