[ug-bosug] Updates on the LiveMedia Tool Kit

Joe G (Joseph George) Joe.G at Sun.COM
Mon Sep 11 21:56:17 PDT 2006


I know some of you are trying to create new live media for OpenSolaris. 
This writeup by Eric B is useful if you are interested in playing around 
with the LiveTool Kit that Moinak and Dave Miner created.

~Joe


-------- Original Message --------
Subject: 	[livemedia-discuss] Exploring the live media kit
Date: 	Mon, 11 Sep 2006 20:35:28 -0500 (CDT)
From: 	Eric Boutilier <Eric.Boutilier at Sun.COM>
Reply-To: 	Eric.Boutilier at Sun.COM
To: 	livemedia-discuss at opensolaris.org



I dabbled with the kit (cool stuff!) over the weekend --
journaling into my blog as I went. Here's a copy. Please
advise of any inaccuracies, etc.

Per a comment on my blog, I'll post my changes (temporary
hacks) too.

Eric


  _________________________________________________________________

Sat Sep  9, 14:54 CDT

For starters, I need to re-remember the details of what I
learned from some initial live-media experimentation I had
done a few weeks ago. So I just read through some e-mails --
one in particular. Here's an excerpt:

http://blogs.sun.com/eric_boutilier/resource/ldkmail.txt

  _________________________________________________________________

Sun Sep 10, 10:01 CDT

Studied the main script (build_live_dvd) to figure out a way
to change the inputs it uses. In other words, the set of
packages from which it builds an ISO image. Lines 150 and 151
appear to tell me what I need to know. I can a.) change
SUNWCall to SUNWCreq to omit X, GNOME, OpenOffice, and lots
of other stuff and thereby shrink down (way down) the size of
my custom CD; and b.) insert the additional packages I want
by putting them into a list and concatenating that into the
pipeline. Those being SUWNbash and a set of security tools
from the blastwave.org (/opt/csw) FOSS repository.

Hm, after looking closer, I think I better create my own
version of the .clustertoc file that the script scans. (By
the way, whenever I read that file name, I always wonder if
the person who named it was a fan of the Clint Eastwood role
in "Heartbreak Ridge; i.e. his memorable response[1] when his
Colonel asks him "What's your assessment of this situation,
Gunny?")

1. http://www.imdb.com/title/tt0091187/quotes

Anyway, I'm off to create my own custom .clustertoc (sir ;-) ).
  _________________________________________________________________

Sun Sep 10, 11:48 CDT

Interesting. It looks like build_live_dvd meticulously
sequences the package installations to account for
dependencies, but then the pkgadd(1) admin file it uses
bypasses dependency checking. No problem though, that's
actually good for my purposes because it'll make it easier to
get the CSW packages included.

  _________________________________________________________________

Sun Sep 10, 14:50 CDT

OK, I just ran my hacked version of build_live_dvd and it
seems to have worked -- at least it generated a valid
mountable ISO (more on that below). I didn't create a
modified .clustertoc afterall. Instead I just appended the
CSW package names onto the end of the standard list of
package names. Then I told the script where to find them
(which I had extracted from datastream to file system format)
by inserting an elif conditional in the while read pkg loop
(around line 152).

Now I haven't tried burning it to and booting a CD yet, but I
mounted the ISO (via lofiadm) and browsing through it I
noticed a "gotcha". As I understand it, live CD/DVDs can run
into problems if the ramdisk size is too big. In order to
prevent this, BeleniX (and therefore Solaris Live Media)
needs the bulk of the files to reside under /usr.  That's
because the booted system accesses /usr via the CD, and
everything else from the ramdisk... or something like that.
And therein lies the problem, my CD will generate a huge
ramdisk because all the CSW files are installed under /opt...

  _________________________________________________________________

Sun Sep 10, 23:22 CDT

Cool. I burned it to a CD, booted it, got a login prompt
(though there were a couple complaints from SMF), logged into
the command line as root, poked around a bit, and tested
various things under /usr/bin and /opt/csw/bin. Everything
worked as expected.

Also, I'm happy to report I was mistaken: installing software
in /opt doesn't bloat the ramdisk at all. That's because /opt
gets mounted from the CD. In other words, I thought I was
going to have to jury-rig things to make the CSW packages
reside under /usr, but that's not necessary afterall.

There is however, a different tradeoff to consider. The
reason /usr is treated special in the first place has to do
with the fact that the BeleniX Live project (from which SX
Live is derived) is obsessive about getting as much software
on a CD (not DVD) as possible. One way BeleniX Live (and SX
Live) accomplishes that is to squeeze the contents of /usr
into a compressed ISO filesystem (I think). So by installing
all the add-on software under /opt/csw instead of say,
/usr/foss like BeleniX does, my live CD doesn't benefit from
that strategy. No worries yet though -- the ISO that I
generated from this experiment is only 341 MB.
_______________________________________________
livemedia-discuss mailing list
livemedia-discuss at opensolaris.org
http://opensolaris.org/mailman/listinfo/livemedia-discuss




More information about the ug-bosug mailing list