打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
Remote VNC login to Ubuntu 11.10 | mlepicki@h...

Remote VNC login to Ubuntu 11.10

Today I’ve installed Ubuntu 11.10 Oneiric Ocelot on my ASrock 100HT nettop. I’ve wanted to remotely control this box via VNC protocol.
My solution was x11vnc server, so I could share one one session between remote and physical access. I’ve found useful thread about x11vnc on Ubuntu 11.10 – I’ve just added some upstart magic to start x11vnc after lightdm.

First of all, I’ve installed x11vnc:
apt-get install x11vnc

Then, I’ve created /etc/init/x11vnc.conf file:
start on login-session-start
script
x11vnc -xkb -noxrecord -noxfixes -noxdamage -display :0 -auth /var/run/lightdm/root/:0 -forever -bg -o /var/log/x11vnc.log
end script

After restart, x11vnc shoud listen on vnc startard port – 5900.

This script is of course based on upstart event mechanism. Lightdm emits login-session-start event (you can find it in lightdm.conf), and we start x11vnc when this event is emited – that’s first line of x11vnc.conf file.

20 thoughts on “Remote VNC login to Ubuntu 11.10

  1. As the started of the thread referenced above I want to thank mlepicki for this startup script which brought everything together.

  2. Yours looks like a truly brilliant solution, however, it fails for me. I installed x11vnc and made the x11vnc.conf file, but I cannot get it to work. After restart, a ps aux | grep vnc shows no x11vnc running, and I cannot login to the machine.

    I looked about everywhere to see if maybe the login-session-start signal needs to be activated, but couldn’t find anything, neither in the upstart lightdm.conf nor in the /etc/lightdm/ directory. Now I am out of my wits.

    Any suggestions to get it to work?

  3. Pingback: Authenticating with x11vnc: what’s the difference between -auth and -rfbauth? | MoVn - Linux Ubuntu Center

  4. Hi there,

    I found your website and it really helped me to get x11vnc working before login.

    Here is what I did to get it to work for Ubuntu 11.10 (your thoughts on this would be appreciated):

    1 – Install x11vnc from Software Centre

    2 – run command

    sudo x11vnc -storepasswd yourpasswordhere /etc/x11vnc.pass

    3 – run command:

    sudo chmod 744 /etc/x11vnc.pass

    4 – run command:

    sudo gedit /etc/lightdm/lightdm.conf

    5 – Add following line of code to the lightdm.conf file:

    greeter-setup-script=/usr/bin/x11vnc -auth /var/run/lightdm/root/:0 -noxrecord -noxfixes -noxdamage -rfbauth /etc/x11vnc.pass -forever -bg -rfbport 5900 -o /tmp/x11vnc.log

    6 – Save file and restart computer and you should now be able to connect remotely using a VNC viewer of your choice

    Kind regards,

    David Johnson

  5. @Tom: Thanks for your links! VNC encrypts passwords sent over the net, but the rest of the traffic is sent unencrypted. That’s ok in my home network, but for public VNC access I’d recommend your solution or other security tools, like VPN.

    • Sure. But if You plan connect with vnc before You login to the desktop on your remote host? Then You must give Your second pass thru unencrypted connection


      VPN of course is a good idea

      _
      regs
      tom

      • For encryption, vncviwer allows a via option to be specified, ala:

        vncviewer -via USERNAME@HOST localhost:0

        From what I understand, this should give an encrypted connection/tunnel to the HOST. From the manual pages for vncviewer, “man vncviewer”:

        -via gateway
        Automatically create encrypted TCP tunnel to the gateway machine
        before connection, connect to the host through that tunnel
        (TightVNC-specific). By default, this option invokes SSH local
        port forwarding, assuming that SSH client binary can be accessed
        as /usr/bin/ssh.

        Best regards
        Viktor S. Wold Eide

  6. Best to tunnel the port (5900 for default of whatever you have chosen vnc to listen on)through ssh and you have an extra layer of security.
    Google ssh tunelling, there are plenty of how-tos out there.

  7. Thanks for this how-to. I installed x11vnc including password authentication according to mlepicki’s updated information. Maybe it would be a good idea to update the original posting so as to rid readers from scrolling.

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
Ubuntu LightDM轻量级桌面显示管理器
Ubuntu 14.04 root用户自动登录
ubuntu 权限不够,解决办法
Ubuntu12.04使用root用户登录
Ubuntu18.0.4折腾日记(四)|如何用root用户登陆Ubuntu
Ubuntukylin
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服