I'm trying to make my Raspberry pi 4 free from my hand in any situations. If something happens I could work remotely from my pc. To do so I choose teamviewer for it. But device could reboot occasionally and even in that I should be able to connect to it if something needs to be done. If the OS in Raspberry pi is window(i don't know if it's possible...) it would be easy because in window an option in teamviewer that make teamviewer start with the system(which means start on boot) worked fine. But in Raspberry pi linux...

Here's the problem. I've turned on the option 'start teamviewer with system' and put this command

/usr/bin/nohup /usr/bin/teamviewer & > /home/pi/log2.txt

in rc.local file. But noting happens... When I reboot the Raspberry pi, teamviewer does not start on boot so I cannot connect to the device without turning teamviewer manually.

Linux version of Raspberry pi is "Raspbian GNU/Linux 10 (buster)". Plus I trying to connect to teamviewer with 'ID and personal pwd' way.

TeamViewer on PC I'm trying to connect is logged in but teamviewer on the device won't.

Nothing prints out in log2.txt...

  • AFAIK Teamviewer should provide systemd-service units for its deamon. Instead of using rc.local-entries, I'd suggest you use systemctl enable teamviewerd for better stability.
    – FelixJN
    Nov 4, 2021 at 12:09
  • I've also used systemctl but didn't work...But thanks anyway
    – 서상원
    Nov 5, 2021 at 1:55

1 Answer 1


This won't work: there's not an xserver or wayland session that this teamviewer could attach to.

What you could do is set up your login manager such that you get auto-logged in when the graphical interface starts, then start teamviewer from that graphical interface ("autostart applications" or similar, depending on your session manager (Gnome, KDE, xfce...)).

  • You mean to connect to the device via teamviewer than teamviewer should start on graphical interface? And depending on my session manager this "autostart applications" can start teamviewer on boot?
    – 서상원
    Nov 4, 2021 at 8:48
  • There are or used to be possibilities for Teamviewer to connect to the login/desktop manager. However some forum entries tell me, it used to work and still may work when the DM starts wayland. Did not test, though.
    – FelixJN
    Nov 4, 2021 at 12:07
  • Thanks. I'll try both of them!
    – 서상원
    Nov 5, 2021 at 1:56

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .