Purpose

Mainly documenting a few things I don't want to forget. Perhaps it's useful to others as well.

If you came here for FISHWORKS (which I'm pretty sure you didn't), click here

måndag 24 oktober 2011

Live screencasting with ffmpeg, ffserver

Put this ffserver.conf file on your server:

 Port 8090  
 RTSPPort 5554  
 BindAddress 0.0.0.0  
 MaxHTTPConnections 500  
 MaxClients 200  
 # 8 Mbits  
 MaxBandwidth 8000  
 CustomLog -  
 NoDaemon  
 <Feed screencast.ffm>  
     File /tmp/screencast.ffm  
     FileMaxSize 30M  
     ACL allow 0.0.0.0 255.255.255.255  
 </Feed>  
 <Stream screencast.swf>  
  Feed screencast.ffm  
  Format swf  
  VideoCodec flv  
  VideoFrameRate 20  
  VideoBufferSize 80000  
  VideoBitRate 768  
  VideoQMin 1  
  VideoQMax 5  
  VideoSize 1376x768  
  PreRoll 0  
  StartSendOnKey  
  AudioBitRate 64  
  AudioChannels 2  
  AudioSampleRate 44100  
  AVOptionAudio flags +global_header  
 </Stream>  
 <Stream status.html>  
     Format status  
     ACL allow localhost  
     ACL allow 192.168.0.0 192.168.255.255  
 </Stream>  
 <Redirect index.html>  
     URL http://www.ffmpeg.org/  
 </Redirect>  

here's a shortcut screencast.sh file, run this on your desktop machine you're screencasting from:
 #!/bin/sh  
 ffmpeg -f x11grab -r 25 -s wxga -i :0.0 -f alsa -ac 2 -ar 44100 \  
  -i hw:PCH,0,0 http://server:8090/screencast.ffm  

Now, simply log on to your server, run ffserver -f ffserver.conf. Then run screencast.sh from your desktop.

You might need to change the input device, you can list them with arecord -l.
Also, replace 'server' with your server address, and check the input dimensions (-s wxga above) and the output dimensions (VideoSize in ffserver.conf) it's a bit tricky and doesn't match the input size to 100%, because the VideoSize dimensions need to be a multiple of 16.

söndag 23 oktober 2011

The Shitty Logitech Squeezebox Radio

Ok, not all shitty once it actually works, but there's a problem with it's software (drivers) or wireless hardware, atleast in combination with my Netgear router.

With WMM enabled, things are really shitty... The Squeezebox shows meta information and browsing the directories is almost not shitty. It's experiencing general slowness and lag. Response to Squeezeboxserver remote commands are kind of random. And audio just doesn't play at all... On one occasion I saw the "Buffering" message reach a staggering 2%. Wow, that's only 98% shitty!

So, turning off WMM (Wireless MultiMedia extension support) in the router seems to fix the issue.



I've never had a problem until now with this on any of the 10-20 devices that's ever been hooked up to my router.

I'm going to say it again, if you have a similar wireless issue on your Shitty Logitech Squeezebox Radio - turn of WMM in your router.

onsdag 14 september 2011

Nokia N900 headset white M+ lead broken

So, after some reading about why my N900 didn't detect my headset as a headset I opened it up and indeed, it was just as they said. The white M+ lead is torn off the solder. I didn't open the headset up until after I had my entire N900 torn apart on my lunch break. At least I got a shitload of dust and pocket lint out of it.




Update:

I now have tools to try to fix this thing.


So, I had 3 minutes left before leaving for the station and soldered the mofo back together and the headset now works!

Update: 2011-10-20: Soldering broke and cable came loose while on my trip to the States, so I resoldered it again today at the office.

tisdag 30 augusti 2011

Compaq Mini 730OE Broadcom BCM4312 Wireless flakyness

Symptoms: Can't connect... 4-way handshake timeout. deauthenticated by Reason: 15.

First of all you need the b43 firmware:

apt-get install firmware-b43-lpphy-installer

Then put this in /etc/modprobe.d/b43.conf:

options b43 pio=1 qos=0

tisdag 29 mars 2011

FreeBSD ZFS Benchmarks






Some sysbench results on a HP ProLiant DL320s with 10 disks.
HP Smart Array P400 controller with 256MB cache. Each physical disk is it's own logical drive.

I know there's not much data or background. I will add more information later.
The script i used on each pool/filesystem.

I also used another script to parse each fileio output file into something usable.

zfs synopsis for all pools:
zpool create tank MEMBERS
zfs -o recordsize=16K tank/sysbench

where MEMBERS were one of the following:
da1 da2 da3 da4 da5 da6 da7 da8 da9 da10

mirror da1 da10 mirror da2 da9 mirror da3 da8 mirror da4 da7 mirror da5 da6

raidz da1 da10 da2 da9 da3 raidz da4 da8 da5 da7 da6

raidz2 da1 da10 da2 da9 da3 raidz2 da4 da8 da5 da7 da6

mirror da1 da10 da2 mirror da3 da9 da4 mirror da5 da8 da6

I'm more used with benchmarking on Linux so I've yet to come up with a really good comparative benchmark method.

I plan to add 2 x Vertex 3 Pro SSDs as cache and 1 x Intel X25-E as log device and try on a bigger dataset, pre-warmup and after post-warmup to see if there's good benefits from the SSD drives. The machine has 1G ram today, tomorrow I will have 6 or 7G ram in it.