How to find malformed - corrupted - dos - BOMByte Files in Linux
Posted
by
Syquus
on Server Fault
See other posts from Server Fault
or by Syquus
Published on 2010-09-09T19:20:18Z
Indexed on
2011/01/15
12:54 UTC
Read the original article
Hit count: 188
I've several problems maintaining large production servers, in which some developers drop files from Windows environments, sometime with BOM-bytes (We use UTF8, and no need for that), causing lots of troubles.
Other times, I got a "no end of line" and "[DOS]" labels when vim-editing files directly on the server.
I recently discovered how to find for the bom byte, and how to delete it in a batch script. What about illegal bytes, bad EOLs? Is it safe to use DOS Text Files on a linux environment? Any drawbacks If I use to convert them with dos2unix cmd ?
Regards
© Server Fault or respective owner