Monday, December 31, 2007

5 degrees of separation

The real temperature, according to the SMN
The folks at Apple are, no matter how much support they give to Gore's global awareness campaign, in total denial of the current global warm, at least, when it comes to Buenos Aires :p ...

According to the page for Bs As of the Servicio Meteorologico Nacional, the current condition is 38 degrees Celsius, something that makes you wanna live inside a freezer, to say the least.



The Weather Widget temperature
While, the Weather Widget shows a "cooler" and sunnier day, with only 33 degrees going... joking aside, and no matter what, we are screwed, the city's infrastructure won't be able to hold for much longer with such heat levels; and the necessary energy to cope with it.

Labels: , ,

Sunday, December 30, 2007

Hot & humid New Year

Weather Widget and a effing hot Buenos Aires
Once again, this summer is going to kill me... Today it reached to 37 degrees Celsius. BTW, the Weather Widget sometimes shows such ridicule values... The screenshot is from 1130 PM, we also had our change of hour today, so not only does the heat climbs, but also, the Sun never goes away... I really hate the summer, specially if it is humid like in Buenos Aires.

Labels: , ,

Saturday, December 29, 2007

So long Belkin and thanks for all the airwaves

My beloved and trusty (so far) Belkin wireless router died today, it got fried when plugged to 220V, it runs on 110V...
So, it was an excellent opportunity to get my newly built incarnation of Goliath, as the main router and firewall for the setup.
It wasn't that hard to setup, it might have taken me a couple of hours, right now Goliath is working as the firewall, DHCP server, caching DNS server & NTPD server.
On top of that, since that box has a huge 80 GB drive on it, I'm using it to download BitTorrents, right now I'm running 6 torrents, on 6 screens, and the load of the OpenBSD barely scratches 1 dot something. I love this OpenBSD stuff! Specially how things are geared towards "getting things done", no bullshit, simple results, as an example, the explanation on how to make your OpenBSD box onto a DHCP Server is amazing, is somehow like a haiku.

For the whole setup, used the FAQs on the OpenBSD site, the firewall at the moment is the plain vanilla example for the Firewall for Home or Small Office, the DNS server setup, a caching only one, it is like the setup of a regular one, except that Bind does not server any zone, but the built-in ones.

Labels: , , , , ,

Friday, December 28, 2007

Friday reading stuff

A couple of interesting articles, not new, but nevertheless interesting ones.

- The end of Info-Tech slavery
- 7 reasons why Linux won't succeed on the desktop


I find specially interesting the first one, it has some very valid points, but those are really hard to 'make it happen' in the real world, specially, in the real world South of the Rio Grande.

Labels: ,

For whom the bells tolls

You cant un-ring a bell
The government will change the hour this 29th at midnight (or 30th at 0 hour) in order to save energy ( link 1, link 2, link 3, link 4 & link 5). This is the second time this year that I have to do this, so, I decided to post here the steps, which are really easy.
Many of the servers don't have internet access, or some of them are really old, besides, the updated tzdata from the vendor usually arrive after the change has taken place, that's why I have decided to write my own tzdata file.

Started by creating this text file. Buenos_Aires2.txt (I use tabs for separators):
Zone America/Argentina/Buenos_Aires2  -3:53:48 - LMT 1894 Oct 31
      -4:16:48 - CMT 1920 May # Cordoba Mean Time
      -4:00  - ART 1930 Dec
      -4:00  - ART 1969 Oct 5
      -3:00  - ART 1999 Oct 3
      -3:00  - ART 2000 Mar 3
      -4:00  - ART 2007 Dec 30
      -3:00  - ART


Then, open the Terminal, and type:

% zic -d tz_change Buenos_Aires2.txt


This will compile the new tzdata file, then, issue:

% sudo cp tz_change/America/Argentina/Buenos_Aires2 /usr/share/zoneinfo/America/Argentina/
% cd /usr/share/zoneinfo/America/Argentina/
% sudo cp Buenos_Aires Buenos_Aires.ORIG
% sudo mv Buenos_Aires2 Buenos_Aires
% cd /etc
% sudo cp localtime localtime.ORIG
% sudo ln -sf /usr/share/zoneinfo/America/Argentina/Buenos_Aires localtime


Then, you can test the new tzdata, like this:

zdump -v America/Argentina/Buenos_Aires


On the output, you'll see the lines that will make the hour change automagically:

