LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-16-2009, 09:06 AM   #1
secretlydead
Member
 
Registered: Sep 2003
Location: Qingdao, China
Distribution: mandriva, slack, red flag
Posts: 249

Rep: Reputation: 31
bring up ncurses program through ssh


I have a few questions.

I have box1 and box2. I'm currently on box1.

Suppose on box2 I...
have an xprogram started, say firefox,
have an ncurses program started, say rtorrent,
and I want to start mplayer-gui.

1)
With ssh on box1, after i've already logged into box2, I would like to open, see, and manipulate firefox on box1. How do I do that?

2)
Same question, only for an ncurses based program. I want to bring up a program already running on box2.

3)
I want to start mplayer-gui. I'd like to start it while I'm on box1, and stop the gui from showing on box2 eventually, but keep it running with a gui on box2.
 
Old 08-16-2009, 10:33 AM   #2
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
Hi secretlydead,

Q1 is pretty straight forward: you need to ensure sshd on box2 is running with 'X11Forwarding yes' in /etc/ssh/sshd_config, once it is you can connect with 'ssh -X user@box2' and any X progs should run on box1.

Q2 .. I'm not sure theres any way to redirect an already running ncurses process to a new ssj session, happy to be corrected though

Q3 .. not sure this is possible, theres no problem starting the app and leaving it running disconnected from your ssh session but I don't think you can prevent it from displaying in the local X server...

cheers,

kbp
 
Old 08-16-2009, 08:15 PM   #3
secretlydead
Member
 
Registered: Sep 2003
Location: Qingdao, China
Distribution: mandriva, slack, red flag
Posts: 249

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by kbp View Post

Q1 is pretty straight forward: you need to ensure sshd on box2 is running with 'X11Forwarding yes' in /etc/ssh/sshd_config, once it is you can connect with 'ssh -X user@box2' and any X progs should run on box1.

kbp
That's the rumor. What I can't find is what command to type after I am in ssh.

For example, if I want to start a new process, 'mcc', i just type 'mcc' and no problem, it appears on box 1.

But what if 'mcc' is already running on box2? Do I use the pid or what?
 
Old 08-17-2009, 01:02 AM   #4
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
Hi secretlydead,

Like I said in answer to Q2, I don't think it's possible to disconnect an app running on a local X server and reconnect it to run on a remote X display via your ssh session

cheers
 
  


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
How to bring a program on system startup lemon09 Linux - Software 5 06-11-2009 10:31 PM
How to execute/bring out a program without opening another terminal? f1l3t0f1sh Linux - Newbie 4 06-06-2005 02:53 PM
when i startx the kde bring 2 bash program by it self Paxmaster Linux - General 1 11-11-2004 07:09 PM
ncurses program gayatri Linux - Software 0 05-03-2004 09:07 AM
compiling program that uses ncurses calble Programming 4 08-10-2003 04:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:10 AM.

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