Inkedsphynx wrote:So, I'm basically a complete noob when it comes to using Linux. I had a very brief amount of exposure to it over 10 years ago, since then, nada. However, since moving into a new job last month, I find that I need to do some serious learning, as I'm working in a primarily Linux environment.
So, I started putting an idea together in my head. I have a system checked out from work for me to use at home to learn Linux (though I'm likely going to attempt to raid some friend's hardware stashes in order to assemble a system I can permanently keep if this works). Now, for me, I can read books and webpages and man pages all day, but I am not really going to learn anything until I do something. So I started thinking to myself, "What could I do with a Linux system that would actually be something I need?
Browsing around the interwebz, I came across the idea of setting up a Linux box to act as a router/server. Seems like a great way to learn, especially since I know very little about networking in addition to my limited knowledge of Linux.
I chose to use Gentoo as I'd seen a co-worker running it, and doing basically everything through a console as opposed to a GUI. Intuition tells me I'm going to learn a lot more operating on the console level as opposed to relying on a GUI crutch.
So, my goal is to setup and configure a working Gentoo server/router without a GUI or at least with a minimal GUI. I decided to post on here and use this as a thread to track my progress, get tips/hints, ask questions, and generally share my adventure into the world of Linux. Updates may not come to fast, as I don't get much time I can spare to the project, but I'm going to do my best to keep progress up.
So far the project consists of me downloading a Gentoo minimal install .iso and burning it to a cd.
If anyone has any comments or tips/knowledge to share, please feel free to do so at any time.
You probably should ask this question on the Gentoo Linux forums. You usually will receive more useful information there than you can get at other forums, especially a forum like this, which has an emphasis more on hardware than on software. Fortunately, we have at least two Gentoo users on these forums, one of which is myself. I happened to see your thread from the main page, so I can give you some advice on this matter.
Read the following documents:http://www.gentoo.org/doc/en/handbook/http://www.gentoo.org/doc/en/xorg-config.xmlhttp://www.gentoo.org/doc/en/xfce-config.xmlhttp://www.gentoo.org/doc/en/home-router-howto.xml
I am suggesting XFCE because you want a minimal GUI. You literally have dozens of other options in this area, with the more popular KDE and GNOME desktop environments being among them.
I don't know how much has changed, but last time I worked with Gentoo, I learned that it was always better to do a manual install instead of using the GUI installer on the LiveCD. For some reason, the kernel that genkernel spat out as part of the GUI installer instantly broke the moment I tried to do anything that wasn't configured during the installation. Besides, you'll learn more doing a manual install
The GUI installer was abandoned for that exact reason. There were too many configurations to support to be able to have it work every time.
Inkedsphynx wrote:I haven't decided how I want to do the install yet. I did download the minimal install .iso and need to stick it on a CD (just noticed a few minutes ago I stuck it on a DVD by mistake). I'm thinking I might go with that method just to get me up and running and then look into other methods after the fact, so at least I've got something functioning. I'll have to do 2 installs anyway, since I'm going to start with this system I have from work and eventually switch to a system of my own once I can obtain the requisite hardware.
Use System Rescue CD to do the installation. It is a fork of Gentoo Linux that exists exclusively as a LiveCD. Many Gentoo Linux users use it to do Gentoo Linux installations because they find that it is better than the official LiveCD.http://www.sysresccd.org/Main_Page
If you want to have your second system up and running in a short amount of time and both systems are the same system architecture (e.g. both are amd64), you can configure your system's CFLAGS and CXXFLAGS (which are likely a clone of your CFLAGS) to be optimal for the lowest common denominator of the two systems to which you will install Gentoo Linux and then configure Gentoo's package manager to generate binary packages:http://www.gentoo.org/doc/en/handbook/h ... #doc_chap4
You will want to do this prior to compiling software on the first system and if you want to make sure all of the binary packages are ready made by the time you install Gentoo Linux on the second system, you will want to run "emerge -eav world" to rebuild all of the software on the system. You could run this overnight. You can also specify the "--jobs" flag to have it build as many packages in parallel as possible. This might cause your system to run out of memory, so you could specify something like "--jobs=n" to limit the number of packages built simultaneously to n. Of course, you would specify a number in place of "n". There is presently a bug in the system package manager
that can cause build failures when multiple packages are built simultaneously, so if you do not want to deal with it, you should probably not bother with the "--jobs" flag.
Once the binary packages are built and you are configuring your second system according to the Gentoo manual, you will want to skip the step where you install a portage snapshot and instead copy the contents of /usr/portage/ from your first system to your second system. You will also want to copy over your /var/lib/portage/world file, your /etc/locale.gen file, and if it exists, your /etc/portage/package.use file. You will then want to verify that you have the same global USE flags in /etc/make.conf. You can likely copy your /etc/make.conf file too, but you will want to double check its contents to verify that they are appropriate for your new system. Once you have done that, you can then run "emerge -kave world" to reinstall all of the software that you had on the first system on your second system via binary packages, which are contained in the /usr/portage/packages directory is contained inside of /usr/portage. After all of the binary packages are installed, you can proceed as you did in the guide, but things will be much faster, because all you need to do is manually install your kernel, boot loader and do some basic configuration work.
Keep in mind that after the binary packages are installed, you could delete the contents of /etc/portage/packages/ and also change your system CFLAGS and CXXFLAGS to be more specific to your system. You could then either run "emerge -ave world" overnight to rebuild everything to be "optimal" for your system's processor or you could just let them pass and as you update your system by doing something like "emerge --sync && emerge -avDuN world", the new versions of software will be compiled specifically for your processor. The difference in performance will not be more than 1% to 2% either way, so whatever you do is fine.
Also, you probably should decide with your first system whether you want to use software that is marked stable or marked testing. Gentoo Linux by default installs only software marked stable. Most of the software marked testing is considered stable by upstream and is basically meant to be available to more advanced users before it is cleared for use by the general public. If you want to be on the bleeding edge and do not mind the occasional hiccup, I suggest you go with the testing tree. If you want to get software that has been thoroughly tested by both upstream and downstream, I suggest that you go with the stable tree. It is possible to mix trees (i.e. select specific packages from one tree when your system is configured to use software from another), but that will cause headaches when dealing with upgrades, so I do not recommend doing it. There is documentation on how to do these things in the handbook. Here is the page from the x86 handbook.
By the way, if you want a 64-bit system, you will likely want to use the amd64 handbook, although for intents and purposes, each version of the handbook is essentially the same as long as you know what you are doing.
just brew it! wrote:Unfortunately I've got zero experience with Gentoo. All of my Linux explorations to date have been with Redhat/Fedora and Debian/Ubuntu, so I can't give much in the way of Gentoo-specific advice.
How fancy do you want to get? There are some fairly simple Linux firewall tools available -- ufw (command line) or firestarter (GUI), for example. Or you can set up a full-blown, "industrial strength" firewall/router package like shorewall.
You'll need two NICs, of course. So if the PC you're planning to use has only one, your first order of business will be to install and configure a second NIC...
Are you not glad that I am here?
Disclaimer: I over-analyze everything, so try not to be offended if I over-analyze something you wrote.