Re: live cd/usb projects?
On Sat, Nov 28, 2009 at 06:57:41PM +0000, T o n g wrote:
> On Fri, 27 Nov 2009 21:34:56 -0500, Rob Owens wrote:
>
> >> . . . My ideal is of
> >> course Debian and apt-get/deb. The Debian/xfce live cd is ok @ 400mb
> >> but
> >> I'd like to shrink it or keep it same size with my preferred
> apps. . . .
> >>
> > I currently use Debian Live. I create my own images for USB using the
> > live-helper scripts.
>
> @Rob, I'm interested in how you do that. I found that the Debian Live/
> live-helper manpage, web, & wiki are just way too unfriendly for me to
> digest.
>
I also found the manual to be a little tough to follow sometimes. It's
actually pretty straightforward.
Here's what you have to do. All of this is done as root.
1) aptitude install live-helper
1a) optional, but recommended: Get the latest live-helper from testing.
The boot menu is improved in this version.
http://packages.debian.org/squeeze/all/live-helper/download
2) You will now have a directory called /usr/share/live-helper/lists.
These are pre-configured package lists. You can create your own
customized one and put it in this directory (I'll pretend you've called
it "mylist").
3) mkdir live1
4) cd live1
5) lh_clean
6) Do either 6a or 6b:
6a) Configure live-helper to make an image suitable for USB on an i386
type machine, using the "lxde" package list:
lh_config -a i386 -b usb-hdd -p lxde
6b) Configure live-helper to make an image suitable for USB on an i386
type machine, using the "mylist" package list, which will not
automatically log in a user (it will stop at GDM or whatever login
manager you have installed), is persistent by default, and has a
hostname of "mylivedebian":
lh_config -a i386 -b usb-hdd -p mylist --bootappend-live "noautologin
noxautologin persistent" --hostname mylivedebian
7) lh_build
8) wait a while
9) With your USB drive inserted and not mounted:
(replace "X" with the proper letter for your device)
dd if=binary.img of=/dev/sdX
10) Create a partition for persistence in the extra space on your USB drive:
fdisk /dev/sdX
p (print the existing partition layout)
n (new partition)
p (primary partition)
2 (partition #2)
enter (accept default start of partition)
enter (accept default to use all remaining space on the device)
w (write the partition table)
11) Create a filesystem for the peristence partition:
mkfs.ext2 -L live-rw /dev/sdX2
(the label of "live-rw" is important!)
12) Boot from your USB stick!
13) Add users, customize the system, install software, etc. I like to
give myself sudo rights and take sudo rights away from the user "live".
-Rob
Reply to: