Penguin
Diff: UbuntuRemastering
EditPageHistoryDiffInfoLikePages

Differences between current version and previous revision of UbuntuRemastering.

Other diffs: Previous Major Revision, Previous Author, or view the Annotated Edit History

Newer page: version 15 Last edited on Thursday, August 24, 2006 9:16:47 am by CraigBox
Older page: version 14 Last edited on Wednesday, April 19, 2006 11:14:02 pm by JoShields Revert
@@ -1,98 +1,13 @@
 !!Notes on remastering an [Ubuntu] CD 
  
-!Why would you want to do this?  
+!Rationale  
  
-I want to take the Hoary CD, remove all the graphical stuff, install a preseed ("answers") file for the installer, add some components from universe, and have a nice neat firewall-on-a-CD. 
+Once upon a time, I wanted to take the Ubuntu Hoary CD, remove all the graphical stuff, install a preseed ("answers") file for the installer, add some components from universe, and have a nice neat firewall-on-a-CD. 
  
-!Procedure  
+!Newer versions  
  
-Copy the CD to your hard drive. __Important:__ Remember there is a folder called ''.disk'' in the root of the CD, which you will miss copying if you use 'cp /cdrom/*', as bash(1) will expand it without the dotfile
+Since Dapper, a "server" CD has been available , which solves the "graphical cruft" problem. I recommend preseeding that for server /firewall installs
  
-!Changing the logo  
-  
-You can replace the splash screen (in isolinux/) with a LSS-format file; the best way is to start with a [PCX] and [read the syslinux splash screen HOWTO|http://sweb.cz/Frantisek.Rysanek/splash/isolinux-splash-HOWTO.html]. Use "pcxtoppm <inpur.pcx >output.ppm" using the "netpbm" package, rather than converting from [GIF].  
-  
-!Create a preseed file  
-  
-Start at [the Ubuntu Installation Guide|http://archive.ubuntulinux.org/ubuntu/dists/hoary/main/installer-i386/current/doc/manual/en/apcs01.html] for how to preseed your install.  
-  
-!Ask less questions at the installer phase  
-  
-In the isolinux.cfg file in isolinux/, add a line somewhat like  
-  
-<pre>  
-LABEL firewall  
- kernel /install/vmlinuz  
- append preseed/file=/cdrom/preseed/firewall.seed preseed/locale=en_NZ kbd-chooser/method=us \  
- vga=normal initrd=/install/initrd.gz ramdisk_size=12288 root=/dev/rd/0 rw --  
-</pre>  
-  
-Three important additions tell debian-installer how to behave:  
-  
-;__preseed/file=/cdrom/preseed/firewall.seed__ : Load debconf information from this seed file  
-;__preseed/locale=en_NZ__: Specify language and country  
-;__kbd-chooser/method=us__: Specify keyboard mapping (note - this is different in Ubuntu to what's published about sarge)  
-  
-!Changing the packages on the CD  
-  
-This is the trickiest part, as everything is [GPG] signed, and your GPG key isn't installed by default. So, to change any of the data on the CD (ie to add your own packages or to remove packages from main), you need to:  
-  
-* create your own GPG key  
-* (optional) import the ubuntu-archive keyring  
-* export your keyring  
-* replace the ubuntu-archive keyring with yours  
-* recompile the ubuntu-keyring package  
-* put it on the CD  
-  
-You have two options; either do your edits in the 'main' respository on the CD, or create an 'extras' repository. Either way, you will have to create your own ubuntu-keyring package; if you use an 'extras' repository then you can just put a higher numbered version in there, which the installer will prefer.  
-  
-If you want to remove packages from the CD (for a firewall I don't need Xorg or GNOME), you can remove the files; apt uses the Packages file for its cache, and not the files on the disc, so assuming you don't try and install Xorg or GNOME, you'll be OK. In my case, immediately upon installation, the sources.list file will change not to refer to the CD, so I could safely delete packages and ignore that the Packages file thinks they're there. It's not the best practice however, so you might want to consider creating a new Packages file and updating the Release file for main (see below).  
-  
-!Putting your packages in the pool directory structure  
-  
-I preloaded a machine with everything extra I wanted, so all the packages were in /var/cache/apt/archive.  
-  
-You can use mini-dinstall, apt-move(8) or apt-ftparchive(1) to move these into a pool/ directory structure - none of them are simple, and I've only found out so far how to use apt-move into a 'fake repository', where I just copy the structure. Some input can be found [here|http://people.debian.org/~osamu/hackdi/ch-d-i.html]. I'll update this as I have information.  
-  
-Put your pool directory structure in pool/extra/.  
-  
-!Create an Extras component  
-  
-If you're using amd64 or powerpc, replace 'i386' with the correct platform name in this and all relevant instructions.  
-  
-In dists/, mkdir extras and extras/binary-i386. Each component must have a Release file telling apt which component this is. copy main/binary-i386/Release to extras/binary-i386/Release and edit it to refer to =Component: extras= instead of main.  
-  
-!Creating Packages file for your components  
-  
-apt-ftparchive(1) packages will generate a Packages file. Use =apt-ftparchive packages pool/main/ > dists/hoary/main/binary-i386/Packages= - this has to be done from the root of the CD image, so paths are relative to that (ie pool/main/l/linux-source/linux-image-i386.foo.deb). Scanning packages can take some time.  
-  
-You can gzip the file to create a Packages.gz, but this is only for speed when doing an apt-get update, so you might not bother on a CD.  
-  
-!Creating a Release file  
-  
-In dists/hoary you need to have a Release file, which refers to all the other Packages/Release files in the repository. The file also contains the SHA1 and MD5 sums for each file. You generate this (from dists/hoary) with =apt-ftparchive release .=  
-  
-Looking at the original Release file, you see there there are lots of other fields set. To set these, create a config file for apt-ftparchive, which includes each word with APT::FTPArchive::Release:: prepended. I generated mine with =head -9 Release | grep -v ^Date | sed 's/: / "/' | sed 's/^/APT::FTPArchive::Release::/' | sed 's/$/";/' > apt.conf= and you add it into the apt-ftparchive commandline with =-c apt.conf=  
-  
-!Create a signature for the Release file  
-  
-You need to create an Release.gpg file, with an ASCII armoured signature for the master Release file in dists/hoary. Use =gpg --output Release.gpg -ba Release= and sign with the signing key you created earlier.  
-  
-!Build your CD  
-  
--b/-c paths are relative to your filepath (in my case, firewall-image contains my Ubuntu CD image): =mkisofs -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -J -hide-rr-moved -o firewall-2..iso -R firewall-image/=  
-  
-!Burn your CD  
-  
-Record the ISO with your method of choice; I record to an IDE CD writer with a 10x rewritable (I burn over this a lot. :), so I use the commandline =cdrecord dev=ATA:,1,0 --blank=fast --speed=10 -tao firewall-2..iso=  
-  
-!Boot off it and test  
-  
-Now you're at the end of the process; you should have a bootable CD, which will ask you less questions, and only install a minimal system.  
-  
-__TODO__: add commands for installing other packages/link to preseed file  
-  
-!If size of CD is to big  
-If the size of your CD is bigger then expected, please check the following link: http://lists.ubuntu.com/archives/ubuntu-devel/2005-May/007383.html  
+!Procedure  
  
-There are also [notes on this at the Ubuntu wiki| https://wiki .ubuntu.com/InstallCDCustomizationHowTo]
+This has been documented in much detail, by myself and others, at https://help .ubuntu.com/community/InstallCDCustomization. Please go there