Wednesday 29 July 2009

The T400 mute button issue when upgrading Ubuntu 9.04 64 bit

I just upgraded ubuntu to accept all the new libraries. It upgrades the kernel to 2.6.28-14 but on doing so, it rewrites "/boot/grub/menu.1st" so effectively overwrites the mute button fix. No worries. Just edit menu.1st again and put the acpi_osi="Linux" option back on the kernel lines!

Tuesday 28 July 2009

How about this for "business computing"?

I was working at a customer site earlier today whose Windows desktops were recently infected with a virus. They are using Microsoft Windows on the desktop and had a corporate strength virus protection program installed. Apparently the virus was out before there was a patch and the patch had to be downloaded separately from the normal "update" process. This they did but when the normal "update" process was initiated, the patch was not in the update. This then overwrote the protection from the patch and the infection started again!

It occurred to me that companies should really be thinking strategically about replacing the desktop OS with something that is not so easily infected by viruses. How is it that in the 21st Century we are still having to handicap our PC's with virus protection software. Something is VERY WRONG.

Really, think about all the desktop PC's that have to run virus protection software. How much of the CPU and disk activity is taken up with "protection"? I don't know the answer for sure but all I do know is that my Lenovo T400 running ubuntu 9.04 64 bit laptop seems far zippier than when I boot it into Windows Vista Business Edition.

Yes I know that you could write a virus for UNiX/Linux too but my guess is that it may be far more difficult - since I am no hacker I can't really comment further on this...

So, why not leave the virus prone operating systems to "home use" and get a more robust desktop operating system for the corporate workplace?

But - what about all the applications?? Good point. But if the developers were to create applications in Java then they could run perfectly happily on a linux desktop and we could get the real power of the applications out for those business users.

Discuss....

CAD for ubuntu 9.04 64 bit!

Well, I wanted a CAD package for my ubuntu installation - but which one. I looked around on google to see if there was anything out there and it seemed that QCad was popular for ubuntu but many posts were indicating that there was only a 32 bit version available and it had issues running on 64 bit ubuntu. But of course I then remembered seeing QCad in the list of applications listed in "Add/Remove Programs". Strange since I was running the 64 bit version! So I tried it and - well - works "out of the box"!
Now I just have to work out how it works! :D

Thursday 23 July 2009

Getting the mute key to work with Ubuntu 9.04 64 bit and a T400

Found a great site here that has some great information about ubuntu and the Thinkpad T400. A great little tip found there is how to get the mute button working on the T400 so that it shows up correctly in gnome. I tried this on my Ubuntu 9.04 64 bit install and it worked perfectly.

The process is to simply add acpi_osi="Linux" to the end of the grub boot string!

You can do this with:
$ sudo vi /boot/grub/menu.lst
Then find the line towards the bottom that launches the correct option. It will start with:
kernel /boot/
Just put the string
acpi_osi="Linux"
onto the end of this line.
Save and restart
Nice!

Wednesday 22 July 2009

Ubuntu 9.04 64 - getting compiz fusion manager

During my reinstallation of Ubuntu 9.04 64 bit jaunty, I installed the drivers for my on board ATI Radeon HD 3270 first. For some reason, my compiz fusion manager was not installed. Question then is how to get the manager installed without installing anything else.
Of course, the answer is pretty simple because that is what the synaptic Package Manager is there for! Simply start the Synaptic Package manager and search for "compiz". It lists up the "compizfusion-setttingsmanager" package. Just click on this and it installs. Other options I installed at the same time were: libemeraldengine0 and emerald. These are other decoration engines for compiz-fusion.

Wednesday 15 July 2009

Ubuntu 9.04 64 bit - disable annoying beep at shutdown

A really annoying beep issues forth from my PC when I shut down ubuntu. I thought I may be able to change the sound used for shutdown but to no avail. Then I discovered this site:
http://ubuntuguide.net/disable-the-annoying-beep-when-you-shutdown
It gives a great little tutorial on how to disable the annoying beep:
Basically:
$ sudo gedit /etc/modprobe.d/blacklist.conf
And add the line:
blacklist pcspkr
Not sure how or why this works but it does! My guess is that modprobe.d is somehow used during shutdown.

Tuesday 14 July 2009

Ubuntu 9.04 64 bit with Skype

I thought this might be a problem since the Skype web site only supports 32 bit versions and also only up to 8.04. However, doing a search around the ubuntu forums shows that skype can actually be installed directly via Medibuntu!

