Linux on the Sun JavaStation NC HOWTO

Robert S. Dubinski

2001-Oct-31

This is a HOWTO document describing how to enable the GNU/Linux OS on the Sun JavaStation NC.


Table of Contents
1. META Information
1.1. The Purpose of this Document
1.2. Acknowledgments
1.2.1. Document Contributors
1.3. History
1.4. Document Copyright and Licenses
1.5. Location of the Latest Version and Source
1.6. Reporting Bugs Found In or Additions to the HOWTO
1.7. TODO List for this HOWTO
2. What is a JavaStation?
2.1. What is a JavaStation NC?
2.2. Definition of an NC including the Differentiation from PC's
2.3. Description of the JavaStation Model Line including Hardware Specs
2.3.1. JavaStation-1 [ "Mr. Coffee"] ["the brick"] [Sun Option No. JJ-xx]
2.3.2. JavaStation-NC [" JavaStation-10"] [" Krups"] ["the tower"] ["the percolator"] [ Sun Option No. JK-xx]
2.3.3. JavaStation-E ["Espresso"] [Sun Option No. JE-xx]
2.3.4. JavaEngine-1 ["JE-1"]
2.3.5. The "Dover" JavaStation model
2.3.6. The Generation 3 "Super JavaStation"
2.3.7. The Pre-Mr. Coffee JavaStation Prototype
2.3.8. The Pre-Mr. Coffee JavaStation/Fox
2.4. Reasons for Running Linux and NC Myths Dispelled
2.5. Why JavaStations are No Longer Produced
2.6. Where to Purchase a JavaStation
3. Background Requirements for Linux on a JavaStation
3.1. Complete Hardware Requirements
3.2. Network Service Requirements
3.3. Understand the JavaStation Boot Sequence
3.4. Additional Software Requirements: Replacement Firmware (PROLL)
3.5. Decide on your Filesystem-type: NFS-Root, or Embedded?
3.5.1. "NFS-Root" Filesystem
3.5.2. "Embedded-Root" Filesystem
3.6. Support Sites to Check Out: Zaitcev's Linux Site
4. Build Your Kernel
4.1. Before you begin
4.2. Make sure you use 32-bit mode
4.3. Supported Linux Kernel Versions
4.4. Required Kernel Configuration Options
4.5. Necessary Patch for "Embedded-Root" FS Configurations
4.6. Build the JavaStation-Ready Kernel
4.7. Convert Kernel from ELF to a.out format
4.8. JavaStation-Ready Kernel Images, System.map and .config File Samples
4.8.1. 2.3.99pre3_embedded_RSD
4.8.2. 2.3.99pre3_nfsroot_RSD
4.8.3. 2.4.2_embedded_RSD
4.8.4. 2.4.2_nfsroot_RSD
4.8.5. Outside kernel mirrors
5. Build A JavaStation-Ready FileSystem
5.1. Preparing Yourself to Build Your Own Filesystem
5.2. Contents of the "/etc/fstab" File
5.2.1. "NFS-Root" Filesystem fstab
5.2.2. "Embedded-Root" Filesystem fstab
5.3. The "Embedded-Root" Image Creation Procedure
5.4. Sample FileSystems
5.4.1. jsroot_varol_19991221
5.5. Sample X Servers
5.5.1. XF86_FBDev_3.3.3.1_19990104
5.6. Outside Sample Filesystems
6. "Out of the Box" JavaStation Boot File Solutions
6.1. Simple Solution #1
7. Set up Your Server
7.1. Preface
7.2. Setting up the RARP service
7.3. Setting up the DHCP service
7.4. Set up NFS service ("NFS-Root Options" Only)
7.5. Setting up for Boot with TFTP
8. Booting Your JavaStation
8.1. What to See When Booting Linux
8.1.1. Stage 1: White Screen
8.1.2. Stage 2: Coffee Cup Logo
8.1.3. Stage 3: A Window to PROLL
8.1.4. Stage 4: Kernel Boot
9. Questions and Troubleshooting
9.1. When booting, the message "The file just loaded does not appear to be executable." Why?
9.2. When booting, the message "no a.out magic" appears and halts the boot. Why?
9.3. I tried booting a Krups but JavaOS comes up. I don't even have JavaOS!
9.4. Cannot Boot an "Embedded-Root" image > 10 MB on my JavaStation. Why?
9.5. After Booting, Typing Anything Yields Garbage Characters. Why?
9.6. In X Sessions to a Solaris server, the font server "xfs" crashes. Why?
9.7. Performing Indirect XDMCP to a Solaris Server Results in Session Login Failures. Why?
9.8. TFTPd config doesn't work on SUSE 6.3. Why?
9.9. Regarding RARP: Is it Needed or Not?
9.10. Can One Use the Smart Card Reader on the Espresso models?
9.11. Can One Use the Solaris DHCP server instead of ISC?
9.12. Can One Pass Arguments to "/sbin/init" in a Diskless Boot like This?
9.13. Enabling X on the JavaStation
9.14. Is There Mailing List Help?
9.15. Can One Boot a JavaStation from Onboard Flash Memory?
9.16. Does "Piggyback" work for the x86 too?
9.17. I put new memory in, but now it doesn't boot. Why?
9.18. Now that JavaStations work with Linux, what about other Free OSs?
9.19. Do the Linux 2.4 kernels work? What's the latest that works?
9.20. Can I compile the kernel on a non-SPARC machine?
9.21. Can I get an ok> prompt like other Sun equipment?
9.22. My keyboard isn't recognized. What can I do?
9.23. Proll reports "TFTP: ARP Timeout". Why?
9.24. Why Can't I Get TrueColor on Krups?
9.25. I followed this HOWTO, but my Dover doesn't work. Why?
9.26. Can framebuffer be loaded following a serial console initialization?
9.27. I really need a complete out-of-the-box solution, pronto!
9.28. You Didn't Answer My Question.
10. Reference Docs
10.1. Mr. Coffee Jumper Info
10.2. Krups Jumper Info
10.3. JavaStation Press Release
10.4. JavaOS 1.0 Download
10.5. Espresso IDE circuit
10.6. JavaStation Boot Monitoring Key Combinations
10.7. JavaStation Photo Gallery
A. GNU Free Documentation License
0. Preamble
1. Applicability and Definitions
2. Verbatim Copying
3. Copying in Quantity
4. Modifications
5. Combining Documents
6. Collections of Documents
7. Aggregation with Independent Works
8. Translation
9. Termination
10. Future Revisions of this License
How to use this License for your documents

1. META Information

This section lists the meta-information of this document. The hows, whys, location and changes to the structure of the document are documented here. The main content begins in the next chapter.


1.1. The Purpose of this Document

This document is to serve as a comprehensive HOWTO and FAQ collection regarding the Sun JavaStation NC and enabling the GNU/Linux OS on it.

The intended audience of this document is anyone who has an interest in enabling Linux on the Sun JavaStations. The document structure is laid out to serve as either a top-to-bottom read for a newcomer, or as quick reference on a single topic for advanced users. Pointers to sample files submitted by users are included for extremely hurried readers.

The author of this document is Robert Dubinski . Robert is the former computer technician and UNIX systems administrator for Marquette University's Math, Statistics and Computer Science Department, where he had 125 JavaStations running Linux. These machines were all configured using the information, techniques and files presented in this document.

In early 1999, Eric Brower wrote the first informal HOWTO for the JavaStation. Parts of this document are inspired by his work, and all unique information presented there have since been merged into this document. Eric's original mini-HOWTO is saved for posterity at: http://dubinski-family.org/~jshowto/Files/texts/eric_brower_js_howto_19980218.txt

This HOWTO also aims to serve as a member document of the Linux Documentation Project. The LDP can be reached at: http://www.linuxdoc.org


1.2. Acknowledgments

Enabling Linux on the JavaStations , and allowing this HOWTO to come to be would never have been possible without the fine work of the following people:

  • Pete Zaitcev (Primary JavaStation kernel mod author)

  • Eric Brower (XFree mods and author of the original embedded-build HOWTO)

  • Varol Kaptan (made available his Krups images and patches. Backported kernel support to 2.2.x series)

  • David Miller (the original Linux/SPARC kernel porter)

  • The Linux/SPARC kernel porters and mailing list

  • The thousands of contributors to the Linux kernel

The HOWTO author wishes to give a second thank-you to Pete and Eric for their work:

 

Pete got me going with Linux on the JavaStation in December 1998, has been the main kernel programmer adding in support for the JavaStation line, and despite his busy work schedule was nice enough to find time to answer all my email queries for help over the last 15 months.

Eric worked on bringing X support to the JavaStation when it had none. He had been working on a dedicated server for the JavaStation in early 1999, and kept me informed of his progress. In mid-1999, he switched tactics and sent a working framebuffer example to test out. He also wrote the first comprehensive mini-HOWTO for the JavaStations, answered my email questions, and got me interested in the embedded solution which I employ here at Marquette.

Thank-you Pete and Eric!

 
--Robert Dubinski, March 2000 

1.2.1. Document Contributors

The following people have contributed to this specific document:

If you contributed a tidbit of info and are not listed, please email the document author to get yourself listed. Everyone deserves recognition helping this document evolve.


1.3. History

Revision History
Revision 1.3031 Oct 2001
Many major changes: restructured for better layout, new chapters added, updated files and file pointers, new master distribution location, source broken into parts, new sample files, md5sums on all sample files, overall update and proofread of materials. Thank-you very much to Simon Kuhn for donating an old Sun4 to enable more sample files be made. Thank-you also to Nate Carlson for donating sample kernels (unfortunately that info was lost during a disk crash...Nate, please contact me.). If anyone contributed items between May 31 and Oct 31 and it does not show up in this revision, please resubmit it.
Revision 1.2530 Oct 2001
This is called the "@#!$?" release. It is called such because there were some small-mid size changes to the document which were lost in a disk failure, prior to me re-uploading to the LDP site. To give you an idea of how bad the situation was, the last version I had on backup was in Docbook SGML, while I had switched to Docbook XML many months prior. Simply put, any contributed changes or email contacts I had with contributors were lost, and are hopefully on their way back in with this release. If you contributed something, and it disappeared, please contact me immediately, and it'll get back in. --RSD
Revision 1.2231 May 2001
Changed file links, some sample file formats, and clarified info relating to the sample files, following requests on the sparclinux mailing list.
Revision 1.2008 May 2001
Information Refresh up to the current date, and change to GNU Free Documentation License 1.1
Revision 1.1501 May 2001
Migrate source to DocBook XML 4.12
Revision 1.1302 Feb 2001
Minimal Bugfixes
Revision 1.1229 Dec 2000
Additional info on the "Fox" model
Revision 1.1123 Nov 2000
Krups truecolor blurb, removed one acknowlegement per email request
Revision 1.115 Nov 2000
Numerous updates and additions revisions
Revision 1.0516 Jun 2000
Requested Format Changes and Fixes
Revision 1.0413 Jun 2000
Suggested Fixes and Added Requests
Revision 1.0304 May 2000
Minor Fixes, Requests
Revision 1.0228 Apr 2000
Small fixes.
Revision 1.0125 Apr 2000
"Brown Paper Bag" Revision.
Revision 1.024 Apr 2000
First submission to the LDP.
Revision 0.918 Apr 2000
Continued reorganization and final merges.
Revision 0.715 Apr 2000
Migration from LinuxDoc DTD to Docbook DTD.
Revision 0.7114 Apr 2000
Received word doc was forwarded inside Sun.
Revision 0.714 Apr 2000
Linked on Metabyte Website.
Revision 0.69 Apr 2000
First semi-public release.
Revision 0.424 Mar 2000
First move to comprehensive HOWTO.
Revision 0.215 Oct 1999
More notes collected and merged.
Revision 0.124 Jun 1999
Initial scraps put together.


1.4. Document Copyright and Licenses

Copyright (c) 1999-2001 Robert S. Dubinski. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with the Invariant Sections being: "Why JavaStations are No Longer Produced", with one Front-Cover Text: "Linux on JavaStation HOWTO", and with one Back-Cover Text: "This document was written by Robert S. Dubinski in the hope that more people can put their JavaStation hardware to good use. Thank-you to the Linux kernel hackers who made this happen, and thank-you to Sun for a rock-solid piece of hardware." A copy of the license is included in the section entitled "GNU Free Documentation License".

The document author makes no warranties that all the information presented here is completely accurate, and cannot be held liable to any loss you experience as a result of the information you use from here.

Best efforts have been made to ensure everything included is accurate as of the publication date listed at the beginning of this document, but there is always a possibility something may be wrong. In this case, doublecheck with alternative sources first before considering implementing anything at a production-level. If you find something wrong, drop the author a line at or send a patch to the document source, and corrections will be made immediately.

This document is an official member document of the Linux Documentation Project.


1.5. Location of the Latest Version and Source

The latest online version of this document can be found at: http://dubinski-family.org/~jshowto .

The pre-processed XML source to this document, written to the Docbook DTD, version 4.1.2, is available from: http://dubinski-family.org/~jshowto/doc/src/

The pre-processed XML source to the GNU Free Documentation License, written to the Docbook DTD, and which this document is licensed under, is available from: http://dubinski-family.org/~jshowto/doc/src/gfdl.xml

Copies of this document are also available from the Linux Documentation Project at: http://www.linuxdoc.org/HOWTO/JavaStation-HOWTO.

This project used to be available at the URL 'http://javastation-howto.homeip.net'. In Spring 2001, homeip.net discontinued their free service and moved to a fee based scheme. Given the hundreds of mirrors of LDP documents, I do not find the fees justifiable. I have changed all references in this document back to my home server. Between my server's address, http://dubinski-family.org/~jshowto, the LDP website, and its hundreds of mirrors, you should be able to always find the JavaStation-HOWTO. If this is not the case, email me immediately at either or .


1.6. Reporting Bugs Found In or Additions to the HOWTO

Any problems or concerns about the HOWTO should be reported via email to the author, Robert Dubinski, at . Do NOT send document bug reports to the SparcLinux mailing list, the debian-sparc mailing list, or the Linux Documentation Project. The folks on there really do not care about my typos or server misconfigurations, so please don't trouble them.


1.7. TODO List for this HOWTO

  1. As NetBSD now supports JavaStations as well, it would be good to talk about support and sample files for it too.


2. What is a JavaStation?

This chapter explains to the reader what the JavaStation line is, its components, NC concepts, how to get one, and why one would choose the Linux OS for it.


2.1. What is a JavaStation NC?

The JavaStation NC is a model line of network computers built and sold by Sun Microsystems between November 1996 and March 2000. The JavaStation line was Sun's low-cost terminal option during that timeframe. It was the marketed successor to the Xterminal 1 and is succeeeded by the SunRay, although all three machines are fundamentally different.

The JavaStation hardware ran Sun's own JavaOS and either Sun's Hotjava web browser, Sun's HotJava Views task-manager software, or custom Java applications of the customer's choice.

The JavaStation was originally billed in November 1996 sneak previews as a low-cost desktop terminal, providing customers access to hot new Java applications, "legacy" X applications, and "legacy" MS Windows apps. During its lifetime, The JavaStation's marketed functionality was changed twice from "desktop terminal" to "single-app desktop device" to finally a "browser-based kiosk device".

At no time did Sun market the JavaStation as capable of running its flagship Solaris operating system the Linux OS, or any other OS than Sun's JavaOS.


2.2. Definition of an NC including the Differentiation from PC's

A network computer, or NC, was hailed as "the next big thing" in computing from late 1995 to early 1998. Conventional PC's, called "fat clients", were expected to be minimized in businesses by thin-client NC's.

Thin-clients get their OS, applications, and data files entirely through the network. They are different from dumb-terminals; they run full-scale graphical applications. Thin-clients are also different than graphical X-terminals. X-terminals typically run an X server and display the client programs of a remote server. Thin clients generally run full-scale graphical programs locally, such as a web browser, a Java application, or a "legacy-connectivity program", which enables the thin-client to display X apps or MS Windows apps which run on more powerful servers.

Advantages of NC's include:

  • "Zero-Administration". (Add a new NC and it will get everything it needs off the network, without an admin ever needing to visit it.)

  • Lower Total-Cost-of-Ownership (TCO) (No internal hard drives, floppy drives or CD players reduces form-factor, repair expenses, selling price and thus total-cost-of-ownership.)

  • Access to all web-based apps as well as "legacy" X and MS Windows apps.

  • Quick upgrades (just upgrade your server and the changes propogate throughout)

  • Longer lifespan (just upgrade the software, growing hard disk and memory requirements is not an issue)

  • Smaller OS footprint (when running brower-based apps)

Disadvantages of NC's:

  • No local access to data files (all your files stored on a remote server)

  • Requires fast, stable networks

  • NC's generally have a low maximum amount of memory. Though not as bad as with fat-clients, this does eventually become a liability for the thin-client.


2.3. Description of the JavaStation Model Line including Hardware Specs

Depending on who you talk to, the number of JavaStation models that were created is anywhere from one to six. The descriptions below will explain why.


2.3.1. JavaStation-1 [ "Mr. Coffee"] ["the brick"] [Sun Option No. JJ-xx]

This model is the most prevalent JavaStation model you are likely to find, although it wasn't the one and only JavaStation model Sun wished to sell to the public. The JavaStation-1 was the first generation JavaStation, released in November 1996 to pilot deployments as Sun's "proof of concept" of the Java NC design.

Hardware-wise, the JavaStation-1 is a Sun4M architecture machine. It is based on the SPARCStation-4 design, with some deletions and PC-like modifications. It is powered by a 110 Mhz MicroSPARC IIe CPU and has no SCSI, internal disks , floppy, CD or expansion slots. The Mr. Coffee motherboard is Sun Part No. 501-3141.

Instead of using the Sun-type keyboard and mice, JavaStation-1 uses PC-like PS2 parts instead. One of the original marketing highlights of the JavaStation was that it would use standard PC parts wherever possible to keep overall price down.

The "brick" has four PC-like SIMM slots. The SIMMs taken are industry-standard 60ns, 32-bit, 72-pin, 5V fast page SIMMs, installed in pairs. Each slot is capable of holding up to a 16MB SIMM, bringing the maximum total capacity of the unit to 64MB. The "xx" in the Sun Option# of the unit indicated how much memory the unit shipped with.

For video display, the JavaStation-1 utilizes the Sun TCX framebuffer, capable of 1024x768@70Hz in 8-bit color. The port connector however, is a standard VGA jack , enabling the user to use standard PC monitors if desired (again, low cost in mind). The on-board audio is a Crystal CS4231 chip , and the network interface is the Sun Lance 10Mbps interface. In addition, the "brick" also came with a 9-pin serial port and 1/8" audio out jack on its back.

The JavaStation-1 was fitted into the Sun "unidisk" form factor case, and has been seen in a number of color schemes. JavaStations have been fitted with casings in the white with light blue trim scheme used in Sun workstations, as well as the dark blue-grey "new desktop" scheme. Some say "JavaStation" and have the Java coffee cup logo written on it, others do not. Collectors may wish to collect all case variations.

The JavaStation-1 was used in early Sun demos, and sold to pilot sites. When first brought out, the cost to pilot sites was $699US. This was at a time when PC 's were still higher than $1000US. By the end of the pilot run, Sun was selling any remaining or used units for $299-$399US, in anticipation for its "real" JavaStation model.

See the JavaStation-1 at: http://dubinski-family.org/~jshowto/Files/photos/mr_coffee_front_view.jpg


2.3.2. JavaStation-NC [" JavaStation-10"] [" Krups"] ["the tower"] ["the percolator"] [ Sun Option No. JK-xx]

This model is the second most prevalent JavaStation model you are likely to find. When you talk to industry people about the "JavaStation", this is typically the model remembered first. Delayed numerous times, the Krups model officially went on sale to the general public Mar. 26, 1998 at the annual JavaOne conference.

Though generation two of the JavaStation line, the Krups model was the JavaStation . Sporting a completely different board design than JavaStation-1 , Krups establishes what was to be the characteristic JavaStation architecture.

Krups is powered by a 100Mhz MicroSPARC IIep chip, (note the 'p'). Its mainboard had the internal addition of a PCI bus, about a year before this standard bus made its well-publicized appearance on the Sun Ultra workstation line. The Krups motherboard is Sun Part no. 501-4267.

Krups keeps the PS2 keyboard and PS2 mouse ports from JavaStation-1 , keeping in mind the low-cost, interoperable goal of generation 1.

With the new board design, came new memory chip sockets. Instead of SIMMs, the "tower" moved to 168-pin DIMMs. DIMMs had begun to make their way from the workstation realm to PC's in the time between generations one and two of the JavaStation line, so it was fitting for Sun to switch to it in anticipation of their status low-cost commodity memory chips. The DIMMs accepted by the "tower" are 168pin, 3.3V unbuffered EDO DIMMs (not SDRAM). With two sockets capable of holding a 32MB DIMM each, the Krups has a maximum capacity of 64MB RAM. As with the JavaStation-1 , the number "xx" in the Sun option number refers to the amount of memory shipped with the unit.

For video display, the JavaStation-NC utilizes the PCI-based IGS C1682 framebuffer, capable of 1280x1024@80Hz in 24-bit "true color". This is a step up from the 8-bit display on JavaStation-1 . The port connector remained a standard VGA jack like JavaStation-1, enabling the user to use standard PC monitors if desired. The on-board audio remains a Crystal CS4231 chip like JavaStation-1. The network interface on Krups is the Sun HappyMeal 10/100 Mbps interface, another step up from the original offering of JavaStation-1.

The "tower" came with the 9-pin serial port and 1/8" audio out jack as JavaStation-1, but it also added a 1/8" audio-in jack, to do sound recording with.

Another addition in the JavaStation-NC is a flash memory SIMM. This allows one to load the current revision of the OS onboard, increasing boot-speed tremendously.

Perhaps the thing most memorable about the JavaStation-NC is its case design. The Krups comes in an aesthetically appealing casing. The mainboard is mounted vertically, and the shell entraps it, giving it the "tower " or "percolator" shape referred to. With the streamlined case, the power supply is moved outside to small transformer. The Krups unit gives off so little heat that there are no onboard cooling fans, making the Krups a dead-silent machine. Imagine the difference in noise when replacing a lab of traditional desktops with the Krups! This case design earned Krups a" 1998 Industrial Design Excellence Award" from the Industrial Designers Society of America. This award announcement is still available for read at: http://www.idsa.org/whatis/seewhat/idea98/winners/javastation.htm" . It is also archived locally via "fair use" for future readers at: http://dubinski-family.org/~jshowto/Files/texts/krups_idsa_award.txt"

The Krups had an initial base price of $599US, $100US cheaper than Mr. Coffee's rollout price. Due to it being the only model formally sold by Sun to the general public, this is how Krups is sometimes referred to as the only JavaStation, and not one model of a product line.

See the JavaStation-NC at: http://dubinski-family.org/~jshowto/Files/photos/krups_front_view.jpg


2.3.3. JavaStation-E ["Espresso"] [Sun Option No. JE-xx]

This model is extremely rare to find. It was never available for sale in quantities to either the general public or the initial JavaStation deployments, limiting the model's production quantity. To call this "Generation Three" of the JavaStation may be improper, as Espresso is nothing like the generation three JavaStation written about in early Sun marketing literature.

The Espresso was designed as an extension of the Krups. It was geared to sites that wanted a little bit more functionality and expansion capability from their JavaStations: a cross between an NC and a workstation.

Espresso is powered by the same 110Mhz MicroSPARC IIep chip as Krups . It's mainboard is similar to Krups, with the addition of PCI slots and an IDE channel for local hard disks. The IDE on Espresso was not enabled in the demo units. Those who have tried to make it work have concluded the wiring is incorrect, and it requires a hardware rework to get going.

Espresso continues with the PS2 keyboard and PS2 mouse ports from Mr. Coffee and Krups.

Espresso uses the same 168-pin, 3.3V unbuffered EDO DIMMs as Krups. The maximum amount of memory for Espresso is reported to be 96MB. As with the Mr. Coffee and Krups , the number "xx" in the Sun option number refers to the amount of memory shipped with the unit.

For video display, the Espresso uses the PCI-based IGS C2000 framebuffer, along with the same standard VGA port connector as Krups and Mr. Coffee. The on-board audio remains a Crystal CS4231 chip like Krups, and the network interface remains a Sun HappyMeal 10/100 Mbps interface like Krups as well.

Espresso came with the 9-pin serial port and 1/8" audio out and 1/8" audio in jacks of Krups, and a new addition of a parallel port, and a second 9-pin serial port. Espresso also comes with the flash memory to load your OS on and bypass the network boot cycle.

One new addition to the Espresso is a smart card slot.

The Espresso comes in a "pizza box" style case like the old Sun SparcStations, only a little taller, and not quite as wide.

The Espresso was never sold to the public. There was an internal testing period at Sun, but the units never went into mass-production.

One Espresso user mentioned he now uses his unit as both a server and router, with the addition of an IDE disk and 3C905 ethernet card, demonstrating the expandability of this unit.

See the JavaStation-E at: http://dubinski-family.org/~jshowto/Files/photos/espresso_front_view.jpg


2.3.4. JavaEngine-1 ["JE-1"]

Like the Espresso, this unit is also an extremely rare find.

This unit is supposed to be of similar board design to the Krups, but in an ATX form factor, with soldered onboard flash memory, and with a regular SVGA video chipset.

Gleb Raiko with the help of Vladimir Roganov did initial the Linux kernel support on "JE-1". Pete Zaitcev later obtained a "JE-1" unit and restored full support in Linux kernel 2.3.x+ .

As the author of this document has never seen a "JE-1", submissions from the public are welcome.

See the JavaEngine-1 at: http://dubinski-family.org/~jshowto/Files/photos/je1_overhead_view.jpg


2.3.5. The "Dover" JavaStation model

This is another box which does not exist officially outside of Sun. Little was known of it at the first revision of this HOWTO. Since then, proud owners have stepped forward. Basically, the Dover takes the Espresso theme and moves it to stock X86 parts.

Dover comes in a case similar to the Espresso, but there's nothing where the 'JavaStation-E' tag would be. Dover can be situated in a vertical position by removable feet. All that is printed on the case is "Sun MicroSystems 1998", and typically a serial number sticker of '12345678' and 'Made in Taiwan'.

The motherboard is 'baby ATX' in configuration, but not quite totally. Near the the front of the case is a fan that points at the CPU heat sink. The CPU heat sink has another fan on top of it. The motherboard has a Socket 7 CPU socket that houses a Cyrix MediaGCm-266GP CPU. There are typical PC motherboard jumpers with silk-screened legends for setting both clock speed and multiplier. The motherboard accepts a PC100 DIMM (max. size unknown) and a powersupply with AT-type power connectors. Included among them are two floppy and regular hard drive type plug. There are two small jumpers going to the motherboard, JPSB1 and JAUTO1, possibly for power management.

Expansion in Dover is via a two-card riser, with one PCI and one shared PCI/ISA slot. As mentioned earlier, the motherboard deviates slightly from standard ATX. Along the back edge under the cards are connectors for audio out, audio in, mic, HD15F video, two USB ports, D25F parallel printer, stacked PS/2 keyboard/mouse ports, and four 9-pin serial ports, marked A through D. Unlike other JavaStation models, there is no on-board ethernet. Instead, it typically is provided by a supplied 3COM 3C905B-TX Fast Etherlink XL PCI card (with a wake-on-LAN cable going to the motherboard). There is a standard Sun MAC address label on the back of the case.

Video is via a Cyrix CX5530 chip, but with the MediaGX chip, may be just an auxilliary chip. There exist both a FDD and HDD headers on the motherboard, but nowhere to mount a FDD in the case and no provision for an HDD bracket either. There is a simple piezo buzzer mounted to the motherboard and additionally a speaker with a cable leading back near the audio out jacks. Like the Espresso, there is a smart-card reader as well, and what looks like a compact-flash socket inside.

When booting it up, you get a blue JS screen. Under the exclamation point, are two memory card icons and a <...> icon. It reads:


Boot device: /ethernet   Arguments:
MAC Address: 08:00:20:95:5b:49
Open Boot 3.0, Built February 16, 1999 17:38:37
NIC: 10b7,9055 ethernet in PCI1                                           64MB SDRAM
Non-Volatile Device Memory Module Not Installed
SmartCard Reader Found
CPU Speed:  266 MHz


Can't open boot device

ok                         

The Dover model, since it is based on an x86 chip, is supported by Linux. This HOWTO however focuses on the SPARC-based JavaStations, so the procedures presented here will not work with it. However, there's plenty of x86 documentation at large to work from.

See the Dover at: http://dubinski-family.org/~jshowto/Files/photos/dover_inside.jpg


2.3.6. The Generation 3 "Super JavaStation"

Sun originally envisioned three generation models of the JavaStation: Mr. Coffee, the Krups, and the "Super JavaStation". Generation Three was billed in early literature as going to be the fastest JavaStation offered, with a high-speed CPU and a JavaChip co-processor to translate Java-bytecode in hardware.

All indications are that it never got beyond the mental stage, and was more of a marketing myth than anything else.

First, consider that the cost of higher performance CPU as a factor. If Sun packaged a high-performance CPU into a JavaStation, the low-cost advantage of an NC goes away.

Next, Sun did have their PicoJava chip available to decode Java bytecode, but rumor is the performance was not as good as expected, and the complete JavaChip project was shelved in the Summer of 1998, not long after Krups was formally released.

The "Dover" project was being worked on, but the "Corona " project, which would go on to become the Sun Ray , was the final nail in the JavaStation 's coffin.

So all indications are that this model is a piece of "vaporware". It is included here though, for the sake of completeness.


2.3.7. The Pre-Mr. Coffee JavaStation Prototype

After the original publishing of this HOWTO, word of one more "JavaStation" model surfaced. John Bodo, a reseller of JavaStation equipment, chimed in that he has a motherboard of a pre-JavaStation machine. It was made by Diba Corporation, which was later bought out by Sun. The unit was released as an early embededded Java platform that developers could use to build embedded Java machines. It has a Motorola 68030 CPU, 14.4k bps modem, ethernet interface, standard VGA interface and even a TV output. The prototype's date is circa 1996.

See the JavaStation Prototype at: http://dubinski-family.org/~jshowto/Files/photos/pre_js_1.jpg


2.3.8. The Pre-Mr. Coffee JavaStation/Fox

After receiving word of the JavaStation prototype from Diba, yet more information has come regarding another pre-Mr. Coffee model. This one though, has a greater known history we can share here.

This model was the JavaStation development box used by the developers of early JavaStation software. Basically it was a SS4/110 in a smaller, custom case similar to the Mr. Coffee enclosure, with more squarish profile.

The case has an off-white color with lateral stripe in Sun gray. It sits like a Mr. Coffee would on its side. The front was a 1/2 cyclinder i design in Sun gray, has the Sun Logo, the word "Sun" under that, and the Java cup logo at the bottom.

When booting up it claims to be a "JavaStation/Fox". The motherboard does not have a normal Sun part number. The CPU is a microSPARC-II running at 110MHz. The box has an onboard external SCSI connector, dual A and B serial ports, audio in and out sound ports (Crystal Semiconductor 4231, lance ethernet network interface, onboard PCMCIA (stp4020), one SBUS expansion slot, one AFXbus expansion slot, 2 72-pin SIMM slots (double-banked SIMMs only), and no on-board video. One would then add their own S-Bus frame buffer, or the 24-bit frame buffer from a ss5. Also, an optional internal SCSI laptop hard drive could be put in.

The motherboard's part number is 501-2785. The CPU is dated 1995 while the NCR chips are dated 1994, establishing the time frame of the Fox.

The NetBSD/SPARC FAQ has a few more words on the Fox at: http://www.netbsd.org/Ports/sparc/faq.html#fox

See the JavaStation/Fox at: http://dubinski-family.org/~jshowto/Files/photos/fox_face.jpg


2.4. Reasons for Running Linux and NC Myths Dispelled

It turns out that Linux makes the JavaStations perform more than adequately on the desktop. Thanks to the dedicated work of the Linux developer community, the JavaStations offer users the low-cost, zero-admin, versatile desktop NC's they were originally billed to be, but with the added freedom granted by the Linux OS.

While low-cost PC's now eclipse the JavaStation in terms of default CPU speed and RAM size, the JavaStations running Linux are still well-suited for a number of tasks:

  • Diskless X-Terminal. (Gives the JavaStations the capability of the Sun Xterminal 1 hardware that they replaced).

  • The NC solution, Linux-style: local X + a java-capable browser can make the JavaStations perform like they did with JavaOS/ HotJava, only many times faster.

  • A beowulf node, or a dedicated RC5/ SETI@HOME client. The JavaStation running Linux makes a stable, long-lasting number cruncher.

  • A small, standalone machine. While a task more suited on today's low-cost machines, there's not much that prevents the JavaStation from performing as a full-fleged standalone UNIX machine by itself. Just remember to set your expectations appropriately when doing so; they were "low-budget" clients when they were sold, and should not be directly compared to today's workstation offerings.

  • A small router and server, particularly with the Espresso model decked out with added IDE disks and NIC.

In all of the above scenarios, there is little to no maintenance of the machine once configured properly. Such is the advantage of the NC hardware.

JavaStations run so much better with Linux than JavaOS, one would think that even Sun should have offered it as an option. Unfortunately, Sun had killed the line in favor of the Sun Ray . While the performance of the Sun Ray is good, keep in mind it is not intended as a dedicated computing device, and due to its firmware is little more than a graphics display hanging off your Sun server, which can give you some unexpected bonus features (translation: "brand-name product lock"). The performance on the JavaStations with Linux will be similar to what you can get with a Sun Ray, but if ever you want to do something different with your machines, you have the flexibility to do so with the JavaStations. There was rumor of work to try and override the default behavior of the SunRay firmware, and make it into an adjustable computing device, but until that happens, running another OS on a SunRay is just a pipe-dream.

Lastly, if you're thinking of switching to diskless Xterminals on your network, you might consider the JavaStations over stripped down PC's. The hardware is standardized, smaller, and you do not need to worry about burning boot PROMs and the like.


2.5. Why JavaStations are No Longer Produced

Sun's official stance is that the JavaStation line was terminated in favor of the new Sun Ray line. A trip to the former JavaStation section of Sun's website at http://www.sun.com/javastation verifies this formal positioning. (fair use archival copy at: http://dubinski-family.org/~jshowto/Files/texts/sun_js_site_death.txt )

As the Sun Ray is not an NC in the traditional sense (it has a MicroSparc IIep CPU, but the firmware on the device prevents anyone from grasping it), there is no explanation why the two products could not co-exist.

In talking to the users of the JavaStations in the pre-Linux era, you will find strong opinions as to why the JavaStations are no more. The common thread in almost all opinions collected is that the software provided by Sun was inadequete for a production environment. Here are collected opinions from users of the Sun-provided software, included with their permission:

 

I only used the Java Stations last summer while teaching 51 and 55/154. GoJoe was incredibly slow and I seem to remember having to login to several different screens and browsers just to be able to start anything.

I had to apologize to my students for the slow and inconvenient machines --- I remember making some jokes about technological progress.

 
--Dr. Alex Ryba, Former Professor at Marquette University (Quoted March 2000)  

 

Well, of course the old JavaStations were practically unusable. It's not a matter of just my opinion; we used to have CU 310 full of students using the Xterms all the time. As soon as the JavaStations appeared there were NO STUDENTS in there at all. The JavaStations killed CU 310. Now that the JavaStations are (thanks to you) back up to speed, students are beginning to come back, but they've gotten out of the habit of working in our lab, and are used to working on their own in the dorms. I think this is a big loss -- they don't learn anything from talking to each other in the labs anymore.

Ghostview was slow, etc, but even vi was too slow. I am used to typing quickly, and when the cursor can't keep up with me, I can't handle it. I would also have worked at home if I didn't have to be here. And there were those annoying red squares left all over the Xterm window when you were in vi. I had to type ^L every few lines to get rid of them to see what I was typing... The pits. The whole setup made me lose a lot of respect for Sun (although I try to separate the different product lines as much as possible); I also think Sun will not get respect for hyping a product like the JavaStation so strongly, and then just dumping it. I would wonder why anyone would not just dump Sun...

BTW, the JavaStations, now that they are fast, are quite fine. I really like mine, and don't see why they aren't a viable product.

 
--Dr. Mark Barnard, Professor at Marquette University (Quoted March 2000)  

 

I believe that it was the triple combination of Sun's JavaOS, the Hotjava software, and GraphOn's GoJoe X-connectivity software which ultimately doomed the JavaStation line.

JavaOS was always sluggish in performance for us. It was rated as having one of the slowest Java VMs by a ZDNet Online Magazane review at http://www.zdnet.com/pcmag/features/javaguide/hfgr10.htm . I speculate this was the the main cause of delaying the JavaStation's formal public release to April 1998.

(fair use archive copy of the PC mag review at: http://dubinski-family.org/~jshowto/Files/texts/pcmag_js_jvm_review.txt )

JavaOS also always lagged behind the current Java developer spec (ie running Java 1.0 when Java 1.1 was prevalent, and Java 1.1 when Java 1.2 was issued). It was tough explaining to students why the books they were buying were all using the new event-model of Java 1.1, but they could not program to it and have it run on "the Java machine ". There were also some implementation problems with some of the AWT peers which sometimes made programming across platforms difficult.

These performance and implementation problems were never addressed in subsequent build of JavaOS for the duration we ran it. I believe the last edition we had used a Java 1.1.4 runtime, when we had a Java 1.2 development kit on the server.

The HotJava browser software suffered from not being able to handle web standards HTML4, cascading style-sheets, or the ECMA javascript. All of these standards were employed in commercial sites at the time, resulting in many sites that weren't viewable by the JavaStations. The Hotjava Browser engine also had serious printing problems with certain webpages, some of which appeared on Sun's own website!

The HotJava Views task selector software also was rough. Users could have multiple apps running, but only one displayed at a time. Manipulation of multiple window panes was difficult (no minimization, no quick list to all apps, resizing not always possible). Flexibility users had grown accustomed to was tossed out in favor of this task-selector approach. On Sun's Java website there was a page boasting of a committee formed that decided this was the "right way" to make a desktop. Tell that to our users.

The GraphOn Go-Joe software was by far the most damaging piece of software to the JavaStation line. This was an X-connectivity software Sun licensed from GraphOn to give users access to the Solaris servers' X apps. The connectivity worked via a daemon installed on the Solaris server, which was connected to by a Java connectivity applet on the NC side. This small applet (only about 250K) simply threw up the latest display state and sent back to the daemon the mouse and keyboard strokes of the user. Unlike Xterminals though, the actual Xserver process was spawned and communicated with on the remote server-side by the daemon. Communication between the GraphOn client applet and the server daemon was supposedly done by a patented protocol to compress communication and speed things up. However, the performance of X under Go-Joe was terribly sluggish, with horrible refresh rates (10-seconds for some page scroll refreshes). Many sites operators I spoke to elected to not run the Go-Joe software past a trial period for this reason. We had to run it though, as our users were heavily X dependant. Alternatives like Weird/X were not available at this time, and VNC proved not up to snuff given the slow JavaOS VM.

This performance in Go-Joe alone was enough to give uninformed users the impression that the JavaStation was an underpowered machine, especially when placed side-by-side with the low-cost, end-of-lifed Sun Xterminal 1 hardware it was meant to replace. Our students left labs in droves, faculty were upset, and giving demos to outsiders was downright embarrassing. In reality the hardware was solid and stable, but was hampered by this new, untested OS and new, untested applications running on a new, untested hardware architecture. This triple-threat combination, and Sun's timeline for fixing the problems is what I feel truly doomed the JavaStation.

I remember that in 1998, Sun publicized that it had rolled out 3000 of these machines in-house, including one on Scott McNealy's desk. One who has used the JavaStations with the Sun software would have to wonder whether he ever turned it on and used it solely for a day? Had he done so, I'm sure he'd demand things be done differently. (update Oct. 2001: many ex-Sun employees who've contacted me say they made great doorstops and paper weights.)

Why Sun never ported and released its tried and tested XTerminal software to the JavaStation, or even a mini-Solaris, remained a mystery to us the whole time before we switched to Linux. It was only after we moved to Linux and the JavaStation line was formally killed by Sun when we learned from some inside Sun sources that Solaris actually was ported to Mr. Coffee, but released only internally at Sun. As a heavily invested customer site who had begged for help, this was not only disheartening, but insulting to discover.

Lastly, the customer support we received at the time was horrible. We pled our case on more than a few occassions, but requests always seemed to fall on deaf ears. Calling up SunSolve for JavaStation help always resulted in a transfer to a Java Language engineer. If the Sun employees do not know their own products, that's a problem!

From our view, there no doubt was politics involved in this, and as customers, we were the ones to bear the results of this. We continue using Sun equipment when it comes to the proven models like the Enterprise-class servers and disk arrays, but on the latest low-cost desktop offerings, we will be forever cautious given the JavaStation history.

Linux now proves the JavaStations are adequate machines, and Sun could take this bait and go with it. If they sell the JavaStations for $250 a piece and the JavaStation running a proven OS like Linux (or Solaris) with proven apps (X), the JavaStation makes for a great network appliance. The recent NetPliance I-Opener Linux hack and subsequent controversy proves there certainly is a market for this type of low-cost device. (Oct. 2001 addition: After the publishing of the Linux hack, NetPliance made their new hardware unhackable, and subsequently ran out of business. The demand for cheap diskless stations still exist. Today's hackable units are set-top receivers and failed internet toasters like the 3Com Audrey)

 
--Robert Dubinski, former Computer Systems Technician at Marquette University (Quoted March 2000)  

More comments and rebuttal statements by Sun employees are always welcome.

(update Oct 2001): A year and a half of this document's existance and not a single rebuttal statement by Sun. There were a couple initial requests to omit this section, but I refused. After all, imagine a new reader who never saw a JavaStation before: They'd read to this section, think "Wow, what a great little machine..let me get one!", and then ask themselves, "If it did all this, why don't they make them anymore?". The bad must be included with the good, and to leave this section out is a disservice to all the users who suffered through the poor software and support during the official lifetime of the JavaStation. This section, therefore, is a necessity, and although this document is licensed under the GNU Free Documentation License, the eagle-eyed reader will note that this section has been labeled as "invariant" to protect it from entities who may wish to bury it (which is precisely the reason why the Invariant clause of the GFDL exists).


2.6. Where to Purchase a JavaStation

Since Sun has canceled production of the JavaStation line, it no longer sells them through their official channels. Sun contacts have informed me that all internal JavaStation stock was cleaned out and dumped in 2000. Therefore, All JavaStations are now found out in the wild.

Your best bet to get JavaStations though is out on the open market. Educational institutions which received a handful from Sun as demo units are now trying to offload them any way they can (too bad they don't read this HOWTO). Search around the auction sites like Ebay and Yahoo Auctions, and you should be able to turn some up.

A great resource for JavaStations used to be "Bodoman's JavaStation site" at: http://www.bodoman.com/javastation/javastation.html. Sadly, as of October 2001, the domain bodoman.com seems to no longer resolve. Ebay may now be your best bet.

Mr. Coffee is the most widespread JavaStation model, and has tended to sell around $30-80US consistently for the last year or so.

Krups models more rare and sell at higher prices, probably because the stylish case still stands out today. Prices on Ebay are always over $100, but for Oct. 2001, their technology is definitely no longer worth that much. A good price would be $80-85US. Many reports have come from the UK telling of many Krups models getting dumped there.

The Dover models were a very hush-hush thing when this HOWTO was initially published, but the secret is out: if you want one, go to South Africa. Dovers seemed to have been dumped there en masse. Pricing is unknown, but should be comparable to a Cyrix-266 PC clone.

The Espresso and JavaEngine models are near impossible to find, so if you get one, consider yourself lucky. If you have a Fox, well, you're just too cool. Pricing for these models is likely a premium. (>$100US).


3. Background Requirements for Linux on a JavaStation

This chapter describes the base hardware and software requirements for enabling Linux on the JavaStation .


3.1. Complete Hardware Requirements

For hardware, you will need one or more JavaStation clients and a server to feed it its Linux image from, all networked on the same net segment.

This server you use can be any server which supports DHCP and TFTP, and RARP. These are the base protocols needed to perform a network boot of the JavaStations. You may also need NFS service as well, but it is not necessary in one type of configuration this HOWTO describes. Also, you can get by without RARP on both the Krups and Espresso models.

This document will describe how to set up serving the network Linux OS image to the JavaStation from a Sun server running SparcLinux. While you do not need a Sun server to serve your Linux image off of, a Sun SparcLinux server is recommended should you wish to compile a kernel of your own, or prototype a new filesystem for your JavaStations to use. Otherwise, you will need to use prepackaged kernels and filesystems somebody else has pre-built and made publicly available for use. (You might also use a cross-compiler to produce the kernel images, but prototyping a filesystem is best done on a Sun SparcLinux server.)

Reports of successful boot servers used include Sun boxes running Sparclinux, Sun boxes running Solaris, and PCs running MS Windows. It is only when you are building a new kernel or filesystem that a Sun box running Linux becomes valuable.

Your network can be a simple 10 Mbps ethernet LAN, but when you begin using more than 50 JavaStations at once, a switched 100 Mbps network becomes desirable for your server to handle multiple concurrent boot requests.

This HOWTO includes pointers to example kernels, filesystems and a complete out-of-the-box solution for you to use, eliminating your need for a Linux/SPARC server, but you still need a server of some type to feed the image to the JavaStations as they boot.


3.2. Network Service Requirements

As discussed in the last section, the JavaStation boot cycle will make use of DHCP and TFTP with possibly NFS and RARP. To understand why, read up on the JavaStation boot sequence in the next section.


3.3. Understand the JavaStation Boot Sequence

The JavaStations follow a typical diskless workstation boot sequence.

When powered on, the JavaStation sends out a broadcast request for its IP. It gets its IP info via RARP or DHCP. With a DHCP response, it gets information about the network it is on and where to go download its boot image from via TFTP.

There are subtle variations in diskless boots from one diskless machine to the next. For instance, BOOTP may sometimes be substituted where DHCP is, and RARP may be eliminated in favor of either of the two. But in general, the sequence is typically the same between the client and the server:

  1. C: "Who am I?"

  2. S: "You are xxx"

  3. C: "Where do I go for my boot image?"

  4. S: "You go here."

  5. C: "Give me my image from here...Please?"

  6. S: "Here's your image."

After the kernel is finished loading, your diskless client typically mounts its root filesystem from the network via NFS. Alternatively, it may load and mount it from a RAMdisk.

The original JavaOS and Hotjava Views environment, when run on a JavaStation, required the setup and maintenance of the core services above, plus also NIS, HTTP, DNS, POP, and NTP servers. If setting up a JavaStation boot server seems like a lot of work, imagine adding these extra services into the mix too.


3.4. Additional Software Requirements: Replacement Firmware (PROLL)

JavaStations came with two different PROMs installed in them. Version 2.30 shipped with the earliest Mr. Coffee models, and was updated by latter versions of the Sun Netra J software environment to 3.11. Krups and Espresso came with 3.x versions of the PROM by default.

It turns out the later 3.x series of PROMs is not conducive to booting Linux upon. Fortunately, a complete PROM replacement called PROLL now exists to get by this limitation.

PROLL becomes the first image your JavaStation grabs by TFTP. It then will load your true kernel image and boot into Linux .

No matter what PROM revision you have, get PROLL. This can make troubleshooting new installs easier.

The current, master version of PROLL is available from: http://people.redhat.com/zaitcev/linux/.

The current version at the time of this writing is "14".

PROLL can also be found mirrored on "VGER ", and also on this HOWTO's distribution site at: http://dubinski-family.org/~jshowto/Files/proll/proll_14.tar.bz2 (HOWTO website mirror - version 14)


3.5. Decide on your Filesystem-type: NFS-Root, or Embedded?

Before you begin, you must decide upon the root-filesystem type you wish to use for your diskless JavaStation. There are two possibilities.


3.5.1. "NFS-Root" Filesystem

In this setup, after the boot kernel is retrieved off the network, the running JavaStation makes an NFS connection for its root filesystem. The root directory "/" is mounted off the network for the duration of the current session.

The "NFS-Root" solution is the recommended way to go for beginners, as it is easier to troubleshoot if there are problems. It also makes it easier to prototype the proper filesystem, as any changes you make on a running system can be propogated for the next boot cycle (so long as you are in read-write mode, of course).

Drawbacks of this type of system is increased network activity as the running JavaStations locate and execute files, plus file organization in large environments.


3.5.2. "Embedded-Root" Filesystem

In this setup, the root filesystem is loaded directly into RAM and accessed from there.

The advantage of this setup is that there is no NFS traffic to worry about, resulting in a clean solution.

The disadvantage of this configuration is that you can no longer do rapid prototyping of your filesystem, as any changes you make to a running system are lost. If you have no "NFS-Root" setup available, you develop an embedded filesystem by making small tweaks and performing reboots to test. Other disadvantages include the requirement of fitting the full filesystem in available RAM; due to a limitation of PROLL, this requirement is much lower on JavaStations than expected. Still, embedded root is the way to go for the cleanest environment.

First time users will want to set up an "NFS-Root" configuration. When you have things stabilized, move to "Embedded-Root" to take use of its advantages.


3.6. Support Sites to Check Out: Zaitcev's Linux Site

One website to keep on reference when you begin thinking about putting Linux on your JavaStation is kernel hacker Pete Zaitcev's website at: http://people.redhat.com/zaitcev/linux/, referenced throughout this document as the "ZLS" site (short for "Zaitcev's Linux Site"). Here you will find the latest version of PROLL and many low-level details about dealing with the JavaStations. Many items on the ZLS have been merged into this document, but not all.

Oct. 2001 update: It is in your best interest to review all the information on Pete's site, in this document, and references pointed to, before diving in and setting up your JavaStation with Linux. Almost all questions people have had in setting up their systems are covered in the materials presented.


4. Build Your Kernel

4.1. Before you begin

This chapter assumes you wish to compile your own Linux kernel for the JavaStation. If this is something you can not do, there are sample kernels pointed to at the end of this chapter.

This chapter assumes you already know how to compile Linux kernels in general, perhaps on a PC, a SPARC server running Linux, or any of the other Linux ports. If not, read the Kernel-HOWTO and the README file of your kernel source.

Compiling a kernel for a JavaStation is not much different than compiling a Linux kernel elsewhere. You just need to know the right options to pick. In general, you're compiling for a Sun4M class architecture, and enabling JavaStation-specific options. The following sections in this chapter will take you through the steps.

While it may be possible to compile the JavaStation -enabled kernel on alternate platforms by way of a cross-compiler, this HOWTO assumes you will do it on a Linux/Sparc based server running in 32-bit mode. Cross-compiling will not be covered, and questions regarding it will not be entertained.


4.2. Make sure you use 32-bit mode

When compiling your own JavaStation-capable kernel on a Sun server, you need to make sure the machine you work on is set to 32-bit mode. So, if you're on an Ultra-class machine, be sure to first switch to 32-bit mode before you begin compiling.

To check what mode you're in, do a uname -a. If it says "sparc", you're in 32-bit mode and don't have to do anything. If it reports "sparc64", then you should perform a sparc32 bash first to switch to 32-bit mode. A subsequent uname -a should reflect the change.


4.3. Supported Linux Kernel Versions

The kernel source revision you should use depends both on which model of JavaStation you have, and which series kernel you are using. The current "stable" series of Linux kernels is 2.4.x, but as we will read in a minute, this may not be the best bet to use.

First, a few note on the 2.2.x and 2.3.x series. Mr. Coffee has had kernel support since about kernel version 2.2.5, and definitely works out of the box with the RedHat 6.0+/SPARC distribution kernels. Krups support did not work well out of the box until the latter 2.3.x kernel cycle. Krups support was added in the early 2.3.x sequence, but the MMU changes to the 32-bit SPARC kernel had kept it from compiling cleanly until later on.

Kernels for both Mr. Coffee and Krups compiled cleanly by the HOWTO author with the Mar. 17, 2000 CVS kernel, and are included in the Sample Kernels section.. Krups support was backported into the 2.2.x kernels (where x>15). The latest 2.2.x kernel "should" compile cleanly for the Mr. Coffee and Krups models, but your mileage may vary.

Now onto the 2.4.x series.

The only kernel which has been tested and compiles cleanly for Mr. Coffee and Krups is version 2.4.2. All other versions are broken or require a patch.

The reason for this is that the sparc32 branch of the kernel has not had an active maintainer for many months. Some are contributing fixes, but without an active maintainer things go slow.

There is another reason to be weary of the 2.4.x series. From 2.4.0 through 2.4.9, the VM of the kernel was found to be inadequate under heavy loads, and was subsequently replaced in 2.4.10+. This was a big change for the so-called "stable" series of kernels.

To add further insult to injury, there have been security flaws detected in all of 2.2.x kernel series and up through 2.4.12. This is patched in pre-2.2.20 and 2.4.12+. As of this writing, 2.4.12+ has not been checked by the author as functioning on the JavaStations.

So basically, it has been a crap-shoot over which kernel to choose. Try a few until you find one that suits you best.

If you can not get a kernel to compile, or wish to avoid the headache or trying, you may try the samples pointed to by this document.


4.4. Required Kernel Configuration Options

When you do your make config command to enter the kernel configuration stage, there are a few things you are required to enable. Note that the following option names are from a 2.2.x kernel, and may be slightly different on a 2.4.x series kernel. If in doubt, check the sample files later in the chapter.

For all JavaStations, you want to enable PCI support:


CONFIG_PCI=y 

Don't forget your mouse:


CONFIG_BUSMOUSE=y 
CONFIG_SUN_MOUSE=y 

You'll want video, done with the Linux framebuffer interface:


CONFIG_FB_TCX=y (for Mr. Coffee) 
CONFIG_FB_PCI=y 
CONFIG_FB_IGA=y (for Krups/Espresso) 

Audio is done with the Crystal Audio 4231 chipset:


CONFIG_SPARCAUDIO=y 
CONFIG_SPARCAUDIO_CS4231=y 

Don't forget your network interface:


CONFIG_SUNLANCE=y (Mr. Coffee) 
CONFIG_HAPPYMEAL=y (Krups/Espresso) 

You'll no doubt need to support a filesystem:


CONFIG_EXT2_FS=y 

You'll want IP autoconfiguration, and RARP/BOOTP support:


CONFIG_IP_PNP=y 
CONFIG_IP_PNP_BOOTP=y 
CONFIG_IP_PNP_RARP=y 

When doing the "NFS-Root" filesystem configuration, you will need both NFS and NFS-Root support:


CONFIG_NFS_FS=y 
CONFIG_ROOT_NFS=y 

When doing the "Embedded-Root" filesystem, configure both RAM disks and "initial ramdisk" support:


CONFIG_BLK_DEV_RAM=y 
CONFIG_BLK_DEV_INITRD=y   (for 2.4.x, also configure size of ramdisk)

You can get a working ".config" file which has the required options set later in this chapter.


4.5. Necessary Patch for "Embedded-Root" FS Configurations

If you have decided to go with the "Embedded-Root" filesystem option, you will want to make a patch to the RAMdisk driver source first.

The default size of a RAM disk when using the RAM disk driver is 4 MB. Chances are that you will want an embedded filesystem of more than that size, particularly when you start thinking about running an X server, or including a Java runtime.

You can do this for 2.2.x kernels by a manual edit yourself, or by using the patch pointed to below. The change is a one-line edit in the file <LINUXROOT>/drivers/block/rd.c . Look for a line that says:


int rd_size = 4096; /* Size of the RAM disks */ 

and change it to the size of the RAMdisk you wish. Typically, most embedded systems are under 16 MB, so a common edit is to change the line to:


int rd_size = 4 * 4096; /* Size of the RAM disks */ 

If you can not do this, the patch below makes the edit for you.

4MB to 16MB kernel patch file is at: http://dubinski-family.org/~jshowto/Files/patches/ramdisk_patch.txt

Kernels in the 2.4.x series allow you to select the amount of RAM as a configuration option. The patch is no longer needed for those kernels.

It should also be noted in this section that there is currently a limit on the size of Linux boot image for all JavaStation models, due to the implementation of PROLL. This limit is technically 8 MB. This topic is mentioned again in the "Questions and TroubleShooting" section of this document.


4.6. Build the JavaStation-Ready Kernel

To build the kernel, you type make vmlinux. If you come from an x86 Linux background, you might be surprised that you do not perform a make bzImage or make zImage. Do not be alarmed: this command is correct.

When the compile is finished, you will find a file named "vmlinux " in the kernel source root directory. You are almost ready to put this kernel to use.


4.7. Convert Kernel from ELF to a.out format

You need to make one more change to your kernel before it is ready for use. You need to convert it from ELF to AOUT executable format. You can do this with the "elftoaout " utility included in most Linux/SPARC distributions.

To convert your kernel image to the AOUT executable format, you issue the command:


elftoaout -o vmlinux.aout vmlinux 

You will probably now want to rename the image file to a longer name which includes the current date and kernel revision you used, so as not to get confused with when you have multiple boot kernel images down the road.

The elftoaout program should come with your SparcLinux distribution. If not, try VGER or your favorite kernel mirror.


4.8. JavaStation-Ready Kernel Images, System.map and .config File Samples

Here are some sample ".config" and JavaStation -ready kernel images. They were prepared and donated to help get you up-to-speed quickly.

Warning: Some of these kernel images are considered out of date, and should be avoided in a production environment. It is up to you to decide how much of a liability you feel running them holds. The document author and kernel contributors cannot be held liable for any damage caused by the use of these kernels. They are provided with absolutely no warranties.

If for some reason you have troubles downloading, try holding left-shift on your browser as you click the link. Kernel images are compressed with bzip2 compression. They must be uncompressed before use. Kernel images are already converted to a.out format.

If you mirror these files, or can verify they work on a machine not yet confirmed, PLEASE email me so I can add your information here.


4.8.1. 2.3.99pre3_embedded_RSD

.config (md5sum c59329ceb2e831f2502c1e410ece141c): http://dubinski-family.org/~jshowto/Files/kernels/2.3.99pre3_embedded_RSD/config__2.3.99pre3_embedded_RSD.txt

kernel (md5sum 8e8d28b13961b92e3f95e4ba98f6f319): http://dubinski-family.org/~jshowto/Files/kernels/2.3.99pre3_embedded_RSD/vmlinux__2.3.99pre3_embedded_RSD.bz2

System.map (md5sum 43205a86fcb0b16ecae7313d38fcbb2c): http://dubinski-family.org/~jshowto/Files/kernels/2.3.99pre3_embedded_RSD/system.map__2.3.99pre3_embedded_RSD.txt

Description:

This kernel is donated by Robert Dubinski. It was used at Marquette University to build an embedded root boot image. This is based off of the Mar. 17, 2000 CVS kernel. It includes support for both Mr. Coffee and Krups machines.

Tested on Mr. Coffee: YES

Tested on Krups: YES

Tested on Espresso: NO


4.8.2. 2.3.99pre3_nfsroot_RSD

.config (md5sum e715370346ac298555dd7ce099c8f80a): http://dubinski-family.org/~jshowto/Files/kernels/2.3.99pre3_nfsroot_RSD/config__2.3.99pre3_nfsroot_RSD.txt

kernel (md5sum fd141e8e8f639df67427d5ecd0ecba76): http://dubinski-family.org/~jshowto/Files/kernels/2.3.99pre3_nfsroot_RSD/vmlinux__2.3.99pre3_nfsroot_RSD.bz2

System.map (md5sum fd141e8e8f639df67427d5ecd0ecba76): http://dubinski-family.org/~jshowto/Files/kernels/2.3.99pre3_nfsroot_RSD/system.map__2.3.99pre3_nfsroot_RSD.txt

Description:

This kernel is donated by Robert Dubinski. It was used at Marquette University to prototype a filesystem. This is based off of the Mar. 17, 2000 CVS kernel. It includes support for both Mr. Coffee and Krups machines.

Tested on Mr. Coffee: YES

Tested on Krups: YES

Tested on Espresso: NO


4.8.3. 2.4.2_embedded_RSD

.config (md5sum dd1a9dd2e92b9b175b7ba747c94edca7): http://dubinski-family.org/~jshowto/Files/kernels/2.4.2_embedded_RSD/config__2.4.2_embedded_RSD.txt

kernel (md5sum 5a1592b7e0a37909ae16374296a7070e): http://dubinski-family.org/~jshowto/Files/kernels/2.4.2_embedded_RSD/vmlinux__2.4.2_embedded_RSD.bz2

System.map (md5sum 1de202e0fab7a9e661bebc80255605b7): http://dubinski-family.org/~jshowto/Files/kernels/2.4.2_embedded_RSD/system.map__2.4.2_embedded_RSD.txt

Description:

This kernel is donated by Robert Dubinski. It is a demonstration kernel for the 2.4.x series, and has not been tested...yet. It includes support for both Mr. Coffee and Krups machines.

Tested on Mr. Coffee: NO

Tested on Krups: NO

Tested on Espresso: NO


4.8.4. 2.4.2_nfsroot_RSD

.config (md5sum cabd1d98613ad169b372666b7eaa869b): http://dubinski-family.org/~jshowto/Files/kernels/2.4.2_nfsroot_RSD/config__2.4.2_nfsroot_RSD.txt

kernel (md5sum c24f42f72c58920c00ac7ff7aaffadde): http://dubinski-family.org/~jshowto/Files/kernels/2.4.2_nfsroot_RSD/vmlinux__2.4.2_nfsroot_RSD.bz2

System.map (md5sum 6af2b374c7d3fc3f97d48ab71b335062): http://dubinski-family.org/~jshowto/Files/kernels/2.4.2_nfsroot_RSD/system.map__2.4.2_nfsroot_RSD.txt

Description:

This kernel is donated by Robert Dubinski. It is a demonstration kernel for the 2.4.x series, and has not been tested...yet. It includes support for both Mr. Coffee and Krups machines.

Tested on Mr. Coffee: NO

Tested on Krups: NO

Tested on Espresso: NO


4.8.5. Outside kernel mirrors

Other sites mirror the kernels here or other kernel samples. Here are a few known sites as of Oct-31-2001:

  1. ftp://atari-source.com/pub/javastation/

  2. http://people.redhat.com/pjones/krups


5. Build A JavaStation-Ready FileSystem

This chapter describes how one constructs a filesystem suitable for use on the Linux-running JavaStations .


5.1. Preparing Yourself to Build Your Own Filesystem

Building a filesystem for use with the JavaStations is a time-consuming, but rewarding task for those who undertake it. You will learn more about library dependencies than you ever thought you could, all the time while trying to keep the overall image size as small as possible.

WARNING: This is not an easy task. Creating a lasting filesystem is not for novices. If you seriously consider undertaking this step, prepare to budget a bit of time to get things just right, particularly if you plan to make an embedded-root filesystem which fits in the 8MB limit. You have now been properly warned.

There are two common approaches one can take when rolling a new JavaStation-ready filesystem.

  1. Start with an established distribution's filesystem and whittle down to the core.

  2. Start with an established distribution's "rescue disk" filesystem and add desired functionality.

Which path you take, of course, is entirely up to you. The "rescue disk" build procedure seems to work best though, as more base commands in a rescue disk are statically linked, increasing the starting image size but causing less initial library headaches. Commands included on a rescue disk also happen to be bare-bones, with many extraneous options not compiled in.

Obviously when building a filesystem in the context of the JavaStation, you will be basing off of an existing Linux/SPARC filesystem. The filesystems that come with the RedHat, SuSE or Debian distributions are good starting points.

Warning

In the future, you will also need to make sure you base off a filesystem built with compiled 32-bit mode executables, as a 64-bit userland project is presently in progress for 64-bit SPARC Linux kernels. As of Oct. 2001, this is still a ways away, but it is being mentioned now for the future.


5.2. Contents of the "/etc/fstab" File

The configuration lines placed into "/etc/fstab" depend on whether you will be using the "NFS-Root" or "Embedded-Root" filesystem configuration.


5.2.1. "NFS-Root" Filesystem fstab

Here is an example of an "/etc/fstab" for an "NFS-Root" boot option.


###
#
your.nfs.server:/path/to/filesystem  /  nfs defaults,rsize=8192,wsize=8192 1 1
#
none                    /proc                   proc    defaults        0 0
###

5.2.2. "Embedded-Root" Filesystem fstab

Here is an example of an "/etc/fstab" for an "Embedded-Root" boot option.


###
#
/dev/ram /     ext2  defaults
#
/proc    /proc    proc  defaults
###

5.3. The "Embedded-Root" Image Creation Procedure

Prepping up the "Embedded-Root" boot image requires a number of extra steps. Due to these extra steps, the "NFS-Root" filesystem option is recommended for beginners to Linux on the JavaStation. You might also try the samples pointed to in this document. Should you still wish to build and embedded image on your own, this section outlines the basic instructions.

Creating the "Embedded-Root" boot image is a 5-Step Procedure:

  1. Prototype Your Filesystem

    This whole chapter deals with rolling your own filesystem. In this step, it is assumed you create your own filesystem, perhaps by prototyping one on a working "NFS-Root" filesystem configuration.

    One thing to keep in mind is that unlike your "NFS-Root" filesystem, the "Embedded-Root" filesystem must fit within the confines of your allocated RAMdisk, generally 4-16 MB. Your maximum size is dependant on the setting of the RAMdisk driver.

  2. Create an Empty File for Your FileSystem

    You now need to create a file-based filesystem "container". This is just a file that is the size of your RAMdisk.

    To create this, try the dd command:

    
dd if=/dev/zero of=./fs_test.img bs=1k count=8000 
    

    Using this example, you now should have an 8 MB file named "fs_test.img". Note: Be sure the count you use matches the RAMdisk size you allocated for in the kernel's RAMdisk driver!

  3. Format your Filesystem "Container"

    Now that you have a "contain