Steam on Debian x86_64 (part 2)

It seems that Valve games are on bad terms with Intel cards on Linux (which I fully understand), all I got when I first launched TF2 on my Thinkpad was a full black screen. But that black screen was nevertheless promising so I repeated the expriment on another machine with a GeForce GTX 560 Ti.

Running Team Fortress 2 on Linux

I managed to launch the game manually but it lacks some authentification mechanisms so I wasn’t able to start any game for now. Launching the game directly through steam doesn’t work probably due to an error in the launcher script which I have to dig into when I’ll have time.

Team Fortress 2 (fullscreen)
I wonder if I’d buy L4D2 to give it a try native games on Linux are neato ! Something else that did really amaze me was the relatively high CPU usage from the Steam client when idle. I may not yet be used to this waste of ressources we see in many (often proprietary) clients nowadays  and this is why I avoid them (I should post about this someday).

CD Key authentification invalid for internet servers.

There’s one thing I’d like to investigate is it possible to work on a free implementation of the Steam chat protocol ? I didn’t look into this at all but a Pidgin plugin would be very cool. Talking about Steam something that scares me though is the idea that only one well known distribution would actually be supported, a stance that we increasingly tend see in the matter of porting prorietary software to Linux but again Ubuntu is not Linux, far from it (I should post about this someday too) ! 

Archos plugins fee

I wanted to watch a movie on my Archos tablet just to find out that actually I can’t !
Archos charges me with additional fees to watch movies with Dolby AC-3 or MPEG-2 codec. But I’m glad we have free alternatives, I mean Flac, Vorbis and Google’s VP8. And now I’ve a reason to reencode all of these using free codecs. Yeah !

So I made a little script to ease encoding with ffmpeg and another program to manage concurrent queues to leverage the dual core cpu. I use a combination of the above codecs which I put in a Matroska container. Actually VP8 is doing quite well with high quality VOB (far better than Theora which came from VP3 anyway) but it still shows some encoding artifacts here and there. Though it may take up to 2 days to encode and I’m still struggling to integrate multiples soundtrack in the resulting Matroska with ffmpeg.

New compose on GMail

GMail has a new compose and he sees fit to remind me constantly whenever I write a new message. But I’d like to have my say on this since we’ll be forced to use this thing in several month anyway. So let’s get things straight, I really hate this, it is just stupid and I guarantee that if Google eventually puts this in place and forces us to use it, I’ll just quit ! That web interface was everything but there it just feels like a hyped gadget.

At least -please- put an option to get back to the original compose permanently so we can write real mails that we focus on. I mean I know most of them are just quick informal replies, just like we would use mobile messaging and I know for sure that services need to evolve from time to time but they just make everything easier and it just gets more useless and annoying at every step.

Steam on Debian x86_64

The Steam Linux beta is out ! Good news !
However it seems like it didn’t work well on Debian and even less on Debian x86_64. But I finally managed to get it running with some little hacks.
Here a screenshot of what is going on a 64bits sid with an integrated intel graphic card.
I’m not enrolled for the closed beta though… Valve do you here me ?

Profil-based firewall

It still amazes me how many people use their shiny Linux machine out there touting for its safety and robustness but never thought to put a single iptable rule in it. Is there any kind of default firewall into those linux-for-wide-audience distributions that I didn’t know about ?

Anyway I finally made my handcrafted profil-based IPv6-ready stateful firewall. Well the “handcrafted IPv6-ready stateful firewall” was already there since years but the “profil-based” part of it wasn’t ! I use 2 profiles basically (home and public) and do the switch automatically with network-manager (/etc/NetworkManager/dispatcher.d).

Small website and PluXml

I rewrote my personal website from scratch several months ago. My main goal was to avoid using any time consuming server-side scripts and database. I did this using a combination of XML and XSLT prepocessing along with a little bit Javascript. The original website was to contain a blog too that I finally did code two weeks ago. But then I took a step back and looked at my creation and ultimately decided that it wasn’t worth the change. 

Until I just found pluxml, it’s a nice little blog which use plain XML for its databases and although it still use PHP it’s good to see solutions that stand out from the eternal LAMP software bundle especially for embedded servers.

TypeMatrix 2030

I was looking to replace my really bad logitech keyboard and at the same time make the switch to the Bepo layout (a french and free ergonomic keyboard layout similar to Dvorak). We have long sought after a quality keyboard like the classic ThinkPad keyboard and avoid the many badly designed toys we found on the market. Macish like keyboards with their flat smooth keys and soft press were right out. I really hate these even if everyone seems to swear only by them nowadays.

So we ordered three TypeMatrix keyboards one month ago and we just received them this week. One of the distinguishing feature of this keyboard is that it doesn’t conform with the classical staggered layout remaining unchanged from the typewriter era and use a vertical columns layout instead which reduces motions. It also comes with a optional switchable skins with different layouts (qwerty, azerty, dvorak, bepo). These not only makes the layout switching easier but also makes the keyboard waterproof and dirt-free. The keyboard itself requires no drivers though you may want to add the following to /etc/X11/xorg.d/typematrix.conf to setup the default layout :

