[clug] file parsing strangeness

Boris Rousak b.rousak at qmul.ac.uk
Fri Jan 7 09:49:52 MST 2011

Good afternoon to all,

The problem is occurring on a VMWare vDR appliance, but this appliance 
is a Centos 5.2 for all intents and purposes, so hopefully someone can 
hit me with a clue bat :)

There is a log file on this VM called
it is a text log. I know this is a text log because when I cat it, I get 
something like the following:

$[//]1/5/2011 3:00:14 AM: Copying 
$[19]$[*!20655,,14,+3]woodpecker$[20]$[//19/%D %.1T: Copying 

I can also head and tail the file. But I can't grep it. Specifically 
grep returns nothing (as if the patter doesn't match).
[root at ib ~]# grep -i copy /var/vmware/datarecovery/operations_log.utx
[root at ib ~]# cat /var/vmware/datarecovery/operations_log.utx|grep -i copy
[root at ib ~]#

same with strings
[root at ib ~]# strings /var/vmware/datarecovery/operations_log.utx
[root at ib ~]#

but awk works fine as does cut. Copying the file and changing 
permissions doesn't seem to help. Running file - gives me this:
[root at ib ~]# file /var/vmware/datarecovery/operations_log.utx

Can anyone suggest anything else can try do to this file to make it grep 
friendly? I'll probably end up doing the parsing using awk, but 
curiosity is getting the better of me :)


PS. a possibly relevant fact - the file is a bit over 2MB in size. But 
splitting into smaller files doesn't seem to help

More information about the linux mailing list