Arch + Openbox: A minimalistic choice


In previous writing I’ve wrote about installing a minimal or barebone arch system that only gives a shell environment to the user.

It’s interesting composing prose, poetry or codes in a barebone system because the black and white environment keeps us much focused on the topic.
But for reading references while doing these jobs, a minimum GUI is also a must for reading and (or) downloading reference texts.

As I’m going to keep the system as minimal as possible, like our music compositions, I would prefer a lightweight window manager NOT a full-fledged desktop environment for the sake of utilising resources.
 

This arch environment is built for only learning systems and network programming purposes - so there’s no need for high resolution
graphical things and recreational apps.  

Snapshot of the Desktop. Notice a few packages have been installed.

Openbox:
I’ve earlier used fluxbox, but this year decided to change the taste and installed openbox- another lightweight window manager.
There might be a fluxbox versus openbox debate ... I don’t give a shit,
cause my philosophy is --
‘DO NOT learn everything, MASTER EVERYTHING NEEDED’

Preparation for window manager:
 

Sync and upgrade the system:  # pacman -Syu

issue this command for getting VGA driver info

$ lspci | grep -e VGA
2:00:02.0 VGA compatible controller: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor Graphics Controller (rev 09)


List available drivers in repository 


$ pacman -Ss xf86-video

So from above information I need to install Intel graphics driver which is ‘xf86-video-intel’
Install VGA video drivers  


#pacman -S xf86-video-intel


Install xorg-server for x window system: #pacman -S xorg-server  
 

Install xorg-init for starting Xorg manually: # pacman -S xorg-init
 

Install window manager openbox: # pacman -S openbox

Configuration:
There’re quality documentations online how to configure openbox, in arch and gentoo wikis also.
However, I explored only the sections I needed. 


First copy the default openbox configuration directory into the home directory issuing:

$ cp -Rv /etc/xdg/openbox ~/.config/ # recursively verbose There are four interesting configuration files in ~/.config/openbox folder:
1.    autostart : runs programme after openbox-session starts working
2.    environment : setting up environment variables
3.    menu.xml : right click menu configuration on openbox
4.    rc.xml : used to specify keyboard and mouse bindings


I did a little configuration of the default menu because this will show a number of options to commands that aren’t installed on the system. 

I’ve first created a
~/.xinitrc file that will be searched by startx, frontend script for xinit, when she is commanded to start an X session.

exec openbox-sessions

 

Notice I’ve commanded to fire up openbox-sessions NOT the openbox. Why? Because openbox initiates a barebones environment where no wallpaper or conky can’t be put in action.
Now command
startx.
 

Pitfalls:
There should be a black screen. If right click doesn’t show menu properly or comes with broken fonts then you’re most likely didn’t install x fonts during arch installations.
Window managers and X server need proper fonts to run a system smoothly.
 

OFF TOPIC: I was not that serious about fonts but this issue taught me the extreme necessity of fonts in *nix world. 
This *nix Guru has devoted his life in linguistics, language acquisition, designing fonts and hacking Linux (Slackware veteran). He has also a number of human and programming languages under his belt. I would highly suggest my penguin friends to have a look at his posts. 

Run: $ fc-list  # list installed fonts
 

If the output is null, we must install xorg fonts.  

Install x fonts: # pacman -S xorg-fonts-misc Now fire up startx. Voila !!! Everything works fine.
 

Final configuration:
Now what I need are a background and a system monitor. I won’t use any menu bar or theme rather use
alt+tab to switch between windows.
For setting up background/wallpaper install feh, a nice tool for browsing photos and setting up wallpapers, and system monitor conky.
Now add these lines to
~/.config/openbox/ autostart
conky &
sleep 5
feh —bg-scale /path/to/pic/png/or/jpg &


Pitfalls:
Add ampersand to the end of each command or the next command would wait for the previous to be terminated. Ampersand sign forces them to run in background.
Take a five-second brake after firing up conky, because sometimes her fonts would go messy with the background if both of them are launched together.
All config files are here


The only graphical apps are xfce terminal and firefox browser


Conclusion:
That’s it. I was setting up a minimalistic environment, part of an effort to acquire more knowledge on the *nix and network system. 


A visually attractive desktop environment often distracts our focus from studying the subject, so I’ve decided to use this basic and visually unattractive system to compose my prose, poems, articles and codes. 


I do use a Debian + Xfce4 environment for recording and editing audio compositions along with residential system and network administration.


Xubuntu is our family distro for daily life and recreational purposes.


Faquir Foysol  
A 90s script kiddie.....

Comments

  1. Suggest to install and run "compton". It allows transparency effect.

    ReplyDelete

Post a Comment