07-30-2003
Thank you very much Perderabo. I was able to automate the report process.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
I'm not very good with the serach patterns and I'd need a sample how to find a line that has multiple patterns.
Say I want to find a line that has "abd", "123" and "QWERTY" and there can be any characters or numbers between the serach patterns, I have a file that has thousands of lines and... (10 Replies)
Discussion started by: Juha
10 Replies
2. Shell Programming and Scripting
Good day, great gurus,
I'm new to Perl, and programming in general. I'm trying to retrieve a column of data from my text file which spans a non-specific number of lines. So I did a regexp that will pick out the columns. However,my pattern would vary. I tried using a foreach loop unsuccessfully.... (2 Replies)
Discussion started by: Sp3ck
2 Replies
3. Shell Programming and Scripting
Hi,
I have to write one script that has to search a list of numbers in certain zipped files.
For eg. one file file1.txt contains the numbers. File1.txt contains 5,00,000 numbers and I have to search each number in zipped files(The number of zipped files are around 1000 each file is 5 MB)
I have... (10 Replies)
Discussion started by: vsachan
10 Replies
4. Shell Programming and Scripting
I have two lists in a file that look like
a b
b a
e f
c d
f e
d c
I would like a final list
a b
c d
e f
I've tried multiple grep and awk but can't get it to work (8 Replies)
Discussion started by: godzilla07
8 Replies
5. Shell Programming and Scripting
I would like to print result of multiple search pattern invoked from an one liner. The code looks like this but won't work
gawk -F '{{if ($0 ~ /pattern1/) pat1=$1 && if ($0 ~ /pattern2/) pat2=$2} ; print pat1, pat2}'
Can anybody help getting the right code? (10 Replies)
Discussion started by: sdf
10 Replies
6. Shell Programming and Scripting
Hi,
I tried to search multiple pattern using awk
trans=1234
reason=LN MISMATCH
rec=`awk '/$trans/ && /'"$reason"'/' file`
whenevr i tried to run on command promt it is executing but when i tried to implment same logic in shell script,it is failing i.e $rec is empty
... (6 Replies)
Discussion started by: ns64110
6 Replies
7. Shell Programming and Scripting
Hi,
I have a file content as below.
Table : PAYR
Displayed fields: 15 of 15 Fixed columns: 4 List width 0999... (4 Replies)
Discussion started by: shirdi
4 Replies
8. Shell Programming and Scripting
Hi All,
I am starting a service which will redirect its out put into 2 logs say A and B.
Now for succesful startup of the service i need to search pattern1 in log A and pattern2 in log B which are writen continuosly.
Now my requirement is to find the patterns in the increasing logs A and B... (19 Replies)
Discussion started by: Girish19
19 Replies
9. Shell Programming and Scripting
Hi Bigshots,
I have a pattern file with two columns. I have another data file. If column 1 in the pattern file appears as the 4th column in the data file, I need to replace it (4th column of data file) with column 2 of the pattern file. If the pattern is found in any other column, it should not... (6 Replies)
Discussion started by: ss112233
6 Replies
10. Shell Programming and Scripting
Hi,
I have scenario like below and need to search for multiple patterns
Eg:
Test
Time Started= secs
Time Ended = secc
Green test
Test
Time Started= secs
Time Ended = secc
Green test
Output:
I need to display the text starting with Test and starting with Time... (2 Replies)
Discussion started by: weknowd
2 Replies
MSGCHK(1) [nmh-1.5] MSGCHK(1)
NAME
msgchk - check for messages
SYNOPSIS
msgchk [-date | -nodate] [-notify all/mail/nomail ] [-nonotify all/mail/nomail ] [-host hostname] [-user username] [-sasl] [-saslmech mech-
anism] [-snoop] [users ... ] [-version] [-help]
DESCRIPTION
The msgchk program checks all known mail drops for mail waiting for you. For those drops which have mail for you, msgchk will indicate if
it believes that you have seen the mail in question before.
The -notify type switch indicates under what circumstances msgchk should produce a message. The default is -notify all which says that
msgchk should always report the status of the users maildrop. Other values for `type' include `mail' which says that msgchk should report
the status of waiting mail; and, `nomail' which says that msgchk should report the status of empty maildrops. The -nonotify type switch
has the inverted sense, so -nonotify all directs msgchk to never report the status of maildrops. This is useful if the user wishes to
check msgchk's exit status. A non-zero exit status indicates that mail was not waiting for at least one of the indicated users.
If msgchk produces output, then the -date switch directs msgchk to print out the last date mail was read, if this can be determined.
Using POP
msgchk will normally check all the local mail drops, but if the option "pophost:" is set in the mts configuration file "mts.conf", or if
the -host hostname switch is given, msgchk will query this POP service host as to the status of mail waiting.
The default is for msgchk to assume that your account name on the POP server is the same as your current username. To specify a different
username, use the `-user username' switch.
When using POP, you will normally need to type the password for your account on the POP server, in order to retrieve your messages. It is
possible to automate this process by creating a ".netrc" file containing your login account information for this POP server. For each POP
server, this file should have a line of the following form. Replace the words mypopserver, mylogin, and mypassword with your own account
information.
machine mypopserver login mylogin password mypassword
This ".netrc" file should be owned and readable only by you.
For debugging purposes, there is also a switch -snoop, which will allow you to watch the POP transaction take place between you and the POP
server.
If nmh has been compiled with SASL support, the -sasl switch will enable the use of SASL authentication. Depending on the SASL mechanism
used, this may require an additional password prompt from the user (but the ".netrc" file can be used to store this password). The
-saslmech switch can be used to select a particular SASL mechanism.
If SASL authentication is successful, inc will attempt to negotiate a security layer for session encryption. Encrypted traffic is labelled
with `(encrypted)' and `(decrypted)' when viewing the POP transaction with the -snoop switch.
FILES
$HOME/.mh_profile The user profile
/etc/nmh/mts.conf nmh mts configuration file
/var/mail/$USER Location of mail drop
PROFILE COMPONENTS
None
SEE ALSO
inc(1)
DEFAULTS
`user' defaults to the current user
`-date'
`-notify all'
CONTEXT
None
MH.6.8 11 June 2012 MSGCHK(1)