[00:33] hi all [00:34] I've just created a custom build of ubuntu-mobile for a trial enterprise deployment... [00:34] I need to make an easy installer/recovery disk from the prototype build [00:35] what is the easiest/fastest way to make a bootable iso that will install this build to new hardware [00:36] I can do this presently by using the 'dd' command to overwrite the target device [00:36] I'd prefer to automate [00:36] Do you know the set of changes you made to a default image? [00:37] they are documented but the list is looooong [00:37] I'd prefer to just have an auto-installer dump this onto a new drive [00:37] Was it just package changes, or config changes as well? [00:37] configs as well [00:37] plus custom packages etc [00:38] Hrm. That gets tricky then. [00:38] So, there's no good way to get an installed system back into an installer [00:38] it no longer uses hildon, but boots to the company's custom window manager [00:38] oh... that sucks [00:38] And using dd has a number of frustrating associated issues related to install-time stuff. [00:39] But there are a number of tools that can help to modify a live image. [00:39] well I have prepped an image that is ready to be configured [00:39] And that can then be used for an install of the modified system. [00:39] so it boots up, creates the new /etc/udev/rules.d/70*persistent-net... etc [00:39] You've already prepared a custom live image for your target? [00:39] as well as prepping all necessary scripts for the stuff that's unique for the hardware [00:40] yes, that's what I dump using dd [00:40] it takes care of the filesystem (ext4) and the mbr [00:40] so I was just looking for an automated way to do this from a cd/usb drive that someone who isn't from engineering could use [00:41] I think we're running into a definition issue. A "live image" is something like a USB stick or ISO that will run live OR perform an install. An "installed image" is the result of having performed an install. [00:41] we currently dump with dd, then grow the fs to fill the new drive [00:41] Which have you prepared? [00:41] installed, but ready for setup [00:41] so in the 'first time' state [00:41] Right. I get it. [00:42] Are you using oem-config? [00:42] nope... actually a lot of the custom ubuntu stuff has been stripped to give a lighter thinner ubuntu [00:42] needs only 170MB RAM and 800MB disk space [00:43] so the special oem-config stuff is no longer there [00:43] OK. I think I understand your current state. [00:43] I don't know of any tools that would construct an installer image from that. [00:43] oh... crap [00:43] I can walk you through the process of modifying an installer image to include the changes. [00:44] hmmm... I'd probably would be better off, scripting the dd and grow fs commands then creating a tarball in a folder on a live cd image [00:44] But that is mostly for changes in package selection. If you have additional configuration, that usually involves a combination of a special foo-default-setttings package and some changes to existing packages. [00:44] just set to boot then run the script [00:44] There are a number of issues with using dd on an installed image for mass-production. [00:45] some of the packages are from our own repo and are foreign to ubuntu [00:45] Some examples are that all installed devices would have the same initial cryptographic salt. [00:45] Some tools contain information about volume sizes that are confused by grow_fs [00:46] And some configuration of the system is *only* done by the installer. [00:46] hmmm... the thing is, so far we have done multiple lab trials and tests with the image and used dd for each install on test hardware [00:46] Using foreign packages is not a problem at all. [00:46] we have scripts for the configs [00:46] so that is taken care of on first boot [00:47] it's a seriously hacked build [00:47] Indeed. I wish I'd caught you earlier in the process :) [00:47] lol... that would have saved us both a lot of probs at this stage eh? [00:48] Yeah. [00:48] I wonder if we can still call this ubuntu or should it be renamed 'xyz distro based on ubuntu'? [00:48] Are you using a swap partition? [00:48] sorta like mer [00:48] no swap part [00:48] single part install [00:48] You can't call it "Ubuntu" if you modified it with stuff not in Ubuntu. [00:49] figured... we'll have to come up with a name for this one [00:49] it's extremely lightweight, like linux distros of old [00:49] No swap partition solves some of the issues with resizing the filesystem. [00:50] yeah, we used the single ext4 from the get go to make installations 'easier' [00:50] so much for that [00:50] Rather than using the installer :) Heh. [00:51] the image is stored as a clean tarball with no lost+found, no bash history, no log files, not apt cache... it's clean as a whistle [00:52] just needs to be extracted to a bootable ext4 [00:52] we created a dd image to take care of the installation of grub [00:52] And the bootloader installed, etc.? [00:52] one less step [00:52] I thought that grub stored the disk geometries in the config. [00:52] all scripts installed just needs the mbr [00:53] the mbr needs to know what the first boot device is [00:53] and what the fs of that device is... so still need to have the right mbr entry [00:54] other than the mbr entry, everything is in the tarball [00:54] And how are you deploying the tarball, or is that what brings you here? [00:56] that's why I'm here [00:57] Right. [00:57] I was trying to find an automated way to do it [00:57] So, we have two installers. [00:57] it just needs to be extracted to root of a single bootable ext4 partition [00:57] then we install grub to the mbr and we're ready to go [00:57] One of them does the base setup, then installs each package from a pool, then does final setup. [00:58] actually, they both do the same [00:58] neither has to install any packages [00:58] The other puts the result of an installation of all the packages in a chroot into a squashfs, and then boots with that as a unionfs and runs some special scripts in the initramfs. [00:58] everything is in an installed state in the tarball [00:59] not even necessary [00:59] I don't think the first will help you, as I have the impression that you'd end up needing to massively rework your configuration scripts. [00:59] we literally just have to extract the tarball to the bootable ext4 partition, install grub to the mbr and the system is ready to boot [01:00] The second relies on there being an installer tool included in the squashfs, which would require modifications to your image that would not be preserved on deployment, which would probably mess up your prior testing. [01:00] the initial setup is for user id and network security config of the terminal [01:01] So, if you wanted to use an Ubuntu installer, I'd suggest attempting to stuff your tarball into a squashfs, and trying that. [01:01] But that might well be fairly painful as you have to differentiate the boot of the live image and the first-time boot. [01:01] So, I think you need a new installer. [01:02] Are you expecting mass-installs or end-user installs? [01:03] is there no way to get a live ubuntu disk to just boot, format the host drive according to a script, install grub to the mbr then extract the tarball to root? [01:03] mass installs [01:03] but it needs to be 'non-tech' proof for recovery or emergency installs [01:03] There are lots of ways to do it, none happen to be recommended as an install method. [01:04] lol [01:04] For your specific case, you might want to perform a minimal installation of Ubuntu Server (without any servers) onto a USB stick. [01:04] Then copy your installation images into that media [01:05] well the installed doesn't need to be x-based either... a simple terminal with progress output is fine [01:05] And then create an initscript that would perform the required actions to partition, create the filesystem, copy the data, etc. [01:05] Ubuntu Server doesn't include X by default, which is why I suggested it :) [01:05] ok, perfect [01:05] For mass-installs, bringing up a whole GUI is often considered slow. [01:06] Again, this is not a recommended way to install, and I predict you'll encounter issues later. [01:06] When that happens, I do encourage you to come back, and we'll look at how to create a mass-install image in a recommended fashion. [01:06] ok, thanks [01:06] lol [01:08] Good luck. [01:08] thanks === asac_ is now known as asac === robbiew_ is now known as robbiew === robbiew is now known as robbiew-AF === robbiew-AF is now known as robbiew-afk === kung|away is now known as kung === robbiew-afk is now known as robbiew === kung is now known as kung|away === robbiew is now known as robbiew_