America/Argentina/Buenos_Aires Sun Dec 30 03:59:59 2007 UTC = Sat Dec 29 23:59:59 2007 ART isdst=0
America/Argentina/Buenos_Aires Sun Dec 30 04:00:00 2007 UTC = Sun Dec 30 01:00:00 2007 ART isdst=0


At 12 midnight on the 29th, it will forward the hour to 1 AM; which is the change it will be taking place. Of course, you have to change the original text file to the location of your servers, and this does not take into consideration what will happen with the running services on the servers on which you change the hour.

Labels: , , , , ,

Thursday, December 27, 2007

Goliath Vs. OpenBSD: configuring X

OpenBSD desktop with the TWM
Well, today, I took sometime to configure X, as you can see on the screenshot, I still have a loooong way to go... That's twm window manager running (and it is Ok for your eyes to bleed a bit), a minimalist window manager (way before Blackbox and Fluxbox make it fashionable to be 'lightweight')

Configuring the mouse, I have a plain vanilla Serial one, a Genius NetScroll, on the console was easy, typed this as root:

wsmoused -2 -p /dev/cua00 -t microsoft


And added this to the '/etc/rc.conf.local' file to automate the execution:

wsmoused_flags="-2 -p /dev/cua00 -t microsoft"


Now, getting to work on X was a little more trickier, but not much, it looks like you can't run the console mouse service 'wsmoused' as well as X, so, I have to kill the console service, before starting X. There is a somehow lengthy discussion/ post about it here

On the xorg.conf file, the mouse is defined like this:

Section "InputDevice"
Identifier "Mouse1"
Driver "mouse"
Option "Protocol" "Microsoft"
Option "Device" "/dev/tty00"


I have yet to get the mouse wheel working, and install another lightweight desktop environment, maybe even Xfce, I'm seriously thinking in getting more RAM for Goliath, if I can maxx it to 768 MB, and get a faster CPU (like a 700 MHz one), I can easily use it as a desktop, 'always on' kinda box.
The main advantage is that it uses the same RAM than my QuickSilver box, Thor.

Labels: , ,

Wednesday, December 26, 2007

Goliath vs. OpenBSD

OpenBSD logo, Puffy
Installed OpenBSD 4.2 on my late Goliath (Goliath is the true definition of the crappy box, an Intel Celeron @266 MHz, with 128 MB RAM, and a 80 GB Western Digital Caviar HDD), all the parts, even the case, where given by my employer, this box was going straight to the land fill.
I used to have Windows 2000 Pro on it, but it simply died on me, so, I let it pass, and get on with the show; just for kicks, tried booting with Ubuntu 7.04, it took nearly 40 minutes to get to a black screen, before I fed up and rebooted it, the CPU is way too slow, and the amount of RAM is a joke for running Ubuntu.

In the other hand, installing OpenBSD was a cake, it took less than an hour to install the newly available ISO image, got it from this mirror
The install does not differ much from a FreeBSD one, excuse me if I offend a purist or something. As on FreeBSD (if you forgot during the main installation), after finishing the installation, you have to add Bash, if you want to make yourself comfortable coming from Linux.
OpenBSD uses (like FreeBSD), 'pkg_add' to download binary programs (and all the necessary dependencies), the only difference between FreeBSD's & OpenBSD's 'pkg_add' is that the late forces you use an environment variable to define the place from which to gather packages, either locally or over the internet.
On the ~/.profile for root, you need to add something like this (replace the URL with a closer one to you):

PKG_PATH=http://openbsd.md5.com.ar/pub/OpenBSD/4.2/packages/i386/
export PKG_PATH


Logout and back in, so you can start using it. (If you installed Bash already, all you have to do is: 'source ~/.profile', no need to logout)

So far, I like OpenBSD, I have set it up as the NTPD server on my LAN (real piece of cake, the simplest ntpd setup I have ever done), and setup the console's font to be a little more useful.

My employer has another real crappy box, this time a laptop, that I want to continue testing OpenBSD, or another *nix variant.

Labels: ,

Sunday, December 23, 2007

Exposé: key-bindings & slow motion

Expose in action
Everybody knows about the slow motion effect that you can have, while using Exposé when you press the Shift key.

(link 1, link 2, link 3, link 4, link 5, link 6)

One thing I noticed, since I have remapped the keyboard shortcuts for using Exposé to the far more handy F1, F2, and F3 keys, is that if you want to use the slow motion trick, it simply doesn't work with the new keyboard shortcuts, also, it doesn't work with the 'Active Screen Corners'.
That is, the trick only works when use Exposé with the default key-bindings and press Shift, I believe those key-bindings might be hardcoded somwhere onto the program?

Labels: , ,

Wednesday, December 19, 2007

Adventures in Ubuntu Land: Turn off the laptop monitor

One thing that really bothered me from day one with Odin was that the monitor refused to turn off all the way, the screensaver and/ or the X server did blanked the screen after a period on inactivity, but never did actually turned off the backlight.
For what I have Googled, it is a known and very, very frustrating thing to happen, because, obviously, it lessens the useful life of the laptop's LCD.

Some of the links I found on Google, while researching this problem:

- Force Monitor Turn On When You Open the Lid
- A Primer on Screen Blanking Under Xorg
- DPMS using vbetool

Unfortunately, none of the solutions I found (not only on the links above) worked fine, they did turned off the monitor, but I wasn't able to turn it on again. The only way to get the laptop useful once again was doing a hard reboot.
Besides, most of the references I found, where related to having problems with the monitor not turning off when the lid was closed, and I wasn't looking for a solution to that problem, what I wanted was to be able to leave all the programs running, and simply turn off the monitor, closing the lid scares me because of the heat, if I closed the lid on any laptop, it is because it will be hibernated in a few seconds.

On many of the links, they mention the script 'sleep.sh'. which is located on '/etc/acpi/sleep.sh', decided to take a look at it, that script, invokes (among many other things) another set of interesting scripts, located on the '/etc/acpi/suspend.d/' directory; in there, there was one that caught my attention: '80-video-vesa-state.sh'.
On it, I saw that there is a way of saving the video status to a file, and then re-read that status file, when the vbetool is executed again to "wake up" the monitor.

Here is the script I wrote, in case someone finds this useful:


#!/bin/sh

VBE="/usr/sbin/vbetool"
STATUS_FILE="/tmp/vbetool.tmp"

## Bring the monitor down
${VBE} vbestate save > ${STATUS_FILE}
${VBE} dpms off

## ------ BEGIN Loop ------ ##
while true;
do
sleep 1;
done
## ------- END Loop ------- ##

## Bring the monitor up
${VBE} post
${VBE} vbestate restore < ${STATUS_FILE}
${VBE} dpms on

# EoF #


This script will keep running, with the monitor turned off, until you type Ctrl + C to interrupt it; it is convenient to execute this script not from a Terminal running X Window, but to switch to a virtual console, login, and issue it there.

Labels: , ,

Tuesday, December 18, 2007

Adventures in Ubuntu Land: Mouse cursors

Like I said before I really, really like to have the mouse cursor shape the way I want it, no matter what Operating System I am running at the moment.
So, the Ubuntu install on Odin couldn't be less, this is what I did to the mouse icons to get them the way I like them, open a Terminal, and type:


cd /usr/share/icons/
sudo cp -R DMZ-Black DMZ-Black.ORIG
sudo cp -R DMZ-White DMZ-White.ORIG


Then issue the following:


cd DMZ-White/cursors/
sudo cp arrow xterm


Do the same, but on the 'DMZ-Black/cursors/' directory.
To test this, open a new terminal, and it'll use your new mouse cursor; but, the old, already opened Terminals will continue to use the old mouse shapes until you close them.

Labels: , ,

Sunday, December 16, 2007

Adventures in Ubuntu Land: More on mimicking gOS


I have found on this site many, if not all, of the gOS icons, some wallpapers, and more importantly, the usplash icon set and source files, so you can make your own gOS booting splash image while using your plain vanilla Ubuntu box.
It took me a while, but in the end, I got my usplash up & running. Also used the source code from the Usplash from Ubuntu, got it here, for instance, and took a lot of hints from the 'usplash-theme-ubuntu.c' file.

Labels: , ,

Friday, December 14, 2007

Adventures in Ubuntu Land: Mimicking gOS


Well, after using gOS for a while, it didn't convinced me to jump ship, so I searched a bit how to get a theme for a plain vanilla Ubuntu installation.
Googling for info on how and where I can get the wallpapers, icons, etc, found out that it seems like you can actually install it on top of your regular Ubuntu:



- Truco/Solución: Instala gOS en Ubuntu
- Is there a way to install the gOS desktop on top of a current Ubuntu installation such that it is an additionnal session option in GDM?
- HOWTO: Install gOS on Ubuntu


