<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Vladimir Cvetic &#187; Ubuntu</title>
	<atom:link href="http://www.hazaah.com/cat/ubuntu/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.hazaah.com</link>
	<description>buffle the world</description>
	<lastBuildDate>Thu, 12 Nov 2009 14:30:29 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Bash job queuing: Task Spooler</title>
		<link>http://www.hazaah.com/programming/bash-job-queuing-task-spooler/</link>
		<comments>http://www.hazaah.com/programming/bash-job-queuing-task-spooler/#comments</comments>
		<pubDate>Mon, 09 Feb 2009 15:19:02 +0000</pubDate>
		<dc:creator>Vladimir Cvetic</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://www.hazaah.com/?p=155</guid>
		<description><![CDATA[Today I found nifty little tool for queuing bash jobs, Task Spooler.
Imagine you hava list of jobs that are dependant on each other.
First job converts video from one format to another, second job should trigger if first job was successful and do some status updating. This is exactly a thing Task Spooler will help you [...]]]></description>
			<content:encoded><![CDATA[<p>Today I found nifty little tool for queuing bash jobs, <a href="http://vicerveza.homeunix.net/~viric/soft/ts/">Task Spooler</a>.</p>
<p>Imagine you hava list of jobs that are dependant on each other.<br />
First job converts video from one format to another, second job should trigger if first job was successful and do some status updating. This is exactly a thing Task Spooler will help you with.<br />
It will prevent simultaneous video conversions by queuing them to run one after another.</p>
<p>Downside is that it listens to port 80 and I haven&#8217;t found a way to change that port. This is a &#8220;bad&#8221; thing because most people have apache listening on port 80 too, so to restart apache you will need to kill all Task Spooler processes or you will get an error that goes something like this:<br />
<em>Address already in use: make_sock: could not bind to address 0.0.0.0:80<br />
no listening sockets available, shutting down</em>.</p>
<p>I will probably play with it some more and try to build out of the box methods for callbacks&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hazaah.com/programming/bash-job-queuing-task-spooler/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>toGDImage() broken: Patching ffmpeg-php 0.6.0</title>
		<link>http://www.hazaah.com/programming/togdimage-broken-patching-ffmpeg-php-060/</link>
		<comments>http://www.hazaah.com/programming/togdimage-broken-patching-ffmpeg-php-060/#comments</comments>
		<pubDate>Sun, 08 Feb 2009 17:51:40 +0000</pubDate>
		<dc:creator>Vladimir Cvetic</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://www.hazaah.com/?p=152</guid>
		<description><![CDATA[As fallow-up to previous post (link).

After toying with fresh ffmpeg-php 0.6.0 I kept getting error:
Fatal error: failed to convert frame to gd image

Problem lies in broken function _php_avframe_to_gd_image in ffmpeg_frame.c, in the base ffmpeg-php package.
To fix this problem download this patch file and apply it to ffmpeg_frame.c like so:

cd /path/to/ffmpeg-php-0.6.0/
wget http://hazaah.com/download/ffmpeg_frame.c.patch
patch -p0 ffmpeg_frame.c < ffmpeg_frame.c.patch

Reinstall [...]]]></description>
			<content:encoded><![CDATA[<p>As fallow-up to previous post (<a href="http://www.hazaah.com/ubuntu/how-to-ffmpeg-ffmpeg-php-lame-libogg-libvorbis-flvtool2-mplayer-mencoder-amr/">link</a>).</p>
<p>
After toying with fresh ffmpeg-php 0.6.0 I kept getting error:<br />
<em>Fatal error: failed to convert frame to gd image</em>
</p>
<p>Problem lies in broken function _php_avframe_to_gd_image in ffmpeg_frame.c, in the base ffmpeg-php package.<br />
To fix this problem <strong><a href="http://hazaah.com/download/ffmpeg_frame.c.patch">download this patch file</a></strong> and apply it to ffmpeg_frame.c like so:</p>
<pre>
cd /path/to/ffmpeg-php-0.6.0/
wget http://hazaah.com/download/ffmpeg_frame.c.patch
patch -p0 ffmpeg_frame.c < ffmpeg_frame.c.patch
</pre>
<p>Reinstall ffmpeg-php &#038;&#038; restart apache.</p>
<p>Thats all.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hazaah.com/programming/togdimage-broken-patching-ffmpeg-php-060/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>How-to: FFmpeg, FFmpeg-PHP, Lame, Libogg, Libvorbis, FLVtool2, Mplayer, Mencoder, AMR</title>
		<link>http://www.hazaah.com/ubuntu/how-to-ffmpeg-ffmpeg-php-lame-libogg-libvorbis-flvtool2-mplayer-mencoder-amr/</link>
		<comments>http://www.hazaah.com/ubuntu/how-to-ffmpeg-ffmpeg-php-lame-libogg-libvorbis-flvtool2-mplayer-mencoder-amr/#comments</comments>
		<pubDate>Sun, 08 Feb 2009 16:08:17 +0000</pubDate>
		<dc:creator>Vladimir Cvetic</dc:creator>
				<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://www.hazaah.com/?p=149</guid>
		<description><![CDATA[This howto is written for Ubuntu 8.10 and is verified to work on 8.2.2009.
I found numerous tutorials on this subject out there but they all failed me, but combination of them all was successful. So fallowing is made from 10 different tutorials.
And for all those who will ask why not just apt-get php5-ffmpeg, answer is [...]]]></description>
			<content:encoded><![CDATA[<p>This howto is written for Ubuntu 8.10 and is verified to work on 8.2.2009.</p>
<p>I found numerous tutorials on this subject out there but they all failed me, but combination of them all was successful. So fallowing is made from 10 different tutorials.<br />
And for all those who will ask why not just apt-get php5-ffmpeg, answer is so we can configure ffmpeg with libs and options we need.</p>
<p><strong>Prepare</strong></p>
<pre>
apt-get update
apt-get upgrade
apt-get install libjpeg-progs libjpeg62 libjpeg62-dev libsdl1.2-dev php5-dev php5-cli php5-gd build-essential unzip
</pre>
<p><strong>Download files</strong></p>
<pre>
cd /usr/local/src
wget http://www3.mplayerhq.hu/MPlayer/releases/codecs/essential-20071007.tar.bz2
wget http://rubyforge.org/frs/download.php/17497/flvtool2-1.0.6.tgz
wget http://easynews.dl.sourceforge.net/sourceforge/lame/lame-3.97.tar.gz
wget http://superb-west.dl.sourceforge.net/sourceforge/ffmpeg-php/ffmpeg-php-0.6.0.tbz2
wget http://downloads.xiph.org/releases/ogg/libogg-1.1.3.tar.gz
wget http://downloads.xiph.org/releases/vorbis/libvorbis-1.2.0.tar.gz
wget http://ftp.penguin.cz/pub/users/utx/amr/amrnb-7.0.0.2.tar.bz2
wget http://ftp.penguin.cz/pub/users/utx/amr/amrwb-7.0.0.3.tar.bz2
wget http://downloads.xiph.org/releases/theora/libtheora-1.0beta3.tar.gz
</pre>
<p><strong>Unpack packages</strong></p>
<pre>
tar zxvf lame-3.97.tar.gz
tar zxvf libogg-1.1.3.tar.gz
tar zxvf libvorbis-1.2.0.tar.gz
tar zxvf flvtool2-1.0.6.tgz
tar jxvf essential-20071007.tar.bz2
tar jxvf ffmpeg-php-0.6.0.tbz2
bzip2 -cd amrnb-7.0.0.2.tar.bz2 | tar xvf -
bzip2 -cd amrwb-7.0.0.3.tar.bz2 | tar xvf -
tar zxvf libtheora-1.0beta3.tar.gz
</pre>
<p><strong>Install Ruby on Rails, subversion &#038; ncurses</strong></p>
<pre>
apt-get install subversion ruby libcurses-ruby
</pre>
<p><strong>Fetch latest Mplayer and FFmpeg from trunk</strong></p>
<pre>
svn checkout svn://svn.mplayerhq.hu/ffmpeg/trunk ffmpeg
svn checkout svn://svn.mplayerhq.hu/mplayer/trunk mplayer
cd /usr/local/src/mplayer
svn update
</pre>
<p><strong>Copy codecs</strong></p>
<pre>
mkdir /usr/local/lib/codecs
mv /usr/local/src/essential-20071007/* /usr/local/lib/codecs/
chmod -R 755 /usr/local/lib/codecs/
</pre>
<p><strong>Create TMP</strong></p>
<pre>
mkdir /usr/local/src/tmp
chmod 777 /usr/local/src/tmp
export TMPDIR=/usr/local/src/tmp
</pre>
<p><strong>Install lamemp3</strong></p>
<pre>
cd /usr/local/src/lame-3.97
./configure
make &#038;&#038; make install
</pre>
<p><strong>Install libogg</strong></p>
<pre>
cd /usr/local/src/libogg-1.1.3
./configure &#038;&#038; make &#038;&#038; make install
</pre>
<p><strong>Install libvorbis</strong></p>
<pre>
cd /usr/local/src/libvorbis-1.2.0
./configure &#038;&#038; make &#038;&#038; make install
</pre>
<p><strong>Install flvtool2</strong></p>
<pre>
cd /usr/local/src/flvtool2-1.0.6/
ruby setup.rb config
ruby setup.rb setup
ruby setup.rb install
</pre>
<p><strong>Install mplayer &#038; mencoder</strong></p>
<p>grab a snack</p>
<pre>cd /usr/local/src/mplayer
./configure --enable-jpeg
make &#038;&#038; make install</pre>
<p><strong>Install AMR</strong></p>
<pre>
cd /usr/local/src/amrnb-7.0.0.2
./configure
make &#038;&#038; make install

cd /usr/local/src/amrwb-7.0.0.3
./configure
make &#038;&#038; make install
</pre>
<p><strong>Install libtheora</strong></p>
<pre>
cd /usr/local/src/libtheora-1.0beta3
./configure
make &#038;&#038; make install
</pre>
<p><strong>Install ffmpeg</strong></p>
<pre>cd /usr/local/src/ffmpeg/
./configure --enable-libmp3lame --enable-libvorbis --disable-mmx --enable-shared --enable-libamr-nb --enable-libamr-wb --enable-nonfree --enable-libtheora</pre>
<pre>
make
make install
</pre>
<p><strong>Important:</strong> You will probably get errors such as: <em>ffmpeg: error while loading shared libraries: libavdevice.so.52: cannot open shared object file</em>, or some other library. To solve this problem you must create symbolic links. Universal code would go something like this:</p>
<pre>
ln -s /usr/local/lib/[YOUR LIB NAME]/usr/lib/[YOUR LIB NAME]
</pre>
<p>So, if you get error for libavdevice.so.52 [YOUR LIB NAME] would be libavdevice.so.52.<br />
Got it? Good, moving on&#8230;<br />
<strong>Install ffmpeg-php</strong></p>
<pre>
cd /usr/local/src/ffmpeg-php-0.6.0/
phpize
./configure --with-ffmpeg=/usr/local/ffmpeg
make
make install
</pre>
<pre>
echo 'extension=ffmpeg.so' >> /etc/php5/apache2/php.ini
/etc/init.d/apache2 restart
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.hazaah.com/ubuntu/how-to-ffmpeg-ffmpeg-php-lame-libogg-libvorbis-flvtool2-mplayer-mencoder-amr/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Can not change theme in AWN</title>
		<link>http://www.hazaah.com/ubuntu/can-not-change-theme-in-awn/</link>
		<comments>http://www.hazaah.com/ubuntu/can-not-change-theme-in-awn/#comments</comments>
		<pubDate>Fri, 08 Aug 2008 08:27:57 +0000</pubDate>
		<dc:creator>Vladimir Cvetic</dc:creator>
				<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://www.hazaah.com/?p=74</guid>
		<description><![CDATA[There is a bug in current version of AWN (Avant Window Navigator 0.3.1), theme manager is broken. After some time I found out that there is a very simple solution for this problem.
AWN doesn&#8217;t make permissions for config folder like it should, owner is root instead of you (the rightful owner). Quick fix is:

sudo chown [...]]]></description>
			<content:encoded><![CDATA[<p>There is a bug in current version of AWN (Avant Window Navigator 0.3.1), theme manager is broken. After some time I found out that there is a very simple solution for this problem.</p>
<p>AWN doesn&#8217;t make permissions for config folder like it should, owner is root instead of you (the rightful owner). Quick fix is:</p>
<pre>
sudo chown -R $USER:$USER /home/$USER/.config/awn
</pre>
<p>I am sure this will be fixed very soon, till then have fun.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hazaah.com/ubuntu/can-not-change-theme-in-awn/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Unrar recursively multiple archives (linux and mac)</title>
		<link>http://www.hazaah.com/programming/unrar-recursevly-linux-mac/</link>
		<comments>http://www.hazaah.com/programming/unrar-recursevly-linux-mac/#comments</comments>
		<pubDate>Fri, 01 Aug 2008 07:11:02 +0000</pubDate>
		<dc:creator>Vladimir Cvetic</dc:creator>
				<category><![CDATA[Database]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://www.hazaah.com/?p=69</guid>
		<description><![CDATA[It really is a drag when you download full season of your favorite show and see 20+ episodes in separate folders, every episode rared. It takes a bit of time to unpack one by one.
Here&#8217;s a little script that should help you with that (and with similar tasks). Download.
Install:

gunzip unrarr.gz
sudo cp unrarr /usr/bin/
sudo chmod +x [...]]]></description>
			<content:encoded><![CDATA[<p>It really is a drag when you download full season of your favorite show and see 20+ episodes in separate folders, every episode rared. It takes a bit of time to unpack one by one.</p>
<p>Here&#8217;s a little script that should help you with that (and with similar tasks). <strong><a href="http://hazaah.com/download/unrarr.gz">Download</a></strong>.<br />
Install:</p>
<pre>
gunzip unrarr.gz
sudo cp unrarr /usr/bin/
sudo chmod +x /usr/bin/unrarr
</pre>
<p>Usage:</p>
<pre>
unrarr /path/to/folder
</pre>
<p>Edit:<br />
To check rar files (through svf files) for consistency CVF package must be installed (<a href="http://cfv.sourceforge.net" target="_blank">cfv.sourceforge.net</a>)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hazaah.com/programming/unrar-recursevly-linux-mac/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Ubuntu: Mounting remote directory, ssh</title>
		<link>http://www.hazaah.com/ubuntu/ubuntu-mounting-remote-directory-ssh/</link>
		<comments>http://www.hazaah.com/ubuntu/ubuntu-mounting-remote-directory-ssh/#comments</comments>
		<pubDate>Fri, 30 May 2008 09:12:50 +0000</pubDate>
		<dc:creator>Vladimir Cvetic</dc:creator>
				<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Fuse]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[mount]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[sshfs]]></category>

		<guid isPermaLink="false">http://www.knowbies.com/?p=60</guid>
		<description><![CDATA[
$sudo apt-get install sshfs

Will install fallowing: fuse-utils and libfuse2
When sshfs is installed:

$sudo mkdir /path/to/mount/point
$sudo chown your-username /path/to/mount/point
$sshfs ssh-username@ssh-server.com:/target/dir /path/to/mount/point

Thats it. To unmount just type

$sudo umount /path/to/mount/point

]]></description>
			<content:encoded><![CDATA[<pre>
$sudo apt-get install sshfs
</pre>
<p>Will install fallowing: fuse-utils and libfuse2</p>
<p>When sshfs is installed:</p>
<pre>
$sudo mkdir /path/to/mount/point
$sudo chown your-username /path/to/mount/point
$sshfs ssh-username@ssh-server.com:/target/dir /path/to/mount/point
</pre>
<p>Thats it. To unmount just type</p>
<pre>
$sudo umount /path/to/mount/point
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.hazaah.com/ubuntu/ubuntu-mounting-remote-directory-ssh/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
