Can confirm this issue.
Script above did not helped me.

All it does

sh vnc.sh 
vnc.sh: 9: [: :1: unexpected operator
vnc.sh: 20: [: true: unexpected operator


Thats the script

#!/bin/bash
vncpasswdfile=/etc/x11vnc/passwd
vtpath=/var/run/lightdm/root
vtuser=:0
vtlock=:1
    vtlast=$vtlock
    switch=true
    while (true); do {
            if [ "$vtlast" == "$vtuser" ]; then {
                    if [ -e "$vtpath/$vtlock" ]; then {
                            switch=true
                            vtlast=$vtlock
                    }; fi
            } else {
                    if [ ! -e "$vtpath/$vtlock" ]; then {
                            switch=true
                            vtlast=$vtuser
                    }; fi
            }; fi
            if [ "$switch" == "true" ]; then {
                    killall x11vnc > /dev/null 2>&1
                    killall -9 x11vnc > /dev/null 2>&1
                    x11vnc -display $vtlast -forever -noxfixes -rfbauth 
$vncpasswdfile -auth $vtpath/$vtlast > /dev/null 2>&1 &
                    echo "Switch to $vtlast ..."
                    switch=false
            }; fi
            sleep 5
    }; done

My startup script is.
x11vnc -xkb -noxrecord -noxfixes -noxdamage -display :0 -auth 
/var/run/lightdm/root/:0 -forever -shared -bg -o /var/log/x11vnc.log -rfbauth 
/etc/x11vnc/passwd -rfbport 5900

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1287171

Title:
  light-locker breaks x11vnc as service

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/light-locker/+bug/1287171/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to