Ubuntu Feisty Fawn on a pen (USB)
Taking advantage of a 1GB USB pen I had lying around (a business gift), I just created a Ubuntu Feisty Fawn laptop.
first thing I did was change the size of the FAT partition that came default in memory of the pen, to reduce it to only 256MB, more than enough to continue using other operating systems and also to serve me as read-write store (casper-rw) in persistent mode (when it works, because now there is a bug on this). For this I used the tool part (as root or with sudo, of course). In my case, having USB pen device / dev / sdb, I:
Eye, very important: previously should do a fdisk-l, not wrong device and cause a mess (and unmount the partition if you have it mounted). Once inside parted, with print can display the current status of the device. To resize the FAT partition, just run (I assume there is still only one partition and that is numbered with 1):
can also be executed step by step (first resize, then 1 ... , as should this method, and is giving you as default values \u200b\u200band is hard to go wrong).
It might happen, I formatted the partition:
mkfs.vfat-F 32-n casper-rw / dev/sdb1
If it is FAT16, change-by-F F 32 16. With the above command, we have put the label casper-rw to be used in a persistent manner. USB Pen
Subsequently, I have parted out (quit) and am willing to create a new partition with ext3 fdisk free space left in memory (could have done well with parted, but just learn to use more tools) . In my case:
fdisk / dev / sdb
Once inside, viewing the current state p, with n creates a new partition (after you tell him to p for primary, 2 for 2 nd partition, and enter the default start and end of partition to fill all available space), with to activate partition 2 to boot with it (bootable ), and w are stored permanently changes (in this sense that I like fdisk parted, as the latter makes the changes immediately.) To exit, q.
format the partition ext3 (ext2 should also enforce). In my case:
mkfs.ext3-L ubuntu / dev/sdb2
I chose to do so for that partition remain invisible to other operating systems and can not be deleted or changed by mistake. This partition will copy data from Live CD of Ubuntu. Assuming you've downloaded the ISO image of Ubuntu, the ride (no need to burn on a CD), for example, as:
mount-t iso9660-o loop ubuntu-7.04-desktop-i386.iso / mnt / external /
Now, finally, mount the USB pen ext3 partition:
mount-o sync / dev/sdb2 / media/sdb2 /
and copy the CD contents to it: cp-Rpdf
/ mnt / external / * / media/sdb2 /
not really need to copy everything, but as there is plenty of room ... (left as an exercise to discover advanced reader unnecessary files).
Now which I think is the most innovative of this article (other than to choose a pen, of course). As we have chosen to use a ext3 partition, invisible to Windows and other viruses will have to choose a boot loader to work in such partitions. It could have been grub or lilo, but that would take Curran few configuration files. And as configuration files available on the LiveCD valid for syslinux and isolinux, I preferred to use the little known extlinux, whose configuration files have exactly the same format. This application extlinux comes in the syslinux package, so to install the package: aptitude install syslinux
First of all, check with fdisk-l it's all right. In my case I get:
Disk / dev / sdb: 1025 MB, 1025507328 bytes
32 heads, 62 sectors / track, 1009 cylinders Units = cylinders
1984 * 512 = 1015808 bytes Device
. Boot Start End Blocks Id System
/ dev/sdb1 1 252 249953 e W95 FAT16 (LBA)
/ dev/sdb2 * 253 1009 7509 44 83 Linux
Look closely where the asterisk (active partition). Must be in the Linux partition. Now, to install the bootloader on the USB pen:
extlinux-z / media/sdb2 /
The-z will be very useful for some computers at startup, perform USB storage devices such as devices ZIPdrive (see extlinux-h). Check that a file in / media/sdb2/extlinux.sys
Some USB, strangely resist the boot process. It is important that only one active partition and that is precisely where we installed the bootloader. If problems persist, look at this article on the subject.
As you have seen, I installed the manager at the root of the partition. I have not heard it another way. This forces us to make a small change in the structure of files from USB. To This move all files in the isolinux folder to the root:
mv / media/sdb2/isolinux / * / media/sdb2 /
and copy the kernel, etc. also at the root (yes, they have to be duplicated):
cp / media/sdb2/casper/vmlinuz / media/sdb2 /
cp / media/sdb2/casper/initrd.gz / media/sdb2 /
cp / media / sdb2/install/mt86plus / media/sdb2 /
Since there is only one thing: copy the isolinux configuration file to another valid extlinux:
cp / media/sdb2/isolinux.cfg / media/sdb2/extlinux.
conf should also be edited. With your favorite editor change it to your liking. I've left and (if you want, you can download): usb DEFAULT
gfxboot gfxboot-BACKGROUND bootlogo
0xB6875A
APPEND file = preseed / ubuntu.seed boot = casper initrd = initrd.gz locale = es_ES bootkbd = en console-setup/layoutcode = es quiet splash - LABEL
usb menu label ^
Ubuntu in persistent mode kernel vmlinuz append file = preseed
/ ubuntu.seed boot = casper persistent initrd = initrd.gz locale = es_ES bootkbd = en console-setup/layoutcode = is quiet splash - LABEL live
menu label ^ Start or install Ubuntu kernel
vmlinuz append file = preseed / ubuntu.seed boot = casper initrd = initrd.gz locale = es_ES bootkbd = is = is quiet console-setup/layoutcode splash -
LABEL xforcevesa
menu label Start Ubuntu in safe ^graphics mode
kernel vmlinuz
append file=preseed/ubuntu.seed boot=casper xforcevesa initrd=initrd.gz locale=es_ES bootkbd=es console-setup/layoutcode=es quiet splash --
LABEL driverupdates
menu label Install with driver ^update CD
kernel vmlinuz
append file=preseed/ubuntu.seed boot=casper debian-installer/driver-update=true initrd=initrd.gz locale=es_ES bootkbd=es console-setup/layoutcode=es quiet splash --
LABEL check
menu label ^Check CD for defects
kernel vmlinuz
append boot=casper integrity-check initrd=initrd.gz locale=es_ES bootkbd=es console-setup/layoutcode=es quiet splash --
LABEL
memtest menu label ^ Memory test kernel
mt86plus
append - LABEL hd
menu label ^ Boot from first hard disk
LOCALBOOT 0x80 append - DISPLAY isolinux.txt
TIMEOUT 300 PROMPT 1 F1 f1.txt
F2 f2 . txt f3.txt
F3 F4 F5 f4.txt
f5.txt
f6.txt
F6 F7 F8 f7.txt
f8.txt
F0 F9 f9.txt
f10.txt
As is above, default boot will be in English and will enable persistent mode (when working properly, then you have to replace the kernel vmlinuz).
Finally, unmount the USB pen, and to prove it, reboot the computer, ordering in the BIOS (it's up to you) to boot with the USB device.
I really going great. How about you?
0 comments:
Post a Comment