lunedì 23 novembre 2009

Java plugin per Firefox su Ubuntu

To execute applets in your Firefox browser you have to install the java plugin.

Follow this steps:
1) sudo apt-get install sun-java6-jdk
2) ln -s /usr/lib/jvm/__JDK-VERSION__/jre/plugin/i386/ns7/libjavaplugin_oji.so /home/__USER__/.mozilla/plugins/

giovedì 5 novembre 2009

Why hibernation doesn't work?

In my case the answer is easy: not enough space in the swap partition.
In order to hibernate the pc, Ubuntu copies the ram to the swap partition, so this must be at least as bigger as the installed ram.

You can verify ram and swap size with:
cat /proc/meminfo | grep SwapTotal; cat /proc/meminfo | grep MemTotal

domenica 1 novembre 2009

Mysql and the default value of a TIMESTAMP column

The DEFAULT value in CREATE TABLE specification indicates a default value for a column.

The default value must be a constant and it cannot be a function or an expression. This means, for example, that you cannot set the default for a date column to be the value of a function such as NOW(). The solution is to specify CURRENT_TIMESTAMP as the default for a TIMESTAMP column.