Anyone who knows me, knows I am very keen on Network / Server Based Computing. As a part of my daytime lila I run a small Windows Terminal Server ‘farm’ that supports 300 remote desktop sessions across 40 branches in a 2500km radius. It’s not completely without it’s faults but it’s pretty damn good.
The more I used Linux, the more I wanted a similar solution to RDP. Anyone who ever advocated VNC as a replacement for RDP really just, well they didn’t quite have a clue. Winvnc, tightvnc etc, etc.. none of them come close in regards to screen rendering quality vs speed. The desktop experience isn’t the same. I then realised X can be used for full desktop via XDM and there was even a Win32 client… but had you ever tried to use it over a WAN? ha..
I’ve been a packet sniffer since way back. My first attempt at ever networking 2 computers together caused me days of grief and hair pulling and led me to realise there was such a thing as a Packet Sniffer which could tell you what was going back and forth on the wire – who was saying what.
Anyway, along comes the NX protocol / software client and server by Nomachine. I mean, this is some cool shit that kicks some serious butt on RDP. In essence it is the X server protocol that is compressed and proxied between the server and the client. On full 16bit colour, full screen across a 512/512 ADSL link it is VERY MUCH like sitting at your own desktop. Try scrolling on a website on the same link with RDP and you will be in for sit and wait.. hit a page with some flash animations on RDP and you’re gonna suffer a little. Nomachine’s NX flies through it all almost seamlessly.
But here comes the rant. In the morning’s when I arrive to work, I connect home via NX and maybe 90% of the day, the connection sits there doing nothing. At the end of the month, my internet usage at work shows me as using some 3gb of data download (2gb of this is NX traffic). This isn’t good as it makes my boss think that I am surfing the net all day (I have the necessary privilege of bypassing the proxy) and we pay big $$ for overages on our Fiber.
So, I sought to find out what the deal was and realised that whilst idle and no screen changes on the remote machine, NX is passing 3-5KB/s (3000-5000 bytes) of traffic inbound. Outbound is neglible, so it’s not an issue. Compare this with RDP, which passes between (6-200 bytes) and you can see the issue here. Now, I have read other people who are seeing 500bytes going across the wire using NX but I can’t replicate that myself (I am using NX Client 2.1.0-6). I am NOT using SMB mounting or Multimedia Support and I still can’t get below this 3000 byte figure. In a business scenario, this traffic usage would grow pretty significantly. ie: 5KB/s x 40 clients = 200KB/s or a 1.5Mb ADSL line maxxed out because of IDLE clients.
Initially, I setup pyshaper on the server side and enable it to shape traffic to 800 bytes before I minimize the NX client, but then it would be a slow process when I would want to access the session again, I have to wait for the delay on re-enabling it. Pyshaper relies on some Linux tools to do it’s job, so it’s not portable to Windows (my desktop at work). So, I have started playing with Netlimiter Pro, which gives me the ability from the Windows Client side to quickly enable and disable traffic shaping on the NX client… not only the NX client but the individual data connection – so if I have an NX connection internally here at work, it will not be affected by the traffic shaping.
I have had a quick hunt around to find a quick way to hook into the NX client in Windows, detect when it is out of focus and automatically shape the traffic. I haven’t found anything as yet and not being a coding guru, I don’t think I will achieve it anytime soon. So, I will sit and hang out with my Netlimiter Pro until the Nomachine guys (who are extremely cool, regardless of my rant) consider implementing this feature.
This also led me to learn more about SSH compression, which deserves it’s own post. For the time being, if you want to use it Putty has it as an option or from bash: ssh -c user@hostname
Technorati Tags: nomachine, freenx, rdp, remote desktop, traffic shaping
Have you tried connecting to home from a linux box at work? Does the platform to platform have any affect on the traffic I mean?
Here’s something which annoys me: on Windows XP, open a pdf document with Acrobat, and also open Task Manager. Click and drag with the hand to scroll through the pdf document and the CPU usage will flicker. Now, try holding the mouse button down. Does your CPU usage jump to a ridiculous level and stay there until you release it? My CPU fan goes crazy when I do that. Haha!
JC