Create a movie file from single image files (png, jpegs)

Posted April 28th @ 12:49 by Werner

In research sometimes you want to make a movie from single images, like plots from experimental data or from calculation to visualize changes or so on. In order to achieve this you can use ffmpeg. First you have to create the images and save them, where the images need to have a continuous number in the filename, e.g. img0001.png, img0002.png, …, …img5467.png. Take care that there is no image missing and that you have enough zeroes in front of the image number, so that the files are in the correct order. Read the rest of this entry »

Changing the php file upload limit in Ubuntu Linux

Posted April 14th @ 2:46 by Werner

If you have your own Ubuntu server running you may encounter the maximal file size upload limit in php scripts which is set to 2Mb as default. In order to change that we first have a look what the size actually is. In /var/www (standard www directory) create a file called info.php with the following content:

<?php
// Show all information, defaults to INFO_ALL
phpinfo();
?>

Read the rest of this entry »

Mounting directory from Mac OS X host in Ubuntu Gutsy Gibbon guest in VirtualBox

Posted February 29th @ 3:30 by Werner

There is a new beta version of VirtualBox for Mac OS X available and installing Ubuntu Gutsy Gibbon worked like a charm (in opposition to Parallels). The only problem I encountered was, that it was not possible to mount a directory from the Mac OS X host in the guest system with either the internal mechanism (Folder sharing) and just directly via samba. In the latter case I could mount the host directory and could view it once, but than the mount was always busy and I had no access anymore. But I found another solution: sshfs. Here is a short introduction how to do that:

Read the rest of this entry »

Install gnuplot on Ubuntu Gutsy Gibbon

Posted January 23rd @ 4:50 by Werner

I again have updated these instructions for Gnuplot 4.4.0 RC1 and newer Ubuntu versions. Find them in this post.

Some months ago I wrote a small Howto about installing Gnuplot on Ubuntu Feisty Fawn with readline, pdf and wxWidgets terminal support. It turned out, that this howto was of interest for many people, since this blog post was the most visited until Gutsy Gibbon came out – and the readline problem was obviously solved, since it works now if you install the standard Gnuplot package. Still the pdf and wxWidgets terminal are not compiled in by default, therefore I wrote a new (shorter) howto about including this terminals.

So here are the instructions: Read the rest of this entry »

Universal binary of netcdf library for Mac OS X (10.5)

Posted November 30th @ 10:01 by Werner

In order to create a universal binary of netcdf first read this post. Than issue this configure command:

./configure CFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch i386" CXXFLAGS="-isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch i386" LDFLAGS="-Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk -arch ppc -arch i386" --disable-dependency-tracking --disable-f77c 

This will correctly build a universal binary of the netcdf library (C and C++). I had to use “–disable-f77″ since I only had f2c installed which is not able to compile the netcdf fortran API. “make test” was successfully run.

Compiling universal binaries in Mac OSX 10.5 (Leopard) against 10.4u SDK problem

Posted November 30th @ 9:49 by Werner

The hint below is actually a hack. The correct solution would be to add “-mmacosx-version-min=10.4″ to the compiler and linker command as mentioned in this post or follow the comment below this post.

If you compile a programm/library on Mac OS X 10.5 (Leopard) against the 10.4u SDK as suggested in this technote to create a universal binary you may encounter this error message:

ld: library not found for -lcrt1.10.5.o

In that case you need to create a symbolic link

sudo ln -s /Developer/SDKs/MacOSX10.4u.sdk/usr/lib/crt1.o /Developer/SDKs/MacOSX10.4u.sdk/usr/lib/crt1.10.5.o

This might solve the linking problem than. This hint was found here and here.

Where is the damn \ and { in Mac OS X?

Posted November 22nd @ 10:38 by Werner

I recently got a new shiny iMac at work with Mac OS X 10.5 on it. Very nice. I like it. If you are used to the Windows/Linux keyboard, you run into troubles though, since some keys are not there where they should be. In order to find out where the are use the virtual keyboard. This utility is somehow hidden, but here are the instructions how to enable it: Read the rest of this entry »

Speed up SSH X11 forwarding

Posted June 1st @ 9:50 by Werner

I use an Ubuntu server as a work-horse for my calculations and connect from my desktop-pc with ssh to the server. For some applications (gnuplot =) this is really slow altough it’s over LAN. I found on the internet some instructions to improve this situation: instead of the AES cipher the arcfour and blowfish ciphers perform much better and switching on compression also doesn’t hurt. Therefore one should use

ssh -c arcfour,blowfish-cbc -XC host.com

to connect to with ssh. And guess what? This really improves the situation, especially for gnuplot. Thanks Samat!

Same swap partition mounted twice (Ubuntu Feisty)

Posted May 31st @ 12:32 by Werner

Yesterday I wrote that my swap partition suddenly vanished, only to find out that suddenly my swap partition was mounted twice. “top” showed twice the amount of swap space available and “cat /proc/swaps” listed two entries to the same swap partition (/dev/sda6 and /dev/mapper/sda6). This seems to be a bug in Ubuntu Feisty and the (temporary) solution is to change the “/etc/fstab”. You’ll find a line “UUID=Your_UUID none            swap    sw”. Replace “UUID=..” with the correct device, e.g. “/dev/sda6″. After a reboot the swap partition should only be mounted once (“cat /proc/swaps”). The system boots now faster btw, sometime it hung during the startup.

Suddenly my swap drive was missing

Posted May 30th @ 3:54 by Werner

When checking ‘top’ after I was told that I have no memory anymore I found out that I had no swap drive anymore. Must have gone lost when I switched to Ubuntu Feisty. Anyway, I found a description to re-initiate the swap drive:

  • First find out which partition your swap drive is, e.g. with ‘sudo fdisk -l /dev/sda’ (the important line is ‘/dev/sda6 8391 8645 2048256 82 Linux swap / Solaris’)
  • sudo mkswap /dev/sda6 – a new UUID will be created and printed on the screen (e.g. ‘no label, UUID=16ef6e6c-dd7e-4efd-bacd-8718ebeac568′)
  • create a link in /dev/disks/by-uuid: ‘cd /dev/disks/by-uuid’ and ‘sudo ln -s ../../mapper/sda6 /dev/disk/by-uuid/Your-UUID’
  • sudo swapon -va
  • sudo gedit /etc/fstab and set the correct UUID in the line ‘UUID=Your-UUID none swap sw 0 0′

To keep swap intact after hibernation additionally you need

  • sudo gedit /etc/initramfs-tools/conf.d/resume and add the line ‘RESUME=UUID=Your-UUID’
  • sudo update-initramfs -u

Options:

Size

Colors