Preserve vm window size

Discussion in 'Linux Virtual Machine' started by OlegV, Mar 6, 2012.

  1. OlegV

    OlegV Member

    Messages:
    24
    This might be something trivial but I can't figure for the life of mine. How do I force Parallels to remember window position and size (and hence guest resolution) for Linux guests? It does it automatically for Windows guests, either XP or W7. But Linux guests are always reverted to 1024x768 or something at startup. Any ideas?
     
  2. dpickett

    dpickett Member

    Messages:
    64
    Set up the xorg.conf file with your desired resolution.
     
  3. OlegV

    OlegV Member

    Messages:
    24
    Hi pdickett,

    thank you for the reply. Will this remember the VM window position too? Regardless, could you please provide more details or yet better copy/paste the corresponding snippet from your xorg.conf? I'm running Ubuntu 10.4LTS 32bit if that matters.
     
  4. dpickett

    dpickett Member

    Messages:
    64
    xorg.conf is located at /etc/X11/xorg.conf.

    Mine looks like this:
    Code:
    #
    # X.Org server configuration file generated by Parallels Guest Tools.
    #
    
    # Parallels Video section
    Section "Device"
    	Identifier	"Parallels Video"
    	Driver	"prlvideo"
    EndSection
    
    # Parallels Monitor section
    Section "Monitor"
    	Identifier	"Parallels Monitor"
    	VendorName	"Parallels Inc."
    	ModelName	"Parallels Monitor"
    EndSection
    
    # Parallels Screen section
    Section "Screen"
    	Identifier	"Parallels Screen"
    	Device	"Parallels Video"
    	Monitor	"Parallels Monitor"
    	Option	"NoMTRR"
    	SubSection	"Display"
    		Depth	24
    		Modes	"1920x1080"
    	EndSubSection
    EndSection
    
    # DefaultFlags section
    Section "ServerFlags"
    	Option	"AllowEmptyInput"	"yes"
    	Option	"AutoAddDevices"	"yes"
    EndSection
    
    # DefaultLayout section
    Section "ServerLayout"
    	Identifier	"DefaultLayout"
    	Screen	"Parallels Screen"
    EndSection
    
    The part you're interested in is Section "Screen", SubSection "Display", line "Modes". Put your desired resolution on that line. Mine, as you can see, is 1920x1080. Save the file, log out, log back in and see if that helps.
     
  5. OlegV

    OlegV Member

    Messages:
    24
    This doesn't work for me for whatever reason. My config is basically identical, the only difference was Modes set to "1024x768". I changed it to "1920x1123" which is the resolution I want. This is the resolution you get when clicking "+" to expand VM's window on a 1920x1200 screen.

    Now whenever I log in it goes to approx 1800x1123 (yes, leaving about 100px empty space on the right) for a short second and then automatically reverts back to 1024x768.

    Ideas?
     
  6. dpickett

    dpickett Member

    Messages:
    64
    Is your OS X dock on the right hand side?
     
  7. OlegV

    OlegV Member

    Messages:
    24
    Dock is at the bottom in autohide mode (mouse hover to show). I've just tried playing with the dock position and options and it appears to not affect X behaviour inside Ubuntu Guest.

    It looks like something is preventing X to go into resolution specified in xorg.conf at startup. It is trying to switch to that resolution because VM window is expanding to somewhat much bigger than the default 1024x768. But only to reset back to 1024x768 in less than a second time.

    I wonder could be because the time xorg.conf setting is applied parallels tools services are not running yet or something like this?

    Manually clicking "+" to expand the VM window brings it back to desired 1800x1123...
     
  8. dpickett

    dpickett Member

    Messages:
    64
    Why are you trying to set the window to that particular size? Have you tried it full screen?
     
  9. OlegV

    OlegV Member

    Messages:
    24
    Because I want to have permanent access to menu & dock bars while I'm in VM. I just want the damn app to remember window position/size for linux in the same exactly way it does for any other guest, not to change my workflow.
     
  10. dpickett

    dpickett Member

    Messages:
    64
    You are asking X to draw to a strange size. Have you tried setting it to a standard resolution, like 1280 x 960?
     
  11. OlegV

    OlegV Member

    Messages:
    24
    Haven't tried standard resolutions in config but there is no difference for me whether it is the default 1024x768 or 1280x960 as you suggest. I still will need to maximize VM window to get the desired 1800x1123.

    I don't think the problem is with X not liking 1800x1123. It is quite happy with this or any other non-standard resolution when you are resizing VM window, isn't it?
     
  12. dpickett

    dpickett Member

    Messages:
    64
    From what I understand, the issue is that your Linux guest window won't remember the size you want it to. My question is whether the issue is you're asking X to default to a non-standard resolution. If you set the resolution to 1280 x 960, and your Linux guest remembers that on restart, then the issue is likely with limitations in X and not Parallels. This is why I suggested you set it to a standard monitor resolution and see if that helps.

    I think I remember having issues with nonstandard resolutions before, but I've been running my Linux guest at full screen for so long I don't really remember.
     
  13. trixie

    trixie Junior Member

    Messages:
    12
    Has anyone found a resolution to this problem yet? Parallels keeps changing the screen size out from under me every time I do anything to the window or go in/out of full screen mode. What I want is for the guest OS to ****PERMANENTLY **** remain in 1280x1024 mode. But it simply won't stick. For instance, when the Displays system settings of Fedora 16 is open, the Resolution keeps changing when I resize my Parallels Desktop window -- to crazy numbers like 904x656, etc. I'd rather just have scroll bars appear for those cases when the guest OS window dimensions exceed the size of the Parallels Desktop window. I seem to remember that this used to work in v5 of Parallels, along with downsampling. Are those options totally gone?

    Here's the snippet of my xorg.conf file relevant to the screen:

     

Share This Page