My Fundamental Misunderstanding of Google Cloud/Compute Engine

0

So my goal is to be able to run some programs/applications on remote computer (windows), all day long. So I created a Google Compute Engine VM Instance, win server 2008 R2 (desktop), with 1 CPU and no GPU.

But these programs need a windows os with 32-bit color depth (the current setting on the VM is 16-bit) and windows 2008 does not allow me to change graphics settings via remote desktop connection. So I tried teamviewer to get around this, but the VM instance doesn't seem to even be graphically active unless RDP is used (the screen appears black in teamviewer)? Teamviewer says the vm is 'probably a minimized remote desktop session'. This is worrying as I need the graphics of the vm-instance to be always up and running like a normal computer, not just activated when RDP is used. So it seems like I'm misunderstanding something here. Basically, teamviewer needs to work at least. Is there a way to do this?

minusatwelfth

Posted 2017-08-18T14:47:42.377

Reputation: 203

Why not add a GPU to the VM? – I say Reinstate Monica – 2017-08-18T14:57:42.200

3Cloud VMs don't have any displays connected, so unless RDP session creates a virtual screen, there are no screens on that machine. – gronostaj – 2017-08-18T14:59:09.763

but the pixels should still exist... in the chips. Teamviewer should still work. Just imagine accessing a computer with the monitor turned off – minusatwelfth – 2017-08-18T15:22:30.230

Answers

1

Depending on how you are "closing" your remote session this page on smartbear suggests that rather than logging out of the RDP session you want to use tscon to disconnect your session from the remote instance without logging it out.

To avoid problems with GUI tests, use the tscon utility to disconnect from Remote Desktop. tscon returns the control to the original local session on the remote computer, bypassing the logon screen. All programs on the remote computer continue running normally, including GUI tests.

To disconnect from Remote Desktop, run the following command on the remote computer (in the Remote Desktop window) as an Administrator:

%windir%\System32\tscon.exe RDP-Tcp#NNN /dest:console

where RDP-Tcp#NNN is the ID of your current Remote Desktop session, for example, RDP-Tcp#0. You can see it in the Windows Task Manager on the Users tab, in the Session column.

They even give you a batch file to automatically disconnect your session:

Create a batch file with this code:

for /f "skip=1 tokens=3" %%s in ('query user %USERNAME%') do (
  %windir%\System32\tscon.exe %%s /dest:console
)
Rundll32.exe user32.dll, LockWorkStation

Mokubai

Posted 2017-08-18T14:47:42.377

Reputation: 64 434

Thanks, I will try this. But I don't think it solves the 16-bit color depth issue. If I log in with RDP and teamviewer at the same time, I'm still not able to change display settings – minusatwelfth – 2017-08-19T00:36:45.973

Reporting back. Ok I ran into 2 issues. The 'Run as administrator' box was greyed out in the batch file's properties, so I right-clicked the .bat and 'Run as administrator'. Team viewer could not even establish a connection this time. However if I sign in with RDP, then teamviewer works normally if I run both simultaneously. – minusatwelfth – 2017-08-19T01:10:45.260

@user2978584 you should be able to change the display settings in the rdp program before you connect to the remote machine. – Mokubai – 2017-08-19T06:09:24.077