OS/2 Tips & Tricks

From OS2World.com Wiki
Jump to: navigation, search

By Christian Hennecke

Here you will find information on avoiding errors, undocumented features and other useful things. There's no guarantee for correctness and I am in no way responsible for any damages that may result in using the given information. Well, who fiddles around with her/his system should always have a backup available anyway.

Contents

Using alternative CONFIG.SYS files

By modifying the CONFIG.SYS you can adapt OS/2 to your needs and e.g. save RAM and increase performance. However, you may have already found out that for different tasks also different configurations are best. You won't need LAN-requester/peer support if you only want to write letters, for example. Or you probably won't need Voicetype most of the time. Now, wouldn't it be nice if you could choose to start OS/2 using a hand-taylored CONFIG.SYS for specific tasks without the need to edit the file by hand each time?

Well, no problem! Remember what happens if you press ALT-F1 at boot time? The screen that shows up offers you several options to choose from. One is to start OS/2 with the standard configuration visible after first installing OS/2. When you press the given key a file CONFIG.key (e.g. CONFIG.X), located in \OS2\BOOT is loaded and used. So you can optimize your CONFIG.SYS for different tasks and save the result as CONFIG.character in \OS2\BOOT. Then you can select the one you wish in the mentioned screen. Well, you'd better see somewhere which file is optimized for which purpose and which are available. Edit the files ALTF1*.SCR (you have to change the read-only attribute) to reflect your additions. Note that ALTF1BOT.SCR should be no larger than three lines!

Feature Installer

This tool is needed to install some of the packages from IBM Software Choice.

First of all I'd suggest to read the installation instructions thoroughly and to follow them to the character. The Feature Installer is very picky.

There are several problem you can come across. One has occured with later version of Netscape Navigator 2.02 where FI states that you have a false version of Navigator installed. Have a look at the NETSCAPE.PKG file in your Navigator's directory. Set the last digit of the SERVICELEVEL entry to 5.

What also may happen is that you have successfully installed FI, rebooted and... the WPS hangs. Well, if you have fixpak #3 installed you a) haven't read the README like I told you to and b) haven't installed the updated OS/2 kernel from the FP3KRNL add-on.

Problems are also likely to arise if you have installed different version of Netscape (e.g. 2.02, 4.04 and 4.61). FI uses a Netscape plug-in and this file called NPFI.DLL is only copied to the plug-in directory of one browser. Make sure the plug-in is also copied to the other browsers' directories.

LINKUP.EXE - crashes for free

This program is often called on invoking Netscape, Webexplorer, FTP etc. to check if a net connection is available and start a dialer if not. Well, a nice idea, but I have made some very bad experiance with it. It seems to be buggy somehow and in case of an error leads to the called program locking up the whole system. I'd strongly recommend that you change your objects' settings to not use LINKUP.EXE!

ODIN (aka Win32-OS/2)

Wouldn't it be nice if you could run Windows 9x/NT programs under OS/2? Some time ago several nice people gathered to begin programming a converter that brought Windows executables from the PE format to OS/2 LX format and provided a package of DLLs providing the Win32 API calls or redirecting them to OS/2 API calls while also using the existing Open32 already contained in OS/2. They called it "Win32-OS/2".

Starting with some small things like NT's Solitaire they soon managed to get the game Quake running. Well, after the release of the second alpha version the project pretty much died. Fortunately some of the original team revived the project in early 1999. They realised that they needed much more people to be successful. Due to copyrighted material in the first attempt they had to re-invent a lot of the code to be able to make it OpenSource. The new project was named Odin.

By now Odin runs larger programs like Acobat Distiller, Quake 3, WarpAmp and Homeplanet 3 (a freeware atronomy program) and an extra package provides experimental hardware OpenGL acceleration for older Voodoo cards. The need to convert every EXE and DLL file by hand has also been removed.

You can get information about Odin at the projects homepage at Netlabs. Builds can be downloaded from the Netlabs FTP server.

Piping on the command line

Under certain circumstances you may find that using the output of one program as the input of another by connecting both with the pipe (the "|" character) on the command line will fail. An example would be redirecting the output of the DIR command into SORT and that one's into MORE to get a sorted directory listing you can view page per page:

DIR | SORT | MORE

You may also find that e.g. connecting four commands this way fails while it works for only three. If this happens you need to shorten the length of your PATH statement in CONFIG.SYS and to reduce the number of defined environment variables in general. This is because somehow these statements occupy the same memory area that is used to process commands like the above. Unfortunately, I don't know how to increase this area.

A similar problem can show up when the stream of piped data exceeds a certain value. For instance, the following command that first decompresses a tar.gz archive and then unpacks it often fails on my system:

gzip -dc file.tar.gz | tar xvf -

I haven't been able to find out what is the cause for this so far.

Soundcards

To make it clear once more: full duplex is no problem with OS/2! Any other statements are simply bullshit. Creative Labs used this argument to draw attention from their miserable OS/2 support. In order to use full duplex you'll have to assign two DMA channels to your soundcard, one for recording and one for playback if you're using an ISA card. I'd recommend soundcards with Crystal Semiconductor chips. Their ISA drivers support all features in OS/2, Win-OS/2 and the DOS-box. The PCI drivers have complete WAVE support and support for OPL2 MIDI in Win-OS/2 and the DOS-box.

