Re: how to separate individual logs?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



From: hadi motamedi <motamedi24@xxxxxxxxx>

> On 12/1/10, John Doe <jdmls@xxxxxxxxx> wrote:
> > Ok,  last try...
> > Did you copy/pasted my code?
> > Did you type  it?
> > Saying just that there's a syntax error without showing the code you  used
> > does
> > not help...
> Please find  below the code that I tried :
> cat Edit3 | tr -d "\r" | while read LINE;  do
> echo "$LINE" | grep -q  '>\.\.'
> if [ $? -eq 0 ];  then
> LOGFILE=`echo $LINE | cut -d' ' -f1`.log
> else
> echo "$LINE"  >> $LOGFILE
> fi
> done
> Please do me favor and correct me on my  mistakes.

I copy/pasted the code above and it works fine...
If I indent it like mine, they are identical.
Check that ftp does not add control chars.
You run it with bash, right?
Ask your sysadmin/colegue to help you.

JD


      
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux