Saturday, January 2, 2016

TightVNC - Connection has been gracefully closed

TightVNC - Connection has been gracefully closed
I had a cascade of problems come up and it took me an embarrassingly long time to figure it all out.

A recently installed game was not launching correctly and I traced the problem down to some outdated graphics adapter drivers. I installed the latest from AMD and suddenly TightVNC (server on the system with the game on it) would no longer allow me to connect to it from my other computers. It would prompt for a password and then say, "Connection has been gracefully closed."

I tried restarting the VNC service, rebooting, reinstalling TightVNC... Nothing worked.

The TighVNC server logs kept coming up with:
Desktop server application failed with error: The desktop server time out expired
write() function stopped because transport has not been initialized yet.
AnonymousPipe::read() failed (m_hRead = 0000000000000370)
The Pipe's read function failed after ReadFile calling (The pipe has been ended. (109))
Exception during DesktopClientImpl creaion: 
Error during RFB initialization: 
Connection will be closed: 

There was very little information of this sort of problem out there. At least that I could find and that matched the log output.

I looked through what exactly AMD bundled with the driver update and one interesting item had to do with .Net. On a hunch, I check my Windows updates and found that I didn't have SP1 installed. The reason being that I never got around to fixing having the correct partition marked as active. Once I fixed that, installed SP1, and rebooted I was back in business.

Hopefully no one will ever need this information, but if you do I hope I have saved you some headaches.

If you happen to have the issues with installing SP1 on Win 7 with error code: 800F0A12...
Click Start (Windows logo).
Type "CMD"
Right click the CMD search result and select Run as administrator.
Enter "diskpart" into the command prompt.
Assuming you have a fairly default installation, once DiskPart is running, enter "select disk 0"
Enter "list partition"
You should get a couple partitions listed with one being about 100MB (NOT GB). It will probably be partition 1 and so I will use it in my instructions.
Enter "select partition 1"
Enter "active"
Enter "exit"
Now reboot your PC. Once Windows comes back up, retry installing SP1.