Sponsored Content
Top Forums UNIX for Beginners Questions & Answers Explanation around "+r" in egrep Post 303036158 by sand1234 on Monday 17th of June 2019 08:19:22 AM
Old 06-17-2019
Response to Peasant

Hi Peasant,

Here's the original output.
So I take this to mean match lines containing one or more numbers followed by the character r?

Code:
#show processes pidin
Mon Jun 17 09:16:27.826 EDT
     pid tid name               prio STATE       Blocked
       1   1 /procnto-smp-instr   0f RUNNING
       1   2 /procnto-smp-instr   0f RUNNING
       1   3 /procnto-smp-instr   0f RUNNING
       1   4 /procnto-smp-instr   0f READY
       1   5 /procnto-smp-instr  10r RUNNING
       1   6 /procnto-smp-instr  10r RECEIVE     1
       1   7 /procnto-smp-instr  10r RECEIVE     1
       1   8 /procnto-smp-instr  10r RECEIVE     1
       1  10 /procnto-smp-instr  10r RECEIVE     1
       1  11 /procnto-smp-instr  10r RECEIVE     1
       1  13 /procnto-smp-instr  10r RECEIVE     1
       1  16 /procnto-smp-instr  10r RECEIVE     1
       1  17 /procnto-smp-instr  10r RECEIVE     1
       1  18 /procnto-smp-instr  10r RECEIVE     1
       1  30 /procnto-smp-instr  10r RECEIVE     1
    8195   1 sbin/dllmgr         10r RECEIVE     4
    8195   2 sbin/dllmgr         10r NANOSLEEP
    8195   3 sbin/dllmgr         10r RECEIVE     1
    8195   4 sbin/dllmgr         10r RECEIVE     4
    8195   5 sbin/dllmgr         10r RECEIVE     4
   12290   1 in/wd-critical-mon  10r RECEIVE     1
   12290   2 in/wd-critical-mon  63r NANOSLEEP
   12290   3 in/wd-critical-mon  11r NANOSLEEP
   12290   4 in/wd-critical-mon  11r NANOSLEEP
   12290   5 in/wd-critical-mon  11r NANOSLEEP
   12290   6 in/wd-critical-mon  11r NANOSLEEP
   12290   7 in/wd-critical-mon  10r NANOSLEEP
   12290   8 in/wd-critical-mon  10r NANOSLEEP
   12290   9 in/wd-critical-mon  10r NANOSLEEP
   12290  10 in/wd-critical-mon  10r NANOSLEEP
   12295   1 pkg/bin/pkgfs       10r RECEIVE     1
   12295   2 pkg/bin/pkgfs       10r SIGWAITINFO
   12295   3 pkg/bin/pkgfs       10r RECEIVE     1
   12295   4 pkg/bin/pkgfs       10r RECEIVE     1
   12295   5 pkg/bin/pkgfs       10r RECEIVE     1
   12296   1 g/bin/devc-ser8250  10r RECEIVE     1
   12297   1 pkg/bin/devc-pty    10r RECEIVE     1
   12298   1 kg/bin/devc-conaux  16r RECEIVE     1
   12298   2 kg/bin/devc-conaux  16r SIGWAITINFO
   12298   3 kg/bin/devc-conaux  16r RECEIVE     5
   12298   4 kg/bin/devc-conaux  16r SEM         79ddc7c4
   12298   5 kg/bin/devc-conaux  21r INTR

 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Explain the line "mn_code=`env|grep "..mn"|awk -F"=" '{print $2}'`"

Hi Friends, Can any of you explain me about the below line of code? mn_code=`env|grep "..mn"|awk -F"=" '{print $2}'` Im not able to understand, what exactly it is doing :confused: Any help would be useful for me. Lokesha (4 Replies)
Discussion started by: Lokesha
4 Replies

2. UNIX for Dummies Questions & Answers

search ")" with egrep - egrep: syntax error

Hi Guys, we have a shell script which basically query the Database which retrieves huge data and use the data with "egrep" . Now there is some data which contains characters like "abc)" and the same is used like below : "egrep (.+\|GDPRAB16\|GDPR/11702 96 abc)\|$ temp.txt" now while... (7 Replies)
Discussion started by: sagarjani
7 Replies

3. UNIX for Dummies Questions & Answers

How to use the "grep/egrep" command to search files.

