Sunday, July 22, 2012

Starting Tips


#!/usr/bin/perl

## ----------------------------------------------------------------------
## Welcome to my Linux From Scratch blog! This blog is formatted 
## completely in perl (or other system-friendly scripting languages). 
## This blog recounts my experience in attempting to put together a
## Linux From Scratch (LFS) distribution. This is primarily a learning 
## experience. 
##
## Getting Started
## ---------------
## You need a "host" system. A host system is a Linux-based system from 
## which the developer can build an LFS system. On the LFS website they 
## do not endorse any particular distro of Linux; it can be anything 
## (RedHat, Debian, Ubuntu, etc.). This statement isn't misleading but 
## the choice of the host system is important. Ask yourself, "How much 
## pain do I want to put myself through?" If your answer is "Very Little"
## then choose a mainstream distro as Googling for answers will make it
## much easier. 
##
## The distro I chose was Debian. The reasons being:
##
## 1) Debian is very stable (2 releases per year).
## 2) Debian's net installer is VERY thin, which is great if you can 
##    work from command line and have no need of a graphical 
##    environment.
## 3) The tools are (almost) all there from the beginning.  
##
## Other distro's are good too, it just comes down to what you the 
## developer feel comfortable with. 
##
## *** Do your work in a virtual machine! I can't say enough about this 
## approach! Using a product like VirtualBox to learn how to put together
## an LFS distro is invaluable because you can use snapshot's to bookmark
## your progress before stepping into a risky set of steps (i.e. building
## gcc). Another suggestion in this regard is to just load from ISO file;
## it seems to go faster this way.
##
## 
## Really Getting Started
## ----------------------
## So you've got your host system distro chosen and VirtualBox is ready
## to go. You start the machine up... now what? Time to set up your 
## host system. If you're like me you go through the distro wizards to
## set up the host system: Language, hostname, auto-prepare 
## the hard drive... WRONG!
##
## Do not let the host distro auto-prepare your drive! Let it set it up
## to the extent you leave a large amount of free space in the file system.
## When I say free space I mean "unpartitioned" space. I typically give
## the host system very little space (10G) and leave the remainder 
## of the space open for LFS. 
##
## Example of Finished Partitioning (on Debian):
##
## SCSI1 (0,0,0) (sda) - 33.1 GB ATA VBOX HARDDISK
##      #1  primary   10.5 GB   B    ext4
##          pri/log   22.0 GB        FREE SPACE  <---- 
##      #5  logical  534.8 MB      F swap         swap
##
## Now just let the host system continue on with the setup wizard. 
## Your Host VBox setup is now complete!