Steps are:
1) Install medibuntu
2) Get "getlibs"
3) Now simply enter the following two commands:
sudo getlibs -p bluez-alsa
sudo apt-get install skype

It will then magically appear under "Applications>Internet"

I had to change my skype settings in order for the microphone to work
I needed to change it to "HDA Intel (hw:Intel,0)" for the mic to work and I had to change "Sound Out" and "Ringing" to "pulse".

Ubuntu 9.04 64 bit with screensaver

My trusty T400 works very nicely with the ATI Radeon fglrx drivers for the built in HD 3470 chips but seems not to work too well with multiple screens.

Various issues take place but it is probably safe to say that stability only really comes back if you switch the System>Preferences>Appearance (Visual Effects tab) settings to "None" BEFORE you start messing around with the screens.

Saturday 11 July 2009

Watchtower Library 2009 on Ubuntu 9.04 64 bit

Fantastic research program but not fully compatible with the shipped ubuntu version of wine (1.0.1). After some looking around, I found this excellent guide to installing Watchtower Library 2009 correctly. This uses 1.1.25 (a beta version) but with this comes working scripture popups. The guide can be found at:

http://mattrudge.wordpress.com/2009/07/03/watchtower-library-2008-on-linux

Basically the instructions are:
1) Get Scott Richies GPG key from http://wine.budgetdedicated.com/apt/ScottRitchie.gpg
2) System>Administration>Software Sources - Third Party Software, Add
deb http://wine.budgetdedicated.com/apt jaunty main #WineHQ-Ubuntu 9.04 "Jaunty Jackalope"
3) Click Add Source, Authentication tab
4) Import the key you saved ealier
5) Close and reload package information when prompted
6) Open terminal and
$ sudo apt-get install wine
7) check version with:
wine -version
should be 1.1.25
8) Now install Watchtower Library with "setup.exe", copy to hard disk
Voila!

Ubuntu 9.04 64 bit and ATI Radeon drivers on T400

The ATI Radeon HD 3470 (Discreet) graphics card embedded with the Lenovo T400 seems to have generated all sorts of issues with ubuntu 9.04 64 bit. I have seen many posts that seem to conclude that your best bet with ubuntu is to choose "Integrated" from the BIOS of the machine and stick with that.
I decided to turn on convention and attempt to install the currnent 9.6 verson of ATI's Catalyst control center for the HD 3470.
After much time on google, I found the definitive "unofficial" guide to this process at:

http://wiki.cchtml.com/index.php/Ubuntu_Jaunty_Installation_Guide

In summary:
1) Get some libraries
$ sudo apt-get install ia32-libs
2)Get the drivers from:
http://support.amd.com/us/gpudownload/linux/Pages/radeon_linux.aspx?type=2.4.1&product=2.4.1.3.5〈=English
Downlaoded file is :
ati.driver-installer-9-6-x86_64.run
3) create .deb packages
sh ati.driver-installer-9-6-x86_64.run --buildpkg Ubuntu/jaunty
This takes some time so be patient!
It generates several deb files:
fglrx-amdcccle_8.620-0ubuntu1_amd64.deb
fglrx-installer_8.620-0ubuntu1_amd64.changes
fglrx-kernel-source_8.620-0ubuntu1_amd64.deb
fglrx-modaliases_8.620-0ubuntu1_amd64.deb
libamdxvba1_8.620-0ubuntu1_amd64.deb
xorg-driver-fglrx_8.620-0ubuntu1_amd64.deb
xorg-driver-fglrx-dev_8.620-0ubuntu1_amd64.deb
4) Install dkms package required to install these debs
$ sudo apt-get install dkms
5) Now, install all the debs we need necessary
$ sudo dpkg -i --force-overwrite xorg-driver-fglrx_*.deb fglrx-kernel-source_*.deb fglrx-amdcccld_*.deb
6) Now edit X server conf file:
$ sudo gedit /etc/X11/xorg.conf
7) Add the foolowing line to the Device section
Section "Device
[...]
Identifier "SOME IDENTIFIER"
[...]
Driver "fglrx"
[...]
EndSection
Save file and exit
8) Now run command:
$ sudo aticonfig --initial -f
9) Reboot
10) Login again and, in a terminal enter:
$ fglrxinfo
You should get back:
display: :0.0 screen: 0
OpenGL vendor string: ATI Technologies Inc.
OpenGL renderer string: ATI Mobility Radeon HD 3400 Series
OpenGL version string: 2.1.8673
A lot of work but it means that you can use the power of your T400 graphics card to the full...

If you install fusion-icon with:
$ sudo apt-get install fusion-icon
and add it to System>Preferences>Startup applications as:
fusion-icon -n
The you can switch compiz off and on from an icon on the top panel

Wednesday 8 July 2009

Ubuntu 9.04 64 bit - sound turns to static

A very peculiar thing here. My perfectly working ubuntu 9.04 64 bit T400 laptop lost its sound - well not exactly "lost" but certainly it was not working. It used to work perfectly but now just generates what appears to be static!!!

I had not used sound for a while and done quite a few things to my laptop so it was not clear what could be the culprit. I had thought maybe the sound card had blown or some other disaster but it turns out that the fix was incredibly simple.

I just opened the speaker volume control from the icon at the top of the gnome screen and chose "Volume Control". For some reason my "PCM" sliders were at the bottom. I just moved the slider to the top and sound is back to normal again.

Phew!

Getting portal started with DB2 Express and ubuntu 9.04 64 bit

See my previous postings as to how I got Portal 6.1.0.1 and DB2 Express 9.7 installed on my ubuntu 9.04 64 bit laptop.
At this point, DB2 can start by "su db2inst1" and I can start Portal on the default "derby" database as "root" only.
I want to ensure that portal starts as the user "db2ins1". To achive that I had to :

$ su root
# cd /opt/IBM
# chown -R db2inst1 WebSphere
# exit

This set of commands ensures that all of the WebSphere stuff is owned by the db2inst1 user. Now, this user can start DB2 Express AND then start Portal. A couple of short shell scripts can do this for me:

startPortal.sh script
db2start
/opt/IBM/WebSphere/wp_profile/bin/startServer.sh WebSphere_Portal

stopPortal.sh script
/opt/IBM/WebSphere/wp_profile/bin/stopServer.sh WebSphere_Portal -user db2inst1 -password {password of db2inst1}
db2stop

Much better but before we use these scripts we have to do a database "transfer" so that Portal knows to use DB2. This is well documented in the Portal infocenter so just follow intructions there. However, make sure that you use the "instance owner" id for the "database administrator" fields in the Portal property files. My mistake was using the DB2 "admin" user created during the db2 install. However this is NOT the user expected by Portal. The instance owner is the one you should use.

Installing DB2 onto ubuntu 9.04 64 bit

I am not a DB2 expert but needed a "real" database for my test IBM Portal 6.1.0.1 installation on my laptop. This is how I got it working.

I chose to install DB2 Express 9.7 onto my laptop. It is just for testing and demo purposes but using DB2 Express over the standard "derby" database makes the Portal respond very much faster.

Firstly, the install wizard had a few issues displaying screens correctly. So to ensure you get the correct screens, set you ubuntu screen "System > Preferences > Appearances", "Visual Effects" Tab to "None". If you don't do this you will not see the installation messages correctly.

1) Ensure you have the linux 64 bit version of DB2 Express 9.7 from IBM and the necessary license file. The 64 bit linux version will be a tar file:

DB2_Exp_Ed_97_Linux_x86-64.tar.gz

yoiu may need libaio so get this with:
$ sudo apt-get install libaio1
2) Extract the tar file to a temp folder for db2. It will create a folder "exp"

$ cd ~/tmp/db2
$ su root
# cd exp
# ./db2setup (graphical)
or
# ./db2_install (console)

If you choose the graphical option then the graphical installation startup screens are shown (it pauses for a while whilst the wizard screens are being prepared). Navigate on the left hand side to "Install a Product" then choose the "Install New" button.

A new graphical wizard will start
1) Accept license agreement (you still need a license key later anyhow) and click "Next>"
2) Choose installation type - I choose "Typical 900-1090 MB". click "Next>"
3) At "Select installation, repsonse file creation, or both" screen, I chose "Install DB2 Express on this computer and save my settings in a response file". I left the response file name standard of: "/root/db2exp.rsp". Click "Next>"
4) At the "Select the installatin directory" screen, leave the default of "/opt/ibm/db2/V9.7" and click "Next>"
5) At the "Set up a DB2 instance" choose "Create a DB2 instance" and click "Next >"
6) At the next screen accept defaults to create the administration user. Enter password and "Confirm password" and click "Next>"
7) At the "Set user information for the DB2 instance owner" leave default to create the owner "db2inst1". Enter "Password" and "Confirm password" screens and click "Next>"
8) At the "Set user information for the fenced user" accept defaults to create a new fenced user (db2fenc1). Enter "Password" and "Confirm password" screens and click "Next >"
9) The next screen is a summary of your responses. Click "Finish" to start the installation.

