Lots of screen savers on Ubuntu: $ sudo aptitude install xscreensaver-data-extra xscreensaver-screensaver-bsod xscreensaver-screensaver-dizzy xscreensaver-screensaver-webcollage

Read more →

I was searching for ways to generate xml feeds ( ATOM / RSS ) using Java. It appeared to be trivial task but its not. There are so many different libraries in Java which are capable of reading and writing XML in Java that it became a daunting task to evaulate them. After a bit of experimentation I have settled down with JDOM. JDOM is so simple to use. On top of that, ROME tools make it even easier to read/write feeds using Java.

Read more →

An energy drink startup in India. In, India we mostly consume only areated drinks. Energy drinks are kind of very rare to see if you consider both urban and rural landscape. So far I have come across a very few engergy drinks - RedBull, Tzinga, Could9, Rio etc. A friend of mine asked me to try this engergy drink called Tzinga. I received a package with all the three flavors ( shown in the picture above ).

Read more →

We are gifted with five senses - sight, hearing, touch, smell and taste. These let us identify color, sound, feel, aroma and appetite. How often do we give active thought to them? Well, of-course, those who are in a profession related to any of the five senses, have to deal with their impact on individuals and the masses. Barring ‘taste’, we can feel all other senses without much effort. Funny and surprising.

Read more →

I packagedRails 3.1.0 and its dependencies few days back for Fedora 16. The repository configuration file is as below: [rails3] name=rails3 baseurl=http://tuxdna.fedorapeople.org/packaging/rubygems/f16/ enabled=1 gpgcheck=0 Now when I installed Rails 3.1.0, I got into a in issue: $ sudo yum install rubygem-rails-3.1.0 ...OUTPUT SKIPPED... --> Running transaction check ---> Package rubygem-polyglot.noarch 0:0.3.3-1.fc16 will be installed ---> Package rubygem-sprockets.noarch 0:2.0.3-1.fc16 will be installed --> Processing Dependency: rubygem(tilt) < 1.3.0 for package: rubygem-sprockets-2.

Read more →

I can’t emphasize more the importance of packaging RPMs ( or any other packaging system ), as I already did it in an earlier post. Same arguments apply to Ruby Gems as well. That is to say, Ruby Gems already have a gem command to install and update packages. However it is still not a complete packaging system in itself. Consider the situation where you need to install a gem called A which dependes on B and C.

Read more →

I just finished a quick packaging of libgit2. It built fine on Koji and can be downloaded from here. A pull request has been submitted to include the spec file in the upstream codebase itself. Rpmfind was of great help in this quick packaging.

Read more →

This is my first attempt at building RPM packages for Ruby GEMS. https://gist.github.com/1885411 Requirements: yum install rpmdevtools yum install ruby rubygems rubygem-gem2rpm How to run: $ ruby make_rpms.rb -t ~/tmp/rpm-gem-packaging/ -n mechanize -r 2.2.1 This will download the gem and dependencies and generate SRPM and RPM files in the following folder: ~/tmp/rpm-gem-packaging/rpmbuild/ NOTE: The status of SUCCESS and FAILURE can be seen in the file: ~/tmp/rpm-gem-packaging/rpmbuild/status.txt Check for RPM and SRPM files which were generated:

Read more →

