Slashdot Mirror


LFS 4.0 Released

Tekmage writes "For those of you who have never had the pleasure of rolling your own Linux install from scratch, take a moment to check out Version 4.0 of Linux From Scratch. Definitely for the techies amonst us, there is (IMHO) truly no better way out there to get down and dirty with the inner workings of our favorite OS." LFS organizes its documentation into "books"; 4.0's book is dated yesterday.

30 of 180 comments (clear)

  1. Re:Gentoo? by Ron885 · · Score: 4, Informative

    gentoo is an alternative, but its not the same as doing it by hand... you just start it and it does it all by itself... with lfs you can compile everything the way you want to with the options you want and dont need to mess around with the config files of gentoo.

  2. Re:Mirrors and /. effect by iamthemoog · · Score: 4, Informative

    For your enjoyment:

    North America
    Fremont, California, USA [8 Mbit] http://www.linuxfromscratch.org/lfs/intro.shtml
    Lufkin, Texas, USA [6 Mbit] http://linuxfromscratch.idge.net/lfs/intro.shtml
    Columbus, Ohio, USA [1 Mbit] http://www.us.linuxfromscratch.org/lfs/intro.shtml
    Calgary, Alberta, Canada [10 Mbit] http://www.ca.linuxfromscratch.org/lfs/intro.shtml

    Europe
    Mainz, Germany [100 Mbit] http://lfs.linux-provider.net/lfs/intro.shtml
    Amsterdam, The Netherlands [100 Mbit] http://www.nl.linuxfromscratch.org/lfs/intro.shtml
    Oslo, Norway [100 Mbit] http://www.no.linuxfromscratch.org/lfs/intro.shtml
    Lancaster, UK [100 Mbit] http://linuxfromscratch.mirror.ac.uk/lfs/intro.sht ml
    Vienna Univ. of Technology, Austria [64 Mbit] http://www.at.linuxfromscratch.org/lfs/intro.shtml
    Karlskrona, Sweden [10 Mbit] http://www.se.linuxfromscratch.org/lfs/intro.shtml
    Freising, Germany [4 Mbit] http://www.de.linuxfromscratch.org/lfs/intro.shtml
    Teesside, UK [256 Kbit] http://www.linuxfromscratch.co.uk/lfs/intro.shtml
    Odense, Denmark [256 Kbit] http://www.dk.linuxfromscratch.org/lfs/intro.shtml

    Australia
    Brisbane, Australia [155 Mbit] http://www.au.linuxfromscratch.org/lfs/intro.shtml

    Asia
    Singapore, Singapore [45 Mbit] http://www.sg.linuxfromscratch.org/lfs/intro.shtml

    --
    No Norm, those are your safety glasses; I'll wear my own thanks...
  3. Gentoo is a great iso-linux distro by Billly+Gates · · Score: 4, Informative
    If you want a balance between installing everything from scratch and a real distro with documentation, then I would recommend Gentoo.

    Gentoo is pretty much based on iso-linux from the linux from scratch project.

    The benefits are great documentation from their website and the best package manager out today. It truly feels like an os you own and not by some corporation since you have to put the os together yourself. The forums are also great. If you want to get your hands dirty and have a huge community help you out through the process then look no further.

  4. Pointless? by TriCCer · · Score: 3, Insightful

    I don't get you. LFS is a great way for people to get a grasp of what gnu/linux is/contains. If they have the time or not is up to them, but this definately is news for nerds. I'd say that lfs has great eductational value. but that's me.

    --
    c0w goes moo.
  5. Re:Gentoo? by Junta · · Score: 3, Offtopic

    That is really bizarre, I've never had any troubles. Especially killing the NIC and IDE controller, I wouldn't blame software if hardware is dying.

    With the portage system, I've never really *needed* to maunally edit unmasked versions of packages. Occasionally I will change the mask rules to try stuff at my own risk, but I haven't needed to do anything.

    All that said, it is at least as workable as LFS and much much easier. While both take forever to get up and going (my computer emerged for an entire weekend), the interactive time for gentoo makes it at least livable (I issued one emerge command with the packages I wanted and spent the weekend doing other stuff).

    LFS is useful for learning a bit more about the system and how it works, but offers few details that can't be gotten in easier ways. What I have found extremely useful about the LFS references is that when I do go after masked packages and have problems, the LFS hints can explain why it broke and a workaround.

    --
    XML is like violence. If it doesn't solve the problem, use more.
  6. Why LFS indeed? by ageitgey · · Score: 5, Informative

    I'm sure people are going to reply saying that LFS is a niche product and not news that many people care about.

    Well, though most of you are probably exposed to Linux through the desktop, Linux is winning it's in-roads in the industry through embedded systems and handheld devices (not desktop). Functional LFS installs can be as little as 5 megs or so and completely customized. Perfect to compete with several-thousand-dollar offerings from MS, Palm, etc.

    So if embedded systems are driving commercial linux support, in a way LFS and systems like it are more important in the short term than Mandrake and SuSE.

    So why not write your local LFS contributer and say thanks?

    --
    Uninnovate - Only the finest in engineering.
    1. Re:Why LFS indeed? by tzanger · · Score: 3, Interesting

      Although the LFS folks have been making the claim of an 8 or 5 meg installation, I've yet to see any clear docs on how to do it. I'd like to.

      That's because you need to learn it yourself. :-)

      Honestly though, I personally have a LFS-based firewall system (kernel+netfilter+ipsec+ssh+snmp+ntp+vim+perl (yes perl)) that fits in to an 8M CompactFlash card. Now I use 16M cards and add a 3M boot/config partition with grub, but making small linux distros is dead simple with uClibc and busybox (both are in the LFS hints).

      The basic recipe is to use uclibc and busybox, optimize for size (-Os), strip everything you can and once all of that is done, go through and remove any unnecessary libraries and files. Big hint: you don't need documentation on small distros.

  7. Re:This is only slightly off-topic but, by Ron885 · · Score: 4, Informative

    the reason LFS doesn't come with cron is because it is not an ESSENTIAL program to the operation of a linux system. you may want/need it, but someone else might not. it isn't essential so its not included, plus there are hints that provide information on how to compile it. that is what is so great about lfs, anyone in the community can contribute by writing a hint.

  8. educational value by mrm677 · · Score: 5, Insightful

    LFS is a great way to learn Linux. It truly helped take me to the next level of my personal understanding of how things work.

    However I would never recommend it for a production system. Even using it for a personal workstation takes loads of time to manage. One doesn't appreciate package management until they have installed a LFS system!!! Of course one could always use RPM/APT/DEB after doing a LFS installation...

    1. Re:educational value by jgkastra · · Score: 3, Interesting
      Package management?

      My current LFS install (3.3) has LFS installed in the default places, and everything else created after LFS in /opt in its own directory. The files are symlinked into their respective directories in /opt, and are uninstalled by reading the list of files in the /opt/foo/* directories. I can then rm -r the directory and uninstall the package.

      My next installation is moved towards installing the core in /usr/lfs and /lfs and symlinking out from there.

      This keeps me in check with the program version and what is installed with a simple ls. The only time I've had to use a package manager is to install Glide (I couldn't compile Glide, so I had to use RPM).

    2. Re:educational value by Tekmage · · Score: 4, Insightful

      Ditto on the educational value. I'd been using Linux in various forms since '93, but it wasn't until I started exploring LFS that I really began to understand and appreciate what went on behind the curtain.

      I'd argue the "never in a production system" point though. For an average end-user, sure. But if you have a particular end use(r) in mind (robot control, wearable computer, multimedia entertainment, home automation, etc) then it may be easier to enhance an LFS recipe than prune back a generic distro.

      --
      --The more you know, the less you know.
    3. Re:educational value by adam613 · · Score: 5, Insightful

      I beg to differ. I'm running LFS (a CVS version from early August) on a small-time production web/email server. It was much simpler to set up than RedHat because I knew exactly what was being installed where, and I had configured everything myself. It took the better part of the day to compile LFS and the other packages necessary to set up the server, but it was ready to go the minute I was done compiling.

      It's been up and serving for 38 days straight. It was up for a month straight before that, but I had to bring it down to add memory and remove the cdrom drive.

      I'm also running LFS on a desktop machine. It's not as pleasant to use as the server (KDE took 8 hours to compile), but it was definitely worth the effort it took to set up in terms of learning, stability, and configuration flexibility.

      I appreciated package management a LOT more before I started using LFS. I got into LFS originally because I got sick of Mandrake installing hundreds of packages I didn't recognize or need. I want to know exactly what's on my system and why. And I hate when a package refuses to compile or install due to dependencies which shouldn't be failing. I've never had that happen in LFS.

      LFS definitely has a steeper learning curve than pre-built distros. But what it loses in initial ease-of-use, it more than gains in long-term stability and simplicity. I wouldn't recommend that someone do their first (or second or third or fourth) LFS build on a production server, but after experimenting with it and really learning how it works, I can't go back.

      YMMV, obviously. Not everyone is paranoid and anal like I am.

    4. Re:educational value by CoolVibe · · Score: 3, Informative
      Also symlinks do have a very small effect in speed and usually take up 4k per symlink depending on your choice of file system.

      This "problem" has a simple solution. If the slack from symlinks bothers you that much, why not move to a extent-based filesystem like XFS? I use it on most my LFS and Gentoo boxes, and it works like a charm.

    5. Re:educational value by Simon+Kongshoj · · Score: 3, Informative

      The GNU tool you're referring to is probably Stow.

      Other good package management tools for LFS use include Depot, Graft, swpkg, opt_depot and the countless other free package managers whose names I have forgotten.

      --
      Six sick .sigs, the Number of the Beast!
  9. Re:problems with GCC3.2 though by ct.smith · · Score: 4, Informative

    I wonder if the problems are really gcc3.2 and not the source code. I've just spent the last week trying to compile a suite of programs with 3.2 just to discover that none of it compiles. However, each problem was actually due to use of non-standard C++ code. The issue is that old versions of gcc let a lot of non-standard code compile, but the newest version is much more strict. I would hope that the solution is to fix the code and not make the compiler do silly things to remain backwards compatible.

    I suspect that there is a large amount of code out there that has the same problem. Probably this includes the packages you couldn't compile.

    --
    ** Sig-a-licious **
  10. "pleasure?" by Anonymous Coward · · Score: 3, Funny

    "Linux install" and "pleasure" do not belong in the same sentence.

    1. Re:"pleasure?" by Xpilot · · Score: 3, Funny

      This guy seems to disagree with you.

      --
      "Backups are for wimps. Real men upload their data to an FTP site and have everyone else mirror it." -- Linus Torvalds
  11. Re:Gentoo? by Fiver-rah · · Score: 3, Informative

    That's an unfair characterization. Sure, you get to compile your own kernel and set up a network and all that stuff. But installing new software is always as easy as typing "emerge ". Saying "everything else needs to be installed from scratch" is pretty unfair. There are scripts and ebuilds written so that pretty much all you do by hand is set up the file systems, handle networking, and compile the kernel. You don't need to worry about where to download things, or what to download, or which patches to apply or anything like that.

    --
    Read Bujold. Free (as in
  12. The Way to Learn by fm6 · · Score: 4, Interesting
    I've heard popular distros like Red Hat criticized because they do too much hand-holding. The theory is that you'll learn more about how Linux works if you use a less user-friendly distro, such as Slackware.

    But if you need handholding, you really need it. On the other hand, if you're comfortable with using Linux, but want to know more about how it's put together, even Slackware is too high-level. LFS, on the other hand, is the ultimate Linux-learners tool, because it doesn't automate anything.

  13. Re:This is only slightly off-topic but, by shoppa · · Score: 4, Interesting
    Three points:
    1. Cron is not essential.
    2. Cron has historically been a security risk. What's the patch level on Vixie-Cron? :-)
    3. Cron packages generally (there are exceptions) require a sendmail-like mail system for reporting results. Sendmail (and even its not so cumbersome clones) isn't generally necessary or even wanted.
    All that said, there's a wide choice of crons you can install, just see the BLFS (Beyond Linux From Scratch) hints.
  14. Re:Gentoo? by handsomepete · · Score: 3, Insightful

    I totally agree. I use gentoo now (bizarrely enough) because it's simple to maintain and not terribly hard to install in the first place if you have a weekend to kill, especially in comparison to lfs. There's a massive difference from installing KDE from source and typing 'emerge kde.' As others have said, lfs is great for getting your hands dirty and learning some stuff. Gentoo is for after your hands are dirty and you want to clean them up while still getting that feel-good speed from compiling every package for your system from source. Yeah yeah yeah, you have to hand edit all of the X/ftp/ssh/profile/etc config files and that's a big pain. Deal with it. You should be doing that anyways.

    Why is that everytime someone mentions lfs, someone has to say, "Why not just use gentoo?" It makes us (the users) look like the next generation zealots. I have a better idea - learn what distros do what things and at what difficulty and then choose for yourself. Suit your own needs, dammit.

  15. Re:This is only slightly off-topic but, by Johan+Veenstra · · Score: 3, Informative

    A text webbrowser, a ftpclient, telnet etc is also pretty basic, but don't expect to find it in LFS. LFS is sorta just enough to build another LFS from.

    If you want that cron/ftp/telnet/lynx/cdrecord/lame/xfree/kde/gnome etc etc stuff, check out Beyond Linux From Scratch:

    http://beyond.linuxfromscratch.org/

    Johan Veenstra

  16. Re:Gentoo? by Junta · · Score: 3, Interesting

    To be fair though, knowing which patches can and should be applied to particular versions of particular packages is not very useful, long term knowledge. Most of the patches installed by Gentoo are bugfix patches, which are *really* short lived. The occasional feature enhancement patch is relevant longer, but not too much longer. Same with the where to download and what to download. The learning experience of LFS basically boils down to knowing *every* dependency in your system, and how to manually configure every package (though that configuration step is not taken care of in gentoo). The dependency knowledge is of dubious value, as that too is subject to change in the details. All gentoo does is hide the nitty-gritty of requisite packages and keeps you from having to know every dependency. I did a Linux from scratch before (before the 'official' LFS existed, played it by ear), and it really doesn't teach you much that you don't learn in time with distributions. The useful knowledge is how to *use* the applications, not install them.

    --
    XML is like violence. If it doesn't solve the problem, use more.
  17. Re:LinuxFromNotSoScratch.com by amccall · · Score: 5, Insightful
    What do you want them to start from? Flip 0's and 1's on a front panel?

    In order to build ANYTHING you need an existing tool chain. Here that means gcc, bash, ld, etc... LFS starts with creating a bootstrap system using your existing distribution: this existing distribution might just be a bootable ISO cd. LFS DOES go through everything: the kernel, gcc, glibc, ... everything.

    LFS will show you how to build your own Linux, step by step. It will tell you everything you need to know to understand the bootup process.

    If you want to run LFS on a 486 though, you'd probably be a lot better off getting it going from your main system, and then copying over. glibc alone can take HOUR(S) to compile on a modern system.

    --
    ------ 24.5% slashdot pure
  18. Re:LinuxFromNotSoScratch.com by jonadab · · Score: 3, Insightful

    > Okay, so what do these people mean by "Linux From Scratch"?
    > Installing another distro first to install "required tools"
    > is in my view not installing from scratch.

    If I understand correctly, the other distro you use to build
    your LFS is not part of your finished project, and does not have
    to be installed on the same drive or end up running on the same
    hardware. i.e., you can take the hard drive from your 486 and
    pop it in any working Linux system and build LFS on it, then
    put it back in your 486 and use your shiny new LFS. At least,
    I think that's the theory.

    --
    Cut that out, or I will ship you to Norilsk in a box.
  19. Re:Too many todo's by HIghoS · · Score: 5, Informative

    Hey fear not. Getting KDE running on an LFS system is not *that* hard.

    There's a subproject of LFS, that isn't as well known as it should be, that's documenting the process of installing software after (or I should say 'beyond' :) the completion of the lfs-book.

    http://beyond.linuxfromscratch.org/view/cvs/

    In there, you will find all the information required to install the graphic libraries, X11, KDE, and so forth.

    You can also check out the lfs-hints for additional software/issues that are not covered by the blfs-book;

    http://hints.linuxfromscratch.org/hints.shtml

    It's more about taking the time todo it ;-)

  20. Re:LFS as the basis for a distro by dogas · · Score: 3, Informative

    Knoppix essentially does what you're saying.

    It's a distro that doesn't use the hard drive at all. It boots from a cd, detects your hardware, and loads up KDE3. It's does a pretty good job at hardware detection, although saving your settings (and files) for the next time is kind of a pain. However, for trying Linux out without screwing up your machine, Knoppix does a pretty good job.

    --
    'When the going gets weird, the weird turn pro.' -HST
  21. Re:Gentoo? by thing12 · · Score: 3, Insightful
    Why is that everytime someone mentions lfs, someone has to say, "Why not just use gentoo?"

    Because it's a troll. It gets discussion started...

    It makes us (the users) look like the next generation zealots. I have a better idea - learn what distros do what things and at what difficulty and then choose for yourself. Suit your own needs, dammit.

    Exactly! Over the past 8 or so years I've used Redhat, Debian, Mandrake, a couple of BSD's, and LFS. Now I use Gentoo because it suits me - and I think it would suit nearly everyone who has an interest in LFS. I can't see why most people, even those who want the flexiblity of a source based system, would spend the time to maintain an LFS based system unless they had nothing on a computer except learn about how the computer works. You have no time left over to take advantage of what the computer can actually do for you -- save you time. How much different are your compile time choices going to be from the ebuild's defaults? And if they are different, then edit the ebuild file.

    LFS is just tedious to maintain. Which is part of the reason why it's perfect for an embedded system. You get exactly what you need, nothing more, and you never change it.

    As others have said, lfs is great for getting your hands dirty and learning some stuff. Gentoo is for after your hands are dirty and you want to clean them up...

    LFS is a wonderful experience to install. I'm not discouraging anyone from going out and installing LFS. I just believe that after you've done it once, you don't need to do it again - and that's where Gentoo comes in. Gentoo essentially is what Automated LFS aims to be.

  22. Re:LFS is really good by CrazyBrett · · Score: 3, Informative

    Ok, here's an example. My linux system at home (functioning as development machine, router, and firewall) is LFS. I've got each package installed in its own subdirectory under /pkg, and I've got /bin /lib /include and /man full of symlinks to the corresponding files in those directories (this is so utils like gcc, man, and the shell can find things without having to go searching all over the disk).

    Removing a package is trivial: just delete its directory and remove the symlinks. Upgrading a package is trivial too: install the new package into a new directory, update the symlinks, and remove the old dir. If an upgrade has some problems, I can roll back to a previous install by rolling back the symlinks (provided I haven't deleted the old installation yet). My next project is to create a program that can manage the symlinks automatically, to make it even easier. (Preemptively: yes, I know about "stow", no, it doesn't do what I want)

    I don't know of any regular distribution that lets you do that :)

  23. Re:LinuxFromNotSoScratch.com by batkiwi · · Score: 3, Insightful

    When you bake cookies "from scratch," that doesn't mean that you're buying some chips-ahoy's in a ziplock bag and heating them up in the microwave.

    It means that you need some tools, a cook book tells you the ingredients and what to with them, and you bake yourself some cookies.