08-29-2012
You probably shouldn't use expect for this. Use the
ksh coprocess facility instead. You can simply terminate the coprocess then by issuing
kill -15 %1 or similar from the main process.
I hope this helps.
bakunin
This User Gave Thanks to bakunin For This Post:
10 More Discussions You Might Find Interesting
1. AIX
I wrote a ksh script for Helpdesk. I need to know how to disable ctrl-c,ctrl-z,ctrl-d..... so that helpdesk would not be able to get to system prompt :confused: (6 Replies)
Discussion started by: wtofu
6 Replies
2. Shell Programming and Scripting
Hi I have written one shell script , using that i am able to connect to remote machine but i have to
#!/usr/bin/expect -f
set address
set username
set password
set OOLpath
set dbusername
set dbpasswd
set tnsname
set recdbusername
set recdbpasswd
set rectnsname
spawn ssh... (1 Reply)
Discussion started by: mnmonu
1 Replies
3. Shell Programming and Scripting
Hi,
I have written one shell script , using that i am able to connect to remote machine but i have to
#!/usr/bin/expect -f
set address
set username
set password
set OOLpath
set dbusername
set dbpasswd
set tnsname
set recdbusername
set recdbpasswd
set rectnsname
spawn ssh... (2 Replies)
Discussion started by: mnmonu
2 Replies
4. Shell Programming and Scripting
Greetings,
I am writing an Expect script to automate multiple processes on an HP-UX system. Everything has gone fine so far but I now have run into a problem. One of the processes that I'm trying to automate requires the key combination of ctrl break and I have so far been unable to figure out... (1 Reply)
Discussion started by: g_trueblood2000
1 Replies
5. Shell Programming and Scripting
I have to send few gzipped files from local server to SFTP server.
My Server Info
Distributor ID: Ubuntu Description: Ubuntu 12.04.4 LTS Release: 12.04 Codename: precise
Created a bash script and could able to send files to sftp, but i want to send email if transfer is successful.
... (1 Reply)
Discussion started by: krux_rap
1 Replies
6. Shell Programming and Scripting
declare -a array=( "LLC-load-misses" "LLC-loads" "LLC-store-misses" "LLC-stores" "branch-load-misses" "branch-loads" "dTLB-load-misses" "dTLB-loads" "dTLB-store-misses" "dTLB-stores" "iTLB-load-misses" "iTLB-loads" "branch-instructions" "branch-misses" "bus-cycles" "cache-misses" "cache-references"... (2 Replies)
Discussion started by: BHASKAR JUPUDI
2 Replies
7. Shell Programming and Scripting
Hi,
I am executing a expect script in while loop for doing telnet on list of servers stored in file as below :
expect script :
#!/usr/bin/expect -f
set timeout 20
set ip
set port
if { == 0} {
send_user "Usage: scriptname ip port\n"
exit 1
}
#exp_internal 1
log_user 0
spawn... (3 Replies)
Discussion started by: omkar.jadhav
3 Replies
8. Shell Programming and Scripting
Hi I am trying the following in my bash script which logs into my machine and runs a command. Trying to solve this using expect.
The first expect statement is hit and it enters the address "10.10.0.10" but when the second expect statement is hit it exits
#!/bin/bash
expect -c '
spawn... (2 Replies)
Discussion started by: skorada
2 Replies
9. Shell Programming and Scripting
Hey All,
I am writing one script using expect, that script which is used in spawn will accepts only 1. Enter 2. Ctrl+c
Press Control-C to exit, Enter to proceed.
Could some one share some thoughts to send the above user inputs in linux expect block ?
Thanks,
Sam (0 Replies)
Discussion started by: SCHITIMA
0 Replies
10. UNIX for Beginners Questions & Answers
Dear Tech Guys,
I am trying to send some commands on the local server and it always asks for user name and password after each command. To serve the purpose I am using expect function as follows:
#!/usr/bin/expect
set timeout 20
spawn "./data1.sh"
expect "Please Enter UserName: "... (6 Replies)
Discussion started by: Xtreme
6 Replies
LEARN ABOUT CENTOS
rstream
RSTREAM(1) librdmacm RSTREAM(1)
NAME
rstream - streaming over RDMA ping-pong test.
SYNOPSIS
rstream [-s server_address] [-b bind_address] [-B buffer_size]
[-I iterations] [-C transfer_count]
[-S transfer_size] [-p server_port] [-T test_option]
DESCRIPTION
Uses the streaming over RDMA protocol (rsocket) to connect and exchange data between a client and server application.
OPTIONS
-s server_address
The network name or IP address of the server system listening for connections. The used name or address must route over an RDMA
device. This option must be specified by the client.
-b bind_address
The local network address to bind to.
-B buffer_size
Indicates the size of the send and receive network buffers.
-I iterations
The number of times that the specified number of messages will be exchanged between the client and server. (default 1000)
-C transfer_count
The number of messages to transfer from the client to the server and back again on each iteration. (default 1)
-S transfer_size
The size of each send transfer, in bytes. (default 1000) If 'all' is specified, rstream will run a series of tests of various
sizes.
-p server_port
The server's port number.
-T test_option
Specifies test parameters. Available options are:
s | socket - uses standard socket calls to transfer data
a | async - uses asynchronous operation (e.g. select / poll)
b | blocking - uses blocking calls
f | fork - fork server processing (forces -T s option)
n | nonblocking - uses non-blocking calls
v | verify - verifies data transfers
NOTES
Basic usage is to start rstream on a server system, then run rstream -s server_name on a client system. By default, rstream will run a
series of latency and bandwidth performance tests. Specifying a different iterations, transfer_count, or transfer_size will run a user
customized test using default values where none have been specified.
Because this test maps RDMA resources to userspace, users must ensure that they have available system resources and permissions. See the
libibverbs README file for additional details.
SEE ALSO
rdma_cm(7)
librdmacm 2011-11-16 RSTREAM(1)