Sponsored Content
Full Discussion: syslog grep/awk/sed display
Top Forums Shell Programming and Scripting syslog grep/awk/sed display Post 302438403 by Franklin52 on Monday 19th of July 2010 02:30:41 PM
Old 07-19-2010
Sorry, I misunderstood the question, try this:
Code:
awk '(!/sshd/ && !/ftpd/) && (/fail/ || /error/){print; f=1;}
/above message repeats/ && f{print;f=0}' syslog.log

This User Gave Thanks to Franklin52 For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

need help!!!awk,grep,sed

hi all by using cat /etc/passwd I've got these output. ajh1ect:x:839:501:Anthony:/home/ajh1ect:/bin/bash mjb1ect:x:840:501:Michael:/home/mjb1ect:/bin/bash mv3ect:x:841:501:Marian:/home/mv3ect:/bin/bash now I want to see just the user ID and group ID. so what is the code will be with... (2 Replies)
Discussion started by: nokia1100
2 Replies

2. Shell Programming and Scripting

Sed | Awk | Grep

Can someone help me in understanding when to use SED, AWK and GREP (3 Replies)
Discussion started by: kn.naresh
3 Replies

3. UNIX for Dummies Questions & Answers

Awk, Sed and Grep

Hello. I am an older newbie trying to learn Unix. I have a task to perform and it entails counting lines of code. Currently, I am pointing to the directory where the files are contained and performing a 'find' on the file extensions (cpp, c, html, java, etc.) and piping that info with a 'wc -l'.... (2 Replies)
Discussion started by: mastachef
2 Replies

4. UNIX for Dummies Questions & Answers

Grep Sed or Awk?

I have two .txt files one called good.txt and the other one is called bad.txt. Both contain email addresses in the following format: john@john.com bob@bob.com sarah@sarah.com Basically, I want to scrub good.txt against bad.txt and save the resulting output in scrubbed.txt meaning that if... (2 Replies)
Discussion started by: holyearth
2 Replies

5. UNIX for Dummies Questions & Answers

How could i get this by sed or grep or awk ????

------------------------------------------------------------------ Ex of Warning messgae,(Many similar lines occure for Both Test and Test1) -WARNING:Below Field not implemented in file File name: /home/test/ new/file1, msg buffer is: :Test:000948 ... (1 Reply)
Discussion started by: prsam
1 Replies

6. UNIX for Dummies Questions & Answers

awk grep sed or something better

Hello all, Can anyone help with the following? :) I have file1 with 150,000 words in a list and file2 with 148,000 words in a list - all of which are in file1. I want to create a new file with the words that DO NOT match (i.e of 2000 words). I have done this very simple command , which is... (1 Reply)
Discussion started by: dr_sabz
1 Replies

7. UNIX for Dummies Questions & Answers

grep/awk/sed?

Thread1 { x = 2 y = 10485 } Thread2 { x = 16 y = 1048 } Thread3 { x = 1 y = 1049 } Thread4 { x = 4 y = 1047 z = 500 } Suppose the above is a piece of code. I need to automate and verify that the value of x under Thread1's 2. There are several... (3 Replies)
Discussion started by: foxtron
3 Replies

8. Shell Programming and Scripting

Display output as columns using grep/awk/sed

I have several files with say something like cat sparrow I can grep for "cat" and "sparrow" and usually the output is one below the other cat sparrow How can I view these as columns say Pets Birds cat sparrow Would be great if this can be on command line using awk or... (1 Reply)
Discussion started by: gubbu
1 Replies

9. Shell Programming and Scripting

Grep awk sed display value

Hello all, I wget a file and i tried to display some value : content=$(wget IP:9005/GlobalStatistics -q -O -) echo onlineusers $content > /home/active_session_log #cat active_session_log {"ActiveSessionCount":0,"ActiveGameCount":0,"QueueMatchMakingPlayerCount":0} My goal is write... (7 Replies)
Discussion started by: acidozik
7 Replies

10. Shell Programming and Scripting

Grep/awk/sed help

got a file as y.txt 1 abc,def,ghj 2 defj,abc.kdm,ijk 3 lmn,cbk,mno 4 tmp,tmop,abc,pkl 5 pri,chk,cbk,lmo 6 def,cbk.pro,abc.kdm i want to search in the above file the key word like abc looking for two outcomes by passing the parameter value as abc into function and the two outocmes are... (6 Replies)
Discussion started by: silgun
6 Replies
Locale::Codes::LangFam(3)				User Contributed Perl Documentation				 Locale::Codes::LangFam(3)

NAME
Locale::Codes::LangFam - standard codes for language extension identification SYNOPSIS
use Locale::Codes::LangFam; $lext = code2langfam('apa'); # $lext gets 'Apache languages' $code = langfam2code('Apache languages'); # $code gets 'apa' @codes = all_langfam_codes(); @names = all_langfam_names(); DESCRIPTION
The "Locale::Codes::LangFam" module provides access to standard codes used for identifying language families, such as those as defined in ISO 639-5. Most of the routines take an optional additional argument which specifies the code set to use. If not specified, the default ISO 639-5 language family codes will be used. SUPPORTED CODE SETS
There are several different code sets you can use for identifying language families. A code set may be specified using either a name, or a constant that is automatically exported by this module. For example, the two are equivalent: $lext = code2langfam('apa','alpha'); $lext = code2langfam('apa',LOCALE_LANGFAM_ALPHA); The codesets currently supported are: alpha This is the set of three-letter (lowercase) codes from ISO 639-5 such as 'apa' for Apache languages. This is the default code set. ROUTINES
code2langfam ( CODE [,CODESET] ) langfam2code ( NAME [,CODESET] ) langfam_code2code ( CODE ,CODESET ,CODESET2 ) all_langfam_codes ( [CODESET] ) all_langfam_names ( [CODESET] ) Locale::Codes::LangFam::rename_langfam ( CODE ,NEW_NAME [,CODESET] ) Locale::Codes::LangFam::add_langfam ( CODE ,NAME [,CODESET] ) Locale::Codes::LangFam::delete_langfam ( CODE [,CODESET] ) Locale::Codes::LangFam::add_langfam_alias ( NAME ,NEW_NAME ) Locale::Codes::LangFam::delete_langfam_alias ( NAME ) Locale::Codes::LangFam::rename_langfam_code ( CODE ,NEW_CODE [,CODESET] ) Locale::Codes::LangFam::add_langfam_code_alias ( CODE ,NEW_CODE [,CODESET] ) Locale::Codes::LangFam::delete_langfam_code_alias ( CODE [,CODESET] ) These routines are all documented in the Locale::Codes::API man page. SEE ALSO
Locale::Codes The Locale-Codes distribution. Locale::Codes::API The list of functions supported by this module. http://www.loc.gov/standards/iso639-5/id.php ISO 639-5 . AUTHOR
See Locale::Codes for full author history. Currently maintained by Sullivan Beck (sbeck@cpan.org). COPYRIGHT
Copyright (c) 2011-2013 Sullivan Beck This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.16.3 2013-02-27 Locale::Codes::LangFam(3)
All times are GMT -4. The time now is 12:22 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy