Difference between revisions of "XDMCP & VNC"

From Briki
Jump to: navigation, search
Line 1: Line 1:
 
* Install vnc4server
 
* Install vnc4server
  
* Edit /etc/kde3/kdm/kdmrc and change Xdmcp section to:
+
* Enable XDMCP:
 +
** For kdm, edit /etc/kde3/kdm/kdmrc and change Xdmcp section to:
 +
<pre>
 +
Enable=true
 +
</pre>
 +
** For gdm, edit /etc/gdm/gdm.conf and change xdmcp section to:
 
<pre>
 
<pre>
 
Enable=true
 
Enable=true
 
</pre>
 
</pre>
 +
  
 
* Add the following lines to /etc/services:
 
* Add the following lines to /etc/services:
 
<pre>
 
<pre>
vnc             5901/tcp            # VNC
+
vnc_1024x768             5901/tcp            # VNC (1024x768)
vnc_large      5902/tcp            # VNC (large screen)
+
vnc_1280x1024            5902/tcp            # VNC (1280x1024)
 +
vnc_1920x1200            5903/tcp            # VNC (1920x1200)
 
</pre>
 
</pre>
  
 
* Add the following to /etc/xinetd.d/vnc:
 
* Add the following to /etc/xinetd.d/vnc:
 
<pre>
 
<pre>
service vnc
+
service vnc_1024x768
 +
{
 +
        disable        = no
 +
        socket_type    = stream
 +
        protocol        = tcp
 +
        wait            = no
 +
        user            = nobody
 +
        server          = /usr/bin/Xvnc
 +
        server_args    = -inetd -query localhost -geometry 950x700 -depth 24 -once securitytypes=none
 +
}
 +
 
 +
service vnc_1280x1024
 
{
 
{
 
         disable        = no
 
         disable        = no
Line 22: Line 40:
 
         user            = nobody
 
         user            = nobody
 
         server          = /usr/bin/Xvnc
 
         server          = /usr/bin/Xvnc
         server_args    = :1 -inetd -query localhost -geometry 950x700 -depth 24 -once securitytypes=none
+
         server_args    = -inetd -query localhost -geometry 1260x960 -depth 24 -once securitytypes=none
 
}
 
}
  
service vnc_large
+
service vnc_1920x1200
 
{
 
{
 
         disable        = no
 
         disable        = no
Line 33: Line 51:
 
         user            = nobody
 
         user            = nobody
 
         server          = /usr/bin/Xvnc
 
         server          = /usr/bin/Xvnc
         server_args    = :2 -inetd -query localhost -geometry 1260x960 -depth 24 -once securitytypes=none
+
         server_args    = -inetd -query localhost -geometry 1860x1120 -depth 24 -once securitytypes=none
 
}
 
}
 
</pre>
 
</pre>
Note: If this config results in only 1 user being able to connect to each service at any given time, then it may be possible to correct this by removing the ":1" and ":2" from the args above. This needs testing to confirm.
+
Note: To enable persistent sessions (which has the downside of only enabling 1 login per service), prefix '''-inetd''' with ''':'''''n'' where ''n'' is a number beginning at 1 for the first service, and counting up.
  
 
* Restart xinetd
 
* Restart xinetd

Revision as of 09:36, 9 August 2007

  • Install vnc4server
  • Enable XDMCP:
    • For kdm, edit /etc/kde3/kdm/kdmrc and change Xdmcp section to:
Enable=true
    • For gdm, edit /etc/gdm/gdm.conf and change xdmcp section to:
Enable=true


  • Add the following lines to /etc/services:
vnc_1024x768             5901/tcp            # VNC (1024x768)
vnc_1280x1024            5902/tcp            # VNC (1280x1024)
vnc_1920x1200            5903/tcp            # VNC (1920x1200)
  • Add the following to /etc/xinetd.d/vnc:
service vnc_1024x768
{
        disable         = no
        socket_type     = stream
        protocol        = tcp
        wait            = no
        user            = nobody
        server          = /usr/bin/Xvnc
        server_args     = -inetd -query localhost -geometry 950x700 -depth 24 -once securitytypes=none
}

service vnc_1280x1024
{
        disable         = no
        socket_type     = stream
        protocol        = tcp
        wait            = no
        user            = nobody
        server          = /usr/bin/Xvnc
        server_args     = -inetd -query localhost -geometry 1260x960 -depth 24 -once securitytypes=none
}

service vnc_1920x1200
{
        disable         = no
        socket_type     = stream
        protocol        = tcp
        wait            = no
        user            = nobody
        server          = /usr/bin/Xvnc
        server_args     = -inetd -query localhost -geometry 1860x1120 -depth 24 -once securitytypes=none
}

Note: To enable persistent sessions (which has the downside of only enabling 1 login per service), prefix -inetd with :n where n is a number beginning at 1 for the first service, and counting up.

  • Restart xinetd