# xrdp: How to define monitor resolution? {Solved}

## keivan

I'm a xRDP user. I have configured my xRDP using this tutorial.

Everything work fine and I am able to connect to my Linux workstation using windows 7 RDP client (My laptop). xRDP startx to kde.

My MOST important problem is that: 

Monitor of my laptop has native resolution of 1280*800. When I remote destop to kde, I see kde in a different (smaller) resolution. Is there a way to define screen resolution for xRDP or TigerVNC?Last edited by keivan on Fri Dec 30, 2011 8:25 am; edited 1 time in total

----------

## Hu

You can instruct a VNC server to use a particular geometry when you start it.  However, unless it supports RandR, you cannot change it after it is running.

----------

## keivan

Please Tell me how to do that.

----------

## Hu

Aftering reading the first page of the fine manual, it looks like the -geometry option will do what you want.

----------

## keivan

I tried to find the manual of tigervnc but I can't find it. I tried

```
man tigervnc
```

where is the manual?

----------

## toralf

 *keivan wrote:*   

> I tried to find the manual of tigervnc but I can't find it. I tried
> 
> ```
> man tigervnc
> ```
> ...

 Probably you need the USEe flag +doc for that package - otherwise an alternative didn't you look at the home page of tigervnc ?

----------

## keivan

I think I should look for the manual of /etc/conf.d/tigervnc configuration file. It seems this configuration file is Gentoo specific and there is no -geometry option for this file.

----------

## user

Hi keivan,

example needed? 

```
# grep VNC_OPTS /etc/conf.d/tigervnc 

VNC_OPTS="-depth 24 -geometry 2500x1400 -interface 127.0.0.1 -nolisten tcp"
```

----------

## Hu

 *keivan wrote:*   

> I tried to find the manual of tigervnc but I can't find it. I tried
> 
> ```
> man tigervnc
> ```
> ...

 Since you want to affect the VNC server, man vncserver.  Per convention, the manual page is named after the command that is executed, not the package that provides the command.

 *toralf wrote:*   

> Probably you need the USEe flag +doc for that package

 There is no USE=doc for net-misc/tigervnc.  The manual page is always installed.

 *keivan wrote:*   

> I think I should look for the manual of /etc/conf.d/tigervnc configuration file. It seems this configuration file is Gentoo specific and there is no -geometry option for this file.

 Per convention, that file is just options used by /etc/init.d/tigervnc when it runs vncserver.  The example given by user looks like it should work fine.

----------

## keivan

Thanks a lot. that example solved my problem.

----------

## To

This doesn't work for me.

I have on  /etc/conf.d/tigervnc

```
DISPLAYS="to:1"

VNC_OPTS="-depth 24 -geometry 1024x768"
```

And on /home/to/.vnc/xstartup

```

#!/bin/sh

XSESSION=Gnome

XDG_MENU_PREFIX=gnome-

#unset SESSION_MANAGER

#exec /etc/X11/xinit/xinitrc

#[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup

#[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources

xsetroot -solid grey

xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &

gnome-session &

```

And I endup with a screen 1.5 x over my screen connecting remotly and my screen is a 1650x1080 .... Any clues?

----------