Hi Team, I am new to this forum and also trying to learn Unix. I will highly appriciate your help if you can help me to get the right command . {{{ I use the command " today | egrep '(10:| 11: )' | grep ERROR " to grep all the files that has been error betweeen 10 to 11... (6 Replies)
Discussion started by: rkhanal
6 Replies

4. UNIX for Dummies Questions & Answers

Explanation of "total" field in "ls -l" command output

When I do a listing in one particular directory (ls -al) I get: total 43456 drwxrwxrwx 2 root root 4096 drwxrwxrwx 3 root root 4096 -rwxrwxr-x 1 nobody nobody 3701594 -rwxrwxr-x 1 nobody nobody 3108510 -rwxrwxr-x 1 nobody nobody 3070580 -rwxrwxr-x 1 nobody nobody 3099733 -rwxrwxr-x 1... (1 Reply)
Discussion started by: proactiveaditya
1 Replies

5. Shell Programming and Scripting

awk command to replace ";" with "|" and ""|" at diferent places in line of file

Hi, I have line in input file as below: 3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL My expected output for line in the file must be : "1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL" Can someone... (7 Replies)
Discussion started by: shis100
7 Replies

6. Shell Programming and Scripting

Escaping backslash and asterisk in egrep to match "\*"

So far what i've got is egrep '^(\\)\*$'No luck. I've searched the web and not much luck. I know about the escape character \ but its confusing to figure out how to use it to match a backslash and use it to escape the asterisk also. Any ides? Thanks! (8 Replies)
Discussion started by: matthewfs
8 Replies

7. UNIX for Dummies Questions & Answers

Explanation on problem "match" function awk

Hello Unix experts, If I could get any explanations on why the code below doesn't work it would be great ! My input looks like that ("|" delimited): Saaaaabbbbbccccc|ok Sdddddfffffggggg|ok The goal is, if $2 is "ok", to remove everything before the pattern given in the match function... (5 Replies)
Discussion started by: lucasvs
5 Replies

8. UNIX for Dummies Questions & Answers

Egrep confusion with "I" and "-I" pattern

I am executing following command egrep -w I filename.txt the filename.txt has following data .... -I 07-18 08:31:19.924 9880 6 SessionManager ConnectConfig: ConfigurationWebService LoginResults=SuccessfulLogin I am so hungry that I need to eat I expect egrep to print only the second... (1 Reply)
Discussion started by: VBG
1 Replies

9. UNIX for Dummies Questions & Answers

Using "mailx" command to read "to" and "cc" email addreses from input file

How to use "mailx" command to do e-mail reading the input file containing email address, where column 1 has name and column 2 containing “To” e-mail address and column 3 contains “cc” e-mail address to include with same email. Sample input file, email.txt Below is an sample code where... (2 Replies)
Discussion started by: asjaiswal
2 Replies

10. Shell Programming and Scripting

Bash script - Print an ascii file using specific font "Latin Modern Mono 12" "regular" "9"

Hello. System : opensuse leap 42.3 I have a bash script that build a text file. I would like the last command doing : print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt where : print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies
RECEIVE(1)						      General Commands Manual							RECEIVE(1)

NAME
receive - receive files from the sendfile spool SYNOPSIS
receive [ -d ] [ -r ] [ -k ] [ -P ] [ -S ] [ -Z spool ] [ -q ] [ -ffrom ] file [...] receive -n [ -d ] [ -r ] [ -k ] [ -P ] [ -S ] [ -Z spool ] [ -q ] file-number [...] receive [ -s ] [ -l ] [ -L ] [ -R ] [ -ffrom ] receive -b user[@host] [ -k ] [ -f"from" ] file [...] receive -b user[@host] [ -k ] [ -f"from" ] -n file-number [...] receive -b user[@host] [ -k ] -a DESCRIPTION
receive files from the sendfile spool which has been sent to you. If there is already a file with the same name you will be prompted for overwriting or renaming. Allowed wildcards in file names are: * ? [abc] [^abc] CAUTION: you have to put wildcards and other special characters in '' quotes to hide them for interpretation by your shell. OPTIONS
-n receive file number(s) -d delete instead of receive -a receive (or delete or bounce) all files -r rename before receiving -k keep files in spool after receiving -P pipe files to stdout -S receive only pgp-signed files -s list files in short format -l list files -L list files and look inside archives, too -R renumber files in spool -b bounce (forward) files to another recipient -q quiet mode: no questions asked -fuser all actions refer only to files from this user -Z spool specify an alternate spool directory EXAMPLES
receive -L list all files in long format. receive 'blubb*' receive all files starting with string "blubb". receive -daf microsoft.com delete all files from microsoft.com sites. receive -b framstag@bofh '*.jpg' bounce all *.jpg-files to framstag@bofh. FILES
/var/spool/sendfile The sendfile spool directory. /var/spool/sendfile/$USER/log A log of the last transfers. /etc/sendfile.deny Users which are not allowed to receive files or messages (set by root). SEE ALSO
sendfile(1). AUTHOR
Ulli Horlacher - framstag@rus.uni-stuttgart.de 3rd Berkeley Distribution RECEIVE(1)
All times are GMT -4. The time now is 03:50 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy