Skip navigation.

linux

Extract audio from .avi file on Kubuntu and finding which package a file in

To extract the audio from an .avi video file, use the command:

mplayer video.avi -vc dummy -vo null -af resample=44100 -ao pcm:file=ripped-audio.wav

Make sure that the program oggenc is installed. I didn't know which package this program was, so I searched and found this nifty tool for Ubuntu: apt-file

Install it and update its internal database:

# apt-get install apt-file
# apt-file update

Then using this tool to search for oggenc told me I could find it in the vorbis-tools package:

$ apt-file search oggenc

Compile OCR Tessaract on Kubuntu

As some of you may know, I am trying to scan a whole book written by my grandfather, as I plan to publish it on the internet. It is a very inspiring book which could change our society.

So, first thing first, I need to scan the whole book and use an Optical Character Recognition (OCR) software as a first step to put it into HTML form.

This is the main documentation wiki for Ubuntu OCR.

I only had a test scan in .pdf format to test with, so I followed the instructions to use GIMP to transform it into a TIFF (.tif) file.

MySQL: changing data dir

I wanted to change the location of the datadir for mysql. I had some troubles accomplishing this and the solutions I saw online were not fully accurate, so for the record, here is how I achieved this.

I installed Kubuntu 9.10 in my new computer, and wanted to move my old database data from my old computer. Also, I wanted to change the datadir to /home/mysql/ instead of the default /var/lib/mysql/.

Stop the mysqld server:

/etc/init.d/mysql stop

edit my.cnf:

vi /etc/mysql/my.cnf
// set:
// dir   = /home/mysql

Syndicate content