Page 1 of 5 123 ... LastLast
Results 1 to 10 of 48

Thread: How do I deploy an iso with persistence built in?

  1. #1
    Join Date
    May 2019
    Beans
    27

    How do I deploy an iso with persistence built in?

    I have a Linux app that must be run from an OS on a USB stick as it is a disk/partition backup/clone app. I've created an iso built from a pared down version of Ubuntu 16.04 that works well. I want to distribute this to new Linux users and have the ability to update the app without the user needing to download an entire new iso, just download the app. I haven't figured out how to deploy an iso that has persistence already built in. I've tried with mkusb but can't figure out how to deploy the results (the multiple partitions). The app is designed for new linux users so I don't want to burden them with mkusb.

    Could a wget function do the update?

    Thanks in advance,
    Larry
    Last edited by lhh29936; February 15th, 2020 at 04:39 PM.

  2. #2
    Join Date
    Nov 2008
    Location
    Metro Boston
    Beans
    14,817
    Distro
    Kubuntu 19.10 Eoan Ermine

    Re: How do I deploy an iso with persistence built in?

    Is there some reason you can't just distribute the app itself as a .deb and let your users install it on top of a normal Ubuntu distribution?

    Also, standard support for 16.04 ends next year. You'd be better off building an ISO starting with 18.04.
    If you ask for help, do not abandon your request. Please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  3. #3
    Join Date
    May 2019
    Beans
    27

    Re: How do I deploy an iso with persistence built in?

    Thanks for the reply. The app is a disk/partition cloning app so the partitions/disk must be unmounted for it to function. That is why what's being deployed as an iso with a minimal Ubuntu and the app pre-installed. The object is to have the end-user burn it to a USB once and then be able to update the app without having to burn a new iso to the USB.

  4. #4
    Join Date
    Nov 2011
    Location
    /dev/root
    Beans
    Hidden!

    Re: How do I deploy an iso with persistence built in?

    Maybe you can use a new feature or Ubuntu 19.10 and newer versions (and if you want a light-weight system, suitable for a USB pendrive, Lubuntu or Xubuntu), that makes it easier to create a persistent live drive.

    Actually all you have to do is edit the iso file with sed in order to make it such that a persistent live drive will be created, when cloned to a USB pendrive and booted the first time.

    Replace exactly 12 characters with exactly 12 other characters:
    Code:
    sed 's/quiet splash/persistent  /' lubuntu-19.10-desktop-amd64.iso > persistent-lubuntu-19.10-desktop-amd64.iso
    
    sed 's/quiet splash/persistent  /' focal-desktop-amd64.iso > persistent-focal-desktop-amd64.iso
    So the end user

    1. downloads this 'persistent' iso file
    2. clones it with 'any' cloning tool
    3. boots into it
    4. installs your application (via a tarball, debian file, PPA ..., whatever method you choose)

    PPA is good for the end user, because it makes it easy to update & upgrade your tool. But you have to set up the PPA, which is a bit difficult.



    If you want to make it more convenient for the end user, you can create (a small) partition behind the cloned image, and then boot into it, install your application, make a [compressed] cloned image of the persistent live system with your application and distribute that [compressed] cloned image.

    Compressed image file with a persistent live system

    An alternative, that might also be fairly portable (installed into a USB pendrive) is to create an installed OEM (installed) system where your application is installed, make a [compressed] cloned image and distribute that [compressed] cloned image.

    Ubuntu_OEM_Installer_Overview

    You can use the Do It Yourself method too according to the following link

    Do it yourself - with the extraction method
    Last edited by sudodus; February 15th, 2020 at 10:04 PM.

  5. #5
    Join Date
    May 2019
    Beans
    27

    Re: How do I deploy an iso with persistence built in?

    @sudodus, thanks for your reply. The app is targeted to new Linux users and is a disk/partition cloning app. The concept is to make it as easy as possible for them.The app itself is 22Mb, while the current iso, including the app, is 550Mb. Due to the rather small size of the iso, it might be easier to just have them download a new iso when there's an update and burn it to a USB.

  6. #6
    Join Date
    Nov 2011
    Location
    /dev/root
    Beans
    Hidden!

    Re: How do I deploy an iso with persistence built in?

    Yes, for new Linux user it might be easier to just have them download a new iso when there's an update and burn it to a USB.

    But for slightly more experienced users with a slow or expensive internet connection, you might offer the application program via a tarball, debian package or PPA. It should not be too difficult, particularly if you have some kind of automatic system, that checks for updates, when connected to the internet.

  7. #7
    Join Date
    May 2019
    Beans
    27

    Re: How do I deploy an iso with persistence built in?

    As a long time Linux user, I have to agree with you. However, all the info I've found is confusing about how to create a persistent partition and how to handle dependence and paths. The app is currently installed in the /home folder. How do I create a persistent folder for it? I just don't understand the relationship of the persistent partition to the iso. Is there a tutorial you can point me to that explains it in clear terms? This is my first attempt at deploying an app so I'm really a newbie even though I've been using Linux for 10 years.

    Thanks for your input.

  8. #8
    Join Date
    May 2019
    Beans
    27

    Re: How do I deploy an iso with persistence built in?

    @sudodus, maybe I'm confused. Here's the situation: The iso is bootable and has a minimal version of Ubuntu and the app. The end-user downloads the iso and burns it to a USB. The user reboots to the USB to run the app. It doesn't get installed to a HD or SSD. I don't want the end-user to have to create a partition on the USB to download an updated app file to, so my thoughts are that I need to deploy the iso with the persistent partition already created or possibly a write a wget routine so the iso handles it internally.

    What are your thoughts?

    Larry

  9. #9
    Join Date
    Nov 2011
    Location
    /dev/root
    Beans
    Hidden!

    Re: How do I deploy an iso with persistence built in?

    Are you asking how you should do it and how to make it easy for a beginner with Linux? Or how to explain for a beginner how to do it?

    With Ubuntu and the Ubuntu family flavours of version 19.10 and newer, it is easy.

    1. Add the boot option persistent

    2. Provide a file with the name casper-rw or a partition with the label casper-rw. A file should reside in a FAT32 file system and the size is limited to 4 GiB. A partition is only limited by the size of the drive.

    Then, when you boot the live Ubuntu system, it will grab the casper-rw and make an overlay system with the root (that is in RAM), and you have a persistent live system. In such a system the /home directory will be stored in the casper-rw file or partition. I make tools for it, but I think you want to understand how to do it.

    If you wish, you can add a file with the name home-rw or a partition with the label home-rw alongside casper-rw, and in such a system the content of the home directory will be saved there.

    So I think you can and should do these things (with or without tools.)

    But and end user, particularly a beginner with Linux, should probably get a system, that is prepared by you, so that the installation and maintenance should be rather easy (without manual messing with casper-rw or home-rw files or partitions). And such a system might be a cloned image of a persistent live system with your tool already installed and with an easy to learn or automatic mechanism to check for and perform updates.
    Last edited by sudodus; February 17th, 2020 at 04:42 PM.

  10. #10
    Join Date
    Nov 2011
    Location
    /dev/root
    Beans
    Hidden!

    Re: How do I deploy an iso with persistence built in?

    Quote Originally Posted by lhh29936 View Post
    @sudodus, maybe I'm confused. Here's the situation: The iso is bootable and has a minimal version of Ubuntu and the app. The end-user downloads the iso and burns it to a USB. The user reboots to the USB to run the app. It doesn't get installed to a HD or SSD. I don't want the end-user to have to create a partition on the USB to download an updated app file to, so my thoughts are that I need to deploy the iso with the persistent partition already created or possibly a write a wget routine so the iso handles it internally.

    What are your thoughts?

    Larry
    Yes, this is very similar to the image files, that I created a few years ago with mkusb installed according to this link

Page 1 of 5 123 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •