VOICE Home Page: http://www.os2voice.org |
November 2003
[Newsletter Index]
|
By Per Johansson © November 2003 |
This article is about making the HOBLink X11 Server work on eComStation, and why you would want to, providing examples. Kim Cheung of Serenity Systems says "HobLink is probably one of the most important applications in the eCS Bonus Package as far as enterprise customers are concerned." The installation package is included in the eComStation 1.1 Application Pack, but there's almost no documentation. Several curious eComStation users have asked about it in the eComstation newsgroups, a good source for information. Anyway, HOBLink can be used to run programs for the X Window system locally and remotely. There was an article about HOBLink X11 on the local network in the April 2002 VOICE Newsletter, and my intention is to take one step back to cover the installation in more detail, and add a few other aspects.
The X Window System is used for the GUI (Graphical User Interface) on Unix systems. Since I had been using Unix for years, one of the first things I did as an OS/2 beginner, was to install XFree86, the free X11 Server. This was not an easy task; I still remember counting the keys on my keyboard to discover that the actual number of keys wasn't listed in the configuration options. I just had to guess what to select. Anyway, it was up and running sooner than expected. I could use it locally with The Gimp (The GNU Image Manipulation Program), and while attending a university course, at which I logged onto the university computers from home, over a modem. The topic of the course was database programming, using Oracle, and this method worked fine as long as I worked in text mode (that does not use X). Using the X GUI was way too slow.
When I got a new graphics card, it was not supported by XFree86, so I had a long pause using anything X11. Anyway, I missed The Gimp; and now I have begun another university course (called Visualization) in which we use Matlab, the ubiquitous "Matrix laboratory" program. Since I would prefer to work more from home, and I now have an ASDL connection, this was a good reason to make HOBLink run on my machine.
HOB is a German company for enterprise connectivity solutions. eComStation 1.1 Application Pack includes HOBLink X11 for OS/2 Version 3.5, package date 2001-07-10, while the included files are from 2000-09-28. There's also a Win32 version with a higher version number but that costs quite a bit of money if purchased, so I'm happy to get it for free. The OS/2 page seems to be in English only, while the general info is available in German and French.
I had tried to install it just like most of the other software from the eComStation
1.1 CD's. This just would not work. The installation broke down in the beginning
with this error message:
EPFIE 187: A product-specific installation error
occurred while executing the 'EXEC' exit routine.
The return code is 0x0005.
Some people have encountered this message and asked for help, but nobody seems to know the answer. I eventually found that the Application Pack registration file ECS11APP.KEY from ecomstation.com had become corrupted. The username was missing. I got a new registration file, and removed the ECSREG.INI key file from the \os2 directory, so the installation would create a new file.
The installation is done through the installation menu on the eComStation Application Pack CD. First, the eComStation registration form is shown, if no registration has been done yet. Then it's the usual OS/2 installer, in which you can select from the following items:
There's no real help available in the installation package, so I initially selected everything. I suppose that the essential selections are just X-Settings HOBLink X11, Minimal Fonts Set, and XSERVER HOBLink X11. If you miss something, you can always add it later. While the base component is being installed, a registration window will pop up, with the values already filled in. Finally, the X-Settings notebook pops up so you can change the default values. I selected Swedish keyboard, and it seems as if Use DIVE extension has to be enabled too. Then it's done. There's no need to reboot the computer.
Figure 1: HOBLink X11 for OS/2 folder.
The folder HOBLink X11 for OS/2 will be created on the desktop. Inside it, there are some programs, depending on what you selected during the installation. The useful ones are XServer and XSettings. Don't even think about touching Telnet, FTP, etc. if you don't know what you are doing (like me)! Now, if you start XServer, all you get is a minimized icon on the desktop. I was somewhat puzzled by this, since XFree86 would have started an X window manager in full screen mode. This is because HOBLink is by default set to Multiple windows. If you start an X program, it will be shown just like a PM (OS/2 Presentation Manager) program. Other options are Single window or Full screen, and using them you'll also need a window manager, which is not included. Multiple windows is the convenient choice.
The eCS Application Pack contains new versions of the HOBLink files. You install them by simply copying them over the original files. The files are the same, just treated with Dialog Enhancer - the software that makes eCS and optionally OS/2 so pretty.
To be able to log on to the university computer, I had to get SSH (Secure Shell encrypts internet connections). A few years ago, a Telnet connection was OK, but security has become more important. Fortunately, SSH is now available for OS/2. I installed OpenSSH version 3.6.1p2 from Kiev Elephant . Installation just means unzip, move some files and create keys according to the instructions, so I won't go into details.
Finally, I had to adjust the firewall settings so the X windows would appear
on my main computer at the local IP address 192.168.0.1. I use InJoy Firewall 1.4,
and while trying HOBLink and SSH on the firewall computer, there was nothing to
change from the default settings. Working from the main computer, I had to use port
mapping, adding this to the firewall\firerule.cnf configuration file:
PORTMAP-X11-IN
Rule-Status = Enabled,
Comment = "X11 connection to the university",
Source = "any",
Destination = "current",
Service = 6000,
Rule-Action = Portmap,
Mapping-Dest-IP = "192.168.0.1",
PORTMAP-X11-OUT
Rule-Status = Enabled,
Comment = "X11 connection to the university",
Source = "192.168.0.1",
Destination = "any",
Source-Port = 6000,
Rule-Action = Portmap,
Now, to test if it works with the simple program xcalc, that is usually
installed on Unix systems. The -l option is for the username to log on
to the remote computer. It's followed by the internet address of that computer.
You also have to tell it to use your computer for displaying X windows. 999.999.999.999
means my own external IP address, which is then mapped by my firewall. The logon
details may vary, but this it what it looks like here on SunOS 5.6 and a tcsh
C shell.
ssh -l username computername.someuniversity.se
mypassword
setenv DISPLAY 999.999.999.999:0.0
xcalc
Figure 2: Xcalc in a window with the Xserver icon below.
It looks just like a normal PM Window, with HOBLink's icon. Its menu adds several items to the default window menu:
Figure 3: HOBLink window menu, Edit expanded.
Figure 4: HOBLink window menu, Options expanded.
Figure 5: HOBLink window menu, Macros expanded.
Finally, run
matlab -nojvmHere's an example from the exercises.
Figure 6: Matlab.
Unfortunately, Matlab does not work very well remotely. It's very slow and hangs after a while, although for instance Staroffice and Framemaker run without any problems. I don't know what the problem is with Matlab. Perhaps it's just too graphics intensive.
There is a load of X applications available. The most interesting one may be The Gimp. Its situation is confusing right now, since it's being ported as a PM application by Netlabs, and the X version hasn't been updated for a while, nor is it easy to find.
There's some work needed to set up your environment before running an X application. It's well described by HOB at HOBLink X11 under OS/2; Installation (German version: HOBLink X11) and at OS/2 eZine Running X applications in 3 easy steps.... The files are available from Heinrich-Heine-Universität Düsseldorf FTP.
I already have EMX runtime (installed by eComStation) and WarpIN 1.0.1 installed, and TCP/IP set up correctly, so I could start with the XFree86 Libraries (XLib-3-3-6.wpi, date of contents 2000-01-09). I set X11ROOT to F:, and selected to install XLib, and not HOME, since the latter is already set up by the eComStation installation. Then, I installed the GNOME Libraries (GnomeLibs-1-2-8.wpi, date of contents 2000-08-25). The latter includes:
I'm not familiar with all this stuff, but some of them are plug-ins for The Gimp. They are a bit old, but it's nice to have them packaged together. These two installations just copy files to the XFree86 directory (created if necessary) and add some lines to CONFIG.SYS.
Finally, The Gimp (Gimp-1-1-25.wpi, date of contents 2000-08-25). It includes Gimp Base 1.1.25, Gimp Data 1.1.24 and X-Scanimage 1.1.22.0. These are the same as gimpbx.x.x.zip, gimpdx.x.x.zip and gimpex.x.x.zip (substitute x with version numbers). Like the packages above, it copies files to the XFree86 directory, adds some lines to config.sys, and also creates a desktop folder called GNOME/2 Apps that contains a program object for The Gimp. You'll either have to rename gimp.exe to gimp1125.exe, or change the program object to gimp.exe if you want to use it. After the three packages have been installed, reboot to make use of the changes in CONFIG.SYS.
Figure 7: The Gimp (190 KiByte)
A peculiar problem with The Gimp and HOBLink is that it won't let you use the text tool the normal way. I have been using GDynText (Gimp dynamic text) to get the text on photos.
The Gimp is one of the few localised applications I have. You may notice that most texts are in Swedish, with an incorrect codepage in one place :-)
It seems that the last Gimp version for X on OS/2 is 1.2.2 (latest filedate 2001-08-23). Right now the latest stable release is 1.2.5 and development release is 1.3.20. The files are available from the Netlabs FTP server. They can be installed by simply unzipping them over the installation that was done in the above paragraphs, and using the gimp122.exe file. After backing up the XFree86 directory, I installed gimpb122.zip, gimpd122.zip and gimpe122.zip. Then I discovered that GDynText didn't work any more! I just got an empty box, and an error message that the font wasn't found. Had to delete the XFree86 directory and restore the old one...
Meanwhile, after a long break, new versions of XFree86 for OS/2 have surfaced. Version 4.3.0 (date 2003-02-28 plus later fixes) is available from Netlabs FTP. I haven't tried it out yet.
A good information source, although oriented towards XFree86 and not so much HOBLink, about X11 and applications is "the X11 files" at The OS/2 Files. It can be used as a starting point since it links several other sites.
The Yahoo! Group Gimp for OS/2 carries some useful information, although there's a lot of old spams in it too; it's moderated now.
You can find advice from seasoned users in the ecomstation.apps and ecomstation.support.misc newsgroups on the news.ecomstation.nl NNTP server.
Team OS/2 Region Trier e.V. has "The official Gimp/2 german mirror page", available in English and German.
The Gimp User's Manual is available for browsing or download. Its date is 1999-11-02, which corresponds to the Gimp version 1.1.11.
Manual for HOBLink X11 version 4.6 for Win32 in English and in German. Manual for HOBLink X11 for Win16 in English and in German.
HOBLink or XFree86 are useful additions to eComStation. HOBLink is way easier to set up than XFree86, and it can run X applications on the normal desktop, although it needs some extra files to run local applications, and there may be some problems such the one with The Gimp text tool.
[Feature Index]
editor@os2voice.org
[Previous Page] [Newsletter Index] [Next Page]
VOICE Home Page: http://www.os2voice.org