16.10 Server - update-rc.d not creating symlinks for vncserver

6,310

LSB Headers required on 16.10 ?

Similar problem for me - my scripts where registering correctly with 16.04 but not with 16.10. I added the LSB headers and it started working correctly with 16.10

I used something similar to the example below, adding it after the #!/bin/sh line

### BEGIN INIT INFO
# Provides:       my_service
# Required-Start:    $local_fs $remote_fs $network $syslog $named
# Required-Stop:     $local_fs $remote_fs $network $syslog $named
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: starts my_service
# Description:       starts my_service using start-stop-daemon
### END INIT INFO
Share:
6,310

Related videos on Youtube

Admin
Author by

Admin

Updated on September 18, 2022

Comments

  • Admin
    Admin over 1 year

    Sorry - edited to clarify that this is Ubuntu 16.10 (Yakkety Yak) NOT 14.10.
    For some reason 14.10 was stuck in my head.

    I am trying to setup a headless VNC server and using this guide as a reference:

    https://www.howtoforge.com/how-to-install-vnc-server-on-ubuntu-14.04

    It mostly seems to work, but vncserver is failing to start on boot, starts manually ok.

    When I run

    update-rc.d vncserver defaults 99
    

    I am supposed to get something like:

    Adding system startup for /etc/init.d/vncserver ...
    /etc/rc0.d/K99vncserver -> ../init.d/vncserver
    /etc/rc1.d/K99vncserver -> ../init.d/vncserver
    /etc/rc6.d/K99vncserver -> ../init.d/vncserver
    /etc/rc2.d/S99vncserver -> ../init.d/vncserver
    /etc/rc3.d/S99vncserver -> ../init.d/vncserver
    /etc/rc4.d/S99vncserver -> ../init.d/vncserver
    /etc/rc5.d/S99vncserver -> ../init.d/vncserver
    

    Which I am assuming is the symlink being created

    Whereas, I get nothing back. Command completes without any error or feedback...

    So have gone looking for the symlinks:

    ls -al /etc/rc?.d/
    

    Shows me no vncserver symlinks created at all. So I am supposing this is why it is not starting.

    I have removed and re-added, re-wrote the script....

    Is there any logging for update-rc.d that might tell me what's (not) going on?

    I guess I can create these links manually, but I have no clue how to do so...

    Any help appreciated.

    • Admin
      Admin over 7 years
      Do you really use 14.10 (which is no longer supported for almost two years now) or is that just a typo in your question title?
    • Admin
      Admin over 7 years
      Sorry - well spotted @ByteCommander - was a typo, I meant 16.10, sorry.
    • Admin
      Admin over 7 years
      ... and sorry @user535733 to have mislead you - I now know more about the differences between Upstart and SystemD tho'
    • Admin
      Admin over 7 years
      @user535733 Its in /etc/init.d and executable.
    • Admin
      Admin over 7 years
      Does the script in /etc/init.d have LSB headers (wiki.debian.org/LSBInitScripts)?
    • Admin
      Admin over 7 years
      The script I am using is in the howto I have linked. It seems to support some of the Init script actions, if that what LSB headers refers to. Otherwise I am not sure/
    • Admin
      Admin over 7 years
      anyone got any thought? @user535733 - thanks !
    • Admin
      Admin over 7 years
      Similar scenario but in my case the same scripts are registered correctly in 16.04 but not in 16.10