Help bring more traffic! Stumble This!

Thursday, July 22, 2010

Quick Arch Linux install!

Well guys, I've been talking about it for a while now. I think its finally time to show to you guys how I install arch. It usually takes me about 10-20 minutes to get to a non-text based stage with a login screen and all. Let's begin!

Note: If you're going to be using Arch Linux with another operating system, such as windows, go ahead and create another partition on your hard drive using the OS that you already use. This partition will be where you're going to install Arch.

First step, find the arch .ISO or .IMG file Here.
You'll notice a 32bit and a 64bit version. 32bit versions can't read ram greater than ~2.9 Gb. 64bit versions won't work on older CPUs such as a Pentium 4. There's not really much difference between the two other than that.

Burn the .ISO to a CD, or copy it to a USB drive using Win32 Image Writer or Unetbootin. Win32 will only copy .IMG. Unetbootin will copy both, but may not work on all versions.

Insert the CD or USB and reboot. Make sure you change your boot order in your BIOS menu to boot from either the CD or USB.

You then should see a screen that looks like this,
Go ahead and select "Boot Arch Linux from Live CD"
Log in by typing "root".
Read the information on the screen and run/arch/setup

Soon after you'll see a screen that looks like this,

This will be your installation home screen. You will go through each one at a time.

Select Source - From here you choose either a net install or core install. Core install will use the information on your disk, while a net install will access information from a remote server. If you have a slow internet connection, you may want to select core. If you downloaded and burned the net .ISO or .IMG, you will use net and not have this option.

Set Clock - Select your timezone. fairly straight forward.

Prepare Hard Drives - This parts fun! If you're going to use PURELY Arch and not have any partitions on your hard drive, just select Auto Prepare. This will completely ERASE ALL OF YOUR PREVIOUS INFORMATION on your hard drive!

If you are using windows, mac, or any other system on your computer, select Manually Prepare hard drives. Split that previously created drive space into 4 seporate parts, each with 32Mb, 500 - 1000Mb, 4,000 - 15,000Mb, and the rest in the last. Highlight the 32Mb part and make it bootable. Make sure you keep track of the names of the parts (typically sda1, sda2...) as you will have no other way of identifying them. I like to write them down.

Select Packages - Here is where you select which programs to initially install. Personally, all I would recommend you add is "Sudoers" under Base. You can install all of these packages later using
pacman. DO NOT DESELECT ANYTHING ON THE LIST!

Install Packages - Select it and let it do its magic. This part may take a while.

Configure System - Select Nano. Select /etc/rc.conf,

Scroll down to where you see HOSTNAME="something" and replace something with the name of your computer (whatever you want). Hit ctrl-o to save and ctrl-x to exit. Select /etc/pacman.d/mirrorlist and scroll down to your country and delete the # symbol in front of about 5-10 lines. You can delete all of them, but you don't need to. ctrl-o and ctrl-x. Select Root-Password and type in your password twice. Hit Done.

When you reboot, you can remove the CD or USB from your computer and change the boot order if you want. If you do this, you will see a screen that looks very similar to the boot screen you saw earlier, but with less options. Select the Arch Linux option.

If you choose not to remove the CD or USB, you will see the same screen as before. You can select More Options... then select Boot from Existing Arch Linux install.

Next you will get back to the original text screen where you can input commands.
Go ahead and log in to root with your root password you defined earlier during
the install.

From here you can configure your system and install a Graphics User Interface (GUI) complete with a desktop, icons and more.

First thing you need to do is update your system. Runpacman -Syu

pacman is the program Arch uses to download packages from the Arch server. Don't confuse this with the little yellow dot muncher. Pacman stands for Package Manager. -Syu is a command specific to pacman. It tells pacman to update all of the packages currently installed and look for a newer version of the linux kernel.
Other usefull commands are -S (standard download and install) -Q (search your computer
for packages) and -R (remove packages on your computer).

Next you want to add your user account. Runuseradd -m -G users,audio,lp,optical,storage,video,wheel,power -s /bin/bash (all one command)
passwd
Where is whatever you want to name the account.

Add that user to your sudoers list. Runnano /etc/sudoers
Nano is the program used to edit text, you chose this before the configurations in the install.
Sudoers is the configuration file that holds a list of all allowed sudoers. /etc is the directory where the configuration file is located.

If you scroll down, you should see something like thisROOT ALL=(ALL) ALL
Directly underneath that, add ALL=(ALL) ALL
Once again, where is the username you just created.

While you're at it, find the line%wheel ALL=(ALL) NOPASSWD: ALL
and uncomment it (delete the %).

Once you add the user name to the sudoers list, you can now run root-only commands while logged into that user. Just add "sudo" to the beginning of your command. For example,sudo pacman -Syu

Next we're going to get started on the GUI. Runpacman -S libgl xorg mesa alsa-utils

And now for the important stuff. Deciding what windows manager you're going to use. The
two most command managers are Gnome and KDE. These are both equal in performance and have very minor differences. If you don't have a preference, just pick one.
For Gnome, runpacman -S gnome gde gnome-terminal gnome-extra
For KDE, runpacman -S kde
There are many different windows managers out there, such as Openbox, Fluxbox, Xfce, FVWM2, and more.
Windows managers are purely user preference. Decide which one you like by trying a few out later.

Next we need to edit your daemons. Runnano /etc/rc.conf
rc.conf is a configuration file for your computer that holds the daemons. This might look familiar,
this is were you changed your computers name. /etc is the directory where rc.conf is located.

After you open rc.conf, scroll down to the daemons list. It should be the last line in the file.
It should look something like this,DAEMONS=(syslog-ng network crond)
Go ahead and add these items to the list.DAEMONS=(syslog-ng hal network alsa crond gdm(for gnome, kdm for KDE))
Order DOES matter, try to make is similar to what is above.
ctrl-o, ctrl-x.

Once that's all done, you should be able to reboot into Arch and be amazed by what you see next.
A LOGIN SCREEN!

After logging into your created user account, you can now control your desktop like any other computer.