Archive for May, 2010

Enable mod expires on Ubuntu 9.10 Karmic Koala

To enable mod expires on ubuntu karmic koala :

sudo a2enmod headers
sudo a2enmod expires
sudo /etc/init.d/apache2 restart

If you internal server error or ExpiresActive not allowed here

Speed up Swing GUI Java Apps

I was writing a small database application using Java and Apache Derby in Netbeans. Soon, felt that the speed should be improved as it was slow compared to a c++ or python app.
There are a few tweaks which could give significant improvement in the speed of a swing gui application.

Zero Seller protection on Scriptlance

Scriptlance is a popular freelance portal where buyers and sellers meet together to work on projects.
Scriptlance has the escrow system which aims at providing sellers with protection against frauds by clients.

Useful ffmpeg commands on Ubuntu 9.10 Karmic Koala

FFmpeg can be installed easily from synaptic

sudo apt-get install ffmpeg

Some useful ffmpeg commands :
1. convert mpeg to flv

ffmpeg -i /path/to/movie.mpeg -ar 22050 -ab 32 -f flv -b 500000 -s 480×360 -y movie.flv

2. convert mp3 to flv

ffmpeg -i /path/to/track.mp3 -f mp3 -ab 64000 -ar 22050 myfile.mp3

3. convert mpeg to flv with mp3

ffmpeg -i /path/to/movie.mpeg -ar 22050 [...]

Access other partitions as writable from Dolphin KDE in Ubuntu

To access other partitions as writable execute the command.

sudo chmod -Rv a+w /media/disk

where directory /media/disk is the path to your partition.