Vino VNC Server unable to start on startup
Solution 1
Must have SSH enabled and root access to the server, then, SSH to it using your normal user account and edit the /etc/gdm3/custom.conf file making the following lines in [daemon] section look as this:
AutomaticLoginEnable=true
AutomaticLogin=yourusername
Save and reboot the server by running "sudo shutdown -r now". Once gdm restarts, it will automatically login as the specified user, and your vino-server process will then start, so you can VNC into the system again. Don’t forget to remove those auto-login lines from /etc/gdm3/custom.conf file when you’re done.
Edited from https://encodable.com/tech/blog/2009/03/02/How_To_Access_A_VNC_Remote_Desktop_After_The_Server_Reboots
Solution 2
create a systemd unit or service to run vino server at startup
cd /etc/systemd/system/
sudo vim vinostartup.service
[Unit] Description = description about the service After = network.target [Service] ExecStart = /usr/lib/vino/vino-server [Install] WantedBy = multi-user.target
-
Enable the service
sudo systemctl enable vinostartup.service
-
Verify it using below command vinostartup.service will be there
ls multi-user.target.wants/
-
If you don’t want to wait until next boot (it’s already enabled) we can start the service
sudo systemctl start vinostartup.service
Related videos on Youtube
The Man
Updated on September 18, 2022Comments
-
The Man over 1 year
So I am trying to get the Vino VNC Server to startup on boot, meaning I don't have to login to have the VNC Server start. I am on Ubuntu GNOME 15.04, and I have already added
/usr/lib/vino/vino-server
to 'Startup Applications'. However, the VNC Server still won't start as soon as I boot up. I have to login in order for the VNC Server to start. What should I do? Do I need to create a systemd unit file? If so, how do I do it?
Edit: This question is different from this becuase I need Vino Server to work, while that guide suggests x11vncserver.
-
Mark Kirby almost 9 yearspossible duplicate of How can I start a VNC server before log on?
-
The Man almost 9 years@markkirby I've edited the post on why my post is different, also, the suggestion of automatic login is not something that I can risk.
-
Matt about 6 yearsI too would like to know how to get Vino to start on boot.
-
Robert Riedl about 6 yearsHave a look at these answers here
-
sancho.s ReinstateMonicaCellio about 3 years@MarkKirby - The OP you linked is not about vino, but "a VNC server", and actually most of the answers do not deal with vino. So I guess it is not a dupe.
-
-
Matt about 6 yearsThanks but doesn't work, unfortunately :(
-
endolith over 5 yearsStartup Application in a desktop won't start until you login though. The question asks how to start the server BEFORE login.
-
endolith over 5 yearsThis doesn't happen until after you login
-
moodboom almost 4 yearsI don't think Vino can start without user login. The Ubuntu VNC docs basically say to switch to x11vnc for that.
-
Ahmed Nazmy almost 4 yearsThanks it did not work
-
Nouman Qaiser almost 3 yearsThis process does NOT work, atleast in Ubuntu 18.04
-
starshine wang almost 3 yearsThis works! Thank you!
-
Maghoumi over 2 yearsThis is the only thing that worked for me after wasting so much time trying to manually start vino using
systemctl --user start vino-server.service
. I was constantly getting the errorvino-server.service: Start request repeated too quickly
. -
sancho.s ReinstateMonicaCellio over 2 yearsIf I understand correctly, one should change /etc/gdm3/custom.conf to allow for (auto-login + vino-server), and once in the session revert the changes for security reasons. Is that correct?
-
sancho.s ReinstateMonicaCellio over 2 years@endolith - It may be the case that vino-server cannot start without a session started. Check the highest voted answer... I think it also suggests doing both things (login + vino-server), even if automatically.