07-25-2011
If I use normal ssh..then the password is prompted from the command prompt...
Is there a way to pass username/pwd together in ssh command?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi ..
I have a dynamic script called from a programming language called Powerhouse (4GL).
The module, called QUIZ, allows the user to call shell commands from within it...
i.e.
!rm -f mipss156t2cmd1.bat mipss156t2tmp1.txt
!printf '#!/bin/csh\n' > mipss156t2cmd1.bat
!printf 'setenv... (0 Replies)
Discussion started by: ElCaito
0 Replies
2. Shell Programming and Scripting
Hi...
Actually, I want to pass a few variables to the function and print it. But, its looks like not working. Could some body help me how could i do that ?... below is my program...
#!/usr/bin/ksh
usage()
{
echo "Usage: $0 -n -a -s -w -d"
exit
}
rename()
{
echo "rename $1 $2"... (5 Replies)
Discussion started by: bh_hensem
5 Replies
3. Shell Programming and Scripting
HI all
I am calling a script "b" from script "a". In script "a", i connect to database and get month and year. I have to pass these same values to script b. How can i do that. How can i pass parameters from one script to another (3 Replies)
Discussion started by: vasuarjula
3 Replies
4. Shell Programming and Scripting
Hi All,
I have a doubt.
Can we assign a regular expression for pattern searching to a variable in a script and then use that variable in place of a regular expression in sed command.I tried but got some syntax error!!Is it not possible.Because my requirement is that i have a generic script to get... (8 Replies)
Discussion started by: usha rao
8 Replies
5. Shell Programming and Scripting
still new to this expect
useing bach shell to cammand expect script i tink i have that right!
i want to have the test im running upon every complted cycle copyed to a folder. cant seem to get it to work.
Ive tryed
log_file -a $globallogdir/deveoper.log
proc dbglog {notsure what... (0 Replies)
Discussion started by: melvin
0 Replies
6. Shell Programming and Scripting
Hi folks,
What I want to do is to check if there is an instance of running vlc on a remote server, then kill it, and start it again. The code I came up with is:
#!/bin/bash
expectFcn() {
expect -c "
set timeout -1
spawn ssh \"$1@$2\" \"$4\"
match_max 100000
expect {
-re... (2 Replies)
Discussion started by: dukevn
2 Replies
7. Shell Programming and Scripting
I need call expect script from shell script and pass values some of which could contain space. How to make expect to treat such values as one variable? (1 Reply)
Discussion started by: urello
1 Replies
8. Shell Programming and Scripting
I'm trying to make an expect function that will pass through a variable.
/usr/bin/expect<<EOD
spawn su -
expect "Password: "
send "$psswd\r"
expect "#"
send "/etc/init.d/network restart >>$log\r"
expect "#"
send "exit\r"
EOD
The $log passes through but my $psswd fails
I know... (1 Reply)
Discussion started by: Lotheovian
1 Replies
9. Shell Programming and Scripting
Hello, I have two bash scripts like the following:
script 1:
#!/bin/bash
var=WORLD
bash path/to/second/script/script2.bash
script 2:
#!/bin/bash
echo "HELLO $var"
I expected the output to be "HELLO WORLD" but instead, I get "HELLO". I understand that when I envoke another bash... (2 Replies)
Discussion started by: jl487
2 Replies
10. UNIX for Dummies Questions & Answers
Below are three variables, which I want to pass into variable RESULT1
username1=userid
poihostname1=dellsys.com
port1=8080
How can I pass these variables into below code...
RESULT1=$((ssh -n username1@poihostname1 time /usr/sfw/bin/wget --user=sam --password=123 -O /dev/null -q... (4 Replies)
Discussion started by: manohar2013
4 Replies
LEARN ABOUT DEBIAN
myproxy-admin-query
myproxy-admin-query(8) MyProxy myproxy-admin-query(8)
NAME
myproxy-admin-query - query MyProxy repository contents
SYNOPSIS
myproxy-admin-query [ options ]
DESCRIPTION
The myproxy-admin-query command displays information about the credentials stored in the MyProxy repository. It can also be used to remove
credentials from the repository, by combining query options with --remove. It accesses the repository directly and must be run on the
machine where the myproxy-server(8) is installed from the account that owns the repository.
An example cron job for running myproxy-admin-query periodically to remove invalid (expired, revoked, etc.) credentials from the repository
is provided at $GLOBUS_LOCATION/share/myproxy/myproxy.cron.
OPTIONS
-h, --help
Displays command usage text and exits.
-u, --usage
Displays command usage text and exits.
-v, --verbose
Enables verbose debugging output to the terminal.
-V, --version
Displays version information and exits.
-l username, --username username
Return information on credentials for a single username. By default, the command returns information on all credentials for all
usernames.
-k name, --credname name
Return information on the credentials with the specified name.
-o DN, --owner DN
Return information on the credentials owned by the specified distinguished name.
-e hours, --expiring_in hours
Return information on credentials with remaining lifetime less than the specified number of hours. For example, -e 0 will return
all expired credentials.
-t hours, --time_left hours
Return information on credentials with remaining lifetime greater than the specified number of hours.
-i, --invalid
Return information on invalid (expired, revoked, etc.) credentials.
-s dir, --storage dir
Specifies the location of the credential storage directory. The directory must be accessible only by the user running the myproxy-
server process for security reasons. Default: /var/lib/myproxy or /var/myproxy or $GLOBUS_LOCATION/var/myproxy
-c file, --config file
Specifies the location of the myproxy-server configuration file, for OCSP options. Default: /etc/myproxy-server.config or
$GLOBUS_LOCATION/etc/myproxy-server.config
-r, --remove
Remove the credentials matching the query from the repository. For example, myproxy-admin-query -e 0 -r will remove all expired
credentials from the repository.
-L 'msg', --lock 'msg'
Places the credentials matching the query under an administrative lock and specifies a message to be returned on access attempts.
Be sure to put the message in quotes so it is captured as one argument to the command.
-U, --unlock
Removes any administrative locks for the credentials matching the query.
EXIT STATUS
0 on success, >0 on error
AUTHORS
See http://myproxy.ncsa.uiuc.edu/about for the list of MyProxy authors.
SEE ALSO
myproxy-change-pass-phrase(1), myproxy-destroy(1), myproxy-init(1), myproxy-logon(1), myproxy-retrieve(1), myproxy-store(1), myproxy-
server.config(5), myproxy-admin-adduser(8), myproxy-admin-change-pass(8), myproxy-admin-load-credential(8), myproxy-server(8)
MyProxy 2011-09-19 myproxy-admin-query(8)