bash shell send script question


 
Thread Tools Search this Thread
Operating Systems Solaris bash shell send script question
# 1  
Old 11-09-2011
bash shell send script question

Hi Experts,

Need your help.

I am trying to send a command via ssh to about a hundred network devices. I intend to do this via a bash script something similar to the below:

ssh -l user testmachine.com "show version"

Obviously this will not work given the password prompt that comes up prior the command being run.

Please take note that I cannot use RSA keys since that would require my installing my pubkey to each device; this will take forever.
I also can't install sshpass cause I would have to reach out to the server admin; that too will take forever.

Thanks in advance.
# 2  
Old 11-09-2011
and now? what do you want us to do?
# 3  
Old 11-09-2011
recompile ssh so it takes password as parameter, obviously.. Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

In Bash shell - the ps -ef shows only the /bin/bash but the script name is not displayed

In Bash shell - the ps -ef shows only the /bin/bash but the script name is not displayed ? Is there any way to get the script names for the process command ? --- Post updated at 08:39 AM --- in KSH (Korn Shell), my command output shows the script names but when run in the Bash Shell... (3 Replies)
Discussion started by: i4ismail
3 Replies

2. UNIX for Beginners Questions & Answers

To send ID and Password for each command using expect feature in bash script

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

3. Shell Programming and Scripting

Send ctrl-C signal using bash script.

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

4. Shell Programming and Scripting

Bash Script: Send files to SFTP using Expect

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

5. Shell Programming and Scripting

Bash shell script undefined array item value question

Hello, I'm new here. I test these expressions's value in my script : (in centOS 6 ) #!/bin/bash array='something' echo "############" echo ${array} echo ${array} echo ${array} echo "############" The output result is : ################# something something #################... (5 Replies)
Discussion started by: lingjing
5 Replies

6. UNIX for Dummies Questions & Answers

How to send e-mail from shell script ( C shell )?

Hi , How to send e-mail from shell script ( C shell ) . Mailx command is not working ( It didn't giving error also ). Please help me (2 Replies)
Discussion started by: arukuku
2 Replies

7. Shell Programming and Scripting

Bash script to send SMS

Hey guys I was wondering how to go about creating a bash script to send SMS..any ideas are appreciated.. (2 Replies)
Discussion started by: blackzeus
2 Replies

8. Shell Programming and Scripting

Quick question: calling c-shell script from bash

Hello, I have a quick reference question: I have a very long, but fairly straigtforward script written in c-shell. I was wondering if it is possible to call this script from bash (for ex. having a function in bash script which calls the c-shell script when necessary), and if so, are there any... (1 Reply)
Discussion started by: lapiduslost
1 Replies

9. Shell Programming and Scripting

one question for bash shell script

Just one question for bash shell script. In bash script, you can use *.txt to call any files in current folder that ends with .txt, like rm *.txt will remove all txt file in current folder. My question is can you actually remember or use the file name among *.txt, I know file=*.txt will not... (9 Replies)
Discussion started by: zx1106
9 Replies

10. Shell Programming and Scripting

BASH shell script question

I want to make shell script that takes a list of host names on my network as command line arguments and displays whether the hosts are up or down, using the ping command to display the status of a host and a for loop to process all the host names. Im new to shell scripting so Im not quite sure... (3 Replies)
Discussion started by: ewarmour
3 Replies
Login or Register to Ask a Question