autostart x11vnc server at boot

Message
Author
mx-user-1704
Posts: 33
Joined: Mon Dec 21, 2020 5:22 pm

autostart x11vnc server at boot

#1 Post by mx-user-1704 »

Hi,

I want to autostart x11vnc server at boot, mx used from usb stick, all-persistent.
So i created a file ~/.config/autostart/x11vnc-start.desktop containing:

[code]
[Desktop Entry]
Type=Application
Name=x11vncstart
Exec=x11vnc -forever -display :0 >/dev/null 2>&1 &
[/code]

But vnc did not start at boot.
Please tell me what I am doing wrong.

Thanks,
mx

ps: i think the code tags dont work for me in the forum atm

User avatar
JayM
Posts: 6796
Joined: Tue Jan 08, 2019 3:47 am

Re: autostart x11vnc server at boot

#2 Post by JayM »

What happens when you run that command in a terminal?

Code: Select all

x11vnc -forever -display :0 >/dev/null 2>&1 &
Please read the Forum Rules, How To Ask For Help, How to Break Your System and Don't Break Debian. Always include your full Quick System Info (QSI) with each and every new help request.

mx-user-1704
Posts: 33
Joined: Mon Dec 21, 2020 5:22 pm

Re: autostart x11vnc server at boot

#3 Post by mx-user-1704 »

Thanks for the answer, good idea.
Using that command in the terminal starts the vnc server, bc i can connect from remote, but i get no icon on the side panel, what is not a real problem, well would be nice :)
So the command seems to work, but not from autostart folder.

User avatar
JayM
Posts: 6796
Joined: Tue Jan 08, 2019 3:47 am

Re: autostart x11vnc server at boot

#4 Post by JayM »

Maybe something's misconfigured in your handmade desktop file. You can add that command in (Menu) Settings -> Session and Startup, on the Application Autostart tab. Just create a new entry and paste that command into it, and check the box to have it run when you log in.

Regarding the icon in your panel, I think it's because x11vnc is a command-line app, not a GUI app, so it doesn't have an icon.
Please read the Forum Rules, How To Ask For Help, How to Break Your System and Don't Break Debian. Always include your full Quick System Info (QSI) with each and every new help request.

mx-user-1704
Posts: 33
Joined: Mon Dec 21, 2020 5:22 pm

Re: autostart x11vnc server at boot

#5 Post by mx-user-1704 »

The entry is there at Session and Startup already, and checked. That surprised me :) The name is the Name entry from the autostart file. I copy/pasted the Exec line from the autostart file directly into the terminal for the test, so it seems to work.
The icon in the panel is there if x11vnc server is startet from the menu.
Everything looks good, but still ...

mx-user-1704
Posts: 33
Joined: Mon Dec 21, 2020 5:22 pm

Re: autostart x11vnc server at boot

#6 Post by mx-user-1704 »

Changed the Name entry in the autostart file to something crazy, reboot, Session and Startup shows that name, so its that file. Funny.
And maybe I should work on the cmd line, mom I will try the one from the menu.

mx-user-1704
Posts: 33
Joined: Mon Dec 21, 2020 5:22 pm

Re: autostart x11vnc server at boot

#7 Post by mx-user-1704 »

New try, and sorry for all the garbage:
Used the cmd from the menu: x11vnc -gui tray=setpass -rfbport PROMPT -bg -o %%HOME/.x11vnc.log.%%VNCDISPLAY
Now at boot, the interface appears, i need to press ok, accept connections, ok.
Thats no good for unattended, but top says x11vnc is running, but i cant connect.
Startet vnc from menu, clicked the mentioned buttons, can connect from remote.
Now top shows 2 xvnc111 running.
Ha, what an adventure :)

I guess i need to work at x11vnc command line.

PS: thanks for the fast answers and happy new year :)

Post Reply

Return to “XFCE Desktop Environment”