open Teamviewer on a Debian machine via PuTTY on a Windows machine
Hey guys/gals, hope everyone is doing well.
Got an issue I would like to pick the great brains in this forum about.
So, I have many Debian machines I often remote into using Teamviewer and a Windows machine, which works out great; however Teamviewer crashes for what appears to be no apparent reason. When such happens, normally I will PuTTY into the suspect Debian machine from a Windows 7 machine and issue the shutdown -r now command. When the debian computer reboots, so does Teamviewer and the suspect Debian machine is now visible in the "My computers" list on my Windows machine.
My question is this, why cant I just type teamviewer from the command line while PuTTYing into the Debian machine and have Teamviewer reopen on the Debian machine, making it visible in "My computers?" When I execute teamviewer command from PuTTY command line, I see the verbose output of teamviewer opening, but the machine never becomes visible in "My computers."
Now, I know it is possible to start Teamviewer remotely and have it show up back in 'My computers" list. I can do it via NoMachine; I simply connect to the suspect Debian machine and double click on the Teamviewer desktop launcher. However, NoMachine is very heavy and quite frankly, i just don't like it. PuTTY would be so much faster.
I have also tried VNC as well as X sessions. In both cases, i can open Teamviewer and it shows up in "My computers," but when I close the VNC of X, Teamviewer also closes and removes itself from "My computers."
Can someone help me figure out a way to restart Teamviewer via PuTTY please? Is there a way to open a desktop launcher via PuTTYs command line? Or is there a way to tell Teamviewer to execute in the suspect Debian machines active desktop session via PuTTYs command line?
I also know, I can execute teamviewer via command line while sitting in front of the suspect Debian machine.
haha sorry guys, but I answered my own question again. Below is a solution to the above problem.
I have to run this via a shell script. I have the following saved on the suspect machine. Name it whatever you like. Mine is called "tv.sh"
gnome-terminal -x teamviewer&
if you try to run the above commands for puttys CLI, it will open teamviewer on the suspect machine, however when you end the putty session teamviewer will close; this is why i saved the sh file on the suspect machine and "./tv.sh" from putty. Make sure you do it as user and not root.
Also, I had to change the xhost controls on the machines for it to work.
this will also work and there is no need to run as a shell script; just send this command via putty.
export DISPLAY=:0.0; gnome-terminal -x nohup teamviewer &
you may now close both putty and the terminal window that appeared on the suspect machine.
have fun and hope someone finds this helpful.
that or run it in screen, but yes the key is to put it to the background as you have done with the nohup and & in your command.
|All times are GMT -5. The time now is 02:16 AM.|