Jerry Westrick wrote:
On Saturday 06 November 2004 03:13, Zvone Zagar wrote:
Hello,
I am breaking my head all day long with the following problem. I use Openvpn to connect my private network to office network. At the remote side I have an ADSL 4096/768 and at home ADSL 1024/256 connection. Everything works just fine except that it takes nearly 40s to run Mozilla on remote PC (ssh -X -C user@server). SuSE 9.0 is installed on server side and Mozilla is upgraded to 1.7.2 via SuSE rpms. Well, I would't be surprised if I had not installed Netscape 7.2. It takes cca. 8 seconds for Netscape to load. OpenOffice (1.1.3) loads in less than 10 seconds. I tried FireFox 1.0 PR from www.mozilla.org. It is not any better than Mozilla. Konqueror needs almost 20 seconds to get loaded.
Why is the Netscape so fast compared to Mozilla. If I run both programs remotely at the office, than is Nescape faster about 30 %.
As I said all other programs run pretty fast. I just started Gimp 1.3 and it took less than 20 seconds.
Any clue ?
Regards Zvone Zagar
This effect is known. The short: Network latency (ie the time it takes for a package to make a round trip.) The long: X-Windows consists of a lot of calls, done sequentially. When you do X-Windows remote the program not only has to wait for the server to execute the command, it has to wait for the command to get there, and for the responce to get back. Multiply this "roundtrip" time by several thousands and you get your 40s.
That is why some programs react badly while others seam not to be affected. It just depends on the number of calls they make to draw the windows!
The worse case is usually drag and drop, when the mouse cursor is drawn by the program with micky (the official name of a mouse tick). When this is done like this you end up with a latency hit for each micky and it becomes unusable. fwbuilder V1. is a program where the drag and drop fails remotetly. (I haven't tried version 2 remotely yet.).
Basically you have 4 other solutions which you can use:
1) NX. NX is an extended version of the X-Windows protocol highly optimized and compressed. It is included on the SuSE 9.2 CD's. There is a GPL version on the SuSE ftp server for 9.1. It is supposed to work wonders in exactly your situation. I've only tried it on a LAN so I cannot speak from experience.
2) Run VNC. The VNCServer sets up a local X-Windows in the remote machine's memory. X-Windows then draws upon that (without any latency problems). The vncserver then sends the drawn pixels to the vncviewer running locally on your machine. The bitmaps are compressed and optimized in several ways. This method also gives you better results with latency sensitive programs. An interesting advantage to this method is that you can run the vncviewer on windows or on a mac, and work on your linux server. (or visa-versa)... vnc is standard installed by default on SuSE installations in both 9.1 and 9.2. SuSE even provides a windows version of vncviewer on the cd's for your convenience.
3) the third method is rather new. It consists of avoiding running the programs remote, instead accessing the files remote. Here you can start a konqueror on your local machine, access the remote machine via SSH by using the URL "fish://servername" (or IP address). After filling in the login prompt, you get a directory listing of the home directory of the signed on user on the remote machine. Now you can open an openoffice file by double clicking on it, or start an editor by right mouse clicking on a file and selecting "open with". Konqueror will then download the selected file to a temporary file on your local machine, and let you edit it. As soon as you are finished editing, konqueror then copies the updated temporary file back. (BTW, the same can be done with windows machines by using the URL "smb://windowsmachine/sharename").
4) and last but not least, you can mount the remote filesystem locally (via NFS or any other network file system) and use your local programs.
Each method has it's advantages and disadvantages... pick your poison. Or do as I do and use all of them switching and choosing as the situation arises.
Jerry
Hi, Thanks for the profound explanation. In the meanwhile I 'discovered' the following issue. I have set up another PC with Debian Sarge. By chance I have started Gnome. ( I regularly use WindowMaker, KDE, Icewm). To my great surprise, Mozilla was up and running in cca. 11 seconds. I have repeated the same procedure with Icewm - the result 20 s. Then I did 'about:buildconfig' in both Mozilla and Netscape and found that Mozilla was build with many many more options. I see that I must deepen my knowledge every day (Nothing new). Well, I must explain you some other points. The latency of Mozilla over my openvpn LAN is not the biggest problem. At the office I have setup a fairly decent PC (2 GB of RAM, Celeron 2.6 GHz, software RAID-1 with Promise IDE 133 controller, SuSE 9.0). Clients are very very old PCs (Pentium 233 MHz, 64 MB RAM, 2 Gb HD, SuSE 9.0, WindowMaker - in the future also Icewm). Clients run almost all applications on server. Some clients work as print servers (LPRng, samba). Access to Internet is done using clients (FireFox). Up to the present time 10 ten users have been migrated from MS stuff. I plan 5 more users (so 15 or even more on one Celeron). The server has been running almost 60 days (I have only killed a few processes). If everything will go as planned, two more servers will be set up. Here comes my question regarding VNC. Would be possible to use such a solution instead of ssh (-X -C). SuSE 9.2 is not yet arrived to our dealer. With SuSE 9.1 I have some glitches. Nevertheless SuSE 9.0 (Debian is an alternative) is going to stay on clients. Maybe some numbers regarding speed: - OpenOffice 1.1.x is started in cca. 3 - 5 seconds - Mozilla needs up to 7s. <--- - Netscape 7.x up to 4s. <--- - Konqueror up to 5s. I have many questions, but at first I must try to solve them myself. If there will be too many unsolved issues I will be heared in this marvellous list. Your 3rd solution I am going to try with standalone Linux workstations. I have almost 30 users running SuSE 8.2 and 9.0 (a few of them even 8.0) I tried it from my private LAN and it worked (in SuSE, Konqueror in Debian Sarge - despite of proper File Associations - does not open OO. For the moment I do not care) Many thanks Zvone Z. I