Apr 20 2009

Finally music in Ubuntu 9.04

Category: Ubuntuadmin @ 4:11 pm

A while ago, I upgraded my Ubuntu from 8.10 to 9.04. Everything went smoothly and after the upgrade most of the applications seemed to run fine. One problem which I noticed almost immediately was caused by Amarok which was updated from the beautiful 1.4.x to the disappointing 2.0.

I wasn’t too happy with this change especially because a few months ago I tried an Amarok 2.0 snapshot, but I reversed to 1.4.x quickly because I wasn’t happy with the features it offered. I was even more upset when I noticed that Amarok would not play any of my music. Initially I thought that I do not have the necessary codecs installed, but this should not have been the case because I used to be able to play both mp3 and ogg files in the 1.4.x.. To make the situation even more confusing I was able to play online streams. After a bit of googling, I came across the MP3 support in Amarok 2 entry in the Amarok forum which suggested a few ways of addressing the problem. In my case all I had to do was:

  1. Install phonon-backend-xine package
  2. Start a terminal and run the systemsettings command to get the KDE control center
  3. Go to Multimedia -> Backend and selected Xine as backend
  4. Start Amarok and enjoy my music :)

Probably I should mention that I am using Gnome, not KDE. Maybe Kubuntu installs phonon-backend-xine automatically so this solution may not be useful for you.

For now, I am using Amarok as any other media player, but I hope in the new versions features that were removed in the 2.0 version will appear again.

Tags: ,


Oct 18 2008

How to run IDLE on Vista?

Category: Python,computersadmin @ 12:21 am

I have recently started teaching Python. At uni, I force my students to use Linux, but as you may expect most students have laptops with Vista. Today, I had to face one of the first problems of running Python on Vista. One student tried to install Python and she could not run IDLE. After a bit of googling if found out the source of the problem: Python need to be installed for all the users, not only for the current user. Otherwise, IDLE will refuse to start. 

There is a hint on one of the Python webpages. It says that if you want to install Python for all users you need to run

runas /user:Administrator "msiexec /i <path>\<file>.msi"

Now there are two problems: First, depending on your version of Vista, you may or may not have a user called Administrator. The second problem is that this command does not seem to work even if you replace Administrator with a user name that is in the administrators’ group.

The solution seems to be quite simpler:

  1. Log in as a user who is in the administrators’ group (if you do not know what is that and you are the only user of the computer, then you are probably an administrator and you do not need to worry)
  2. Create a file run.bat somewhere on your computer
  3. Edit the contents of the file and put the following command:
    msiexec /i <path-to-python-installer>\python-2.6.msi
    (e.g. msiexec /i c:\Users\dinel\Desktop\python-2.6.msi)
  4. Save the file
  5. Right click on the run.bat file and select “Run as administrator”
  6. Install python making sure you install for all users not only for yourself.
  7. Enjoy IDLE :)

This solution seems to work on Vista Home Premium Edition. Please let me know if it also works on other versions of Vista.

Tags: , ,


Sep 03 2008

Google Chrome – first impression

Category: computersadmin @ 1:18 am

Ok, so unless you live on a different planet you have already heard that Google has released their own web browser called Chrome. After all the news stories I heard on the radio (even on BBC World Service), I decided that instead of going to bed like any normal person, I stay up till this stupid hour and try the new browser. As if staying up was not a sacrifice big enough, I also had to boot my computer in Windows Vista, as there is no Linux version yet.

The installation of the program is very easy. You need to go to Google Chrome page and download a small installer (about 400k). After that, the setup program downloads the files necessary for installation, but unfortunately it does not give you any indication how big are these files. Anyhow, they cannot be too big because the whole process took less than one minute (but some transparency would be nice).

Continue reading “Google Chrome – first impression”

Tags: ,


Aug 12 2008

Ubuntu Intrepid Alpha 3 – Part 2

Category: Uncategorizedadmin @ 10:46 pm

In my yesterday’s post I mentioned two annoying bugs. The first one was linked to Evolution. In the end, it proved to be due to gtk and it is already fixed. Don’t you love open source.

The second bug I mentioned was that I cannot reboot or shutdown my computer. In the end it doesn’t seem to be a bug as such. The new Ubuntu seems to use a new system of authorizations which indicates what actions a user can perform including rebooting and shutting down the system. As you may imagine none of the users on my computer was allowed to reboot the system. If you want to find out more go to System/Administration/Authorizations. So this should solve the problem of rebooting the system.

Now it’s time to find out why I cannot access my user directory from a browser even though the userdir module is enabled in apache.

Tags: ,


Aug 11 2008

Ubuntu Intrepid Alpha 3

Category: Ubuntu,computersadmin @ 10:28 pm

I have just decided to install Intrepid Ibex, the new version of Ubuntu. I am not sure what determined to do that. Probably because I had too much time :)

Given that it is an alpha version, I expected to find lots of bugs. Surprisingly enough, I had very few problems. On the down side there seem to be only a few new features for the desktop version … but I may be wrong and the features are well hidden and will become obvious later.

One of the first things I noticed in Evolution is that I can finally have my Exchange account enabled and the program does not freeze as soon as I try to compose an email. A few months ago, after a security upgrade, I was no longer able to keep my Exchange account enabled when I wanted to compose emails (from any type of account) and I found no workaround. Strangely enough the same version on the same distribution worked perfectly on a different computer. The sad news is that the current composer seems to have some kind of major bug which makes email writing a pain. See the images below:

Problem composing an HTML emailAfter one key is pressed the composer gets back to normal

The composer keeps going from one state to another every time when you press a key regardless whether you compose a plain text email or an HTML one. Being such an obvious bug, I would be surprised if it is not fixed in the next release.

A new feature of Evolution is the move to sqlite database for folder summaries. I did not notice big improvements in the search speed, but I did not have time to test it properly. During the initial migration I had problems due to the fact that I have over 2G of emails. Every time when I started the migration, Evolution allocated more and more memory till it crashed. The only way to complete the migration and access my emails was to move a big chunk of emails from .evolution folder and then after migration put them back. After that everything was fine, as evolution seems to build the missing summaries on fly.

Booting the system does not seem to be free of bugs. At times my computer refuses to start with the current kernel (2.6.26.5), but on the second or third attempt it does. A nice addition at booting time is the fact that now you know for which encrypted disk you have to enter the password. I have two encrypted disks in my computer, each with its own password, and in the past I had to know the order in which I have to enter the passwords. Now a clear message is displayed.

Currently it doesn’t seem to be possible to shut down the computer from Gnome. The only solution I found is to type halt in a terminal. I know that linux machines are well know for their massive uptimes, but removing the restart/halt option does not seem to be a good way to combat global warming (just kidding, there are shutdown and reboot buttons, it just that they don’t work yet).

The hyped new darker theme did not appeal to me at all so I switched back to my customised theme. There seem to be a new set of desktop icons which looks quite nice (but maybe I did not pay attention to them before). The flash plugin seems to bring down my Firefox more rarely, but it may be too early to know for sure. However, the other day I accessed a page with Flash (cannot remember which) and the plugin seemed ridiculously slow.

It’s too early to say whether Ubuntu Intrepid is a step forward, but I have to admit that for an alpha version is surprisingly robust. There are four days to go till the next alpha version is released. Let’s see what that version will bring.

Tags: ,


Feb 16 2008

Installing Ruby gems in NetBeans 6.0

Category: NetBeans,Ruby,computersadmin @ 11:44 pm

One of the great features of the new NetBeans 6.0 is the possibility of developing Ruby code with it. Unfortunately if you run Linux you will find out that you cannot directly use the RubyGems you have installed with your distribution unless you set some very generous file permissions or run NetBeans as root. None of these solutions is appealing. A much better solution is to install your own version of RubyGems. The NetBeans wiki explains how this can be achieved, but unfortunately it does not work in my case (I am currently running Ubuntu 7.10). I suspect that this is due to some changes in the way RubyGems have to be installed. The rest of this post explains the steps I took in order to install RubyGems on my computer and use them in NetBeans 6.0.

  1. Find out which version of RubyGems is installed on your computer and download the same version from RubyForge (Given that NetBeans will be the one who will manage the Gems I suspect that this is not so important. However, it is likely that it will save lots of headache if you do not always want to run your Ruby programs from NetBeans). In my case I have rubygems version 0.9.4-1ubuntu1, and therefore I downloaded the 0.9.4 version
  2. unpack the rubygem-0.9.4.tgz with
    tar -xzvf rubygem-0.9.4.tgz
  3. create the directory where you will store your rubygems:
    mkdir ~/.localrubygems
  4. create the directory where the lib files are stored.
    mkdir ~/.localrubygems/lib

    This step is not compulsory, but unless you set this option a lib directory is created in your home directory (which I did not like)

  5. change to the directory with the rubygem source
    cd rubygem-0.9.4
  6. install rubygems:
    GEM_HOME=/home/dinel/.localrubygems/ \
    ruby setup.rb all --installdirs=home \
    --prefix=/home/dinel/.localrubygems/ \
    --libdir=/home/dinel/.localrubygems/lib/

    the –installdirs=home indicates that the installation is done in the user’s directory and the –prefix and –libdir indicated where the files which go in the lib dir are stored

  7. that’s it. The installation is complete now.

In order to use NetBeans with Ruby you need to set the GEM_HOME and GEM_PATH environment variable and start NetBeans:

	export GEM_HOME=/home/dinel/.localrubygems/
	export GEM_PATH=$GEM_PATH:/home/dinel/.localrubygems/
	netbeans

If everything went fine you should be able to go to Tools/RubyGems and see:

Ruby gems window

Select the New Gems tab, click Reload Gems button and you will see all the Gems available for installation:

The ruby gems window

Now is time to try some real Ruby programming to find out whether this solution poses some problems.

Tags: , , , ,