D
Deleted member 43773
Guest
Hi, it's me again,
I found some likewised threads (what gave me the idea about convmv and several other things, like look a file's names by cat or hexdump to see the truth), but I didn't found an answer that helped me to understand my actual problem.
I am daily taring my /home/...
This dir contains 200 files originally came from a Win7 system (NTFS, filenames in UTF-16).
So I wrote a tiny trivia script to do it automatically (not be worth to be printed here.) The core line is just the tar command, nothing special:
tar -czf /destination/tarfile.tar.gz ~
If cron executes it, everytime I reveice a long mail with 200 entries about those files:
: Can't translate pathname 'home/....äöü (1) ß 101_p9764...' to UTF-8
(mail's error messages of course respect file- and directory names - what formerly came from Windows.)
But if I do the same tar command by hand, except
tar: Removing leading '/' from member names
no message occur, even if I add -V (verbose) to the tar command.
Also if I run the same script by myself, no message occur.
It doens't matter if I do the tar on a related file directly (full path) or its directory.
So after I understood Win7 = UTF-16-, Unix/BSD/Linux...=UTF-8-filenames, I want to rename the files.
Of course I don't want to rename all 200 files by hand.
So I tried:
convmv -f UTF-16 -t UTF-8 --notest on_a_file_to_test
That had no effect on cron's error message, "Can't translate pathname..." still stays.
Also trying to be sure
convmv -f UTF-8 -t UTF-8 --nfc --notest on_the-same-testfile
gives me: "Ready! I converted 0 files in 0 seconds." So, nothing was done. File is already correctly converted to UTF-8, right?
Cron's error messages mails stay.
It doesn't matter, if I put the destination on my local machine or directly to my little NAS (both FreeBSD with ZFS utf8only off), or change the shebang (what indeed is pointless anyway, I just try and tell you to see I've tried several things, before I bother to ask.)
So the only difference I figured out yet, what produces me the error messages or not, is if I do it in cron or not - but this can't be, can it?
As far as I understand the system, cron just starts the commands/scripts only, just as I would do it in the shell - or not?
Or does it receives more messages from a task as me if I do the same in the shell? (You see, again I don't see the forest because of the trees anymore.)
What do I not see/understand?
Thanks in advance for your time and answers!
yours
Profighost
I found some likewised threads (what gave me the idea about convmv and several other things, like look a file's names by cat or hexdump to see the truth), but I didn't found an answer that helped me to understand my actual problem.
I am daily taring my /home/...
This dir contains 200 files originally came from a Win7 system (NTFS, filenames in UTF-16).
So I wrote a tiny trivia script to do it automatically (not be worth to be printed here.) The core line is just the tar command, nothing special:
tar -czf /destination/tarfile.tar.gz ~
If cron executes it, everytime I reveice a long mail with 200 entries about those files:
: Can't translate pathname 'home/....äöü (1) ß 101_p9764...' to UTF-8
(mail's error messages of course respect file- and directory names - what formerly came from Windows.)
But if I do the same tar command by hand, except
tar: Removing leading '/' from member names
no message occur, even if I add -V (verbose) to the tar command.
Also if I run the same script by myself, no message occur.
It doens't matter if I do the tar on a related file directly (full path) or its directory.
So after I understood Win7 = UTF-16-, Unix/BSD/Linux...=UTF-8-filenames, I want to rename the files.
Of course I don't want to rename all 200 files by hand.
So I tried:
convmv -f UTF-16 -t UTF-8 --notest on_a_file_to_test
That had no effect on cron's error message, "Can't translate pathname..." still stays.
Also trying to be sure
convmv -f UTF-8 -t UTF-8 --nfc --notest on_the-same-testfile
gives me: "Ready! I converted 0 files in 0 seconds." So, nothing was done. File is already correctly converted to UTF-8, right?
Cron's error messages mails stay.
It doesn't matter, if I put the destination on my local machine or directly to my little NAS (both FreeBSD with ZFS utf8only off), or change the shebang (what indeed is pointless anyway, I just try and tell you to see I've tried several things, before I bother to ask.)
So the only difference I figured out yet, what produces me the error messages or not, is if I do it in cron or not - but this can't be, can it?
As far as I understand the system, cron just starts the commands/scripts only, just as I would do it in the shell - or not?
Or does it receives more messages from a task as me if I do the same in the shell? (You see, again I don't see the forest because of the trees anymore.)
What do I not see/understand?
Thanks in advance for your time and answers!
yours
Profighost