When you have finished you can start the DB2 instance by logging on as the db2inst1 user as a new login session and then use the db2start command:
$ su - db2inst1
$ db2start
$ exit
To stop the instance
$ su - db2inst1
$ db2stop
$ exit
By the way, ff you forget any of your responses you can simply open the /root/db2exp.rsp file and take a look at what you typed (passwords are not held in clear text in this file!)

Ripping DVD's using ubuntu 9.04 64 bit

I have to spend quite a lot of time travelling on the train so I use my laptop (ubuntu 9.04 64 bit) to watch my purchased DVD's.
So instead of lugging DVD's around, I wondered if I could rip my DVD's to hard drive and watch them without having to have the DVD player spinning.
A quick google shows that "handbrake" is a popular DVD ripper for this type of process. Question is whether it would ever work on ubuntu 9.04 64.
The answer is "Yes -very easily". This is what I did to get it working
Simply download the 64 bit version of handbrake from:

http://handbrake.fr/?article=download

It downloads as a "deb" file so just double click it to install. It will appear under "Applications > Sound and Vision"

If you start the app, then choose a ripping format on the right pane, open the DVD using the button at the top and then start.

I used "Basic>Normal" encoding and checked the box "Support iPod 5G". For this type of file it is a two pass encoding and the file created is an mp4 placed in my "home/Videos" folder. It takes a while (about three times as fast as watching it). Double clicking on the created file launches the standard ubuntu "Movie Player" - but on my system, it does not have the necessary decoders. Amazingly, it knows where to find these (assuming it is connected to the internet). It complained about not having
MPEG-4 AAC decoder
H.264 decoder
Then proceeded to go find them in the following packages:
gstreamer0.10-ffmpeg
gstreamer0.10-plugins-bad
I let them install and hey presto, I can watch the ripped movie on my laptop.

Of course this should only be done with DVD's you actually own but it is great for those boxed sets where you get seven seasons as a set of 50 or so DVDS. A 40 min episode rips to a file about 300GB

Tuesday 7 July 2009

Installing Portal 6.1.0.1 onto ubuntu 9.04 64 bit

The installation of IBM Portal 6.1.0.1 onto ubuntu 9.04 (64 bit) was unbelievely easy. However, there are some pre-requisites to a smooth installation:
1) you MUST change the symbolic link of the shell by logging on as root
$ su root
# cd /bin
# rm ./sh
# ln -s bash sh
2) You must have a Sun Java environment - you can install this from Applications>Add/Remove and search for "sun" or:
3) I would recommend also installing the Sun Java plug in for the browser
$ sudo apt-get install sun-java6-plugin
4) Make sure you can ping and .. For example if your host name is "portal" and your domain is "infosys.co.uk" then you must be able to:
$ ping portal
and
$ ping portal.infosys.co.uk
5) Next ensure you have the needed libraries with:
$ sudo apt-get install libstdc++5 ia32-libs
6) Now do a "standard" installation and you will have portal up and running on the bundled debry database.
As a final step, I would recommend ensuring that the entire "WebSphere" folder structure has its ownership changed to a user that will eventually run the portal. You can defer this step until after the database is installed and transferred.
Now portal starts with
$ su root
# cd /opt/IBM/WebSphere/wp_profile/bin
# ./startServer.sh WebSphere_Portal
Get to the front screen by directing your browser to:
http://localhost:10040/wps/portal
Starts like a dream!

Thursday 2 July 2009

Ubuntu and a .bundle file

Installing a ubuntu packages is pretty simple:

$ sudo apt-get install .deb

However, if you get a *.bundle then a slightly different process is needed.
Firstly, download the file with the bundle extension.
Next:

$ chmod +x

Now you can simply run it with:

$ ./

Simple when you know how :D

BUT
Even simpler is to run the bundle from a new shell with:
sh
That's all you need.

Wednesday 1 July 2009

Getting ubuntu to print to a PDF

A great way of saving web pages is to print them to a PDF file. With windows I used the CutePDF utility for ubuntu you need cups-pdf. The installation is practically an automatic process but without a second step it WILL FAIL.
I got this working with:
sudo apt-get install cups-pdf
mkdir ~/PDF
The first step downloads the correct application and installs it automatically into the printers. However without the second step printing will fail.
Cute PDF asked for the pdf file name everytime it was used. cups-pdf simply creates the file for you in the PDF folder and the name is automatically assigned. This means that if you print the same web page then the second print will overwrite the first one - without warning. So - you have been warned :)