Robert Elder Software Linux Operating System
blog.robertelder.org
blog.robertelder.org
Today I'm a Gentoo/Funtoo users, which is sorta like LFS with package management. I've had to do a lot of work with embedded systems and Linux servers in my career, and I feel like using LFS for nearly a full school year in University really helped me understand Linux fundamentals.
(and if I'm wrong and/or the bash patch just makes things lots easier, then I'd love to see it posted somewhere people who know the bash source well can see if they can help turn it into a real feature, because custom error handlers seem as awesome as custom completion handlers)
The source patch is located at
~/.fop/patched-executables/bash-4.3.30-post-patch-call-python-hook.patch
is has been applied after the LFS bash patch.
This patch is extremely sloppy and breaks certain things, but it does what I need for now. The way it works for bash commands is before handing a line of input off to be processed, it calls an external python hook which decides whether that line of input should be ignored or not, gives the hook a change to perform it's own custom behaviour (such as print an error message).
(I checked, even malformed lines like '|foo' go into the history)
Another couple reasons I patched bash: Being able to detect when users use tab completion and using the up key to check history. Those are 2 massive productivity enhancements, and I wanted to created modules where I can verify that they used these.
Has patched versions of bash and nano to fit in with the author's intention to provide a learning tool. Designed to run under virtualbox, not as a traditional install. The .ova image includes training material.
For educational purposes it's acceptable but still less effective than simply creating an educational environment on an existing distro.
Acceptable only because you won't have as much exposure and therefore security maintenance won't need as much of your time as it would in a distro used for servers or clients.
Still though, my point is that there are very little valid reasons to build your own distro these days. To distribute a certain set of tools and defaults you have the option to base your distro off of Debian or Ubuntu for example. Fedora has great options for making "spins" of their distro.
And the things the author mentions as custom bash and custom nano for example, those things could just as easy be in a virtual environment using aliases, cgroups or a number of other features available in any Linux distro or shell.
Let's call it what it is, three dead trolls had the right of it; "setting it up is half the fun". That's exactly what this project was for the author. A fun but largely pointless exercise in setting up a Linux distro.
New distros should bring something more unique to the market than just a toolset. A properly made package manager, albeit a major change, should easily be deployed on any distro.
Most distros even have well developed support for custom kernels, as long as you package according to their guidelines.
When it comes to using C keep in mind a lot of developers are interested in lower-level interactions--perhaps at the hardware level. There is probably value in creating simplified, isolated environments that can test certain features in a VM.
"For educational purposes it's acceptable but still less effective than simply creating an educational environment on an existing distro."
How is it less effective? If anything the author now knows more about setting up a full environment and can tailor make a minimal setup to showcase some specific features. These minimal setups can then be hosted in a VM preconfigured for students.
Just some thoughts. I've never done LFS or taught C programming. Though I do use C often and enjoy the language, warts and all :)
>How is it less effective?
It's simply overkill and insecure to not use an established distros patch and package management.
The most effective thing is to create packages, or if you want some larger modifications a "spin" in fedora language.
I can't see any reason why you'd be restricted by packages. You can deploy your own compilers, your own shells, your own init system if you want. You can deploy patched kernels as long as you follow packaging guidelines.
It's smarter to spend time on packaging guidelines and internal yum repos than to build everything from scratch.
Overall this is a project born dead if its true intention is to be a useful tool for the beginners.