Page 1 of 6 123 ... LastLast
Results 1 to 10 of 60

Thread: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

  1. #1
    Join Date
    May 2008
    Location
    China
    Beans
    49

    HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Much of the information comes from this threads http://ubuntuforums.org/showthread.php?t=122402 and http://ubuntuforums.org/showthread.php?t=191564 and links in the threads. However the threads were started since 2006 and many pages long. After spending a few days digging through the information and links, I hope this information will save you time if you are setting up vncserver and gdm on 8.04.

    The setup was done almost immediately after a fresh installation of 8.04 desktop on our office internal network.

    Objective:
    To have vncserver setup with gdm on the host so that a remote vnc connection to it will be greeted with a gdm login screen for the user to login.


    Clarification of terms used:
    Host - refers to the PC you are trying to install vncserver on.
    Remote - the PC that is going to connect to the host

    1. Get required packages installed
    On the host, run
    Code:
    sudo apt-get install vnc4server xinetd
    Being a server guy, I prefer to ssh into the host and do all the work, so I also
    Code:
    sudo apt-get install openssh-server
    This way I can directly test the vnc by using vncclient on my remote desktop to the host.
    Of course if you have only a host PC, then you may also need a vncclient to test it.

    2. Enable XDMCP
    This is the part that is responsible for bring up the gdm login.

    Code:
    sudo vi /etc/gdm/gdm.conf
    Uncomment this line
    Code:
    RemoteGreeter=/usr/lib/gdm/gdmlogin
    Enable xdmcp, look for [xdmcp] and change Enable to true.
    Code:
    [xdmcp]
    Enable=true
    Restart gdm,
    Code:
    sudo /etc/init.d/gdm restart
    3. Setup xinetd
    Create a new service file for xinetd
    Code:
    sudo vi /etc/xinetd.d/Xvnc
    (vi is of course one of many editors you can use)

    Paste the following into the file and save:
    Code:
    service Xvnc
    {
            type = UNLISTED
            disable = no
            socket_type = stream
            protocol = tcp
            wait = no
            user = nobody
            only_from = localhost
            server = /usr/bin/Xvnc
            server_args = -inetd -query localhost -geometry 1024x768  -depth 16 -cc 3 -once -SecurityTypes=none -extension XFIXES
            port = 5901
    }
    Restart xinetd
    Code:
    sudo  /etc/init.d/xinetd restart
    4. Connect from remote
    Because I added only_from = localhost in /etc/xinetd.d/Xvnc above, I will need to ssh tunnel and forward my remote port (see term clarification above, as this is actually my local PC that I working from) to the host (this is the 'remote' where vncserver is being installed). If you do not need this step (why not?), just remove the line.

    I use putty on Windows so just go to
    Connections >SSH >Tunnels
    Source Port: 5901
    Destination: localhost:5901
    Add
    Then establish a normal ssh connection to the host or use my existing ssh connection.

    This link might be helpful for those using other clients https://help.ubuntu.com/community/VNCOverSSH

    I use UltraVNC, so this is what I do:
    Open Viewer
    VNC Server: localhost:5901
    Connect

    5. Done
    The vnc viewer should open up and a gdm login screen presented (with a Debian logo).
    Enter your username and password. That's it.


    Hopefully this do not generate 45+9 pages of discussion.

    Update :
    How to connect with an Ubuntu remote using vinagre (Ubuntu's default vnc client) through an ssh tunnel
    Last edited by kcnnc; June 18th, 2008 at 09:44 AM.

  2. #2
    Join Date
    Feb 2006
    Beans
    65

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Some notes on using this with kdm would be great. I guess i'll have to dig in those threads you found.

  3. #3
    Join Date
    May 2008
    Location
    China
    Beans
    49

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    I have no experience with kdm. Presumably step 2 (Enable XDMCP) is the only point to focus attention on.

  4. #4
    Join Date
    Mar 2008
    Beans
    3

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Great how to works perfectly.
    Question though how do you make it work to have another remote session on 5902. Which would truely give you multiple remote sessions?

  5. #5
    Join Date
    May 2006
    Location
    United Kingdom
    Beans
    469
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Thanks for that, nice concise write-up.

  6. #6
    Join Date
    May 2008
    Location
    China
    Beans
    49

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Quote Originally Posted by tmaleshafske View Post
    Question though how do you make it work to have another remote session on 5902. Which would truely give you multiple remote sessions?
    Just open another vnc connection to the same port.
    It works ... I just did it on my desktop.

  7. #7
    Join Date
    May 2006
    Location
    United Kingdom
    Beans
    469
    Distro
    Ubuntu 11.04 Natty Narwhal

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    What about getting privileges to perform tasks such as Shutdown from the power button icon. Do changes just have to be made under the login window preferences to allow remote connections admin rights or another way?

    TIA

  8. #8
    Join Date
    May 2008
    Location
    China
    Beans
    49

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Quote Originally Posted by geezerone View Post
    What about getting privileges to perform tasks such as Shutdown from the power button icon. Do changes just have to be made under the login window preferences to allow remote connections admin rights or another way?
    In my case I don't have a need for those so I don't ready know how to do it. Maybe someone has an idea?

  9. #9
    Join Date
    Jan 2005
    Location
    Italy
    Beans
    9
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Worked perfectly for me on 8.04 desktop (not fresh install, upgraded from 7.10).

    Thanks!

  10. #10
    Join Date
    Mar 2008
    Location
    Port Macquarie, Australia
    Beans
    11
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: HOWTO: Setup vncserver + gdm on Ubuntu 8.04 Desktop

    Very nice work. I spent a couple hours trying to get this to work using those guides you mentioned, but I could never got the login screen to come up. Your guide worked perfectly though.

Page 1 of 6 123 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •