Switching the active pts?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Switching the active pts?
# 1  
Old 06-25-2007
Switching the active pts?

My apologies in advance if this question has already been asked or if I use incorrect terminology; I have tried searching for nearly an hour without any luck.

Is there any way to change the active TTY for a session? I was monitoring a long (~5 hour) process through an SSH connection and the network went down. The box is still running the job, but my SSH connection is no longer associated with it.

I tried doing a tail -f on the file descriptor in /dev/pts but get no output. Is there a straightforward way to change my session's pts?

Thanks,
Tres
# 2  
Old 06-25-2007
If the job is no longer associated with a pseudo-terminal then (as far as I know) it cannot be re-attached from outside the process.

Is the process "1" the ultimate parent of the group of tasks?
# 3  
Old 06-25-2007
Quote:
If the job is no longer associated with a pseudo-terminal then (as far as I know) it cannot be re-attached from outside the process.

Is the process "1" the ultimate parent of the group of tasks?
No, it is still associated with a pseudo-terminal - I'm just wondering how I can set that pseudo-terminal as the active one for my session. Here is one process that was active when the network went down:

Code:
tspicher 22682 18433  0 15:50:58 pts/5    0:01 lynx

How can I set pts/5 as my active pseudo-terminal?
# 4  
Old 06-25-2007
I must admit I don't know.

Traditionally there are the pairs /dev/ptyXX and /dev/ttyXX where one side was the terminal for the program, the other was for a controlling program.

But the /dev/pts/XX come from being created by opening /dev/ptmx, this will create new pairs as required as the previously mentioned mechanism didn't scale.

I don't see how you could open /dev/ptmx and get a previously created /dev/pts/XX.
# 5  
Old 06-25-2007
Quote:
Originally Posted by porter
I must admit I don't know.
Thanks for trying! If anyone else has any ideas, I'd love to hear them.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Problem with PTS

Hello, I´m working with an m4000 server, with solaris 11. the problem is when users connect to the server, I have the range from pts/65 to pts/128 "blocked". The system does not take any pts of that range. Usually a close all the connections and the problem is solved, but this time that solution... (3 Replies)
Discussion started by: salvador_cast
3 Replies

2. Red Hat

Switching services from active node to failovernode in cluster

Hi All, I was asked to Switch the service from failover to active node as we need to reboot active node for regular maintenance. Unfortunately our senior admin left the organization. It would be helpful if some one answer this query. Detailed info with steps will be appreciated. Here are... (1 Reply)
Discussion started by: vamshigvk475
1 Replies

3. Shell Programming and Scripting

How do I calculate total number of active and non active hosts?

#!/bin/bash for digit in $(seq 1 10) do if ping -c1 -w2 192.168.1.$digit &> /dev/null then echo "192.168.1.$digit is UP" else echo "192.168.1.$digit is DOWN" fi done (3 Replies)
Discussion started by: fusetrips
3 Replies

4. Solaris

Link based Active Active IPMP

Hi, I need to configure 4 ip address (same subnet and mask) in one ipmp group (two interfaces) in an active active formation (link based). Can some one provide the steps or a tutorial link. Thanks (2 Replies)
Discussion started by: Mack1982
2 Replies

5. AIX

Question about HACMP for active-active mode

Hi all, I am new to HACMP. So sorry for the newie question. But I did search the forum and it seems that no one asks this before. So if a 2-node cluster runs in active-active mode (and the same application), what is the benefit of using HACMP ? If it runs in active-stanby, it is easy to... (9 Replies)
Discussion started by: qiulang
9 Replies

6. UNIX for Dummies Questions & Answers

Sending alt-n to /dev/pts/1 from process bound to /dev/pts/2

Hello, i am using finch (unix commandline instant messaging client using libgnt) which is running connected to /dev/pts/1 Now I would like to "remote control" the program by sending the key combinations normally typed on the keyboard from a programm in another shell. So I tried:... (0 Replies)
Discussion started by: mentos
0 Replies

7. UNIX for Dummies Questions & Answers

pts and tty

hi iam very new to linux can anyone tell me about pts and tty acctually today morning i logged into my pc at 9:51 when i have given #who it has given sam tty7 9:51 sam pts/1 10:11 so what does it mean (1 Reply)
Discussion started by: praneel2k
1 Replies

8. UNIX for Advanced & Expert Users

one of the mount pts 100%

Hi all, recently we had a critical error like one of the mount points /online was 100% full. Even when we deleted three ( 3 ) 0.5 GB files available space in /online mount was not increasing rather df -k for /online continued to show as 100% full. what could be the problem, even... (6 Replies)
Discussion started by: matrixmadhan
6 Replies

9. UNIX for Dummies Questions & Answers

what is /dev/pts/1

hi, i ran tty and get this /dev/pts/1? what does /dev/pts/1 indicates about my terminal and the device files? thanks (4 Replies)
Discussion started by: yls177
4 Replies
Login or Register to Ask a Question