09-22-2010
Thanks a lot for your suggestion!
I was looking for a way to do it directly but apparenty there isn't one!
Thanks again!
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
New to shell scripting.
I can't get my script to execute multiple commands.
Here's the code. It's a menu script.
#!/bin/ksh
clear
print "SDE MENU"
PS3="SDE MENU, enter choice:"
select clean_menu in "tasdedev instance 5151" "orkindev instance 5155" "tasdetst
instance 5157" "orkinsys... (1 Reply)
Discussion started by: hvincent
1 Replies
2. Shell Programming and Scripting
I want to log into a remote server transfer over a new config and then backup the existing config, replace with the new config.
I am not sure if I can do this with BASH scripting.
I have set up password less login by adding my public key to authorized_keys file, it works.
I am a little... (1 Reply)
Discussion started by: bash_in_my_head
1 Replies
3. Shell Programming and Scripting
I've struggled to find a solution to this problem from searching so I thought I'd write a post to see what can be done.
I'm attempting to connect and run commands on 'server2' but because of security limitations I cannot access it directly. I can however ssh into 'server1' and then into... (7 Replies)
Discussion started by: mcintosh.jamie
7 Replies
4. Shell Programming and Scripting
Hi
Can someone help me to figure out
Want to execute few cmds in remote host thru ssh
Tried below cmd
-------------------------------excerpt-------------------
RDIR=/data1/logs ---> variable stores rem. server directory
TODAY="`date '+%b %d'`"
ssh -i $userid@$host "cd... (2 Replies)
Discussion started by: id100
2 Replies
5. Shell Programming and Scripting
I have a file as follows:
cat /etc/mxg/ssh-hostsmx.example1.com.au:2225
mx2.example2.com.au:2225
mx.example3.com.au:2225
mail.example4.com.au:2225
mail.example5.org.au:2225
mail.example6.com.au:2225I want to dynamically create aliases for quick access to these servers from bash. I wrote... (4 Replies)
Discussion started by: jelloir
4 Replies
6. UNIX for Dummies Questions & Answers
commands to execute unix script (1 Reply)
Discussion started by: sunilamarnadh
1 Replies
7. Shell Programming and Scripting
Requirement:
Run a shell script with below inputs
file name
checksum
path
the script should go to multiple servers (around 35) and verify the input cksum and if there is a mismatch display a simple message to the user that cksum verification failed.
host details, user id /... (1 Reply)
Discussion started by: amicableperson
1 Replies
8. Shell Programming and Scripting
Hello,
I am running into few issues, please suggest me what I am missing.
I am running this script on a linux host.
Main idea of this script is to, login to each host via ssh and get uid of user, service user that I trying to run this script, has already deployed ssh keys and provide sudo... (8 Replies)
Discussion started by: bobby320
8 Replies
9. Shell Programming and Scripting
Hi,
The below command is not giving me the count , Can somebody help me in re-writing this pls .
Proc_Exist=`ssh -q -o "BatchMode=yes" -o "PasswordAuthentication=no" $OAUSER@${Primary_Node} ps -ef |
grep -v grep | grep "${ICM_Proc}" |wc -l `
Also the same problem with below... (13 Replies)
Discussion started by: Y.balakrishna
13 Replies
10. Shell Programming and Scripting
Hi
I need to write a script to ssh through several hops (e.g. HostA-HostB-HostC-HostD), where Host A does not have direct assess to HostC ; HostB cannot access HostD directly.
when I ssh 3 hops and run command with arg1, arg2 and redirect the output to a file, e.g.
HostA> ssh -t HostB ssh -t... (3 Replies)
Discussion started by: chiensh
3 Replies
LEARN ABOUT DEBIAN
snmail
snmail,v0.3.8(8) System Manager's Manual snmail,v0.3.8(8)
NAME
snmail - mail-to-news filter
SYNOPSIS
snmail [-sP] [listname [prefix]]
DESCRIPTION
snmail reads a single email message on standard input, and writes the converted message to standard output. This output is suitable for
feeding to snstore.
snmail does these conversions: If the first line is a UUCP From_ line, it is silently discarded; a Newsgroups: line is added with the value
of prefixlistname (prefix concatenated with listname), and other existing Newsgroups: lines are removed; and a Path: line is created from
all Received: lines, which are removed; all header lines are unfolded; if no message ID exists, one is created; message IDs in all Refer-
ences: lines and In-Reply-To: lines are collected into a single References: line; all lines are rewritten to end in CRLF; and a lone . on
a line is written at the end of the message.
snmail will accept and pass on messages with invalid header fields.
snmail is meant to be run from a .forward or the /etc/aliases file (if you're using sendmail or similar) or from a .qmail file (if you're
using qmail). snmail may write status or error messages to standard error.
OPTIONS
-s Pipe output to snstore directly, do not write to standard output. This is so the exit status is not lost in a shell pipeline. If
you use this flag, it is also a good idea to also use -c (tell snstore to check if article already exists).
Other options
snmail also accepts options intended for snstore, viz. -c, -v, and -n, and these are passed on uninterpreted.
ARGUMENTS
prefix is the prefix of the newsgroup; if not specified, it defaults to local. (note the trailing .). prefix may not begin with a .
(dot) but it may be empty.
listname
completes the newsgroup name; if not specified, it is the local part of the address in the Return-Path: line if it exists and isn't
empty; otherwise it is the local part of the messages' first From:. So if the message originated from the list <linux-lem-
mings@vger.rutgers.edu>, then the default newsgroup becomes local.linux-lemmings. listname may be empty if prefix isn't.
You may want to have a file /var/spool/sn/prefixlistname/.nopost to deny posting from all and sundry, to prevent the mailing list
newsgroup from being contaminated.
prefix and listname may contain uppercase characters; these are converted to lower case.
USAGE
There are two ways of forwarding mail to the sn news spool: directly from a user's mail address; or forwarded to a central address and then
invoking snmail. The central concern here is permissions; while anyone can run snmail, not everyone may store mail in the spool. Mail
setups vary a lot, so basically you're on your own here.
ENVIRONMENT VARIABLES
SNROOT If this is set and is not empty, the value is used in place of /var/spool/sn, the default news spool directory.
PATH If -s was specified, determines where to look for snstore, before looking in /usr/sbin.
EXIT STATUS
snmail exits 0 if the message was successfully converted and written, or if the message ID already exists in the ID database and the mes-
sage was not stored or converted.
snmail exits with 1 on usage error, 2 on operational error, 3 if the mail message wasn't in the proper format.
N.B. Harold Tay snmail,v0.3.8(8)