Sponsored Content
Top Forums Shell Programming and Scripting How to break out of hung or waiting telnet session in shell script? Post 303010564 by rdrtx1 on Wednesday 3rd of January 2018 08:05:23 AM
Old 01-03-2018
Code:
timeout 1s telnet blah blah

 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Telnet Session

{ sleep 2 echo "$user" sleep 2 echo "$password" sleep 2 echo " ls" sleep 10 echo "exit" }| telnet $server I have a machine x and i have executed the above script on machine 'x'. i entered the... (6 Replies)
Discussion started by: pathanjalireddy
6 Replies

2. UNIX for Dummies Questions & Answers

Unix Telnet session

Hi Is there any way whilst in a telnet session you can view your client machine name that you are using to connect to the Unix box ? :eek: (2 Replies)
Discussion started by: mlucas
2 Replies

3. Shell Programming and Scripting

closing a telnet session on error, in a shell script

I am using a shell script to telnet into a remote unix server and execute certain commands. But if any command being executed remotely, throws an error, the script just hangs. And the telnet session does not get closed. I want to be able to close the session and complete the script execution in... (1 Reply)
Discussion started by: farahzaiba
1 Replies

4. HP-UX

hpux telnet session is getting hung after about 15 minutes

Hi All, Our server OS info: HPUX-UNIX>uname -a HP-UX hps B.11.11 U 9000/800 2983362429 unlimited-user license We access our server from Windows m/c through telnet sessions. But for unknown reason any telnet sessions are getting hung after about 15 minutes idle time. Then we close it and... (2 Replies)
Discussion started by: mhbd
2 Replies

5. HP-UX

ssh session getting hung (smilar to hpux telnet session is getting hung after about 15 minutes)

Our network administrators implemented some sort of check to kill idle sessions and now burden is on us to run some sort of keep alive. Client based keep alive doesn't do a very good job. I have same issue with ssh. Does solution 2 provided above apply for ssh sessions also? (1 Reply)
Discussion started by: yoda9691
1 Replies

6. Shell Programming and Scripting

SQL PLUS Command 'ACCEPT' is not waiting for user input with sh shell script

Dear All, The sqlplus 'Accept' command is not waiting for user input when I include the command within a shell script. Note: The 'Accept' command is working fine if I execute it in a SQLPLUS Prompt. Please fins the below sample script which i tried. SCRIPT: -------- #!... (4 Replies)
Discussion started by: little_wonder
4 Replies

7. Shell Programming and Scripting

Expect script to automate telnet session

Hi all, I am currently running a daemon which creates a virtual terminal for testing purposes. Essentially, if I were to interact with it manually, this is what I get. john@test1:~$telnet localhost 7777 Trying ::1... Connected to localhost. Escape character is '^]' mip6d> pl eth2... (6 Replies)
Discussion started by: abxccd
6 Replies

8. Shell Programming and Scripting

Unable to close telnet session from script

Hello people, I am creating a script that will alert me in an ftp or telnet account on my system expires. FTP part is ok, but when I am entering the 3 script, it stucks. I can see that the script will not close the telnet seession. Can you please check and let me know what I am doing wrong? What if... (7 Replies)
Discussion started by: drbiloukos
7 Replies

9. Shell Programming and Scripting

Waiting for a process to complete in shell script

Hi, I need to initiate a process script which will start and do some processing and then shuts down. Then i need to other verifications. But the the process takes around 25 to 3o minutes. One thing i can monitor the nohup.out file for this process where i can wait for shutting down statement to... (3 Replies)
Discussion started by: Prashanth19
3 Replies
RXTELNET(1)						    BSD General Commands Manual 					       RXTELNET(1)

NAME
rxtelnet -- start a telnet and forward X-connections. SYNOPSIS
rxtelnet [-l username] [-k] [-t telnet_args] [-x xterm_args] [-K kx_args] [-w term_emulator] [-b telnet_program] [-n] [-v] host [port] DESCRIPTION
The rxtelnet program starts an xterm window with a telnet to host host. From this window you will also be able to run X clients that will be able to connect securely to your X server. If port is given, that port will be used instead of the default. If setting up the X forwarding failes, rxtelnet will still telnet in to the remote host, but without X forwarding. The supported options are: -l Log in on the remote host as user username. -k Disables keep-alives. -t Send telnet_args as arguments to telnet. -x Send xterm_args as arguments to xterm. -X Send kx_args as arguments to kx. -w Use term_emulator instead of xterm. -b Use telnet_program instead of telnet. -n Do not start any terminal emulator. -v Be verbose. EXAMPLE
To login from host foo (where your display is) to host bar, you might do the following. 1. On foo: rxtelnet bar 2. You will get a new window with a telnet to bar. In this window you will be able to start X clients. SEE ALSO
kx(1), rxterm(1), telnet(1), tenletxr(1), kxd(8) KTH_KRB March 7, 2004 KTH_KRB
All times are GMT -4. The time now is 10:00 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy