following the script i got here worked well in getting file input
Code:
#!/bin/bash
alarm= `cat ~/alkatel.txt`
echo $alarm | while read line
do
{
echo $line
}
done
thanx 4 it
but will you plz help me in extracting the whole string following ! , !! or !!!
coz i can only extract just one letter at my best using code
the example of file im trying to extract strings is given above
more i am trying to use cut command to extract string components in file.
can i use this command to extract a complete log of alarm from file e.g.
!!! *A0628/303 /07-12-17/15 H 46/N=7501/TYP=COM/CAT=IM/EVENT=MAL
/NCEN=MULCT /AFUR =URAD- 4/AGEO=BUDLASAN-B01
/TEXAL=SINGLE JUNCT/UT OOS/COMPL.INF:
/CN=3
i want to extract the string in this way above
i used the command cut to extract date and time from the file as
Code:
cut -b 16-32 ~/alkatel.txt
but i got the output as
/07-12-17/15 H 46/
T /AFUR =URAD- 4
hope u will understand my problem
please read the threads above , to be sure about solution of my problem