05-19-2004
get last section from large logfile
Hi all,
I need to pull the (last section) from the header to the end of file. This logfile will have many sections appended, but I only need to capture the last one and email it to someone. Any ideas? Thanks Kathy
Example Logfile:
=============
= BOX : SAPCFI
= JOB : SAPCFI
= Commande : -D -k A -C cfg_PK pr
=
= Wed May 19 13:10:25 EST 2004
=
blah
blah
blah
=============
= BOX : SAPCFI
= JOB : SAPCFI
= Commande : -D -k A -C cfg_PK pr
=
= Wed May 19 13:21:25 EST 2004
=
blah
blah
blah
10 More Discussions You Might Find Interesting
1. Post Here to Contact Site Administrators and Moderators
What are the chances of possibly posting some of the more common how-to type stuff for the newbies so we can avoid the repititious stuff that appears every other day? Not so much like a Q&A forum, but more like a reference area for the mundane stuff.
Beyond searching the forum, I think people... (3 Replies)
Discussion started by: ober5861
3 Replies
2. Post Here to Contact Site Administrators and Moderators
Just like we have a section "Unix for dummies..." , why not have a section on UNIX BACKUP AND RECOVERY
Thanks
:) (3 Replies)
Discussion started by: kapilv
3 Replies
3. Shell Programming and Scripting
I am dealing with a very large firewall logfile (more than 10G),
the logfile like this
*snip*
Nov 9 10:12:01 testfirewall root:
Nov 9 10:12:01 testfirewall root: 0:00:11 accept testfw01-hme0 >hme0 proto: icmp;
src: test001.example.net; dst: abc.dst.net; rule: 1; icmp-type: 8;... (8 Replies)
Discussion started by: fedora
8 Replies
4. Shell Programming and Scripting
hi
iam new of the ksh script.iwant in formation of how to call in logfile in
ksh scripts. if the meaning in ksh.
please help me
thanks
naveen.g (1 Reply)
Discussion started by: naveeng.81
1 Replies
5. Post Here to Contact Site Administrators and Moderators
Hi
Just a thought if it already hasn't been suggested.
While looking at the forums I thought it might be a good idea under somewhere like 'special forums' add a section called 'projects'. I think this would be good for people to be able to post projects they have created.
For example I am... (3 Replies)
Discussion started by: woofie
3 Replies
6. Shell Programming and Scripting
I have a list of Servers in no particular order as follows:
virtualMachines="IIBSBS IIBVICDMS01 IIBVICMA01"And I am generating some output from a pre-existing script that gives me the following (this is a sample output selection).
9/17/2010 8:00:05 PM: Normal backup using VDRBACKUPS... (2 Replies)
Discussion started by: jelloir
2 Replies
7. Shell Programming and Scripting
Hey,
I have a problem about how to get one section of a file?
I'm new to shell, but by reading some tutorial, I think I can use awk to do this.
my input file:
>ref|ZP_04937576.1|
ECRINAEDPKTFMPSPGKVKHFHAPGGNGVRVDSHLYSGYSVPPNYDSLVGKVITYGAD
DEALARMRNALDELIVDGIKTNTELHKDLVRDAAFCKGGVNIHYLE... (11 Replies)
Discussion started by: ritacc
11 Replies
8. Shell Programming and Scripting
I have searched in a variety of ways in a variety of places but have come up empty.
I would like to prepend a portion of a section header to each following line until the next section header. I have been using sed for most things up until now but I'd go for a solution in just about anything--... (7 Replies)
Discussion started by: pagrus
7 Replies
9. Shell Programming and Scripting
Hi, I have a log file from Munin like this:2012/12/04 13:45:31 : Munin-update finished (29.68 sec)
2012/12/04 13:50:01 Opened log file
2012/12/04 13:50:01 : Starting munin-update
2012/12/04 13:50:01 Error occured in under in the configuration.
2012/12/04 13:50:01 Could not parse datafile... (9 Replies)
Discussion started by: Jotne
9 Replies
10. Shell Programming and Scripting
Bonjour,
I've wrote a script to monitor a logfile in realtime. It is working almost perfeclty except for two things.
The script use the following technique :
tail -fn0 $logfile | \
while read line ; do
... some stuff
done
First one, I'd like a way to end the monitoring script if a... (3 Replies)
Discussion started by: Warluck
3 Replies
LEARN ABOUT DEBIAN
arbtt-recover
ARBTT-RECOVER(1) Program references ARBTT-RECOVER(1)
NAME
arbtt-recover - tries to recover a broken arbtt data log
SYNOPSIS
arbtt-recover [OPTION...]
DESCRIPTION
arbtt-recover tries to readsthe data samples recorded by arbtt-capture(1), skipping over possible broken entries. A fixed log file is
written to <file>~/.arbtt/capture.log.recovered</file>. If the recovery was successful, you should stop arbtt-capture and move the file to
<file>~/.arbtt/capture.log</file>.
As a sid effect, arbtt-recover applies the log compression method implemented in version 0.4.5 to the samples created by an earlier
version. If you have a large logfile written by older versions, running arbtt-recover is recommended.
OPTIONS
-h, -?, --help
shows a short summary of the available options, and exists.
-V, --version
shows the version number, and exists.
-i, --infile
logfile to use instead of ~/.arbtt/capture.log
-o, --outfile
where to save the recovered file, instead of ~/.arbtt/capture.log
FILES
~/.arbtt/capture.log
binary file, storing the arbtt data samples
~/.arbtt/capture.log.recovered
binary file, storing the fixed arbtt data samples
SEE ALSO
See the arbtt manual for more information and the arbtt hackage page[1] for newer versions of arbtt.
AUTHORS
Joachim Breitner <mail@joachim-breitner.de>
Main author of arbtt
Sergey Astanin <s.astanin@gmail.com>
Contributor
Martin Kiefel <mk@nopw.de>
Contributor
Muharem Hrnjadovic <muharem@linux.com>
Contributor
NOTES
1. arbtt hackage page
http://www.hackage.org/package/arbtt
arbtt manual 04/07/2012 ARBTT-RECOVER(1)