Section "InputClass"
Identifier "Typematrix"
MatchIsKeyboard "on"
MatchVendor "TypeMatrix.com"
MatchProduct "USB Keyboard"
Driver "evdev"
Option "XkbRules" "xorg"
Option "XkbModel" "pc105"
Option "XkbLayout" "fr"
Option "XkbVariant" "bepo"
Option "XkbOptions" ""
EndSection

Howto save a lot of disk space on nokia N810

The Nokia N810 is an internet tablet (not a phone though it can communicate with cellular phone via bluetooth). It’s a nice small device which run the Maemo Distribution which seems to be based on Debian since it uses the Debian Package Manager. But the distribution’s structure really feels like an embedded device and this is quite annoying when you try to optimize this device.
One thing which is really boring is the lack of disk space on the device. Actually the device use two miniSD (MMC) cards for personnal documents, images, videos and so on and a 256MB MTD using a JFFS2 compressed file system to store the whole distribution which means every package and their data files which takes a large amount of disk space and even so much that the MTD can easily be completely filled with a few apps.
The basic idea to save some disk space is to move some part of the MTD on the MMC primarely reformated from vfat to ext2. Many articles explain how to move stuff like /var/cache and others using symlinks which can save you about 20MB. But they also explain that you can’t do that with /usr/share/ for example since it will break the boot process. Indeed the boot process depends on many stuff located in /usr/share and thus if the MMC are not mounted while boot occurs the system will just stall waiting for an hard reset to get everything right and clean again. Here comes a way to go around this :

As root we check the run level :

Nokia-N810-43-7:~# runlevel
N 2

We see we are in runlevel 2. Let’s check how the boot process arranges itself in that runlevel :

Nokia-N810-43-7:~# ls /etc/rc2.d
K00zzinitdone
S12fb-progress.sh
S20dbus
S20hal
S20osso-applet-display
S21mce
(…)

It looks like fb-progress.sh is the first script executed in the boot process. So we edit this script (/etc/init.d/fb-progress.sh) and add the following line at the beginning of the script (line 19 or so):

/usr/sbin/osso-mmc-mount.sh /dev/mmcblk0p1 /media/mmc2
/usr/sbin/osso-mmc-mount.sh /dev/mmcblk1p1 /media/mmc1

So we know that MMC will be mounted at first in the boot process. After that scripts which need share stuff or other may look on the MMC since we know they were already mounted. Then we move things like /usr/share on the MMC :

Nokia-N810-43-7:~# mkdir /media/mmc1/.usr
Nokia-N810-43-7:~# cp -aR /usr/share /media/mmc1/.usr
Nokia-N810-43-7:~# rm -rf /usr/share
Nokia-N810-43-7:~# ln -s /media/mmc1/.usr/share /usr/share

Of course the same could be done for other directory. Here is the list of directory that I switched from MTD to MMC without breaking the boot process :

  • /var/backups
  • /var/cache
  • /usr/local
  • /usr/share
  • /usr/bin
  • /usr/games
  • /usr/lib
  • /home/user

The df entry for the MTD follow :

Filesystem Size Used Available Use% Mounted on
/dev/mtdblock4 249.5M 16.8M 232.7M 7% /

And it almost never grow when apps are installed.

Ext4 on root filesystem

Since a few days the last version of squeeze’s debian installer (which runs sid I think) is able to install on an ext4 filesystem. Which means that the ext4 filesystem could now easily be used as root filesystem.
When the installation is completed a problem might appear at the first boot. The kernel will simply panic complaining that he cannot mount the root filesystem. Actually the squeeze’s default kernel is currently 2.6.26 and this version does not fully support ext4.
The quick fix is to use the rescue part of the debian installer which will chroot you in your root partition and let you temporarily change your apt’s sources from squeeze to unstable so that you can install the last unstable kernel (>= 2.6.28) wich is ext4 capable.
If you try to install with the stable debian installer or any GNU/Linux distribution which is not ext4 capable here is a trick to use ext4 as your root filesystem.
First install your system with an ext3 filesystem and let /dev/sda1 be that partition. Then install grub2 and make sure it works perfectly. Then boot on a live system which is ext4 capable, backup all files so you can create an ext4 filesystem on /dev/sda1, put your backup back in it. Then change fstab in /dev/sda1 and replace ext3 with ext4 for the root filesystem. Check that grub.cfg in /dev/sda1 doesn’t use UUID to pass the root parameter to the kernel (actually they’ll change since you made a new filesystem) and use root=/dev/sda1 instead. Now reboot and your system should be running ext4 on the root filesystem.

GNU Flash Movie Player

Do you want flash for free ? I mean really free ? Try Gnash the GNU Flash Movie Player which can be run as a plugin from within Firefox (or Iceweasel).
Actually Gnash is SWF v7+ compliant which means it can play video, music and many website which randomly use it.
What more is it can be easily installed on x86_64 (64bits) and it is absolutly free software (GPL).