VNC VINO at boot

VNC VINO at boot

I need VNC VINO at boot in a customer debian server. To do it I copied the following script in /etc/init.d/ and I maned it as vnc-vino

#! /bin/sh
# /etc/init.d/vnc-vino
#

# Some things that run always
touch /var/lock/blah

# Carry out specific functions when asked to by the system
case "$1" in
  start)
    export DISPLAY=:0.0
    /bin/su - iperuser -c "/usr/lib/vino/vino-server &"
    ;;
  stop)
	killall vino-server
    ;;
  *)
    echo "ERROR"
    exit 1
    ;;
esac

exit 0

to run the script at boot (runlevel 2, 3, 4, 5):

update-rc.d vnc-vino defaults

It could be necessary to check the following directories to see in which order will be run our script and, if necessary, move it at the bottom of the list

/etc/rc2.d/
/etc/rc3.d/
/etc/rc4.d/
/etc/rc5.d/

the service vnc-vino could start using

service vnc-vino start

If we need to run vnc-server manually:

export DISPLAY=:0.0
/usr/lib/vino/vino-server &

If I wrote too many mistake please forgive me (as Brian Adams suggested) but I’m not a debian expert (actually I hate it).

vnc

vnc

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.