change max_allowed_packet (or any arbitrary DB parameter group value) in Amazon RDS from commandline

This task sounds to be quite easy, but because the AWS Management Console does not allow the manipulation of parameter group values, you have to go the way using the API from your commandline (or from wherever you want). This post will explain how to do it in your console using the API tools from… Continue reading change max_allowed_packet (or any arbitrary DB parameter group value) in Amazon RDS from commandline

Create MATLAB readable avi from bmp frames

Use the following command ffmpeg -vframes 200 -f image2 -i airport1%03d.bmp -f avi -vcodec rawvideo -pix_fmt bgr24 -acodec pcm_s16le airport.avi This will convert all the files airport1000.bmp to airport1200.bmp to an avi file. Using mencoder will allow you to chose the framerate: mencoder “mf://*.bmp” -mf fps=12 -o out.avi -ovc lavc -lavcopts vcodec=msmpeg4v2:vbitrate=800

tab exension for hostnames in ssh

Using the tab extension is a nice thing. To make ssh know your hosts, add three lines in the ~/.ssh/config folder: Host mySpecialHost HostKeyAlias somehost-somewhere.ch Hostname somehost-somewhere.ch

send big chunk of data over linux sockets

Sending a big chunk of data over linux sockets can  be tricky, because we need to call the write function multiple times. The following snippet assumes a valid socket filedescriptor “socketfd”, after the connection is established. Make sure that PACKETSIZE is smaller or equal to 2^16 and that nbytes equals the amount of bytes of… Continue reading send big chunk of data over linux sockets