Can Java Developers make Ubuntu – Linux their primary work OS? – Part 1

For quite some time I have been planning to make Linux my primary work environment. So I setup a Ubuntu – WinXP dual boot machine and have since been gradually trying to make Ubuntu my primary OS. The idea is that by the time people start moving to Windows Vista, I will be on Ubuntu.

Ubuntu is a user friendly flavor of Linux that enjoys great community support through its forums at UbuntuForums.org . Installing Ubuntu is straightforward if you are installing on a new machine. However for a dual boot Windows + Ubuntu installation, you would encounter some steps during installation that are very good at scaring you and making you wonder if you are losing all your Windows data.

Several popular software like Firefox, OpenOffice and Gimp work fine on Ubuntu. OpenOffice and Gimp actually perform better on Ubuntu than on Windows.

However the list of software that won’t install is also quite long.

  1. Yahoo Messenger πŸ™
  2. Google Talk πŸ™
  3. Google Earth πŸ™
  4. Skype 😐 A basic version is available
  5. Sea Monkey πŸ™
  6. Opera 😐 Installation through software channel doesn’t work. .bin file works
  7. WYSIWYG HTML Editors support πŸ™
  8. No Internet Explorer 😐 All web development has to be tested on IE, irrespective of whether you like it or not.
  9. Sound and Video players 😐 Few options
  10. FTP client – GFTP which is the most popular is not that good. Filezilla 3 is supposed to work on Linux (currently in beta)

You can use Wine, which is a Windows implementation for Unix. Wine will simulate Windows and a Windows directory structure, tricking the Windows application installer into thinking that it was being installed on a Windows machine. But making applications work by simulating Windows on Linux is no fun, especially if the primary reason you are using Linux is to move away from Windows.

Apart from issues with availability of software, I had some trouble with file sharing between Ubuntu and Windows machines on the same network. Also you can read files from Windows partitions on your machine using Ubuntu, but the driver to write back to the Windows drive is still in beta.

Ubuntu is based on Debian, and to install software on Ubuntu you don’t just download and run installer files. It is recommended that you look for the software in the Ubuntu repositories and install it from the repository. Coming from the Windows world, it takes time to get used to this approach. Also at times you need to add a new repository before you can add a software in that repository. Once you have a basic office machine setup, you would now want to make it a developer machine and get it setup for Java development.

Page 1 OF 2

Java Development

By default the GCJ Java Virtual Machine is installed with Ubuntu. However for any commercial Java development, you would want to install Sun Java. The Ubuntu repositories take time be updated, so Java 6 isn’t yet available for installation through the repositories. However you can install Sun Java 5. Just find Java 5 in the repositories and install. Ubuntu will handle the download, installation and dependencies.

Note that even after you install Java 5, the JAVA_HOME environment variable doesn’t get set. To set that value you need to execute the following two commands: sudo cp /etc/bash.bashrc /etc/bash.bashrc_backup sudo gedit /etc/bash.bashrc Next append the System-wide Environment Variables at the end of file:
JAVA_HOME=/usr/lib/jvm/java-1.5.0-sun-1.5.0.08

Now your JAVA_HOME value is set, but GCJ will still continue to be the default Java installation. To change it to Sun Java, you would have to execute the following command.
sudo update-java-alternatives -s java-1.5.0-sun

Now your Java environment is setup and you can run java and javac using Sun Java on Ubuntu.

Java IDE / Tools

As regards IDE availability. Eclipse was the only IDE I could find in the repositories. The basic Eclipse platform does get installed fine. However I couldn’t install any additional plugins / upgrades. I am not the only one, and similar Eclipse problems on Ubuntu have been logged earlier.

Even after you make Sun Java your default Java installation, Eclipse continues to run using GCJ. To change this, you need to start Eclipse and navigate to Preferences > Java > Installed JRE and add the Sun JRE to the list. In my case GCJ was at /usr/lib/jvm/java-1.4.2-gcj-4.1-1.4.2.0 while Sun JRE was at /usr/lib/jvm/java-1.5.0-sun-1.5.0.08. Select the Sun JRE as default.

However that didn’t fix the upgrades problem for me. I continued to get errors while trying to install plugins for Eclipse.

So that’s where things stand today. I can run Java commands and do some basic stuff, but Ubuntu is certainly not my primary Java development OS. I haven’t ventured into installing application servers and stuff on Ubuntu, but I am not exactly looking forward to the same. I have already come across posts mentioning issues with some app server installations.

I could find a couple of posts talking of NetBeans and JDeveloper usage on Ubuntu. However neither the NetBeans site nor the JDeveloper site have any specific instructions for Ubuntu.

Conclusion

Overall it looks like Ubuntu – Linux is still a long way from being popular amongst Java developers. It does have a lot of good things going for it, but having to put in some extra effort for getting every little Java thing to work as expected, is quite irritating.

For any computer user whose usage is limited to using the web, an office suite, playing music and maybe the occasional game, Ubuntu is ready. You can dump Windows and switch today. But if you are a software developer, especially a Java software developer and are used to development on Windows, migration to Ubuntu is going to be difficult and might not be worth the effort.

I haven’t yet given up on Ubuntu as my primary work OS and I hope to write more about my experiences with setting up other bread and butter Java developer software.

If you know of any Ubuntu – Java success stories, please do write about them in the comments section below.

Harshad Oak

Content Team

The IndicThreads Content Team posts news about the latest and greatest in software development as well as content from IndicThreads' conferences and events. Track us social media @IndicThreads. Stay tuned!

18 thoughts on “Can Java Developers make Ubuntu – Linux their primary work OS? – Part 1

  • September 10, 2010 at 1:45 pm
    Permalink

    Linux is a powerful OS, it offers more control and better performance and stability than windows, but this comes with a price, complexity!
    Also it’s because most linux users are advanced users and this is why its makers normally don’t put much effort in making easier (and more appealing to normal users).
    but Linux is still the defacto OS for real life production servers, whether PHP or Java, so it’s actually recomended to learn it and use it for testing and deployment.
    As for development, I’m still trying this out now myself, but I know people who develop using IBM products successfuly on Ubuntu, it’s not a miracle, but learning curve seems to be steep πŸ™
    but the gain should be worth it, linux is faster and this helps when you are working on big projects.

  • January 26, 2009 at 10:21 pm
    Permalink

    Ha, ha, ha. What are you saying? I came to this article when i was only searching some more tools for java on Linux(other debugging software). I have been using Linux for all my java related projects and all successfully. I find your problem is Linux not Java on Linux. Come on it’s just an operating system and java is platform independent. More over if you work on Microsoft windows for more than 90% of you time then you will try to search Windows even on what you eat. If you are a seasonal and trying to find Windows on Linux never think of switching to Linux, but if you really want to work on Java on Linux then Java works best on Linux than Microsoft Windows unless you work any thing other than JNI (i mean dll for windows, not .so). Besides that i started my Java on Linux from JMF and now after doing several projects on Linux, i have reached a point where i have to spend weeks to setup same configuration on Windows. I have worked previously(Java related works) on Fedora 7, Fedora 8 and now switched to Ubuntu Hardy(current), even installed on Ibex and have been using it for what ever java can do. I have installed successfully many stuffs as Arved Sandstrom and jboss, glassfish, mysql etc. If you are on to a serious java development then i would recommend using Ubuntu over windows. I don’t know about MacBook. In ubuntu you have added benefit of other different things also, once you get used to it. Just work seriously on Ubuntu for at least 3 weeks then you will certainly agree me, if you find other things more useful than a sleek GUI or looks

  • December 26, 2008 at 2:59 pm
    Permalink

    This is almost two years after you wrote. I can’t speak for Ubuntu back then – it’s not the Linux distro I used then. But certainly on others using Eclipse/NetBeans and several J2EE servers was no problem.

    I currently have Eclipse Ganymede, NetBeans 6.5, Apache 2.2, Tomcat 6, Subversion 1.5, PostgreSQL 8.3, Oracle XE, oc4j standalone, Oracle AS with the SOA suite, SQL Developer, JDeveloper etc all running on Ubuntu 8.10. It’s not my main work computer – a MacBook Pro is – but I can do essentially everything on Ubuntu that I need to. In fact, I’d have a very queasy feeling running everything on Windows XP or Vista that I do on Linux or Mac OS X.

  • September 30, 2008 at 1:35 am
    Permalink

    Though i am responding to this after a year its been written. The answer to the above question is Yes

    I have been working on UBUNTU for the last 6 months and have found no problems for using this as a java developer box

    Applications i use

    IDE : Eclipse Ganymede – works beautifully, has good memory handling abilities
    Application Server : Jboss
    Database : Mysql

    In regards to messaging i use pigdin which comes bundled with ubuntu and can be configured for gmail, yahoo, aim , any xmpp compliant messaging.

    I have ubuntu installed as my primary os and run any other os from vm. I use innotek virtual box and run vista , primarily to work with MSPROJECT.

    This is one software because of which i use windows. The day wine /crossover can port MSProject, i will uninstall windows.

    For configuring ubuntu to use java 1.5 instead of gcj follow the link
    http://ubuntu-tutorials.com/2006/11/21/how-to-install-suns-java-development-kit-jdk-v50-ubuntu-6061-610/

    thanks
    vinod

  • March 2, 2007 at 5:55 am
    Permalink

    Re your comment about requiring drivers. I have seen that elsewhere – but my standard Kubuntu installation just does it. You do need to specify user permissions – otherwise it defaults to read only. Something like this in your /etc/fstab file should do the trick alongside winbind and samba client:// /home// smbfs credentials=/home//.smbpasswd,uid= 0 0

    Replace the stuff in as appropriate and create a file .smbpasswd in your home directory of this form:

    username= your windows username
    password= your windows password

    Reboot and I find filesharing with our Windows 2k server more reliable than from my wireless XPP PC!

    As a web designer my only blocker on dumping Windows XPP/Vista atm is the loss of HoTMetaL Pro. Can not get it to install under Wine. I agree NVU is too immature and undeveloped to be of industrial use. Currently checking out Quanta Plus …

  • February 28, 2007 at 4:58 am
    Permalink

    How about Modem/internet configuration for this?.I find this very difficult to this on Linux-OS.

    Best Wishes
    Dharam(VS)

  • January 30, 2007 at 10:01 am
    Permalink

    What I use on my Ubuntu install.

    >> 1. Yahoo Messenger πŸ™
    I use gaim on Windows as well as Linux. gaim.sf.net
    There is also a yahoo messenger clone for Linux that does voice and webcam.

    >> 2. Google Talk πŸ™
    http://www.google.com/support/talk/bin/answer.py?answer=24073

    >> 3. Google Earth πŸ™
    Works fine on my Ubuntu install.

    >> 8. No Internet Explorer 😐 All web development has to be tested on IE, >> irrespective of whether you like it or not.
    http://www.tatanka.com.br/ies4linux/page/Main_Page

    >> 9. Sound and Video players 😐 Few options
    I can play just about any media that exists.
    http://getautomatix.com/

  • January 25, 2007 at 11:36 pm
    Permalink

    Thanks for all the feedback and glad to know about Java development on Ubuntu-Linux experiences.

    A few points –

    * Skype Linux is low on features compared to the Windows version
    * If Linux is not meant for geeks only, WYSIWYG editors are required. Nvu and Bluefish do a decent job but cannot be compared with Dreamweaver or similar editors available on Windows.
    * Using VMWare is a possibility had missed my consideration
    * I have termed software that are not available as .deb files or directly through the repositories as not available for Ubuntu. There are ways to install using .bin .rpm or .tar files but I don’t think somebody just starting with Linux would want to get further confused by these formats.
    * There sure are FTP SSH clients for Linux. I just found them to be nowhere as good as the Windows one.
    * I think all Linux distros should get every release reviewed and approved by a group of ‘only Windows users’. Once these people start understanding a bit of Linux, they should be replaced. πŸ™‚

    Here are some links that might help someone starting off with Ubuntu
    * [URL=http://www.beginningubuntu.com/software_1.html]Beginning Ubuntu – Software Installation[/URL]
    * [URL=http://www.linux.com/article.pl?sid=06/07/08/1451246]Updating and Installing Software[/URL]

  • January 25, 2007 at 1:07 pm
    Permalink

    1. Skype runs fine under linux. No problems whatsoever in both SuSE and Ubuntu.
    2. SeaMonkey also runs fine. Don’t know where you got your info that there was any issues there.
    3. Wysiwyg HTML editors: a. Why would you even want such a thing? b. How about Bluefish, Nvu, Quanta???
    4. No Internet Explorer. If you must, run VMWare to get to Windows; at least, you can limit the damage. Otherwise, I’d rather consider this a feature than an issue….
    5. FTP Client: How about ftp itself??? or Nautilus (Gnome’s File Browser). Frankly, if you’re still using FTP to upload sites, you’re doing yourself a disservice. You should really be using SCP, which at least uses an encrypted pipe.

    Appreciate the instructions on Java for Newbies, but you should refrain about saying something works or doesn’t until you’ve seriously investigate the matter and talked to a few knowledgeable people.

  • January 25, 2007 at 12:58 pm
    Permalink

    The only real ‘issue’ with running Eclipse on Linux (Ubuntu included) is that of file permissions. If you must, just install Eclipse in your Home directory as a regular user, and you won’t have any problems installing plugins. If you want a more centralized installation, unzip to /opt/, but then make sure to run Eclipse as root (gksu) when you need to install plugins.

    I’ve been running Eclipse on Linux (and Ubuntu) for about two years, without any issues.

  • January 25, 2007 at 9:08 am
    Permalink

    And I am sure ubuntu can also be for you.

    Personnaly I prefer to install packages that come from the provider (SUN, Jetbrains, jakarta) instead of the one in URPMI repositories.

    And everything works very well.

    by the way, google earth final version is very easy to install (plf repository) and works very well.

    IE6 can also be installed through the project ies4linux. (use wine but the whole installation is very well packaged)

    Hope it helps, but I can only encourage you to continue your journey.

  • January 25, 2007 at 7:04 am
    Permalink

    My former company has been using Ubuntu for Java development (Eclipse / JBoss / Apache) for some time quite happily on several workstations. There’s a learning curve, of course, but once set up it’s more stable and vastly less prone to ‘bit rot’ than Windows. You also get the benefit of much nicer tools for text manipulation and system monitoring than Windows gives you.

  • January 24, 2007 at 10:25 pm
    Permalink

    we’ve use redhat 4 at work for about 2 years now and it works fine. Opera, google earth, gftp, and eclipse all work with no problems. For yahoo messenger – try installing a jabber client such as psi, then create an account on a public jabber server that supports the yahoo messenger transport service. For WYSIWYG html, try VNU or Bluefish. For Java 6 just download the linux install file from java.sun.com and run it.

    You’re not going to move from windows to linux without pain, the trick is to stick it out and work through the problems.

  • January 24, 2007 at 11:01 am
    Permalink

    ‘In addition to hardware certification, Sun’s Project Glassfish will now find its way into Ubuntu as well. GlassFish is Sun’s Java Enterprise Edition 5 application server. GlassFish is not currently in Ubuntu Edgy nor is it in Ubuntu’s main software repositories.’

    ‘Official NetBeans support for Ubuntu is something that Sun is working on very aggressively.’

    Ref: InternetNews[URL=http://www.internetnews.com/bus-news/article.php/3642481]InternetNews[/URL]

  • January 24, 2007 at 3:31 am
    Permalink

    It’s easier to get started with Java Development on Red Hat Linux

  • January 24, 2007 at 3:26 am
    Permalink

    You need Real Player or any other software capable of running Real Video files.

Leave a Reply