grep command does not work to find a string inside a file utf-16 format
Issue
grep string file_name
works but for a specific file dont work. Use the file command to check the format and it is in UTF-16.
file file_name.txt file_name.txt: Unicode text, UTF-16, little-endian
- While use grep command with other file format (ascii) it works fine.
- Try to use dos2unix command to change the format but dont work.
Environment
- Red Hat Enterprise Linux ALL
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.