How can I issue a ctrl+c in a unix korn shell script
I've tried: echo "^c" but this doesn't work. Can someone please tell me what the correct syntax would be? Thanks
I am writing a script that will make sure I can telnet to a box that has an intermittent problem. When this problematic situation occurs, I can ping the box but I cant telnet to it. My script does something like:
telnet sp18 1>/tmp/telnet.out 2>&1
I then grep telnet.out for a string. The problem that I am having is that the telnet command makes the script hang(at a login prompt,of course) so, I want to send a ctrl + c sequence so that the script can continue and then exit
have a look at the kill command, you can use it to send an INT signal (a Control-C) to a process Mike
michael.j.lacey@ntlworld.com
Email welcome if you're in a hurry or something -- but post in tek-tips as well please, and I will post my reply here as well.
raider - sorry to be thick, how does that work then? Mike
michael.j.lacey@ntlworld.com
Email welcome if you're in a hurry or something -- but post in tek-tips as well please, and I will post my reply here as well.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.