I have a bit of a problem and i'm on a serious deadline. My file server house about 70 GB of data in tens of thousands of files. I discovered that there are hundreds of files that have unusual characters in their filename. This wouldn't be a problem except that I'm migrating these files over to a new file server and it won't accept these files.
In order to fix this problem I need a script that can replace these invalid characters with a valid one.
The script needs to establish a base set of "OK" characters (a-z A-Z - _ , . @ etc...) and then iterate through every file and substitute any illegal characters with a underscore. So, "monthly^??report.xls" would change to "monthly___report.xls"
The script would also need to descend into subdirectories doing the same thing to them. Ideally it would output its changes to a logfile for tracking too.
I haven't touched in PERL in 4 years and forgotten just about everything. I'm okay at reverse engineering scripts, but creating them from scratch is beyond my current skill set. Can someone help?