My main desktop has Mint 14 and I approached it via SSH from another computer, because I didn't have a screen on the Mint one. Then I tried to start teamviewer just I order to launch its desktop session remotely. I started the teamviewer and everything ran fine, but then I tried to stop this application from the terminal and this is what happens:
Checking:
x@x-pc /opt/teamviewer8 $ ps -ef | grep team
root 1567 1 0 20:55 ? 00:00:00 /opt/teamviewer8/tv_bin/teamviewerd -f
x 2892 1 0 21:41 ? 00:00:00 /opt/teamviewer8/tv_bin/wine/bin/wineserver
x 2914 2822 0 21:48 pts/0 00:00:00 grep --colour=auto team
Using one-liner just to feel myself more hacker like :)
sudo for i in `ps -ef | grep team | awk {'print $2'} | xargs`; do kill -9 $i; done
Checking again:
x-pc teamviewer8 # ps -ef | grep team
root 3003 1 0 21:50 ? 00:00:00 /opt/teamviewer8/tv_bin/teamviewerd -f
root 3009 2957 0 21:50 pts/0 00:00:00 grep --colour=auto team
Killing again:
x-pc teamviewer8 # ps -ef | grep team
root 3003 1 0 21:50 ? 00:00:00 /opt/teamviewer8/tv_bin/teamviewerd -f
root 3011 2957 0 21:57 pts/0 00:00:00 grep --colour=auto team
x-pc teamviewer8 #
x-pc teamviewer8 #
x-pc teamviewer8 #
x-pc teamviewer8 #
x-pc teamviewer8 # kill -9 3003
x-pc teamviewer8 #
x-pc teamviewer8 #
x-pc teamviewer8 # ps -ef | grep team
root 3012 1 2 21:57 ? 00:00:00 /opt/teamviewer8/tv_bin/teamviewerd -f
root 3017 2957 0 21:57 pts/0 00:00:00 grep --colour=auto team
#########################################
No matter how many times I killed it, it receives new PID. How can I kill it?