LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 11-04-2013, 01:13 AM   #1
Crushed26
LQ Newbie
 
Registered: Oct 2013
Posts: 6

Rep: Reputation: Disabled
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?

Thanks all

I also know, I can execute teamviewer via command line while sitting in front of the suspect Debian machine.
 
Old 11-04-2013, 06:11 AM   #2
Crushed26
LQ Newbie
 
Registered: Oct 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
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"

#!bin/bash

export DISPLAY=:0.0
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.

good luck.
 
Old 11-04-2013, 07:36 AM   #3
Crushed26
LQ Newbie
 
Registered: Oct 2013
Posts: 6

Original Poster
Rep: Reputation: Disabled
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.

Thanks
 
Old 11-04-2013, 08:31 AM   #4
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora/Pop!_OS
Posts: 2,983

Rep: Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551Reputation: 551
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.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Printing from Debian machine to Win machine, What I did wrong. sarajevo Debian 8 04-30-2008 11:08 PM
open GUI on Linux machine from other machine (Windows or Linux) vietdoclap Linux - Newbie 3 04-25-2008 01:14 AM
how to watch linux client machine desktop(activities) from windows machine deepak rawat Linux - Networking 7 07-03-2006 04:59 PM
sharing internet from a windows 98 machine to a Red Hat Linux machine ritwiksolutions Linux - Newbie 7 03-14-2006 10:20 AM
how to open a dilog on local machine when i do ssh to remote machine fahad26 Programming 3 05-03-2005 07:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 11:29 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration