Hi, I have a file like:
START
Length: 1432
RIdentifier: 4
VIdentifier: 4
Format: 5
TS number: 9
DHeader
Version = 1
Length = 1432
Command Flags = RPT (0xd0)
Command Code = Accounting-Request (271)
Application Id = Rf-Application (3)
Hop By Hop Id = 51
End To End Id = 8847360
START
Length: 12
RIdentifier: 2
VIdentifier: 4
Format: 5
TS number: 6
DHeader
Version = 1
Length = 1432
Command Flags = RPT (0xd0)
Command Code = Accounting-Request (271)
Application Id = Rf-Application (3)
Hop By Hop Id = 51
End To End Id = 8847360
START
I need to collect all the lines that are found between START
and write it into 2 files.
I tried with flip flop in Perl like:
open(FILE, $ARGV[0]);
while (<FILE>) {
if (/START/ .. /START/) {
print "$. $_ \n";
}
}
But I am getting only the lines that have START
. Could you please help me?