Set Windows Server 2012 default screen resolution (VM Ware)

6

2

I need to set (default) screen resolution to Win Server 2012 hosted in VMWare vcentrum 5.5.0. It is a dedicated server for running automatic GUI tests for Windows applications by Jenkins. When connected from Jenkins, it has the screen resolution of 1024x768. I need higher, at least 1024px height.

What i tried so far:

Run setres.exe from Jenkins

c:\windows\system32\setres.exe -w 1280 -h 1024

result: The settings passed in could not be applied to the graphics device.

Add the following lines to the vmx file

svga.autodetect = "FALSE" 
svga.vramSize = "20971520" 
svga.maxWidth = "1920" 
svga.maxHeight = "1080" 

result: setres.exe -i still returns 1024x768

Use Win API functions: ChangeDisplaySettings, EnumDisplaySettings

I wrote a C# utility which worked correctly on WS2003 (run from Jenkins) & Win7 (run locally), but on WS2012 run from Jenkins EnumDisplaySettings returns:

Supported Modes:
1024 by 768, 32 bit, 60 hertz
1280 by 1024, 32 bit, 60 hertz
1920 by 1080, 32 bit, 60 hertz
...shortened

However ChangeDisplaySettings returns

-1  : dislplay change failed

Alter registry:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Video\{A8405CA4-B9D8-4123-B809-D912D3B666DC}\0000

enter image description here

result: none and after Jenkins connects, it sets the keys VidPNSource0Width & Height back to 1024x768

Any ideas?

Edit: VM hardware settings enter image description here

Ondrej Sotolar

Posted 2014-10-02T11:33:32.730

Reputation: 143

Is there any Video card connected?. What cable you are using VGA/HDMI/DVI?. – Renju Chandran chingath – 2014-10-06T16:34:29.143

No, its a virtual machine. No cables. – Ondrej Sotolar – 2014-10-07T05:41:55.217

Oh sorry. My bad. I misread VMWare vcentrum. – Renju Chandran chingath – 2014-10-07T12:07:33.663

Answers

1

  • Make sure VMTools is installed on the virtual machine
  • Shut down the virtual machine
  • Go to Edit Settings for the machine
  • Select the video card
  • Increase the Total video memory to about 64 MB

That should provide you with a wide array of possible resolutions

GapWim

Posted 2014-10-02T11:33:32.730

Reputation: 158

0

Within the VM client settings just go to graphic cards adapter, "List all modes", choose a mode, click OK and click OK again.

DarkEvE

Posted 2014-10-02T11:33:32.730

Reputation: 377

I have no such settings there. Please see the screenshot at the bottom of the question. – Ondrej Sotolar – 2014-10-07T11:53:55.430

ahh right sorry, well then judging by the software I would suggest this page http://www.tomshardware.co.uk/faq/id-1820753/vmware-virtual-machine-incorrect-display-resolution.html

– DarkEvE – 2014-10-07T12:19:46.507

0

Try MultiRes - maybe it would succeed where setres failed.

Jonathan

Posted 2014-10-02T11:33:32.730

Reputation: 2 294