This is the grep command I used
grep -ic address log*
The output is 0. I know for a fact that there are more than 60 occurrences of the word address in the log file. But I still get 0.
Now, I copied the contents of the log into a new file log2
grep -ic address log2
outputs 65! I copied the contents by selecting all and copy pasting instead of the cp command. I checked and made sure the file permissions were all fine.
ls -l show this
-rwxrwxrwx 1 root root 91694 Jul 26 16:18 log -rw-r--r-- 1 root root 45220 Jul 30 14:16 log2*
The only discrepancy I can see is that the first log is twice the size of its copy. Is this a format issue?
When I open the file in vim it shows
[converted][dos] as the format.
How can I fix this?
Any help is appreciated.