First install RVM and set it up: sudo yum install rubygem-rvm rvm-install To include RVM into your bash shell, add following line to ~/.bashrc: [[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # This loads RVM into a shell session. Now install JRuby and use it as default Ruby interpreter: source ~/.bashrc rvm install jruby-1.5.6 rvm use jruby-1.5.6 Setup Rails environment: gem install rails gem install bundler Lets create a new Rails application:

Read more →

My first Java exclusive conference! I arrived at the venue right on time. Surprize, there were a lot of people already holding their welcome kits. Conference was already running quite smoothly. Wifi worked most of the time. The sessions, lunch, tea were always on time. Actually, there were people assigned to ring bells, just like in schools, to notify timeout during lunch and tea breaks :) The whole confenence was revolving around four major topics: JBoss AS7, Infinispan, Drools and OpenShift.

Read more →

At JUDCon 2012, I had a discussion and argument with Jaikiran Pai and Ravi Maurya on «Packaging Java JARs as RPM packages». Well it is not just RPM, it could be any package management system ( eg. dpkg, protage etc. ), doesn’t matter as long as it serves the purpose of: automatic dependency resolution installation of dependencies rollback an install step install multiple versions of a (JAR) package ensure the packages are authentic ( for security )

Read more →

I wanted to experiment with Ruby bindings of Apache Qpid. Lets install the the server and client: $ sudo yum install qpid-cpp-server ruby-qpid qpid-tools $ service qpidd start Now check which version of Ruby bindings have we installed here: $ rpm -qi ruby-qpid Name : ruby-qpid Version : 0.8 Release : 2.fc15 Architecture: x86_64 Install Date: Fri 13 Jan 2012 06:21:55 PM IST Group : Development/Ruby Size : 219877 License : ASL 2.

Read more →

How do I dereference a symbolic link? $ ls -l /usr/bin/java lrwxrwxrwx. 1 root root 22 Jul 20 2010 /usr/bin/java -> /etc/alternatives/java $ ls -l /etc/alternatives/java lrwxrwxrwx. 1 root root 30 Aug 9 2010 /etc/alternatives/java -> /usr/java/jdk1.6.0_20/bin/java $ ls -l /usr/java/jdk1.6.0_20/bin/java -rwxr-xr-x. 1 root root 50810 Apr 13 2010 /usr/java/jdk1.6.0_20/bin/java Lets create a chain of symbolic links: mkdir /tmp/symlink cd /tmp/symlink echo "this is a test file" > abc.txt ln -s abc.

Read more →

In this post I am going to list the steps to resize a Virtual Machine image created using virt-install There are three steps: Resize the VM image Resize the LVM volume inside the VM ( both physical volume and logical volume ) Resize the filesystem on the LVM volume First locate where the image for your VM is stored. # virsh dumpxml vm2 | xpath /domain/devices/disk/source Found 1 nodes: -- NODE -- <source file="/export/vmimgs/vm2.

Read more →

zif critical errors

zif

Every once in a while I get these errors when installing a package using zif: Downloading [==================================================================] (59%) packages/glusterfs-server-3.2.4-2.fc16.x86_64.rpm [2.9 MB/s] om 64 to 52 on 0x1fb60b0! 5) zif-main.c:2590 (5/6) 4) zif-main.c:2401 (3/5) 3) zif-transaction.c:3989 (1/3) 2) zif-package-array.c:243 (0/1) 1) zif-package-remote.c:416 (2/3) 0) zif-store-remote.c:505 (1/2) (zif:18671): Zif-CRITICAL **: percentage should not go down from 60 to 19 on 0x78e6410! 4) zif-main.c:2590 (5/6) 3) zif-main.c:2401 (3/5) 2) zif-transaction.c:3989 (1/3) 1) zif-package-array.c:243 (0/1) 0) zif-package-remote.

Read more →

On Fedora 16, I used zif. zif is an alternative to yum and its fast! How to setup zif? So easy: sudo yum install zif zif-tools All set! Search for packages using zif: sudo zif search mongodb Do a offline serach ( like cached -C in yum ): sudo zif search -o mongodb Install packages using zif: sudo zif install mongodb-server mysql-server Update all packages: sudo zif update And if you feel like canceling the operation using Ctrl+C, it happens almost instantaneously!

Read more →

How to setup multiple monitors on Xfce desktop? I just followed the instructionson Xorg RandR 1.2 wiki - http://www.thinkwiki.org/wiki/Xorg_RandR_1.2 Lets find out how many monitors we have connected? $ xrandr -q Screen 0: minimum 320 x 200, current 1280 x 800, maximum 8192 x 8192 LVDS1 connected 1280x800+0+0 (normal left inverted right x axis y axis) 261mm x 163mm 1280x800 60.0*+ 50.0 1024x768 60.0 800x600 60.3 56.2 640x480 59.9 VGA1 connected (normal left inverted right x axis y axis) 1680x1050 60.

Read more →

I installed Fedora 16 x86_64 and then installed Emacs. Then I logged in into (XFCE or GNOME) desktop and started Emacs. For text selection in Emacs I use Ctrl+Space ( which is the default in Emacs ), and is no longer working. So I cannot select text using Ctr+Space. However, if I login into virtual terminal (Ctrl+Alt+F3), then login and start Emacs, the key-binding (Ctrl+Space) for text selection works fine. Therefore there is no problem in Emacs itself.

Read more →

Lets first install wirble sudo gem install wirble Add following lines to ~/.irbrc #!/usr/bin/ruby require 'irb/completion' require 'rubygems' require 'wirble' Wirble.init Wirble.colorize Now invoke irb. $ irb >> 1.m # press TAB here to auto complete 1.method 1.methods 1.modulo >> 1.methods # press ENTER and the output will be colorized :) => ["%", "odd?", "inspect", "prec_i", "<<", "tap", "div", "&amp;", "pretty_print", "po", "clone", ">>", "public_methods", "__send__", "object_id", "instance_var iable_defined?

Read more →

If yum whatprovides /path/to/file is slow for you, try a faster alternative: rpm -q --whatprovides /path/to/file For example: $ rpm -q --whatprovides /usr/bin/clibrary speech-dispatcher-0.7.1-5.fc15.x86_64 rpm is quite fast and yum is too slow. Get back to basics!

Read more →