|
|
|
|
||||||
| comp.unix.shell Using and programming the Unix shell. |
![]() |
|
|
LinkBack | Outils de la discussion |
|
|
#1 |
|
Messages: n/a
Hébergeur: |
Hi all
for example some cpp part on application ....... std::cout << resoult ; // output to cout; std::cerr << error_message ; // output to cerr; file << informations ; // output to some file; ....... on machine A I opened 3 SSH/Telnet connection on machine B I executed the application my question is can I redirect these output to machine A's terminal individually ? or even can I add some prefix? How :P ? thank you very much! key9 |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
I think I found the key:
using " 1>;/dev/pts/0 2>;/dev/pts/1 " can solve this problem , but I am still confuse on file When we execute a app , 3-x is we opened file in app; and after we closed a file , will fd be reused next? opened fd table 0 1 2 3 -> this pointed file3 4 -> this pointed file4 if we closed 3 ,and open file5 , the fd will be 3 or 5? |
|
![]() |
| Outils de la discussion | |
|
|