Please do not link directly to this page. This page has been temporarily broken apart from the magazine to reduce bandwidth. In a couple months this article will be merged with the magazine. Instead please link to the following url: http://www.troubleshooters.com/tpromag/200006/200006.htm#_vnc |
[ Back to the June 2000 Troubleshooting Professional Magazine ]
The trouble is, most physical office environments don't have enough room for two ergonomically comfortable workstations. It's seldom feasible to buy large, high resolution, quality monitors for both a Windows box and a Linux box. These factors make it difficult to effect a gradual transition. The ideal solution would have you accessing both Linux and Windows with a single monitor, keyboard and mouse. The two most common ways to do this are VMware and VNC.
VMware is an incredibly clever layer below the operating system allowing one computer to operate two or more distinct operating systems simultaneously. For all practical purposes, VMWare exposes two completely separate and independent computers that just happen to share common ports, including monitor, keyboard, mouse, modem, NIC, serial ports, printer ports, usb ports, etc. As far as I know, the NIC's can use different IP addresses.
But I'm not writing about VMWare today. Running two complete OS's on one box, and slicing between them, requires immense memory and CPU resources. Your mileage may vary, but for my business I'd rather devote every one of my Linux desktop's 512Meg of Ram and dual Celerons (Windows98 can't even use dual processors) to my Linux apps. My Linux desktop can run 20 simultaneous apps in memory, and still have plenty of RAM to cache just about all files used. It's quick.
So I use VNC to access my Windows box from my Linux box. VNC is an Open Source product similar to the Windows world's PC Anywhere. You run a VNC server on the Windows box, then fire up vncviewer on your Linux box (in GUI mode), and you get your entire Windows desktop in a Window on your Linux box. From there you can operate the machine exactly as you would from the Windows machine's keyboard and monitor. Thus you can have your Windows box off in a corner, either with a dinky cheapo monitor, or even headless, and still access your favorite Windows apps when needed. I've found that with my LAN 100mb Ethernet, I can VNC to my Windows box, run Word on a Samba-available file on my Linux box, and there's plenty of bandwidth to spare.
VNC is the ideal transition tool because once the need for Windows disappears, you simply stop using it (to connect to Windows, that is). With VMware, after leaving Windows for good you'd need to either accept VMware's resource tax, or remove VMware from the box.
Many Linux distros come with the vnc server and vncviewer already installed. Mandrake certainly does. This is a good thing, because VNC is difficult to compile from source. If you don't have a preinstalled VNC for your Linux box and you can't get the source at http://www.uk.research.att.com/vnc/index.html to compile, go for an RPM or binary.
The Windows binaries for VNC are downloadable at http://www.uk.research.att.com/vnc/download.html under the "Binary packages" section, simply check the "Windows 9x/2000/NT (Intel Win32)" checkbox and continue. Check Tucows.Com's Linux section for RPM's, or check rpmfind.com.
Installing on the Windows box is a little tricky, so follow my instructions. Your Windows vnc file will be called somthing like vnc-3_3_3r6_x86_win32.zip. Unzip it into a temporary directory, because it unzips into installer files rather than the actual software. I unzipped it into L:\temp. It unzips into a tree like this below your chosen directory (L:\temp in my case):
vnc_x86_win32 | |---vncviewer `---winvncThe vncviewer directory contains only vncviewer.exe. The installation is done by running setup.exe in the winvnc directory. It's a typical Windows/Installshield installation. You know you're in heaven when you're greeted by the Software License Agreement and you see "The VNC system is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License...". Now *thats* the kind of shrink wrap license this UCITA hating boy can get used to. The next screen asks you for the software's destination directory, defaulting to C:\Program Files\ORL\VNC. I personally don't like that "program files" stuff, so I changed it to G:\vnc, and it worked perfectly. It asks you for a startmenu folder, and I kept the default VNC. When you proceed from that point, the files are copied and at last you're greeted with the following prompt: "To use the VNC server you should either add a link to theStartup Group, or run "winvnc -install" to install VNC as a service."
I recommend the latter. With VNC installed as a service, the VNC server
(winvnc.exe) is run *before* logon, so you can run your Windows box headless.
The VNC icon (
) should appear in your system tray.
Unless you have a reason to do otherwise, fill it out as shown above. The password is the password the person operating vncviewer must type to access the box from VNC. The disable keyboard and pointer check boxes are primarily for teaching situations where you don't want two people moving the mouse at the same time (mouse wars) or operating the keyboards at the same time (keyboard wars). I amazed my 7 year old triplets with VNC, followed by a keyboard war between myself and my son. But I digress...
Notice that I've checked Poll Full Screen. That slows the display on the viewer screen, so why in the world did I do that? Simple. If you do not do that, rubberbanding functions (you know, drawing a select box on screen) fail miserable in poorly written Windows apps (and of course most Windows apps are poorly written). So if you encounter situations where selection boxes are not visible as you draw them or after you've completed your drag, or if mouse movements leave artifacts on the screen, immediately see if you've checked Poll Full Screen, and if not check it.
You create such a link by right clicking your KDE desktop and choosing
new and then application from the popup menu. You'll then get the initial
Kdelnk screen, which looks like this:
Simply change the name Program to something more descriptive, such as winboxvnc, for instance. Leave the .kdelnk alone. Once you click OK you'll get to the kdelnk properties dialog box, which can later be accessed by right clicking the desktop icon and choosing properties.
The dialog box has four tabs: General, Permissions, Execute and Application, as shown below:
The General tab is where you define the name of the kdelnk file, and not much more.
The Permissions tab is where you define the permissions and ownership
for the link. Who can use it, who can write it, and does it get any special
priveleges like Set UID.
The Execute tab is where the rubber meets the road. Here you define
the command to be executed upon clicking the kdelnk, and the icon. See
the command I placed in the Execute text box? Replace the string wincli
with the name of your Windows box. Other than that, the command remains
the same, always assuming that your copy of vncviewer indeed resides in
the /usr/bin directory. To pick the icon, click the button below the browse
button and choose an icon from the multitudes displayed. Note that the
Run in terminal box is checked. This gives you a place to type in the required
password, rather than placing it insecurely in the kdelnk itself.
The Application tab should look like what's shown below.
It's quite easy to copy a completed desktop icon to the menu by simply dragging it and dropping it on the start button (which is a graphical K in KDE). Once that's done, you can use the Menu editor (start:Utilities:more:Menu Editor). Click here to see an image showing how to access the menu editor.
You asked for it, you got it. Press the F8 button on the keyboard and the following popup menu appears:
Clicking on the Full screen choice toggles between Windows in a Window and Windows full screen. That's how you can toggle between Linux and Windows, using Windows (almost) exactly as you would on a genuine Windows box. The preceding menu has several other interesting features such as the Clipboard: local->remote and Clipboard: local<-remote, which allow copying too and from each OS. Think this might be handy in tech writing?
The Send ctrl-alt-del is a way of sending the three finger reboot signal to the Windows side without risking rebooting your Linux box. Send F8 allows you to use the F8 key in Windows. You can also use two F8 presses in a row to accomplish that.