Arch setup II

So onto part II.

There are a few important things that one needs to remember when configuring Arch – one is that most of the configuration is done through plain old text files; no clumsy or hand-holding GUIs here to help you out. Secondly, most of the configuration files in Arch are in exactly the same place where you would expect them to, i.e. Arch interferes very little with /etc allowing programs to place the files there, without moving them to a special place. Most distributions keep a special system for managing configuration files, Debian has debconf, Gentoo has etc-update, Arch has none, and it needs none. When a configuration file is to be overwritten, Arch will give you a warning; if it does not you can be sure that it’ll not overwrite and instead the new config will be placed with a .pacnew extension.

I am a bit of a console freak, so first off I installed gpm. GPM is this really cool
program which allows you to use the mouse in the console. I did need to a do a bit of tweaking in /etc/conf.d/gpm and I added this line:
GPM_ARGS="-m /dev/input/mice -t imps2"

(other great console apps: irssi, centericq, and of course mutt!)

Another good thing that I like about Arch is its bleeding edge packages. The magic command
to sync up on the newest stuff is pacman -Syu. Also I made sure to install the latest version of pacman (version 3.0.4 as of writing). It seems a bit faster, the progressbar for installing also looks neater; of course there are lot of changes underhood too. The other good news for those wanting to try out Arch for the first time – they’ll release a 2007-05 version (codename Duke) soon with the new kernel 2.6.21. So wait a few days and download that instead of 0.8!

Then I installed slim (the simple login manager) and beryl, compositor-king. In Arch if you know the name of a package, then you can install it with pacman -S package. If you don’t sync frequently you can also tag a -y to it like pacman -Sy package. That’ll make sure you get the repositories refreshed with the changes (-y stands for refresh). You can also search for a package by this package -Ss whatever.

Arch has a few repositories. To put simply, a repository is a collection of binary packages maintained by Arch developers, or other members of the community. The official repositories are current, extra, unstable, testing, community. Out of these current and extra contain stable packages. testing contains the absolutely new stuff, and one that could (but never has, in my case) break your system (like say, a new kernel version or a new video graphics driver). unstable contains, well unstable code. I don’t use it and it doesn’t contain many packages anyway. community is a repo of software that users wrote PKGBUILDs for (I’ll be coming to what PKGBUILDs are, soon) and they have been voted or are important enough, that binary packages are provided for a few of them. (Did you know, that
anyone can upload packages to the Archlinux User Repository?)

If you want to enable some of those repositories, go to /etc/pacman.conf and uncomment out the repos you need, you can also add other repos if you want.

Installing stuff is a no-brainer as I told before. I quickly installed openoffice-base, pidgin, seahorse (manages GPG keys), muttng (grabbed a few configs from codemac, thanks codemac!), screen (the wonderful terminal multiplexer), nitrogen (a wallpaper setter), alunn (excellent notifier for new packages, quietly sits in systray), totem movie player, VLC, etc….

Now onto configuring NetworkManager. First I had to install the required packages (networkamanger and gnome-network-manager if you use GTK+/GNOME or knetworkmanager if you use KDE). Then you have to go to rc.conf and disable the interfaces which we want to use. You must also remember that your wireless card uses a different interface than your ethernet port. That you have to find out by trial-and-error. In my case it was eth2. So in my rc.conf, I now have:

  eth0="dhcp" #if you don't want dhcp put something like this:
  #eth0="eth0 netmask" where the first address is the IP you want
  INTERFACES=(lo !eth0 !eth2)
  # Routes to start at boot-up (in this order)
  # Declare each route then list in ROUTES
  #   - prefix an entry in ROUTES with a ! to disable it
  gateway="default gw"

Then you need to install the appropriate drivers for your wireless card (if you haven’t done so already). My card is a Intel IPW3945ABG so I installed the ipw3945 package. For this driver, I also need to startup the ipw9345 daemon, so I added to the DAEMONS array. While using networkmanager, we have to disable the network script, so put a ! before it and also add dhcdbd and networkmanager to the DAEMONS array. Next time you reboot, NetworkManager will take over your network settings from rc.conf. So now my DAEMONS array looks like this:

  DAEMONS=(syslog-ng ipw3945d !network alsa dbus hal @powersaved @mpd dhcdbd netwo
  rkmanager @lastfmsubmitd @lastmp @netfs vsftpd crond slim)

(the @ before some daemons means that daemon will be started in the background)

To use the GNOME applet, you can put nm-applet --sm-disable in your .xinitrc or whatever system your DE uses to autostart apps on login. The reason --sm-disable is required is that otherwise nm-applet gets confused and multiple instances of it startup 😦

Lastly I configured mpd. For anyone who does not know, mpd is a daemon which plays your music in the background. So even if you kill X, your music goes on. There are many good frontends for it; I prefer Sonata which supports editing tags too.

Next time, I will write about how drop dead simple it is to make your own packages in Archlinux. Have a look at the wiki; and till next time happy pacman -Syu’ing!


Arch setup I

It’s been a long time in the coming, true. Due to a lot of stuff in real life, I haven’t been to blog properly. In some ways this is better, as it’s now a month with Arch, and I have a better understanding of it.

So after I booted off the CD (Version 0.8), I got few screenfuls of text, with the livecd checking for binary packages in every removable medium it could find. It seems that arch will allow you to install any package that’s in the /packages directory of some removable media. Then /arch/setup brought me to the installation screen.
That gave me the choices like Partition, Set Mountpoints, Install packages, Install Kernel, Configure System Install Bootloader and Reboot. My hard disk was already partitioned, so there was no problem. I went straightway to set the mountpoints (in my cases just / and /home).

Since I had downloaded the full version of the CD, I had to wade through a lot of packages to finally settle for what I liked. Installing was finished in a jiffy, and then I had to configure the system. I did not touch /etc/modprobe.conf and /etc/modules.conf. /etc/rc.conf is the master configuration file in Arch, having settings for everything from timezone, to what modules are loaded at startup, what daemons are started, etc. The comments are self-explanatory.

Installing the kernel and the bootloader was straightforward. I installed GRUB to the MBR (master boot record) and rebooted.

Then I copied my xorg.conf from my Gentoo install to here. I installed openbox, trayer and a few other applications (like gaim – now pidgin), put them in my .xinitrc
and startx’d.

Since I installed XFCE, which is nowadays heavily dependent on HAL, I remembered to
add hal and dbus to the DAEMONS array in /etc/rc.conf. Also be sure to
add yourself to the storage, optical, video, audio and power groups, otherwise you won’t get a wholesome experience.

I’ll put some more details on how I configured NetworkManager, and how I started
building packages for arch in a later post. What I like about Arch, is its beautiful simplicity. That kind of simplicity really opens your mind up to new possibilities, that’s probably why we have a lot of cool things discussed in the forums; nice and
simple, the kind of tools that make you feel warm and cozy.

Till next time – enjoy the beautiful world of open source!