This method is usually quite fast and allows you to scroll around a large virtual desktop. It assumes that you are using a Unix-based terminal. If you are using X11 remotely from a non-Unix terminal then see below.
patch x11vnc/x11vnc.c x11vnc.diff CPPFLAGS=-DBIG_CURSOR make -einstead of make. Newer versions have this functionality integrated and you can use (e.g.) -scale_cursor 4:nb on the x11vnc command line.
xvncviewerbinary and its
libvncauth.so.0library from another distribution, in which case don't forget to add the library's directory to
vncserver :2 -geometry 1052x864 -depth 16
killall Xvnc Xrealvnc Xtightvnc); this first run was only to create the initial
.vnc/xstartupfile and does not need to be done every time.
.vnc/xstartupfile and add the line:
x11vnc -display :2 -rfbport 5903 -forever -scale 2:nb &where the 2 after the
-scaleis the scale factor you want (the
:nbmeans avoid blurring, which gives a clearer image when using integer scale factors).
-scale_cursor 4:nbto the above command line (the 4 is how much you want the mouse cursor to scale in relation to the unmagnified screen).
xvncviewer -fullscreen :3
killall Xvnc Xrealvnc Xtightvnc.
.vnc/xstartupfile before starting the server again.
.xsessionand avoid running a window manager outside the VNC client, so that all your keypresses reach the window manager on the VNC server (but remember to add a
sleep 2to let the server start before running the viewer).
Option: "backingstore"added to the
XF86Configand restart the X server. This will improve the responsiveness of scrolling around the desktop. (If it takes time to repaint the screen when you scroll then that means backingstore has not been enabled properly.)
vncserver :2 -geometry 640x480 -depth 16The geometry (in the above example, 640x480) should be at most half of your screen's resolution, so if your resolution is 1280x1024 then your maximum geometry is 640x512. (If you want to magnify three times, choose one third instead of half, and so on.) Any larger and you will have to scroll around the desktop using scrollbars, which can be awkward.
wine vncviewer.exe(or run it natively under Windows) and a small dialogue box should appear. In Wine it is possible that the text in the dialogue box will not display; don't worry about this.
localhost:2for the above example. Now press the button on the bottom right to bring up the Settings dialogue. Find the check box that has two small text boxes immediately to the right of it, and check it. Double click on the first text box to the right of it and type 2 (the magnification factor). Press Enter, then click the top button.
killall Xvnc Xrealvnc.
.xsessionand avoid running a window manager outside the VNC client, so that all your keypresses reach the window manager on the VNC server. This is especially the case because you will be doing a lot of keyboard navigation due to the lack of being able to drag around the desktop. (Choose a window manager with many shortcuts, e.g. FVWM2, to run on the VNC server.)
If your local machine is Windows then setting up an off-display VNC server can be difficult. But if you have administrative access to the system then (if the system won't run Linux) you might be able to install CoLinux:
colinux-daemon.exe kernel=vmlinux cobd0=root_fs root=/dev/cobd0 \ hda1=:cobd0 eth0=tuntap,"Local Area Connection 9" mem=512 -t nt(you may want to put that in a batch file.) The initial root password is "root", and you'll have to type in qwerty regardless of your keyboard map; however you can do "loadkeys dvorak" once logged in, if you want to type Dvorak or any other layout. (To shut down the virtual Linux system, just give it a
nano /etc/apt/apt.conf.d/70debconf) and add the following lines:
APT::Cache-Limit 12582912; APT::Force-LoopBreak true;then save and exit, and do
apt-get update(it may give some 404 errors which can be ignored as long as the main mirrors respond OK).
apt-getcommand goes wrong, try this:
echo '#!/bin/bash' > /usr/sbin/update-rc.d chmod +x /usr/sbin/update-rc.d apt-get -f installand then repeat the
vncserverpackage; be sure to get the fonts packages also. Put
.Xsessionif appropriate, see note above), then add the above
x11vnccommand before it (if you're using x11vnc for the magnification, which is the recommended method). If your Windows VNC client is TightVNC then you may need to add
-rfbauth ~/.vnc/passwdto the x11vnc command line because some versions of TightVNC will hang if the server doesn't need authentication. If the NX server is on a VPN then you may find that coLinux can't see this VPN, so you'll need to set up an SSH tunnel and tell nxclient to connect to that instead, and
.vnc/xstartupmay be a good place to put the appropriate ssh command; if you've set up an RSA identity then you should just need something like
ssh -N -l userID -L localhost:8222:nx-host:22 ssh-relay-host &(you may also want to include an
xsetroot -solid darkbluecommand so you don't have to look at a checkered background if the connection is delayed).
Finally, start the VNC server by using a command such as
vncserver :2 -geometry 480x300 -depth 16You may wish to add an
echocommand after that, reminding you to connect the VNC client to the IP address of the coLinux machine, display 3.
If your VNC client does not support bump scrolling, then the geometry
should be half the screen's resolution (assuming the magnification factor is
2 as it is in the above
x11vnc command). This may lead to a
very restrictive display. If nxclient says "press Next to continue"
but the Next button is off-screen, you can just press Enter, but once you're
on the remote desktop, you may find that some applications give you dialogue
boxes that are too big for the screen. If your VNC client supports
then you can multiply this reduced geometry by between 1.6 and 1.8 (i.e.
make it 80-90% of the screen's resolution if the magnification factor is 2)
and then you'll be able to pan around a virtual desktop. (You probably
don't want to make the virtual desktop any larger than 1.6-1.8 times the
screen size, otherwise you may ``get lost'' since even a full-screen window
can disappear too easily.)
TightVNC 1.3.9 under Windows supports bump scrolling in full-screen mode, but it's so fast that you'll probably only be able to position the display on a corner. If you need a more steady scrolling speed, try RealVNC Free Edition 4.1's full-screen mode (you might want to turn off 'Render Cursor Locally' in the RealVNC Options, because x11vnc displays one). I find that neither of these options are as good as bump scrolling in real X11. You might want to have two configurations, one with a small geometry for normal use and another with a larger geometry for when you need to configure applications that have large dialogue boxes; you will however have to re-login to the remote machine each time you change between these configurations.