After installing it (it obviously adds Enlightenment to your Ubuntu box) used for some time, but it didn't convinced me either, it is not exactly like the real thing, the gOS site does warn you about the differences between the real gOS, and the Ubuntu theme:


"Currently there is a greenos-desktop package in our repository, but it will not give you the complete experience."


So I got the wallpaper, the GDM theme, and the usplash theme, and so decided to get my Ubuntu themed like gOS (see the screenshot). Using as a base the Gnome's default Mist theme, giving it a touch of green hues in various tints. Also, I wanted to replicate the main menu on gOS, that has a green leaf instead of the 'Start here' from the Windows menu, so, I googled info no how to replace the Ubuntu logo, it was a bit daunting, because most of the info available is for earlier releases, so here it is: Changing the Ubuntu Start Menu Panel Icon, and my own commands:


sudo cp ~/your.22x22.icon.png /usr/share/icons/hicolor/48x48/apps/distributor-logo.png
sudo gtk-update-icon-cache /usr/share/icons/gnome/
killall gnome-panel

Labels: , , ,

Thursday, December 13, 2007

Taking gOS for a spin


Being a bit busy (a f*cked up backup server, had to reroute all some of the backups to the second one)
I read about gOS about 20 days ago, but had no time to download it yet, so I got it, and boot it on my Compaq Presario to test drive it.
There are many, many, many reviews out there.
One thing I love about it, right after I saw it ,is the GUI, the theme, the looks of it.





gOS uses Enlightenment as the Window Manager/ (light) Desktop environment, I have used it before, briefly, a couple of years ago, mostly because there was a cool (a the time) Os X Aqua theme available for it.
As I mentioned on other posts, the resolution of the Compaq Presario is a real show stopper, just look how a few Terminals clog the whole desktop... Besides, this theme it is not designed to be uses with such a meager resolution.





The icons, the Dock, or 'iBar', are really good, and it works rather well and feels snappy, even though I was running it from a live CD session. The thing I don't like much is the whole I of having a huge bar on the right side of the screen with that clock, and those 'Network Neighborhood-like' computer icon (that only echoes your IP address...)
If you have more icons on your iBar, or minimized, that the ones that they 'fit', they will scroll, so you can find the one you want.





One thing I found rather comic is that they place a Google search widget on the desktop, that the first time that you use it, it prints a huge banner warning.
Another thing, there is no screen capture program, so I had to take the screenshots the old school X Window way, and then use The Gimp to convert them to regular jpg files.

Labels: , ,

Tuesday, December 11, 2007

OpenSSL tricks


A couple of useful tricks using OpenSSL, since OpenSSL can be installed just about anywhere, you can use this on any platform you whish.

File encryption:
To save an encrypted file with all your passwords, or sensitive data, write them on a file called ''secrets.txt", then open a Terminal, and type:


openssl enc -aes256 -salt -a -e -in secrets.txt -out secrets.txt.enc ENTER


You'll be asked for a pass-phrase (twice), don't forget that pass-phrase!
To decrypt the data, type:


openssl enc -aes256 -salt -a -d -in secrets.txt.enc -out secrets.txt ENTER


You'll be asked for the pass-phrase to decryt the file.


MD5 checksum:
You can easily get the checksum of a file using OpenSSL, for instance, to make sure that the file downloaded correctly, like this:


openssl dgst -md5 fileName.something ENTER

Labels: , ,

Monday, December 10, 2007

Adventures in Ubuntu Land: Screenshot fun


