Archive for the ‘linux’ Category


Thursday, March 17th, 2011

Had everything running upto XBMC, except hardware video decoding. Tonight I started looking for a solution to fix a missing library figuring that could mean something. Installing xvba-va-driver thinking all would be good. Next thing I know the system has no working X setup anymore. Xorg config has not changed judging by it’s timestamp and yet X just won’t work anymore… All I can think of now is a Dutch word: kutzooi!

Let there be music

Wednesday, March 9th, 2011

Woohoo, finally got sound :D As usual it took a lot of reading up and fiddling around, while in the end it all seems so simple. In short I did the following things; first make sure the Xonar DX card is the first device instead of HDMI audio, then figure out the needed device configuration and unmute channels.

Switching device order was trial and error, but eventually it worked. In the end all that was needed was append the following line to /etc/modprobe.d/alsa-base.conf

options snd-hda-intel index=1

This moves HDMI audio output from 1st to 2nd place enabling the Xonar card to take the first place. Initially I also added  line for the Xonar (snd-virtuoso), but this resulted in an error message during boot (cannot find the slot for index 0 (range 0-0, failed with error -16). No idea why, but it’s not mandatory, so remove and problem solved.

Next was figuring out the exact configuration that produced sound. I’ll spare you the details, but what eventually worked was this:

  • hw:0,0
  • default mixer (not driver default, this produces invalid CTL errors)
  • line or master channel

By now I had the side and back channels working. Front channel was silent. Double checked if all channels had enough volume and were unmuted with alsamixer. All set but no sound. Running out of ideas I just muted and unmuted the card (you could see the ascii-art switch colour) and voila, sound on all channels. Must have been a glitch that the front channel wasn’t working in the beginning. Haven’t had a silent channel ever since, even after reboots (and switching on/off side and back channels work fine). Haven’t tried S/PDIF yet, but for the moment I’m assuming it will work now that analog output is working.

Audio and video troubles

Monday, March 7th, 2011

Last entry of this weekend and just need to blow of some steam. Been trying to get Alsa audio to work and well, what a mess! One audio device, no problem, but with multiple devices the trouble starts. If you have this Alsa version, do that. If you have that distro, change it to this. Using udev? Your loading order can get scrambled and you need to change that config there. New version? Don’t use snd_ prefix in that case. On that distro, you config is located there, and if not, look over there. Linux/Alsa devs, I’ve got 1 thing to say to you; W….T….F….?!

Also not working is hardware video decoding. As expected ATI cards are a pain. 2D, no problem, got that working. But decoding is a different story. Need to get VA-API running/compiling, which in turn is a wrapper for XvBA which is a wrapper(?) to get to the UVD2 engine. Or something like that? Installing libva-dev has no effect when compiling MPlayer, e.g. configure still thinks the VA dev stuff is missing. No idea why, but haven’t spend much time on this yet. Want to get audio working first because listening to some music has a soothing effect in situations like this ;)

Limit found

Sunday, March 6th, 2011

Hmmm, it seems I’ve crossed a limit in the current setup. Just gave it a 1080p x264 video @10Mbps with DTS 5.1 96 kHz/24 bit @1.5Mbps to chew on. 100% CPU usage and slowed down playback. Still no sound, so the DTS stream might not even play a role. My guess is hardware decoding is not used by mplayer and/or fglrx driver. Let’s call it a challenge =)

Some early and completely unscientific numbers

Saturday, March 5th, 2011

A quicky with some numbers. Keep in mind nothing is optimised yet. All software is generic 686 32-bit, not amd64. The RAID5 array is up and running with 5.5TB of space ready to be filled (still have 1 2TB drive doing nothing). Copying files via NFS from the old seedbox to the new server peaks at around 66MB/s. When peaked, CPU usage is around 30% for one core and 80% on the other. While it’s copying, power usage hovers around 70W.

Note that above numbers were done on an extremely scientific basis. Mount the NFS share, start copying with Midnight Commander and watch a movie while keeping an eye on the server ;)

There is an issue however. I still haven’t managed to get audio working. Alsa is a pain when it comes to multiple audio devices and in this case the HDMI and Xonar devices are batteling eachother. On a positive note, 720p video plays great, but again no sound.

To be continued…

Making progress

Saturday, March 5th, 2011

If the MicroServer were human and female, I’d be in love. The little thing is fantastic. Got Debian testing and Fluxbox running out of the box, the RAID5 array is rebuilding in the background and slowly working through all steps. Even ATI’s proprietary driver install went relatively smooth (once you figure out it needs kernel headers). ATI’s installscript logs things in /usr/share/ati/ and only there. According to the GUI nothing is wrong and the entire install went fine. Which of course isn’t the case. Apart from this annoyance, it went remarkably well.

One of my worries was the temperature of the passively cooled vga card. So far things appear to be within limits. Last night it stabilised around 62.5 °C and during the night it went down to 52 °C (signal off and central heating turned down). This morning it has risen to 59.5 °C while typing this. This doesn’t give a complete yet, since I still need to test 1080p movie playback.

To get each temperature reading I used the aticonfig tool:

aticonfig –odgt

Linux kernel got fat!

Monday, February 28th, 2011

Just downloaded the latest kernel sources in preparation for the new server. The bzip2 compressed archive is over 70 MB these days… what the…? Last time I build a custom kernel it was 36 MB.

Should ATI still burn in hell? Very likely so!

Sunday, February 27th, 2011

There’s probably a week’s worth of ranting about ATI’s and NVIDIA’s proprietary gfx card drivers, but for now I’m keeping it short. A short introduction is in order. Years ago I knew exactly which card was needed to get the best performance. It took time reading up and keeping up-to-date with all the latest developments. Since then my interests changed from knowing the exact details to something along these lines: I don’t care how it works as long as it works as you can reasonably expect (and I expect a lot by default. If you can’t deliver a decent piece of hardware, software or service, please do the world a favor and burn down your company as quickly as you can. Stopping myself here, as this is also one of those subjects I can go on about for days).

Anywaaaay… all those years ago I bought ATI gfx cards for the simple reason that they were the fastest. Not that you’d ever notice this in a real life usage, but synthetic benchmarks ruled. But as you know a decent piece of hardware is only half the story. So imagine you’ve got this sexy (the nerdy kind of sexy, not the erotic variant) piece of hardware lying in front of you, you wipe the drool of you chin, you plug it in and boot the latest Linux kernel. Next is installing ATI’s latest driver only to discover you’ve ended up in hell. It may have been years ago, but my mind still bears the scars of agony and frustration… hours on end. For this alone ATI deserves to burn in hell for all eternity (which is a pretty pointless thought if you don’t believe in heaven and hell (but the creation of an artificial hell would be most welcome. We could stuff all those greedy corporate bastards there. Maybe even a webcam and some running man style show for our entertainment to watch (which in turn we would watch via networks run by the same corporate bastards and thus negating the entire idea… anywaaaaay :)))).

Long story short I swore never to use ATI again. Since that time I’ve switched to NVIDIA on systems that required high performance 3D and embedded Intel for everything else. While NVIDIA cards also come with a proprietary driver, their installation process was (or is) much less frustrating. Intel on the other hand sucks for 3D, but just works for everything else. For non-gaming purposes, Intel is a blessing and I can highly recommend it if you don’t want to fiddle around. Now fast forward to 2 weeks ago when I ordered the MicroServer. Never thought of the ATI horror and focused on a card that fit and satisfies the max power limitation (25W for the PCIe x16 slot). And from what I’ve read ATI’s Linux support is still something to cry about. Don’t care about 3D, but for HTPC usage hardware decoding support is more or less mandatory.

So when all components have arrived I’ll be attempting to get a Radeon HD 5450 GPU up and running. This GPU has an UVD2 video engine (UVD = Unified Video Decoder) and uses the XvBA (X-Video Bitstream Acceleration) API. The UVD 2 engine features full bitstream decoding of H.264/MPEG-4 AVC, VC-1 and MPEG2 video streams. If rumours are correct it sucks balls compared to NVIDIA’s Video Decode and Presentation API for Unix (VDPAU). Rumour also has it that this proprietary crap has to do with DRM. Just as you think your hatred of a certain technology can’t get any deeper, it does. In any case I’m already preparing for some torture and if all else fails I’m just gonna get a GeForce G 210 or GT 220 card (only realistic options considering the 25W PCIe limitation).

Btw, anyone else thinks writing your entire company name in capital letters makes you think of sad 16 year olds screaming for attention on the net?