 Today, I'm going to be running through an installation of Gen2. I did a Gen2 installation video probably about three or four years ago, and I haven't actually installed Gen2 myself personally on any of my equipment probably in nearly two years probably. So it's been a while for me. So today I wanted to actually do a Gen2 installation and record it on camera for you guys because I have been getting people asking me to do this kind of video. And I think a lot of people are asking about it because they're curious about the install process for Gen2. Many people have this misconception that the Gen2 installation process is really, really hard, really, really difficult, and it's actually not hard at all. Those of you if you've ever installed Arch Linux, for example, you know, the Arch install and the Gen2 installation process are practically the same. You do a lot of the same commands. The only difference is some of these commands, once they have to execute, take a lot longer in Gen2, right, especially installing software because Gen2 is not a binary distribution like Arch Linux and most other Linux distributions that you guys know about. Gen2 is a source-based distribution. So when it's installing software, it has to compile the software. And that takes a long time. The installation process for Gen2 can take a few hours. It could even take a couple of days on really old hardware. So it's lengthy the process of installing Gen2, but it's really not hard at all. Now I do have to consider that Gen2, you know, to install it in a timely fashion so it doesn't take all day, you know, I need to do it on a machine that has some beefy specs. The only machine that I have that's halfway decent as far as the specs on it is my main production workstation here at this desk. The only problem is that, you know, recording video and editing video and streaming and things like that, you know, doing this kind of work that I do on this YouTube channel also requires a beefy machine. And again, I only have the one machine, so I can't install Gen2 on this machine and also record it using this machine. So what I'm going to have to do today is I'm going to install Gen2 inside a virtual machine. But don't worry, every time I do one of these Arch installs or Gen2 installs inside a virtual machine, I get people asking, hey, man, could you do it on real hardware? Because they think the process is different. The process, the commands you enter are exactly the same. So don't worry that I'm doing this in a virtual machine. The installation process, I promise you, is exactly the same. I've installed Gen2 on physical hardware just like I'm going to install it inside a virtual machine. I've installed Arch, you know, in virtual machines and on physical hardware. The commands I enter are exactly the same. You guys, if this is your first time installing Gen2, I also strongly suggest installing it in a virtual machine first, you know, installing it in something like virtual box just to practice before you actually try to do it like on a main production machine because you may screw up, right? And because the installation process is such a lengthy process, it's better to practice a few times in a virtual machine before you actually format the drive on your main production machine. And then, you know, you mess up the installation process two or three times and you're without a computer for a couple of days. So do this inside a virtual machine if this is your first Gen2 installation. So let's go ahead and get started. The very first thing you want to do is you want to pull up the Gen2 handbook. So the handbook is basically your installation guide. The installation guide, first of all, the very first thing you want to do is select your CPU architecture from almost everybody that's going to be AMD64. That's your standard x8664 processor. There were other architectures available such as ARM. They even had a RISC-5 and there's even some old PowerPC stuff there. But for most people, what you want to do is get the Gen2 AMD64 handbook. So let's go ahead and get into the installation. Installing Gen2. Now, some of this I'm going to skip because some of it is covering really basic stuff like the very first chapter here about the Gen2 Linux installation. That introduces you to, you know, some of what you're about to get into with installing Gen2. I'm not going to bother reading that if you guys want to read it. Go ahead and check that out. Choosing the right installation medium. I'm not going to cover this either. This is a, you know, how are you actually going to install it? I'm telling you right now I'm going to go grab one of the ISOs from the Gen2 downloads page. I'm going to grab a Stage 3 ISO. That's what most Gen2 users probably do is a Stage 3 installation. This page here also covers how to verify the ISO as far as checking the checksum. I'm not going to do that here on camera. Also I'm not going to cover how to burn the ISO to a USB stick. I hope you guys know how to download an ISO and burn it to a USB stick. If that seems like you need help with that, then please just stop with the Gen2 installation right now. You're not ready for it. The next chapter is configuring the network. Now I will open this just in case I need it. We may not need it, but this is for setting up the network, the Ethernet connection. I'm going to be on a wired connection. I know some of you guys are probably going to do this on a laptop. You're going to need Wi-Fi. Understand that I'm going to install Gen2 for my machine. So I'm going to do certain things that maybe aren't going to be what you need on your particular hardware. Just understand that don't copy me. If you're doing this on a virtual machine, it's fine to do exactly what I do. If you're doing this on physical hardware, then some of the commands I enter, you need to enter different commands. So don't blindly follow this video. Actually read the handbook and make sure you're doing what you need to do for your particular hardware. Now let me switch over to my desktop. This is the virtual machine I created. I gave this VM six threads of my 24 thread threadripper. So that's plenty for the VM to work with. It should install Gen2 rather quickly. Of course, I gave it 12 gigs of RAM. Typically what you want is however many CPUs you give a VM, you want to give it twice that much of RAM. And let me go ahead and start the VM. And we get a boot prompt. If I don't do anything, it's going to try to boot off the disk. We haven't installed anything. So there's nothing to actually boot into. So I'm just going to hit enter. And we get into a TTY prompt, essentially a live environment, it's just a TTY prompt. First we need to load the key map. If I don't hit anything in the next few seconds, it automatically defaults to US key map. 43 was the number of the US key map if I needed to enter the number. And then we get to this prompt here. Now if I go back to the handbook, you can read a little bit about how to check your IP address, check to see if the network is working. I'm not going to read all of this to you guys. If you guys want to check this out, go ahead and read it. I just want to verify that networking is working. And if it is, then we can move on to the next thing. So if I run this command here ping, and I'll just ping Google.com. And I'm getting output returned. It's actually hitting Google.com. So networking is working. Control C will kill the ping. You just wanted to give it a number of pings to do. I could do a dash C for count three. And then Google.com. And it will ping Google exactly three times. And then I don't have to bother doing the Control C to kill the ping. Now the next part of the installation process is probably the most important part of installing any operating system really is preparing the disks. So this is setting up your partitions. Now I strongly urge you guys, I know I skipped the first three chapters essentially in the handbook. You can get away with that. I strongly recommend though that you read this. So really pay attention to preparing your disk. You need to decide whether you're going to do a legacy boot or UEFI. So we're talking about master boot record versus, you know, GPT. And if you don't know what that is, again, read this page. I'm going to do legacy boot in this VM. But it's really the commands for installing legacy boot or UEFI are practically the same. They're just some minor differences. I may mention those differences as I go through the installation process. By scroll down the page, you get an example of a default partition scheme. You should create three partitions, at least according to them. And you don't have to do this, but this is just what they recommend. You should do a boot partition, a swap partition, and then, of course, your main partition for your data. And that's exactly what I'm going to do. And they recommend using the F disk utility or parted. Those are two command line utilities you can use to set up your partitions. I'm not actually that familiar with either F disk or parted. I usually use a program called CF disk. But for this video, what I'm going to do is I'm going to use F disk because since that's what the Gen 2 handbook recommends, I want to follow the handbook as closely as possible. I don't want to veer away from it because then, you know, you guys might be a little confused about what I'm doing. So the first thing I need is the name of this device because it's not going to be SDA the way it is in the handbook. In this virtual machine, it's typically VDA. But if I run this command, LS BLK for list block, you will see that my drive is VDA. So that is the actual device. So I want to do F disk slash dev slash VDA. And then I don't know the F disk commands because I don't run F disk that often. So it tells you to hit them for help. That's what I'm going to do. And then it gives you all the commands for F disk here. And it looks like we need to create a new partition table. Now, do I want to do a DOS partition table for Master Boot Record? Or do I want to do GPT for the UEFI? I'm going to do the DOS partition table. So I'm going to hit O and then enter. And it said created a new DOS disk label with disk identifier, yada, yada, yada. Now let's go ahead and add our partitions in. Adds a new partition. So I'm going to do in and then is that primary or extended? It's going to be primary. And then what is the partition number one through four for legacy boot? If you're doing UEFI, you have potentially up to 128 partitions you could choose from. We're going to do partition one here. The first sector just hit enter and let the first sector be the first sector. And then the last sector, you could give it a number. But what I like to do is just do plus. And then however big you want to make it, this is that boot partition that they recommended in the handbook. And they recommended 256 meg. So do plus 256 capital M for the last sector. And that created a partition one of type Linux, the size 256 megabytes. Great. Now let's do in for new partition, primary partition. And this time it's going to be partition two. And the first sector, once again, just hit enter. And then the last sector, how big do we want to make? This will be our swap. I'm going to make this only one gigabytes here in the VM because the swap partition is kind of wasted space in the small VM. If I make a huge swap partition, I'm not going to have enough disk space to actually do the installation. But I did want to create a swap on camera. It'll just be a small one gigabyte swap partition created new partition type of type Linux size one gigabyte. We will have to change the partition type for the swap because it needs to be type swap instead of type Linux. But we'll get to that in just a second. One more time, let's do in for partition and then primary. And then the partition number this time will be three. And then the first sector just hit enter for the default. And then the last sector, we wanted to take up all the remaining space on the disk. So this time just hit enter. All right. Now let's change the partition type of that swap, especially. So hit M for help. And let me see type T to change a partition type. So let me hit T on the keyboard. And then what partition number are we changing to was the swap. And that's the one I want to change. And then the hex code or the alias, I could type L to get a full listing of all the available types and swap is 82. So the aliases Linux is 83 swap is 82. And that's the only ones we really need. I'm going to do 82, of course, for this swap partition. All right. And then M for help one more time. Now, one thing we didn't do, we haven't made anything bootable yet. So let's hit a to toggle a bootable flag. What partition needs to be bootable? Well, partition one obviously needs to be bootable. That was our boot partition. And if everything we've done is correct so far right now, I think we could just write the table to the disk and exit. So just type W for write, hit enter. And that should be all we need to do with F disk and setting up our partitions. Now let's get back into the documentation. Now we got to talk about creating our file system. Now in the file system, I'm going to go with extend for. That's typically what I go with. You guys want to install anything else, you know, butter FS or XFS or Ryzer or whatever file system you want to put on the machine. You do you just read the documentation for me. I'm going to do extend for. So I need to run the command mkfs dot extend for. That's make file system extend for. So let me switch back over to the desktop here and let's go ahead and start making these. Now they recommended doing extend to for the boot partition. That's kind of the old school Linux way extend for would also work for the boot partition. But since they recommend doing extend to. So let's do mkfs dot extend to space. And then slash dev slash VDA one is the first partition on the virtual machine on physical hardware. Typically this is going to be SDA one. But here because it's a virtual disk, you know, they call it VDA one. And let's write that. All right. And then now we've made that file system. Now let's make the swap. So mk swap is the command to make a swap slash dev slash VDA to was the swap partition. And we've just created the swap. Now let's actually turn the swap on. So do swap on and then slash dev slash VDA to. And now finally let's make the extend for partition on the third partition. So mkfs dot extend for space. And then slash dev slash VDA three. And now that we've created that third partition, especially, you know, we've got that extend for partition. We need to actually mount that because that's where everything we do from here on needs to actually be placed on that particular partition. So let's mount slash dev slash VDA three. And then I'm going to space. And then where am I mounting it to? I'm going to do slash mount slash gen two and hit enter. And let's get back into the install guide in the handbook. The next chapter is installing stage three. So I mentioned we were going to do a stage three installation. Now, what do you need to do is you actually need to, from the command line, go and download the stage three tour ball. Before that, though, they also talk about setting up date and time. You typically won't need to do this. If the date is correct. So if I type date, let me verify that that's actually, yeah, that's correct on my system, but they do in the handbook discuss how to change that time and date if, for some reason, it is needed. So let's go ahead and download the stage three tour ball. So the first thing we need to do is we need a CD into slash mount slash gen two. So let's go ahead and do that CD slash MNT slash gen two. I'll just tab complete. And then what the handbook recommends is downloading the path to the stage three URL using the command line download utility W get. Now that's great, except getting that very lengthy URL and name of the ISO. It's not a small path to that ISO, right? So you could use W get, but what I strongly recommend is what they talk about next is using one of the terminal browsers like links, L.I.N.K.S. Or links, L.I.N.X, both fine terminal web browsers. And I'm gonna actually use links. We'll use links, L.I.N.K.S. for this because it makes downloading stuff very easy. So I'm gonna go in here. I'm gonna type links space and then HTTPS colon slash slash gen two dot org slash downloads. I believe we'll actually get us to the downloads section and just click okay here. And then with the arrow keys, just go down and that one right there, stage three open RC. I'm gonna use the open RC init system. Those of you that wanna do a system D installation would choose the system D install. But there's the documentation for the most part is mostly built around using the open RC init system. That's the traditional init system that Gen two has always used. So that's what I'm gonna do for purposes of this video. So I'm gonna hit enter on the stage three open RC and then it's gonna ask me, do I want to save this? Yes. And it's asking, do I wanna download it? Okay. And it's gonna download it right here in the browser. And once this bar has reached 100%, we will hit Q to quit out of the links browser. Let me Q to quit out of links. Now that we've downloaded that and we downloaded it right here in the directory we're in which is slash mnt slash gen two. The next thing we need to do, that was a compressed tar ball, right? We need to unpack that tar ball. And how you do that is entering this very lengthy command here, make sure you add the correct flags at the end of it as well. So let me switch back over and I'm gonna type the command tar and then the flags are x p v f space and then just type ST and then tab complete. And that's the stage three tar ball. We just downloaded using the links browser and then space and then these flags dash dash x a t t r s dash include equals. And then in single quotes, we need to do asterisk period asterisk then the ending single quote and then space and one more flag dash dash numeric dash owner. And if we did that right, let me verify that looks good and hit enter. And it's going to unpack that tar ball. This is gonna take a few minutes and unpacking the tar ball took about five or 10 minutes. And the next part of the installation is configuring the compile option. So this is the flags. So this is our make flags. Gives an example of the make.conf and the safe flags here, this link here. I remember correctly, this is actually pretty useful because depending on your CPU architecture, you know, for me, I've got the thread ripper so I'm gonna do the Ryzen, the thread ripper I've got it's model 1920 so the thousand and 2000 series, it tells me exactly, you know, the flags that I may want to do in the make.conf. So let me switch over and go ahead and open the slash Etsy slash portage slash make.conf is VIM installed. I don't think it is. Yeah, so VIM is definitely not installed. So I can't do VIM, it's VI, I'm pretty sure it's in here. So let's do VI slash Etsy slash portage slash make.conf. So VI is here, if you guys wanted to use nano, I know nano is also available for you. I'm gonna go down to this line here, common flags here and I'm gonna edit this line because going back to a page, my particular CPU architecture, it tells me to make this dash O2 space dash march equals ZNVER1 space dash pipe. So what I need to do is in between dash zero two dash pipe, I need to go ahead and add dash M arch equals ZNVER1. And then the last thing I need to do is the documentation did mention one other thing that you probably wanna do is you wanna tell the config file here, how many cores to use, make ops equals dash J2. That would be what you would use for, I guess a two core processor. Now I gave this machine six cores, right? Or six threads, but the virtual machine treats them as cores. So I'm gonna go in here and I'll just add this to the end of this document here. So that's gonna create a new line and I'm gonna do make ops equals and then inside double quotes dash lowercase J and then the number that I gave this. So six cores there. Then I'm gonna hit escape and then I'm gonna write and quit. And then let's get back into the documentation and let's click on the next chapter which is installing the base system. So this is where some of the magic really starts happening. First we need to get our mirrors and we want the fastest mirrors obviously to download the software. So I'm gonna enter this mirror select command here. Let me get back into the desktop and I'm gonna type mirror select and then space dash I space dash O space and then two greater than signs. And that's very important, it's two of them because we're gonna add to an existing file here. We're gonna write to it slash mount slash, let me make sure I got the path right slash gen two slash Etsy slash portage and then make dot comp. So all right, so we get a incurses menu where we can select the mirrors that we wanna add to the make dot comp for me. I'm gonna add mirrors in the US which I believe it's alphabetical by country. So let me go toward the end here and I'm just going to go ahead and hit the space bar on each USA mirror. I don't know if I need them all but that's plenty. Let me go ahead and hit okay. The next thing we need to do is the gen two e-build repository. We need to make a directory and then we need to copy some stuff over to that directory. So the first thing we need to do is a make directory. So mkdir space dash dash parent. So give it the parents flag and then space slash mnt slash gen two slash Etsy slash portage slash repose dot comp. Let me make sure I spill that because it's a new directory. I couldn't tab complete it. Let me, yeah repose dot comp is the name. And then what we wanna do is copy so CP space and then that same path we just typed. So slash mnt slash gen two slash Etsy slash portage slash repose dot comp space. And then what we wanna copy that to is slash mnt slash gen two slash Etsy slash portage slash repose dot comp slash gen two dot comp. You'll have to type that and hit enter and it says CP dash R not specified. So what happened here is I typed something wrong. So let me verify the page here. I got ahead of myself here and copy. I thought these paths were the same the copy path but it's not. You see, instead of mount gen two Etsy portage it's mount gen two user share portage. All right, so let me fix that. So I'm gonna go back in here and instead of mnt slash gen two slash Etsy mnt slash gen two slash user slash share slash portage slash, and then there's one more directory config slash repose. All right, so let me make sure that's right. Slash mnt slash gen two slash user slash share slash portage slash config slash repose dot comp. All right, and then we're copying to mnt gen two Etsy portage repose dot comp gen two dot comp. All right, so this command should work now. All right, no errors were returned to verify that work. What we should really do is actually make sure that this file that we were writing to that something was actually written to it. So if I did a cat on slash mnt gen two Etsy portage repose dot comp gen two dot comp. Yeah, so it did write something to it and getting back into the handbook. The next thing is copy DNS info. So it looks like we just need to do this command here, this copy command. I'm gonna do cp space dash dash d reference space and then slash Etsy slash resolve can't tab complete. No, it does tab complete. So resolve dot comp space and then slash mnt slash gen two slash Etsy and hit enter. And then the next part of the installation is mounting the necessary file systems. There's these five commands you have to enter. You do need to actually enter these correctly. This is probably one of the more tedious commands as far as you got some typing to do here. So let me just go ahead and get this done here. So I'm gonna do mount space dash dash types space proc space. And then what are we doing this? We're doing this as a slash proc space and then slash mnt slash gen two slash proc. So again, that would be something that very easy to miss type or miss read, you know, but I'm pretty sure I got that right that time. So then the next command is mount space dash dash our bind space and then slash sis and then space slash mnt slash gen two slash sis. And then mount space dash dash make dash or slave space and then slash mnt slash gen two slash sis. Once again, then mount space dash dash or bind or bind space slash dev this time space slash mnt slash gen two slash dev and then last one mount space dash dash make dash or slave space slash mnt slash gen two slash dev. Then getting back into the handbook here. It says if we were installing this on a non installation media non gen two installation media. So you were installing this from inside another Linux distribution. You may have to do this here in the red box. I'm doing this from the official gen two installation media. So I'm just gonna skip that. But you guys, again, you know, you may be doing things a little differently than I can't do everything possible with a gen two installation on a single video. Just know that if you deviate in any way, read the handbook. And finally, we need to cheroot into the new environment. So we need to cheroot into the new mounted file system. And that's where of course everything's gonna get compiled and installed to and everything. So this is very important here. So let's go ahead and do cheroot space slash mnt slash gen two and then space and then slash bin slash bash. Of course, the bash shell. And then we need to source the Etsy profile. And then finally, they recommend this here. This isn't really needed what they're doing here, but you want to change the prompt. So export PS one, PS one is your shell prompt. And then what they recommend is doing the word cheroot inside parentheses space. And then your standard PS one prompt. So, and then the ending double quotes there. And you see all that does is just change the prompt instead of live CD and then the path. And now it's cheroot live CD and then the path. So that just lets us know, you know, the prompt gives us confirmation that we're actually in the cherooted environment. And the next part of the installation is mounting the boot partition. So this is very easy. So let's go ahead and mount space and slash div. They say SDA one, but remember in my virtual machine here, it's the disk is actually VDA one for the partition space and then slash boot. And then finally configuring portage. Portage is gen two's package manager. The command line interface to portage is a utility called emerge. And installing a gen two eBuild repository snapshot from the web, emerge dash web rsync. This is kind of optional, I think. I think I could skip this if I wanted to, but just for sake of, you know, being on the safe side, I'm gonna go ahead and run the emerge dash web rsync. And go ahead and let that go ahead and sync to the repositories here. This probably will take a few minutes. So I'm gonna step away, make a cup of coffee, I'll be back when this is done. And the emerge web rsync has finished. The next thing that we need to do in the handbook, it says, yeah, after running, you know, emerge, you may get some eSelect news. This is important messages from the gen two teams. It could be critical messages about things you need to know. I usually just skip this, but if you actually wanna read the eSelect news, you type eSelect news and then read and it's gonna list the messages, or it's all gonna scroll by a better way to do that would have been to do eSelect news list, I believe, would have just, yeah, gave you the overview of the messages and there were six messages. So it gives you the title of each one. And the next thing we need to do is choose our right profile. So eSelect profile list and let's make sure that we actually do this correctly. This is another thing that you wanna make sure you get this right cause there's a lot of different profiles you could choose and depending on whether you wanna do 32-bit libraries or strictly 64-bit, if you only wanted 64-bit only, then obviously one of the profiles you need it needs to include the word no multi-lib. Also, we've got some things like MUSL for those of you that would rather do MUSL than a G-lib C, I guess. I wouldn't recommend that unless you really know what you're doing. Got some system D stuff, of course, we're doing open RC. The default profile is number one and it looks like it's already selected because that's why it's got the blue asterisks but if you needed to select a different one, you would do eSelect profile and then set and then the number. So if I was changing from profile one to profile two, for example, I would, you know, eSelect profile set two. But for me, one is fine, it's already set but I could select it again and getting back to the handbook. The next step is updating the world list. I know this step usually takes a while. You have to enter this command here, emerge dash dash ask, et cetera, et cetera. Updating the world set, what is the world set? Well, we could click on the Gen2 Wiki link for world set and it explains world set encompasses the system set and the selected set and the system set contains the software packages required for a standard Gen2 installation. So obviously we need that and the selected set contains packages. The admin has explicitly installed. So let's go ahead and update the world set. So let me switch over to the desktop and I'm gonna type emerge space dash dash ask space dash dash verbose space dash dash update space dash dash deep space dash dash new use space at world. Hit enter and obviously, because again, it's a source based distribution, there's gonna be a few things that it's going to have to update here, install or update. Actually, it's just a few things, five. But I think this process usually takes a little while. So I'm gonna pause the recording, I'll be back once this is completed. And updating the world set finally finished. I did remember that that took a long time and I was correct, that took almost an hour to do that. The next thing, configuring the use variable. So this is some of our use flags. And if you wanted to see what use flags are already in use, let me go ahead and enter this command emerge dash dash info. And then what you wanna do is pipe that into grep. And then we want to do the carrot symbol that symbolizes the beginning of a line and then all caps use. So it's gonna find a line that starts with use and then you have use equals and then a whole bunch of flags here. So that is all the use flags. If you wanted to edit that, you could. You could actually edit the make.conf. I'm not going to do that. I'm not really interested in playing with the flags. If you wanted to see what the flags actually are as far as the description, you could use the less command. And then what you wanna do is take a look at slash var slash db slash repos slash gen two slash profiles slash use dot desc. And that will pipe all of the flags into less, just hit enter to get the list to go down. But you can see, for example, if you had the also flag that adds support for media libraries and also libraries, you know, just hit enter to go down and read the entire list q to quit out of less. And the next thing in the handbook is configuring the accept license variable. They say it's optional. So it's what kind of license do we want to accept as far as installing our software? Do we want only GPL compatible software or only FSF approved or OSI approved, et cetera, et cetera? Since they say this is optional, I'm assuming I could skip this step. If I really wanted to though, I probably would accept probably the most liberal set of licenses just to cover all bases. So I didn't run into a situation where I was trying to install something, but couldn't. Scrolling down even further, we get optional using system D as the init system. And they say the remainder of the Gen2 handbook focuses on open RC. And this is the reason I'm doing the open RC installation is because it focuses really on open RC. If you wanna do system D, the documentation is kinda sparse, right? So moving on time zone. So we probably need to go ahead and set up a time zone. So let me go ahead and do an LS and I'm gonna do an LS in user share zone info. And if I do an LS, you see you get a listing of the possible regions. So this, if you've ever done a graphical installation of a boon to or anything that uses like the Calamari installer, for example. You know, typically it sets the time zone, sometimes automatically for you, typically, you know, I'll just click on the little world map and choose America slash Chicago. Well, where is that graphical installer getting that information? Well, it's getting it from user share zone info. You know, this particular directory here. And I see America in the list. So if I did an LS on user share zone info, America, you know, did an LS in that, you see Chicago in the list. And so that's exactly what I want to set my zone to, America slash Chicago. So how you do that is you need to echo, and in my case, America slash Chicago. And that needs to be wrapped in quotes and then space and then a single greater than sign. And then we're gonna write that to slash etsy slash time zone. And then we need to emerge space dash dash config space, sys dash libs slash time zone dash data. And that emerged very quickly. So that was just updating the local time to now reflect, in my case, America slash Chicago. No, I'm not actually in Chicago. You guys know the Southern accent. I'm actually in Louisiana, but Chicago's the central time zone, Louisiana's the central time zone. So that's why I always just choose Chicago out of the list. And the next step is configuring our locale. So we need to open the slash etsy slash locale dot gen. So let me go ahead and do that. And they were using nano. I'll just use VI since it's here actually, because a merge is already set up. I probably could go ahead and just emerge Vim. And I'm looking through the gen two wiki for Vim. And Vim is app dash editors slash Vim. Well, let me just go ahead and do that. Let me do an emerge and then app dash editors slash Vim. Just to get me a better text editor. I'm not that comfortable with VI. And I can't use nano at all. So let's just go ahead and get Vim installed. So Vim finally finished installing. That took about half an hour to install. Was it worth it? Well, for me, I was eventually gonna install Vim no matter what anyway. If you guys don't use Vim, obviously, you don't need to do that. Now back to configuring our locales. Now, if you're not sure what locale you need to choose, you can check it out in user share, internationalization supported. So let me go ahead and show you guys that. If I wanted to run this through less, let's do less and then slash user share. Now that was internationalization. That's I 18 in where 18 signifies. There's 18 letters in between I and N. It's just a short form for internationalization. And then supported. And there are all the locales. Again, piping it through less just hit enter to go down. Of course, you could pipe it into grip if you wanted to search for a specific locale. Obviously, I'm going to do English US here. And they actually already have the codes for English US here. So let me go ahead and I'm gonna open this in Vim. So I'm gonna Vim slash Etsy slash locale.gen. And they already have C dot UTF eight here. I'm just gonna go ahead and leave that, but I'm gonna add English US ISO dash 8859 dash one and then add English underscore US dot UTF dash eight. You need to have at least one UTF dash eight locale specified some things just need that. I'm gonna go ahead and write and quit and back to the browser here. And the next thing you need to do is run the command locale dash gen. So let's do that locale dash gen generating three locales because that's how many locales were in the file that we added and going back to the handbook. If you wanna see the available locales, you could always type E select locale list. So I could do E select locale list and there were the locales. The default one right now is set to seven. Now, if I wanted to change that, I could do E select locale set and then let's do English US UTF eight. So I'll set number six. Now we need to resource our slash Etsy slash profile for that change to take immediate effect and it gives you the command to type. You need to type period space and then slash Etsy slash profile. Unfortunately, doing that, it ruined our charoute prompt. We're still charouted, but it set the PS1 prompt back to its default form. If I wanted to, I could take the time to put that back. So let's export PS1 equals and do you guys remember what it recommended? It was charoute inside parentheses. It could be anything. It's just the main thing is changing the font to something different just so you know that you're actually charouted. And going back to the handbook, now reload the environment with ENV dash update and then source the Etsy profile and then export. Okay, so I actually ended up doing basically this, not this exact command, but we already took care of that. If I had actually read the rest of the page, I would have just run that command there. So let's go ahead and click on configuring the kernel. So first we need to choose an appropriate kernel source and install it using a merge. So I'm just gonna type that first command there and emerge space dash dash ask space. And we're gonna install sys dash kernel slash gen two dash sources. And I'm just gonna click enter for yes. This may take a few minutes to install. All right, and the gen two kernel sources installed that took about 20 minutes. So not terribly quick, but not terribly long. And when I give the times, of course, that's particular for this virtual machine I created, those of you that have even better beefier machines, you know, these things may install quite a bit quicker. Those of you that are trying to install gen two on a potato, this could take hours and hours, right? So all right, so the next thing we need to do after the emerge of the gen two sources, let's do an LS dash L user source Linux just to verify that it created a symbolic link. And I do apologize, guys. If you hear the train going by here, there's a train track not too far from this office here and user source Linux is what we needed. No such file or directory. Let's go back into the documentation. It looks like we need to do a E-select kernel list and then choose a kernel. So I don't know why they gave the LS command before that because, yeah, because it's obviously not gonna return anything until we actually choose something from the list, available sim link targets. So then run E-select kernel set. And obviously there's only one target available. So set number one says can't load module kernel. Hi, misspelled kernel. Instead I typed kernel. Okay, E-select kernel set one. All right, and now let me up arrow back to LS dash L user source Linux. And now that sim link has been created. And finally the moment everyone's been waiting for kernel configuration and compilation. Now the handbook here, the gen two handbook says manually configuring a kernel is often seen as the most difficult procedure a Linux user ever has to perform. Nothing is less true, okay? So it's hard, but you know what? It's really not hard. So, and if you want to actually do this we need to install the PCI utils. So we need to emerge sys dash app slash PCI utils. Let's go ahead and do that. So emerge space dash dash ask space and then sys dash apps slash PCI utils and hit enter. All right, and now that the PCI utils are installed the next thing we need to do is CD into user source Linux. Remember that was created for us. So CD into user source Linux. And then we need to run this command make space menu config. And this should launch an incurses program where we can configure the kernel manually. And this is typically not something I do but they do have some good information here in the wiki for those of you that want to configure the kernel. Some things that you may want to enable or disable things like dev tempfs support, SCSI diss support, selecting necessary file systems depending on what file system you're using. Typically I don't care to go through and manually configure every module in the kernel that I want. Typically I just installed the big kernel so that's what I'm going to do. So I'm gonna merge sys dash kernel slash gen kernel. So let me get back over here. And again, if you guys wanna configure your own kernel I mean you can go through the menu and hit enter and tick on and tick off things. What I'm gonna do though is I'm just gonna exit out of this and then what I'm gonna do is I'm gonna merge space dash dash ask space sys dash kernel slash gen kernel. And we're just gonna install the big generic kernel and I get some errors here. So let's read the errors says sys kernel Linux firmware. So something is wrong with installing Linux dash firmware saying something about redistributable license. So if I get back into the handbook here and go back, you remember the licenses that I said were optional because it does say optional configuring the accept license variable and we didn't set one. One of them was redistributable binary dash redistributable and I've actually got some notes here. This is not in the gen to handbook but I've done a search for this in the past and I've got some personal notes here on what I need to do to fix this problem. Apparently I've had it before I need to echo and then in double quotes sys dash kernel slash Linux dash firmware because that's the program that's having a problem is because we didn't accept a binary dash redistributable license. So let's go ahead and do the at symbol and then all caps binary dash redistributable. Make sure I spelled that right. And yeah, and then what I'm gonna do is I'm gonna pipe that into this command line utility called t, t takes standard input so it's gonna take that echo command and it's going to write that to a file. And I just noticed I didn't do the ending double quotes there, let me do that. Okay, then pipe that into t dash a to append a file meaning add this as a line at the end of the file don't overwrite the entire file with this echo and this needs to write that to slash etsy slash portage slash package dot license. And of course the package dot license file I had to type the whole thing in because we never created it in the first place. So, and now that we've done that you get the output here in the command line but it also wrote the output to slash etsy slash portage slash package dot license. And now that should allow us to up arrow and then emerge again the gen kernel and it should allow it. Yep, no more licensing issues. Now installing the kernel is gonna take a while. I'm expecting with the system resources that I gave this VM it might do it in a half hour. Maybe it takes up to an hour. I don't know what I'm gonna do is I've been at this computer now going on about four hours. So I'm gonna step away. I'm gonna actually go out to lunch and I'll probably be back before this big generic kernel has finished compiling. Guys, it's been two hours since I had started the compilation of the generic kernel. So I actually canceled it compiling because I think it hung up. It didn't look like the virtual machine was using any CPU. So I think the emerging of the gen kernel had reached a point where it was just frozen. It wasn't doing anything and it had already been two hours passed by and it's been nearly six hours since I actually started the whole installation process. So what I did is I went ahead and hit control C and canceled the compilation of the gen kernel and I went ahead and installed the gen two dash kernel dash bin package. That is a binary of the gen two kernel. So hopefully that will install correctly. Hopefully it'll go a little faster. I found that, by the way, in the gen two handbook. This was the gen kernel. I scrolled down. There were some alternate distribution kernels that we could install including gen two dash kernel and gen two dash kernel dash bin. So dash bin, I'm assuming it's a binary. It should maybe install quicker, we'll see. All right, so the gen two dash kernel dash bin kernel actually installed in about 25 minutes. So a much quicker installation than the gen kernel trying to compile. I really think the gen kernel probably compiles a lot quicker than two hours. I really think that for whatever reason the whole process just froze up because after two hours, I've never had a kernel take that long to compile especially since I gave this VM plenty of resources to work with. Now, since I installed one of these alternate distribution kernels, it says post install and upgrade. So every time there's a kernel upgrade, I need to run this command here which is emerge dash dash ask at module dash rebuild to rebuild the kernel modules. All right, so moving on, let's get past all of this. Finally, installing the firmware emerge dash dash sys dash kernel slash linux dash firmware. I think we already installed that though earlier because that was the package that had a problem with the licenses that, you know, it wanted to force us to agree to that binary redistributable license. But just to make sure, I'm gonna do emerge space dash dash ask sys dash kernel slash linux dash firmware just to make sure it's here. So would you like to merge these packages? It didn't tell me it was already installed. So I'm just gonna go ahead and emerge it again. Might as well. I mean, we've been at this install now nearly six and a half, seven hours. And that really took about one minute to install the linux dash firmware package. Now let's move on to configuring the system. And this is about the F stab. So this is the file system table. So it asks us to do nano slash etsy fstab. Does it give an example of what the fstab should look like? Yeah, here's an example etsy fstab example. And this is using NBR. So that is a good example for me to follow there. So let me get back over into the VM. And I'm gonna do vim space slash etsy slash fstab. Fstab stands for file system table. So I'm gonna go down here and clean some of this up. First thing we need to do is actually just uncomment all of these. Now if I wanted to use the labels, I think I could. If I wanted to specify specific partitions, for example, instead of label equals boot, I could actually change this to actually the name of the drive or the path to the drive. So I could change this to slash dev slash vda one was the boot partition. And if I wanted to do the big partition the same way, let's just get rid of uuid and I'll do slash dev slash vda three was that partition. The swap was of course slash dev slash vda two. And then let's go ahead and uncomment slash dev slash cdrom for the optical drive, even though I won't be using that really in this VM. One thing I noticed in the example fstab here is they assumed that the slash boot file system here was extend four. And of course we did make that. I believe we made that extend two. So I better change that. And then let me write and quit here. So do colon wq here in VM. And the next thing we need to do is the networking information host and domain information. So we need to set a host name at slash etsy slash conf dot d slash host name. So this is very simple here. So in your text editor, nano or in my case, VM open up slash etsy slash conf dot d slash host name. And host name is set to local host. Obviously change that to anything you want. I'm gonna name this particular machine. I'm gonna call it vert dash gen two. Just a nice descriptive name, especially if I ever SSH into this VM, I'll actually know exactly what it is because of the host name vert dash gen two tells me it's my gen two VM. And going back to the handbook, the next thing it talks about is the slash etsy slash conf dot d slash net file. It doesn't exist by default. And it says, if a domain name is needed, then we set that file. We don't actually need that though. I'm just gonna skip that for now. I don't think we need to play with that. Let's go down to configuring the network. And we need to install some network utilities. So we need to run this command, this emerge command. So let me go back here and clear the screen here so you guys can better read what I'm typing here. Emerge space dash dash ask space dash dash no replace space net dash m i s c miscellaneous slash net i f r c. And that installed very quickly. And back to the handbook. It talks about the conf dot d slash net file again. I don't know, maybe we actually do need that. And we're gonna be using DHCP. I'm gonna be using that, of course, for ethernet. And it mentions adding that line to etsy conf dot d slash net. So just in case that is needed, I don't see what it would hurt for us to actually go into that. So I'm gonna vim slash etsy slash conf dot d slash net. And of course that file was an empty file meaning we just created it. So the line I wanted to add according to the handbook is config underscore f zero equals DHCP. Then I'm gonna escape colon WQ to write and quit. Now at the zero, we need to make sure that that is actually the interface here. So I'm gonna do IPA and make sure yes, it is actually f zero. And back to the handbook. Now we need to make sure that networking automatically starts when we reboot. So CD into slash etsy slash a net dot d. So CD into slash etsy slash a net dot d. And then we need to create this symbolic link here while using this command LN space dash s. So we're creating a symbolic link for net dot lo space net dot eth zero. And then we need to make sure that this starts this service this networking service starts every time we reboot we need to make this happen with open RC. So we need to run this open RC command RC dash update space add space net dot by tab complete eth zero and then space and then the word default can I tab complete that? No, I have to type it all the way out. And it says added net dot eth zero to run level default. Moving on, we need to edit our slash etsy slash host file and they give an example of what one might look like. These are actually pretty simple. It looks more complicated than it is. So open in your editor slash etsy slash host. And for me, what I'm gonna do is I'm gonna go down here and it's already got 127.0.0.1 local host. That looks pretty good. I'm also gonna add the host name for this computer. So I'm just gonna do vert dash gen two and then tab over and we'll also leave local host here. And then colon colon one, I'm just gonna do the same thing. So let's go ahead and add the host name for this computer. So vert dash gen two and we'll also leave local host in this file. And that's really all I'm gonna do in slash etsy slash host. All right, and we're getting really close to being able to reboot into our freshly installed gen two. Now, but we need to set a root password. So we need to obviously run the pass wd command. So pass wd, and of course we're logged in as the root user. So this will be the root password. Now gen two requires you to create a strong and complicated password. It has to be eight to 40 characters. It can't use dictionary words and it would be advisable to use a mixture of upper and lowercase letters. So let me type a strong and complicated password. I hope I remember this password, I think I will. All right, so we've created the root password. The last three things here, I don't really think I need to play with those. One is editing slash etsy slash rc.conf. That's the open RC, it's like startup services. And if I really needed to play with the init system, I could play with that file. I don't need to do that. Then it talks about slash etsy slash conf.d slash key maps for our key map. It's already set to a US key map. So I don't really need to go back in there and play with that file. And then hwclock is the clock. Make sure it's set to local. I guess just to make sure that that is the case, I could vim slash etsy slash conf.d slash hwclock. Now it's actually set to clock equals utc. If I wanted to, I could set it to local. Note that if you dual boot with Windows, then you should set it to local. This is not a dual boot machine, so I'm good on that. So let's get back to the handbook and then installing tools. So this is your system logger, installing a system logger that's very important. So let me go ahead and get to the desktop here. And I'm probably just going to install the first one that they recommend, which is called sysklogd. So emerge space dash dash ask space app dash admin slash sysklogd. And now that sysklogd has been installed, the next thing we need to do is actually make sure that that auto starts every time we log in. Again, once again, we have to use open RC here. So let's do RC dash update space add sysklogd and then default. And sysklogd added to run level default. And back to the handbook. This is optional, but on most Linux systems, you probably want to add a Cron daemon and they advise you to install crony. And then of course, registered that with open RC. I'm actually going to skip this because in this VM, I'm not going to be setting up any kind of Cron jobs or anything. You could also add mlocate which that allows you to use the locate command to find files and directories on your system. I'm fine just using the find command, which is just a part of the standard new core utility. So I don't need mlocate SSH. You may want to install the SSH server on your system. If you plan to SSH into the machine right now, I don't need to add that. But if you need to add that to your open RC startup services, then of course you need to do that once again with the RC dash update add command. Then it mentions you may want to install some file system tools. So depending on what file system you used, in my case, I used extend four. There's some extra tools that come along with that file system that you may find useful. In my case, I need to install sys-fs-e2fsprogs. And I will do that because I think that is actually very important to do. I'm going to do an emerge dash dash ask and sys-fs-e2fsprogs and hit yes to that. And the next thing is installing network tools. Mainly we need a DHCP client, so we actually have a working internet when we reboot. So we need to go ahead and emerge DHCPCD. So let me go ahead and do that. Emerge, space dash dash ask, space net dash m-i-s-c slash d-h-c-p-c-d. And that's finished installing. Next, after DHCPCD, optional, we could install PPP. If that is used to connect to the internet, I don't need that. You also could install WPA supplicant. That's needed for wifi. This is strictly ethernet. So all I really needed was DHCP in my case. So I'm going to go ahead to the next chapter, which is configuring the bootloader. And of course, this is going to be about installing grub. The first thing we need to do is emerge grub2. So let me go ahead and do that. I'm going to clear the screen here if I can type correctly. And I'm going to do an emerge dash dash ask space dash dash verbose because I guess we want to actually see the output from what's going on with this command. sys dash boot slash grub colon two. And I'm going to answer yes to that question. Now while that is emerging, I should mention that I am doing master boot record and that is actually what that command is for. Those of you that wanted to do a EFI boot, I mentioned, I mentioned this when we got to it is the differences. The differences is you actually need to run this command, which adds this line grub underscore platforms equals EFI dash 64. It writes that to the make.com file. And then you need to emerge the grub2 bootloader. And grub has finally finished emerging. That took about an hour and 20 minutes to emerge grub. It took a very long time. So when I said earlier that, you know, after a little over two hours, I quit trying to compile the generic kernel, the big kernel. And I thought maybe the virtual machine was hung up. Maybe it wasn't. It's just really slow at compiling some of this stuff because I did not expect a grub to really take that long to emerge. And we're really not through with the grub install because we still have to run the actual grub dash install command on our device on most machines. That's gonna be it slash dev slash SDA. Of course, inside this virtual machine, the device is VDA. So let me run grub dash install space slash dev slash VDA. And it says installation finished. No error reported. Once again, just for sake of completeness, that was for me doing the legacy boot bios. Those of you doing EFI instead of the grub install and then the path to the device, you would do grub install dash dash target equals x86 underscore 64 dash EFI and then give it the dash dash EFI dash directory equals slash boot flag. And now that we've run grub dash install, the last thing is to actually create a grub config file. So we need to run grub dash MK config for make config. So let me clear the screen here because this is a very important command. Let's make sure we get this right. So it's grub dash MK config space dash O space and then slash boot slash grub slash grub dot CFG. And at this point, we could go ahead and reboot the machine, but let's exit. So let's go ahead and do that. Exit and then what we wanna do is CD and then we want to unmount. So run you mount for unmount space dash L and we're gonna unmount slash MNT slash gen two slash dev. And then inside the braces here, I'm gonna put slash SHM comma slash PTS comma and then you mount space dash capital R slash MNT slash gen two. And then finally, let's go ahead and reboot. So let's go ahead and see if the machine reboots. All right, and we get a grub menu. So our installation is completed. It worked. Thank you. And we get some net system information. So open RC is working. We get some networking information. It looks like the networking is working. Let's go ahead and make sure though we have to log in right now. All we have is a root user. So vert dash gen two was my host name. It says vert dash gen two log in. So what user do we want to log in as? Of course, root is the only one. Now I need to enter our strong and complicated password. I hope I remember what I'd set for the password. Okay, and now we're actually logged in as root. So let's go back to the documentation and the last chapter is finalizing. And really the only thing left is to add a actual user that's not root. So you need some other user other than root on the system and you need to use the user add command. And let me go ahead and just show you guys this here. Let me clear the screen. We're gonna type user add dash lowercase m space dash capital G. And then we need to add this user to some groups. I'm gonna add the user to users comma wheel comma wheel is the most important because that adds it to the pseudoers group. We also need comma audio comma video. No spaces between these commas, by the way. Some other groups that you probably want your home user to be a part of CD-ROM. You may want him to be a part of floppy. You may want him to be a part of games. I think right now that may be all I need one more. I should probably add USB. That probably covers most of the groups. So then space dash S and this is for the shell. We want the default user shell to be slash bin slash bash and then finally space and then the name of that user. I'm gonna call my user DT. And it says the group games does not exist. So let me go ahead and up arrow. I'm gonna remove the games group. I was actually looking at the documentation for groups to add and games was actually listed there. But let me up arrow and just remove games from the group list. And now we've created the DT user. Now the DT user needs a pass. So do pass WD DT. And now choose a password for the DT user. So let me create a strong and complicated password for the DT user again. You have to follow the rules for gen two. So eight to 40 characters and uppercase, lowercase, no dictionary words. So now that we've set that password and let me try to log in to the DT user. So SU DT for switch user to DT. And it just allowed us to do that because we were already the root user. The root user can do anything. And I think that's where I'm gonna quit with this portion of the installation because honestly that's the end of the installation guide. Where do you go from here on this final page? Well, where you go from here is whatever you wanna do. Is this gonna be a server? Is this gonna be an actual desktop? Do you actually want a graphical environment? So if you want to actually have it as a desktop computer, obviously, you're gonna have to install XOR, right? The X11 display server. And then you're gonna have to put a desktop environment or a window manager on top of that. You're probably gonna wanna log in manager. Where you go from here is a million different paths. You know, everybody's gonna do something different. So I'm not gonna do that on camera for two reasons because everybody will want something different but the other reason I'm not gonna do it is because it's gonna take hours. Especially if you guys wanted to see me install the full GNOME desktop environment or the full KDE Plasma desktop environment. It's very easy, you just emerge those desktop environments. The problem is it's gonna take hours. Like if I had to install full GNOME or full KDE Plasma, it literally would take probably as many hours as I've already put in to this point just to install those packages. I'm not going to do that. Maybe in the future, I'll do some kind of minimal install. We'll do XOR and maybe a really minimal window manager. I don't know, something like DWM which you don't even have to bother emerging because DWM, you just go grab the source code from suckless.org and you manage that stuff yourself. What I suggest you guys do is try this. If you're gonna be a Gen2 user, stay minimal because it takes so long to compile this software. Updates also take forever. You don't want a really big heavy bloated desktop environment. Stay light, do window manager only. Also, if there's binary packages available for a program, use it because it'll save you from compiling. For example, many Gen2 users don't compile the web browser. That's another thing. If I had to compile Chrome or Firefox, they would take hours, many, many hours. There's binary packages available for the web browser. Install those. Same thing with the full LibreOffice suite. Don't compile that thing. There's a binary for LibreOffice, install that instead. So right now what I'm gonna do is I'm gonna go ahead and just leave this VM as is. I may clone it a couple of times and we may come back to it at some point. And again, maybe I'll throw XOR on it and a window manager if I do. Of course, I'll do that on camera and share it with you guys. Now before I go, I need to think a few special people. I need to think the producers of this episode. I'm talking about Absi, James, Gabe, Mitchell, Wes, Akami, Alan, Chuck, Kurt, David, Dylan, Gregory, Erion, Alexander, Paul, Polytech, Scott, Steven, Sven, and Willie. These guys, they're my highest tiered patrons over on Patreon without these guys. I couldn't have spent all morning, all afternoon, and all evening compiling Gen2 today. I couldn't have done it. This show is also brought to you by each and every one of these ladies and gentlemen as well. All these names are seeing on the screen right now. I sincerely appreciate each and every one of these ladies and gentlemen, their support because I don't have any corporate sponsors. I'm sponsored by you guys, the community. If you like my work and wanna support me, please, consider subscribing to Distro Tube over on Patreon. All right, peace. After all that, if I rebooted and didn't get a grub screen, I probably would have punched my monitor.