A screenshot of my current Ubuntu setup on Odin. Yes, it is simple, and boring; but when you are forced to only running at 800x600 & a minuscule 8 MB of video RAM, there isn't much eye candy to begin with.
So, no desktop icons, no wallpaper, all the fonts reduced, the bare minimum Panel widgets running (thinking on removing the Networking icon); needless to say, the desktop effects are disabled (they can't even be activated on this laptop)
Of course, I could have installed Xubuntu, but I wanted to test the plain vanilla one.

Labels: ,

Adventures in Ubuntu Land: trimming the Evolution

On Odin, my Ubuntu laptop, I'm using Evolution as the mail client, it is a nice one, really, but, like many, many programs nowadays, it is not designed o be used on a smallish monitor, with a low, ghetto-like resolution; so I had to do a couple of things to regain as much screen real state as I can possibly get. Even tho it seems like stupid easy thing to do, I haven't found any info Googling for this, so here it goes...

Getting rid of unwanted columns on Evolution
The first thing, is to get rid of all the columns that show info that, in our situation, are of not much importance, and that can be sacrificed in order to get a nicer, more comfortable working environment.
The columns I have disabled are the first three: the one that shows if an email has been read, the one that shows if the email has an attachment, and the one that shows the priority of the email.
To get rid of those columens, simply make a right click on the one you want to get rid of, and select: 'Remove this Column'.
I have also did the same for the 'From:' column, simply because it not only showed the name of the person who sent the email, but also showed on brackets, the email address, a lot of screen space on that column!


Adding the Sender column to Evolution
So, if you delete the 'From:' column, how do you know who sent you the email, simply add a new column, called 'Sender' that simply shows the name of the person who wrote you.
It is not the safest thing in the world, but it works for this scenario.
Simpy right click on an existing column, and then on 'Add a Column', on the pop window, select 'Sender' and then drag it to the position you want it, usually the first one, you'll a couple of red arrows when you are placing the column.

Labels: , ,

Sunday, December 09, 2007

Another screenshot

Another excelent screenshot of my QuickSilver
Time for another screenshot, once again, the wallpaper comes from Vlad Studio, sort of an Aquaish Cubist motive :)

Labels: ,

Saturday, December 08, 2007

Adventures in Ubuntu Land: chasing the mouse

Finally got the PS/2 mouse up & working on Odin, my Compaq Presario laptop. The problem was simple, but it took a lot of researching, fumbling & Googling to find out about it.
The thing is, the 'psmouse' kernel module needs to be mounted with an option passed, that's all, so, you have to unload the module:


sudo modprobe -r psmouse ENTER


And then mount it once again, passing the option:


sudo modprobe psmouse proto=imps ENTER


That's it, the PS/2 pops back to life. Automate that so you don't have to type it each time that you reboot, and you are done.

Found the answer on this August 2006 Forum list archive: ps/2 mouse

Now the little laptop got a much, much useful, I finally got everything I was having already working on FreeBSD, but running Ubuntu (one might think that the other way around is how things should go, but...)

Labels: , ,

Wednesday, December 05, 2007

Another shot of my Quickie

My super dupper excellent QuickSilver setup
Re arranged a little bit the setup, I was far, waaaaay, uncomfortable on the previuos spot. Besides, the little monster was getting perhaps a bit too hot in there, after the summer, when things are back civilized, I'll se where the hell I can place it.

Labels: , ,

Monday, December 03, 2007

Adventures in Ubuntu Land

For a stinking project at work, I need the Cisco VPN client, no matter what I tried, it was impossible to get it up & running on FreeBSD, and using vpnc I was unable to connect to the VPN concentrator at all. Of course, the VPN client for Os X didn't work either.
So, I decided to give Ubuntu a try, and installed on my Compaq Presario 1200. I haven't used it since the first release, called 'Hoary' IIRC, some years ago.
The only problem I'm having is with the external mouse, thru a PS/2 port, I can't get it to work, no matter what; while I was using FreeBSD -on the exact same laptop-, I was able to use it with no problem at all.

First off all, I wanted to boot onto RunLevel 3, I found out that Ubuntu does not use an /etc/inittab file to control that, so if you want to boot onto the console, issue this command:


update-rc.d -f gdm remove ENTER


After a reboot, you'll be at the console.

Then, I wanted to get high resolution console; something that I was already using on FreeBSD; this probed to be quite a PITA to setup.
After a lot of Googling, I found this thread on the Ubuntu Forums:
No console mode in high resolution with Ubuntu 7.10

On top of what the thread says, I had to edit the file "/boot/grub/menu.lst", and remove the option "splash" from the line 'defoptions', so the line ended up like this:


# defoptions=quiet vga=789


A couple of packages I installed (as a side note, I cant't believe that the default Ubuntu install doesn't turn on an iptables firewall!)


apt-get install openssh-server
apt-get install emacs-nox


Also, setup the Gnome desktop to reduce the memory/ CPU foot print:

Don't show the content of a window while dragging or resizing it:

gconftool-2 --type bool --set /apps/metacity/general/reduced_resources true

It transforms it onto a wire frame.

Turn off the tips (only works for the Applications, Places & System)

gconftool-2 --type bool --set /apps/panel/global/tooltips_enabled false



It doesn't speed the system up, but it sets things like they should be:

Set the Emacs keybindings globally on Gnome:

gconftool-2 --set /desktop/gnome/interface/gtk_key_theme Emacs --type string

(To revert, use --unset)

Labels: , , , , , ,