Comments
Richard Davies wrote: The UK has a good crop of technology pioneers in cloud computing - for example ElasticHosts, FlexiScale, Flexiant, OnApp - and also some strong government initiatives such as G-Cloud. We will have to see whether this kind of technical leadership converts into swift mass-market adoption or not.
Cloud Expo on Google News

SYS-CON.TV
Cloud Expo & Virtualization 2009 East
PLATINUM SPONSORS:
IBM
Smarter Business Solutions Through Dynamic Infrastructure
IBM
Smarter Insights: How the CIO Becomes a Hero Again
Microsoft
Windows Azure
GOLD SPONSORS:
Appsense
Why VDI?
CA
Maximizing the Business Value of Virtualization in Enterprise and Cloud Computing Environments
ExactTarget
Messaging in the Cloud - Email, SMS and Voice
Freedom OSS
Stairway to the Cloud
Sun
Sun's Incubation Platform: Helping Startups Serve the Enterprise
POWER PANELS:
Cloud Computing & Enterprise IT: Cost & Operational Benefits
How and Why is a Flexible IT Infrastructure the Key To the Future?
Click For 2008 West
Event Webcasts
Java for Linux
Java for Linux

Two technologies that have gained widespread interest and support in the past few years are Java and Linux. Until recently, however, the two were separate, although they share similar visions of open, ubiquitous computing. As interest in both Java and Linux solutions increases, developers are naturally looking to combine the two, and want to write applications in Java that run on Linux systems. But they need stable, fast and fully functional JVMs, especially for server solutions that require servlets and support for Java Server Pages.

Several independent efforts to port JVMs to Linux are in progress, including those by IBM, Sun Microsystems, the Blackdown Java-Linux Porting Team headed by Steve Byrne and the Kaffe group headed by Tim Wilkinson. The IBM and Blackdown ports are based on code licensed from Sun, while Kaffe is a "cleanroom" implementation. Ports based on Sun code are complicated - and frequently delayed - by licensing issues. While IBM has an industry license for Java technologies, the Blackdown group had to make special licensing arrangements to obtain the Java 2 JVM source code. Sun's Community Source Code License may eventually make it easier to resolve these licensing issues, although the prevailing opinion within the Linux community seems to favor the GNU Public License.

Current JVMs for Linux
Sun currently supports reference implementations of JDK 1.1 and JDK 1.2 (now called Java 2 SDK) for Solaris and for Windows 95 and NT. Also available are highly optimized production versions for Solaris and Windows. At the JavaOne Developer's Conference this past June, Sun announced a restructuring of the Java APIs and specifications into the Java 2 Micro Edition for handheld and embedded applications, the Java 2 Standard Edition for workstation applications and the Java 2 Enterprise Edition for server applications.

The Micro Edition, for example, excludes some libraries - such as the AWT classes - that aren't needed for embedded systems and handheld devices. The Enterprise Edition targets server application development and supports Enterprise JavaBeans classes. The Java for Linux efforts now in progress target the Standard Edition, which includes the Java Foundation Classes.

Available Linux JVM ports are all based on the "Classic" JVM reference code and don't include any of Sun's HotSpot or other performance-enhancement code.

IBM's port is an early-access release of the 1.1.8 JVM, and includes a JIT compiler and support for native threads. Linux users who have worked with this JVM report good performance and stability. IBM is reportedly working on a Java 2 port, but they correctly observe that there is still much demand for 1.1 applications and that 1.2 isn't widely used yet.

The Kaffe JVM, included with some Linux distributions, is a cleanroom implementation of the 1.1 JVM specification. But the most recent release, 1.0b4, doesn't include RMI support and is missing several crucial security features such as bytecode verification and observance of "private" modifiers. Tim Wilkinson, who leads the Kaffe effort, says several improvements are in progress, including a significantly faster JIT compiler and support for the Java 2 Collections API.

The Blackdown ports of the 1.1 and 1.2 JDKs are probably the best-known implementations for Linux. Led by Steve Byrne, a former Sun employee, the team has been working on a fully JCK-compliant 1.2 JVM for nearly a year. The current "prerelease" is fairly complete and stable, and includes a JIT compiler.

Sun has provided some engineering support to the Blackdown group for JDK ports, and has even worked with several Linux distributors such as RedHat to help port Linux itself to UltraSPARC systems.

Linux developers would like to see Sun provide a supported reference implementation of the Java 2 SDK, but Sun has made no announcements about its plans for supporting Java on Linux.

Java Programming on Linux Systems
You can download Java Developer Kits for Linux from IBM (www.ibm.com/java) and Blackdown (www.blackdown.org). Installation consists of uncompressing the downloaded file and extracting the component files and directories. Linux includes utilities for uncompressing ZIP files and other compression formats. The Blackdown distribution file jdk1.2pre-v2.tar.bz2 is compressed with the bzip2 program. To extract and install the files, use these two commands:

bzip2 -d jdk1.2pre-v2.tar.bz2
tar xvf jdk1.2pre-v2.tar

After you install the files in a directory, you need to set your PATH environment variable so your command shell can find the javac compiler, the java runtime program and other Java utility programs. Also, if you plan to use third-party Java libraries, you must set your CLASSPATH environment variable to include the directory location of those libraries. For example, I set my Java environment variables for my command shell, ksh, like this:

export PATH=/usr/local/java/bin:$PATH
export CLASSPATH=/home/hfoxwell/MyJava

Test your installation by entering "java - version" from your command line. The JVM should start up and report "java version 1.2" or something similar. If you're testing more than one JDK, be sure to set your PATH and CLASSPATH explicitly for each version that you plan to use (see Figure 1).

Linux JVMs typically require a "glibc" C library in order to run. Check the Release Notes for your JVM to determine which version of this library is required. Most current Linux distributions ship with one or more versions of "glibc". The Blackdown 1.2 JDK requires "glibc2", also called "libc6", and is found at "/lib/libc.so.6".

All of the current Linux JVM offerings are unsupported beta or early-access releases. As such, they are incomplete, buggy and not fully optimized for performance. The Blackdown 1.2 JVM doesn't have a working native threads module yet, and the IBM port is missing some IO exceptions. Moreover, important extension APIs, such as Java 3D, Advanced Imaging, and Sound, aren't yet ported to Linux. Sun has provided source code for these to IBM, Blackdown and other licensees, but it may be a while before you see these APIs on Linux.

Java Development Tools for Linux
At JavaOne several vendors announced plans to provide developer tools for Linux, including IBM, Inprise and MetroWerks. Blackdown's Web site includes an extensive "Java Tools for Linux" link that lists IDEs and other programs for Java developers. If you're familiar with "Emacs", have a look at "emacs-JDE" at www.sunsite.auc.dk/jde/. If you'd like a full-featured, drag-and-drop IDE, try NetBeans from www.netbeans.com/ (see Figure 2). NetBeans is written in Java and runs nicely on Linux using the Blackdown 1.2 JVM. It supports development in Java 1.1 or 1.2, and is distributed in a free personal-use version as well as a commercial, enterprise development version.

Conclusion
Open source advocates have raised the awareness of Linux as a stable, richly featured operating system. They're also attracted to Java's platform-independent programming model and to the new solutions it enables, such as Jini, Enterprise JavaBeans and JSPs.

As Linux JVMs from Sun, Blackdown, IBM and others become more stable, complete and competitive, Linux developers will be able to contribute their considerable expertise to the widespread deployment of Java technologies.

URL Resources

  1. GNU Public License: www.fsf.org/copyleft/gpl.html
  2. IBM's Java for Linux: www.alphaworks.ibm.com/tech/linuxjvm
  3. Blackdown Java-Linux Porting Team: www.blackdown.org/
  4. Netbeans Java IDE: www.netbeans.com/
  5. Kaffe: www.kaffe.org/
  6. Metrowerks CodeWarrior for Linux: www.metrowerks.com/desktop/linux/
  7. Sun's Linux information site: www.sun.com/linux
About Dr Harry Foxwell
Dr Harry Foxwell is Chief Technologist, Sun Microsystems Federal, Inc.

In order to post a comment you need to be registered and logged in.

Register | Sign-in

Reader Feedback: Page 1 of 1

Latest Cloud Developer Stories
Swisscom, the Swiss telecom, is going into the cloud business. Its subsidiary Swisscom IT Services AG has signed up with Red Hat as a Certified Cloud Provider and launched a public cloud Infrastructure-as-a-Service (IaaS) cloud targeting enterprise-class customers primarily in ...
Apache Deltacloud, the Red Hat-contributed ReSTful API that abstracts differences between clouds so services on any cloud can be managed – provided of course there’s a driver – has graduated from the Apache Foundation’s incubator and is now a full-fledged Top-Level Project (TLP)....
In a surprise move on Tuesday, January 10, Oracle wheeled out its Big Data Appliance. That’s the one it said in October would be ready sometime in the first half. Only nobody believed it meant early in the first half. Heck, it’s not even clear anybody thought Oracle could make ...
Rackspace Hosting, the service leader in cloud computing, on Thursday announced its acquisition of SharePoint911, an industry leader in SharePoint consulting, training, and "JumpStart" services within SharePoint. The unification of both companies provides capabilities to deliver ...
CloudLinux, Inc., on Thursday released CafeFS 3, a virtualized file system for shared hosters that cages each customer within its own virtualized file system. CageFS becomes part of CloudLinux OS at no additional charge. CloudLinux OS, the only commercially-supported Linux OS m...
Subscribe to the World's Most Powerful Newsletters
Subscribe to Our Rss Feeds & Get Your SYS-CON News Live!
Click to Add our RSS Feeds to the Service of Your Choice:
Google Reader or Homepage Add to My Yahoo! Subscribe with Bloglines Subscribe in NewsGator Online
myFeedster Add to My AOL Subscribe in Rojo Add 'Hugg' to Newsburst from CNET News.com Kinja Digest View Additional SYS-CON Feeds
Publish Your Article! Please send it to editorial(at)sys-con.com!

Advertise on this site! Contact advertising(at)sys-con.com! 201 802-3021

SYS-CON Featured Whitepapers
ADS BY GOOGLE

Breaking Cloud Computing News

BEACHWOOD, Ohio, Feb. 16, 2012 /PRNewswire/ -- DDR Corp. (NYSE: DDR) today announced operating re...