Search Ubuntu life...

Custom Search

Sunday, August 14, 2011

Installation of the latest eclipse Java EE IDE in (K)Ubuntu 11.04 x64

  • Java JRE (ubuntu packages sun-java6-jre or openjdk-6-jre).
  • Current Ubuntu repositories package (eclipse 3.5 (galileo)), which will be purged after installation/configuration of the latest eclipse. If it is not present install it using the command:
    sudo apt-get install eclipse

  • To (temporally) install the latest version (placed for example in ~/Downloads) at /usr/lib/eclipse_indigo/eclipse, open a terminal and give the commands:
    cd /usr/lib
    sudo mkdir eclipse_indigo
    cd eclipse_indigo
    sudo tar zxvf ~/Downloads/eclipse-jee-indigo-linux-gtk-x86_64.tar.gz
  • Keep the current (executable) script:
    sudo cp /usr/bin/eclipse /usr/bin/eclipse.curr
  • Purge ubuntu eclipse:
    sudo apt-get purge eclipse
    sudo apt-get autoremove
  • Move (as root) the latest eclipse from /usr/lib/eclipse_indigo/eclipse to /usr/lib:
    sudo rm -r /usr/lib/eclipse
    sudo mv /usr/lib/eclipse_indigo/eclipse /usr/lib
    sudo rmdir /usr/lib/eclipse_indigo
  • Move back (as root) the executable /usr/bin/eclipse:
    sudo mv /usr/bin/eclipse.curr /usr/bin/eclipse
  • Open as root the file /usr/bin/eclipse and change all occurrences of galileo to indigo.
  • Copy /usr/lib/eclipse/eclipse.ini to /etc
    sudo rm /etc/eclipse.ini
    sudo cp /usr/lib/eclipse/eclipse.ini /etc
  • As root create the file /usr/share/applications/eclipse.desktop to make a new (kde) menu entry:
    [Desktop Entry]
    GenericName[en_US]=Eclipse 3.7 (Indigo)
    GenericName=Eclipse 3.7 (Indigo)
    If this entry is placed in "Lost & Found" menu category, move it to "Development", using the KDE Menu Editor.

Relevant Links

Installation of latest Liferay IDE (using eclipse-postgreSQL+postgis) in (K)ubuntu 11.04 x64


  • Java JRE (ubuntu packages sun-java6-jre or openjdk-6-jre).
  • Latest eclipse (click here for installation instructions)
  • PostgreSQL 9 (click here for installation instructions).



Assuming that
  • liferay portal and plugins sdk will be installed in home directory and
  • downloded files are placed in ~/Downloads
open a terminal and give the commands:
unzip Downloads/
mkdir liferay-plugins-sdk-6.0.6
cd liferay-plugins-sdk-6.0.6
unzip ../Downloads/


For eclipse/Liferay to be able to correctly locate PostgreSql/postgis jdbcs:
cp ~/liferay-portal-6.0.6/tomcat-6.0.29/lib/ext/postgresql.jar ~/liferay-portal-6.0.6/tomcat-6.0.29/lib/ext/postgresql.jar.1
cp ~/Downloads/postgresql-9.0-801.jdbc4.jar ~/liferay-portal-6.0.6/tomcat-6.0.29/lib/ext/postgresql.jar
sudo cp /opt/PostgreSQL/9.0/PostGIS/java/jdbc/postgis* ~/liferay-portal-6.0.6/tomcat-6.0.29/lib/ext

Next Steps

To set PostgreSQL as the default database of Liferay:
  • Extract the file create-minimal-postgresql.sql from the downloaded,
  • create database lportal using the command
  • psql -f create-minimal-postgresql.sql -U <user_name>
  • and follow the instructions of this link to configure Liferay.

Friday, August 12, 2011

Installation of the latest (postgis enabled) PostgreSQL in (K)Ubuntu 11.04 x64

Latest version of  PostgreSQL Graphical Installer (for the time being is postgresql-9.0.4-1-linux-x64.bin)

  • To install  PostgreSQL at /opt directory, call the Graphical Installer:
  • sudo chmod 0755  postgresql-9.0.4-1-linux-x64.bin
    sudo ./postgresql-9.0.4-1-linux-x64.bin
  • Optionally, install  postgis-1.5, using the Application Stack Builder before closing Graphical Installer. Otherwise, you may install it later, by calling the Application Stack Builder entry in your (kde/gnome) menu (after resolving the corresponding problems (see below)).

Edit ~/.profile and append the line

source /opt/PostgreSQL/9.0/
at the end, to update $PATH and set other env variables (you have to logout/login, for this change to take effect).

  • Execution of
  • /opt/PostgreSQL/9.0/stackbuilder/bin/stackbuilder
    executable failed, with a number of messages for missing libraries. The following links to (installed) libraries had to be set:
    sudo ln -sf  /usr/lib/x86_64-linux-gnu/ /usr/lib/x86_64-linux-gnu/
    sudo ln -sf /lib/x86_64-linux-gnu/ /lib/x86_64-linux-gnu/
    Depending on your current installation, other links to libraries (or the libraries themselves) may be missing as well. You have to locate those libraries (and if they miss, to install them) and make the corresponding links.
  • To be able to run stackbuilder from the (kde) menu entry, edit (as root) the file
  • /usr/share/applications/pg-stackbuilder-9_0.desktop
    and change the line
    Exec=kdesudo /opt/PostgreSQL/9.0/scripts/
  • To correct the (postgis related) problem of "$libdir/ not found", execute the command:
  • sudo ln -sf /opt/PostgreSQL/9.0/lib/ /opt/PostgreSQL/9.0/lib/postgresql/

Thursday, April 1, 2010

Keyboard layout configuration for Lubuntu 10.04 Beta1

For a (permanent) usa/greek keyboard configuration, using alt+shift for language switching:
  • sudo vi /usr/lib/X11/xorg.conf.d/05-evdev.conf
  • and modify
Section "InputClass"
Identifier "evdev keyboard catchall"
MatchIsKeyboard "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
Section "InputClass"
Identifier "evdev keyboard catchall"
MatchIsKeyboard "on"
MatchDevicePath "/dev/input/event*"
Driver "evdev"
Option "XkbLayout" "us,gr"
Option "XKbOptions" "grp:alt_shift_toggle"
Change gr above to your language symbols, to get the proper keyboard layout.

Wednesday, March 24, 2010

Kubuntu 9.10 upgrade to 10.04 Beta1

A minute ago, (almost) automatic upgrade of kubuntu 9.10 to 10.04 finished in my Dell XPS M1330. The only problem appeared after restarting laptop, because of the line:

none /dev/bus/usb usbfs devgid=125,devmode=664 0 0

in /etc/fstab.

Kubuntu complained that usbfs format is unknown and I had to boot from an ubuntu CD in recovery mode, to put this line in comments.

KDE4 is by far the most amazing 3D-based desktop and ubuntu becomes better and better every 6 months :)

Tuesday, September 22, 2009

How to expand a WinXP virtual disk in Virtual Box

(Thanx to user "gushy" in this thread) do the following:
  • Create a new disk using Virtual Disk Manager (in VirtualBox goto File -> Virtual Disk Manager)
  • download System Rescue CD
  • set your current VM to have the new disk image as it's second hard disk and the System Rescue CD iso file as it's CD
  • boot the vm from the CD
  • at the command prompt type startx
  • when X Windows starts, type gparted in the terminal that is open on screen
  • in gparted select the windows partition and choose copy
  • select the second hard disk
  • right click on the representation of the disk and click paste
  • gparted will prompt you for the size of the disk, drag the slider to the max size
  • click apply
  • wait .......
  • when it's done right click on the disk and choose Manage Flags, and select Boot
  • exit gparted and power off the VM
  • change the VM settings to only have one disk (the new bigger disk) and deselect the iso as the CD.
  • boot the VM into your windows install on it's new bigger disk!