You are not logged in.

#1 2017-11-14 02:00:21

Nap
Member
Registered: 2017-11-14
Posts: 8

Customising Live USB

I would like to add some packages from the repo to my Live distribution of "bl-Deuterium-i386+NonPAE_20170429", so they will be available for use on the next boot.  (Specifically, I need to install the ssh daemon, openssh-server package.)  If this is possible, how can it be done?

Also, I need the boot sequence to not wait at the boot menu and go directly to the Live install.

Any help, URLs to guides, would be appreciated.

Cheers,
Nap

Offline

#2 2017-11-14 06:46:51

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Customising Live USB

See https://forums.bunsenlabs.org/viewtopic … 536#p63536

The GRUB configuration can be found in the image under boot/grub/grub.cfg

Offline

#3 2017-11-14 07:14:48

Nap
Member
Registered: 2017-11-14
Posts: 8

Re: Customising Live USB

Thanks.  I notice you're doing this from a host OS, is Ubuntu 16.04 LTS ok?

Offline

#4 2017-11-14 07:18:00

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Customising Live USB

Yes, the guide should be fairly generic but I think Ubuntu has a different live-build system so the image layout may not be exactly the same as I have described, just poke around a bit and look for a filesystem.squashfs file.

EDIT: if by "host OS" you mean the system from which the ISO is remastered then no, that does not matter at all.

Last edited by Head_on_a_Stick (2017-11-14 07:18:58)

Offline

#5 2017-11-14 07:29:50

Nap
Member
Registered: 2017-11-14
Posts: 8

Re: Customising Live USB

I've chrooted into the distro, but when I do an 'apt-get update', I get a bunch of errors indicating the sites can't be reached;

Err http://deb.debian.org jessie InRelease
  
Err http://pkg.bunsenlabs.org bunsen-hydrogen InRelease
  
Err http://deb.debian.org jessie-updates InRelease
  
Err http://security.debian.org jessie/updates InRelease
  
Err http://pkg.bunsenlabs.org bunsen-hydrogen Release.gpg
  Could not resolve 'pkg.bunsenlabs.org'
Err http://deb.debian.org jessie Release.gpg
  Could not resolve 'deb.debian.org'
Err http://security.debian.org jessie/updates Release.gpg
  Could not resolve 'security.debian.org'
Err http://deb.debian.org jessie-updates Release.gpg
  Could not resolve 'deb.debian.org'

I am able to ping IP addresses, but it seens the DNS resolver isn't working.

Offline

#6 2017-11-14 07:42:34

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Customising Live USB

Exit the chroot, copy /etc/resolv.conf inside the chroot filesystem tree and enter the chroot again.

Or use this command from inside the chroot:

# echo nameserver 8.8.8.8 > /etc/resolv.conf

Offline

#7 2017-11-14 07:43:21

Nap
Member
Registered: 2017-11-14
Posts: 8

Re: Customising Live USB

Right, was just about to answer my own question.  Cheers!

Offline

#8 2017-11-14 07:50:09

Nap
Member
Registered: 2017-11-14
Posts: 8

Re: Customising Live USB

Hmmm.  I cannot find grub.cfg anywhere, neither in the mounted iso, nor in the ~/iso/remix.
The closest, grub related files I can find are in ./isolinux

Last edited by Nap (2017-11-14 07:50:26)

Offline

#9 2017-11-14 19:58:56

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Customising Live USB

Well, in the BunsenLabs image there is a boot/grub/grub.cfg but I must admit that I have been trying to make changes to that file work in the booted image and failing  hmm

There must be some intermediary layer, I will investigate more when I have time and I suggest that you do the same.

EDIT: to clarify: I have nothing to do with producing the live images for BunsenLabs, I've just had reason to pull one apart and change it recently so I don't really know the details of the ISO production process.

Last edited by Head_on_a_Stick (2017-11-14 20:00:32)

Offline

#10 2017-11-15 02:16:46

johnraff
nullglob
From: Nagoya, Japan
Registered: 2015-09-09
Posts: 12,668
Website

Re: Customising Live USB

Head_on_a_Stick wrote:

I have nothing to do with producing the live images for BunsenLabs, I've just had reason to pull one apart and change it recently so I don't really know the details of the ISO production process.

I have been involved in that, but it's not a simple process and involves a lot of automation via a labyrinth of scripts and config files known as live-build: https://anonscm.debian.org/git/debian-l … -build.git

The most recent BL isos were built on a Stretch environment with live-build 1:20170213 but the while the git repo is now at  1:20170920 the changelog doesn't suggest any drastic differences, so you could just 'git clone' from that to get a local copy of live-build to poke around in. (Once the files are on your machine you can use grep and friends...)

What this boils down to is I'll be glad to furnish any information that might help fix the grub issue, but making an iso that works is complicated, and live-build itself is doing all the difficult stuff. What I can say now is that l-b is generating grub.cfg dynamically during the iso build process. There certainly should be such a file, but the relevant one is in boot/grub in the iso not in the unpacked squashfs system. I can't think of any intermediary layer, but if the system is booting from EFI then grub is ignored, is it not?


...elevator in the Brain Hotel, broken down but just as well...
( a boring Japan blog (currently paused), now on Bluesky, there's also some GitStuff )

Introduction to the Bunsenlabs Boron Desktop

Offline

#11 2017-11-15 06:59:54

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Customising Live USB

Thanks John, that is massively helpful.

johnraff wrote:

l-b is generating grub.cfg dynamically during the iso build process

OK, that makes sense — I am generating the image using the `genisoimage` command so it uses a different process to generate the GRUB menu, also the current command does not produce an EFI bootable image.

but if the system is booting from EFI then grub is ignored, is it not?

The image seems to use GRUB's .efi loader for UEFI booting and that will still read grub.cfg

Having said that, the firmware on my UEFI laptop is broken so I usually boot in "Legacy" mode instead.

Offline

#12 2017-11-15 18:49:37

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Customising Live USB

Right, it turns out that the ISO image is booting with syslinux rather than GRUB roll

I found this guide:

https://unix.stackexchange.com/question … mmediately

But I can't figure out how to make it work, the best I can do is to edit isolinux/isolinux.cfg and set

timeout 1

This boots the default entry after 0.1 seconds, which is pretty quick.

Offline

Board footer

Powered by FluxBB