Visual Age for C++ - Installation problems

If you install VA C++ Version 3 on a Warp 3 or 4 system with a recent fixpak you will run into a version conflict, since VA C++ comes with its own SOM.DLL that comes first in the LIBPATH after installation instead of the one in \OS2\DLL. Rebooting with this configuration will most probably result in OS/2 crashing on startup. To correct this simply change the order of the paths in your LIBPATH statement in CONFIG.SYS accordingly directly after installing VA C++.

There are also potential problems with Visual Age C++ Version 4. Its online help has been changed to HTML format. To make it work, you have to activate the machines loopback interface prior to installation. Moreover, ensure that VAC's small web server doesn't conflict with any other HTTP server that might be running on your system. You will probably have to change the port the server is listening on. Maybe you can also re-configure the online help to use another HTTP server (think of virtual hosts and Apache).

Voicetype

Many people think that this part of OS/2 Warp 4 isn't worth much. There are several reasons for this. The training is one. Make sure that you speak "monotonous" and don't train the system when you've got the flu or there are loud background noises. Another reason if the use of some Creative Labs cards. Their microphone input is a joke and it doesn't even provide power for the microphone.

The hardware needs are another point. Don't run Voicetype on a system with less than 64MB!

As Voicetype slows down the whole system you may want to setup a special CONFIG.SYS. Have a look at Using alternative CONFIG.SYS files. Delete any x:\VT\SPCH statements from the LIBPATH, PATH and DPATH from CONFIG.SYS you are planning to use if you don't need Voicetype.

Warpcenter

A very nice feature in Warp 4, but it sometimes causes frustration, too, by locking up the WPS or preventing it from starting. A workaround is to delete WARPCENTER from the AUTOSTART statement in CONFIG.SYS and placing a shadow of Warpcenter in the Startup folder instead.

If you don't need the diskspace display don't deactivate it, but select "Selected drives" and deselect all drives.

Don't place seven or eight icons in a Warpcenter tray.

It seems that the above problems have been fixed in recent fixpaks. One more reason to update the system to the latest level.

IBM has added some undocumented features to Warpcenter that can be activated by setting some environment variables in CONFIG.SYS:

   SET SCKILLFEATUREENABLED=ON 

activates a process killer that can be invoked by CTRL-left-clicking on the Warpcenter window list symbol. After selecting a process to kill you will be presented with a dialog asking for confirmation. This security dialog can be turned off with SET SCKILLCONFIRMDISABLED=ON. Note that this process killer is no viable replacement for WatchCat.

   SET SCUSEPRETTYCLOCK=ON 

replaces the normal Warpcenter clock with one that has a digital display.

   SET SCFINDUTILITY=progname 

replaces the built-in search facility with a program of your choice.

Warp'n'Go

This nice utility for changing CONFIG.SYS with help for the lot of possibilities normally refuses to run under Warp 4 saying that it only supports OS/2 2.30 (internal code for Warp 3). Now what? Well, OS/2 has the ability to fake its version number for certain programs. To setup this feature you need to edit the file OS2VER which resides in the root directory of your boot drive and has the hidden and read-only attributes set. Add two lines 23=warpngo.exe and 23=warpngo.dll (don't forget to terminate the lines with a CR). If you want to install Warp'n'go using the install program, you'll have to temporarily add 23=install.exe. But this doesn't do anything but copy the files and create a WPS object.

Well, from what I've seen of the developer release 0.9.1 of XWorkplace (the successor of XFolder), Warp'n'Go will be superfluous pretty soon.

Win32s

This is another source of lots of misunderstandings. Warp 3 and 4 support Win32s up to version 1.25a. However that doesn't mean that OS/2 comes with Win32s. So you have to get the package yourself, e.g. from Hobbes or LEO. The version 1.25a on LEO does not contain OLE.

Some general notes on installing and using any Win32s version with OS/2:

  • Make sure to comment out or remove any reference to a "real" Windows (3.1x, 9x or NT) on your system, especially in your PATH statement in AUTOEXEC.BAT before installing the package.
  • For all programs using Win32s the setting WIN_RUN_MODE set to Enhanced compatibility is mandatory.
  • You may need to enlarge the DOS_FILES setting as high as 255.
  • If a program still crashes try to adjust DPMI_MEMORY_LIMIT. In this case adjusting can also mean lowering the setting.
  • Some programs will only run in a Win-OS/2 fullscreen session.

Now what if you want to use a program that claims to need Win32s 1.30? Well, chances are good that this claim is not true and it will run with 1.25a. If it doesn't you can still do the following:

  • Get Win32s 1.30c from LEO or (yuck!) M$.
  • Install 1.30c from a Win-OS/2 fullscreen session.
  • Backup your WIN32S.INI file.
  • Install 1.25a over 1.30c. If it complains about a newer version delete WIN32S.INI before starting the installation.
  • Replace the WIN32S.INI with the one from 1.30c.

This will leave you with a 1.25a/1.30c-Hybrid with all the files from version 1.25a and the additional files from version 1.30c. There will still be some programs that really need the additional functoinality of 1.30, but they're few.