I had a system failure last week. It seems the power supply fried both
the motherboard and the SATA drive.
What I did was build up a new system: The new Mini ITX motherboard has
an Intel Atom D2700 (2.1 GHz, 4 Cores) ($90) with 2GB Ram ($33) and a
Seagate 500 GB SATA Drive ($80). A new case/power supply was $55.
I probably could have saved a little by buying on-line, but I didn't
want to wait for delivery.
This system is used mostly for backups and to output some mp3 tracks to
speakers so I didn't lose any data. I still have all the originals.
In any case, I had a raw system and wanted to put LFS on it. I thought
I'd try to set up a Debian install for the initial system so I could
build LFS on it.
I started by downloading debian-live-6.0.5-i386-rescue.iso and putting
it on a thumb drive. This worked, but using dd seemed to hang. Finally
I figured out that the following worked:
# dd if=debian-live-6.0.5-i386-rescue.iso of=/dev/sdd \
bs=1048576 oflag=direct
The copy time was a little over a minute.
I was able to boot the new system from this thumb drive. I used parted
to set up a gpt partition table that eventually looked like:
$ sudo /sbin/gdisk -l /dev/sda
GPT fdisk (gdisk) version 0.8.5
Partition table scan:
MBR: protective
BSD: not present
APM: not present
GPT: present
Found valid GPT with protective MBR; using GPT.
Disk /dev/sda: 976773168 sectors, 465.8 GiB
Logical sector size: 512 bytes
Disk identifier (GUID): 577AEE2B-CA4C-45F0-940D-EF6A7B2A9F52
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 976773134
Partitions will be aligned on 8-sector boundaries
Total free space is 911178814 sectors (434.5 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 20479 9.0 MiB EF02 primary
2 20480 215792 95.4 MiB 0700 boot
3 215793 4122043 1.9 GiB 8200 swap
4 4122044 23653294 9.3 GiB 8300 debian root
5 23653296 44624815 10.0 GiB 8300 LFS
6 44624816 65596335 10.0 GiB 0700 debian x86_64
Although I initially used parted, I found that gdisk
(gptfdisk-0.8.5.tar.gz) is a much more comfortable interface for gpt
partition tables. It's a package that needs to be added to BLFS.
Note that the first partition is for grub. I do need to reset partition
6 to Linux (8300).
----
While I was able to install the rescue system to partition 4, it was a
32-bit OS, so I downloaded debian-6.0.6-amd64-CD-1.iso, again copied it
to the thumb drive, and installed in partition 6.
Now to install LFS. There were a lot of issues with the host system
requirements. The first thing to do though was to update the packages
just installed:
# apt-get update
# apt-get dist-upgrade
One thing that Debian does is to set up bash-completion. For me, this
is not desired because it gets in the way of filename tab completion and
pollutes the environment.
# apt-get remove bash-completion
# dpkg --purge bash-completion
Now add the packages needed for LFS:
# apt-get install bison
# apt-get install gcc
# apt-get install ncurses-dev
# apt-get install bzip2
# apt-get install make
# apt-get install gawk
Now I'd like to get the LFS book and build via jhalfs
# apt-get install subversion
# apt-get install xsltproc
# apt-get install docbook
# apt-get install libxml2-utils
# apt-get install docbook-xml
# apt-get install tidy
And manage the partitions
# apt-get install gdisk
Get the book:
$ svn co svn://linuxfromscratch.org/LFS/trunk/BOOK lfs-svn
$ svn co svn://svn.linuxfromscratch.org/ALFS/jhalfs/trunk jhalfs
Now mount the lfs partition and get the sources:
# mkfs -t ext4 /dev/sda5
# mount /dev/sda5 /mnt/lfs
# chown bdubbs.bdubbs /mnt/lfs
$ mkdir /mnt/lfs/sources
scp LFS sources from development system.
At this point, I ran the jhalfs configuration and then started the LFS
build. It's running now. I'll update this when it's done.
-- Bruce
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page