[Originally posted by hharink on 2007-06-11 09:48:17-07]
Not completely sure if im on the right spot to ask this question but anyway
I have an windows XP SP2 laptop with exiftool.exe (6.90)
a jpg file called test.jpg in the directory c:\test
and exiftool.exe in the same directory
i open a commandbox run cmd
and issue the following statement
Exiftool "-DateTimeOriginal+=5:10:2 10:48:0" test.jpg
i get the errormessage
error renaming test.jpg
and if i do a DIR of the test directory is see
test.jpg AND a file called test.jpg_exiftool_tmp
the tmp file has the requested exif data changed, the file test.jpg is still in its original state.
[Originally posted by exiftool on 2007-06-11 12:39:37-07]
This is the right spot to ask that question.
It sounds like somehow you don't have permission to rename the
original file. These are the steps that exiftool takes when writing
an image:
1) Write modified image to "FILE_exiftool_tmp".
2) Rename original image to "FILE_original".
3) Rename temporary file to "FILE".
This is failing at step number 2. Check the permissions on the
image. I'm not familiar with the how to do this in Windows, but
hopefully you know how or maybe someone else can help here.
- Phil
[Originally posted by hharink on 2007-06-11 19:21:07-07]
Ah well if i do it myself on the commandline it works
rename test.jpg test.jpg_original
so the permissions should be oke unless the program is run as a different user..
but then cacls says
BUILTIN\Administrators:F
NT AUTHORITY\SYSTEM:F
WULFTOP\hennie:F
BUILTIN\Users:R
i myself am logged in as hennie.
i tried it with changing BUILTIN\Users:F but it did not help.
[Originally posted by hharink on 2007-06-11 19:39:23-07]
Ah well if i do it myself on the commandline it works
rename test.jpg test.jpg_original
so the permissions should be oke unless the program is run as a different user..
but then cacls says
BUILTIN\Administrators:F
NT AUTHORITY\SYSTEM:F
WULFTOP\hennie:F
BUILTIN\Users:R
i myself am logged in as hennie.
i tried it with changing BUILTIN\Users:F but it did not help.
[Originally posted by hharink on 2007-06-11 19:47:44-07]
And it IS something like you say because if i use......Exiftool -o testout.jpg "-DateTimeOriginal+=5:10:2 10:48:0" test.jpg.................Then everything goes fine. But nevertheles i would like to change the original and have no idea what causes this behaviour.
[Originally posted by hharink on 2007-06-11 19:59:11-07]
Oke little bit more info out of testing.... use option -overwrite_original gives errors........
errors are 0 image files update 1 files werent updated due to errors and the exif_tool_tmp file exists..... user option -overwrite_origina_in_place WORKS.... but allso here the exif_tool_tmp file exists still and is not gone BUT the original is now written.
[Originally posted by exiftool on 2007-06-12 12:39:06-07]
It seems like a problem specifically with the rename function (and
maybe the delete function), because -overwrite_original_in_place
is able to open the original file for writing.
So I think it comes down to something different about your
operating system. What OS are you running? Also, what version
of ExifTool (the stand-alone Windows version 6.90?).
It must be something very specific to your system because I
haven't seen this problem before.
Also, do you have Perl installed, and did you ever install any
other versions of ExifTool using a different installation technique?
(I'm wondering about possible library conflicts between versions.)
- Phil
[Originally posted by hharink on 2007-06-12 13:13:38-07]
I just tried exiftool now so have the current version, never tried it before.\n
I am using windows XP Home edition.\n
It works in windows safe mode.\n
I have trie first the windows executable. \n
today i have install active perl and got the perl distribution. \n
This gives the same result. \n
a standard simple perl rename script wich i wrote and tested on the same jpg file gives no problems. \n
Hmm how do i get a linefeed in this forum working?\n
[Originally posted by exiftool on 2007-06-12 13:25:01-07](you have to type
to get a line feed in this forum,
or two for a blank line)
There is nothing weird about your OS version. I forgot to ask, but
you're using the cmd.exe shell?
That was smart to
try the rename command separately, but now it is even more of a
puzzle as to why it doesn't work. Could you try these two commands?:
> exiftool -author=me test.mie
1 image files created
> exiftool -author=you test.mie
1 image files updated
I just want to see what happens when you try to edit a file
that is created initially by exiftool.
- Phil
[Originally posted by hharink on 2007-06-12 14:03:42-07]
Oke first your test
C:\test exiftool -author=me test.mie
1 image files created
C:\test exiftool -author=you test.mie
Error renaming test.mie
Then i found your the piece in the exiftool code that does the renaming and copied it into a simple test
This WORKS....... its is indeed very strange...
I tried to copy it into this forum but it doesnt want to except it
[Originally posted by hharink on 2007-06-12 14:13:53-07]
yes i use the cmd exe shell (forgot to anwer that one)
[Originally posted by exiftool on 2007-06-12 14:29:38-07](to post a block of code to the forum, enclose it in
...
)
If I could duplicate this problem I could iterate between the script
that works and the full exiftool script that doesn't. At some point
there must be a single reason that one works. Do you think there
could be a problem with the long extensionn (ie. "image.jpg_original"),
or can your rename a file to a name like this?
- Phil
[Originally posted by hharink on 2007-06-12 14:33:32-07]
I just tried exiftool now so have the current version, never tried it before.\n
I am using windows XP Home edition.\n
It works in windows safe mode.\n
I have trie first the windows executable. \n
today i have install active perl and got the perl distribution. \n
This gives the same result. \n
a standard simple perl rename script wich i wrote and tested on the same jpg file gives no problems. \n
Hmm how do i get a linefeed in this forum working?\n
[Originally posted by hharink on 2007-06-12 14:41:03-07]
Ah well like i said i copied your rename code from the exiftool.pl
and put it in a simple script.
keeping the names like they are
and that works oke. so it mut be something that happens before that makes the file cannot be renamed.
i would think.....
I never used perl so have difficultys reading all, otherwise i could try to debug myself, wich i am trying anyway ....
my guesses . some program in my latop like a firewall virusscan windows defender is still holding the file
i tried to put a delay 10 before the rename i did not help
other idea the file is opened and locked by the prog itself
i tried to make a file handle did open fhandel filename
and then close fhandel filename
did allso did not give a soluytion
i allso tried to lock and unlock it before did not help eather
but as said this is the first time i look into perl so....
[Originally posted by hharink on 2007-06-12 14:41:34-07]
Ah well like i said i copied your rename code from the exiftool.pl
and put it in a simple script.
keeping the names like they are
and that works oke. so it mut be something that happens before that makes the file cannot be renamed.
i would think.....
I never used perl so have difficultys reading all, otherwise i could try to debug myself, wich i am trying anyway ....
my guesses . some program in my latop like a firewall virusscan windows defender is still holding the file
i tried to put a delay 10 before the rename i did not help
other idea the file is opened and locked by the prog itself
i tried to make a file handle did open fhandel filename
and then close fhandel filename
did allso did not give a soluytion
i allso tried to lock and unlock it before did not help eather
but as said this is the first time i look into perl so....
[Originally posted by exiftool on 2007-06-12 14:46:56-07]I appreciate the work you are doing to track this down, because
all I can do from my end is come up with ideas.
Here's one: Put the following line in exiftool just before it dies
on the rename error (this will print the actual error message):
print "The error is: $!\n";
- Phil
[Originally posted by hharink on 2007-06-12 15:00:17-07]
The error is: permissiom denied
[Originally posted by exiftool on 2007-06-12 15:44:07-07]
OK, thanks. This confirms my initial suspicions. I think maybe
the thing to try now is to disable all of your virus protection to
see if it is causing the problem. Unfortunately I'm not an expert
in Windows permissions, so hopefully you or someone else
reading this forum will have some more ideas here.
- Phil
[Originally posted by hharink on 2007-06-12 17:07:39-07]
Ah thanx for all your help thats first!
as i mentioned before i allready tought i tried to shut down all my firewals and scanners though...
The Norman Antivirus i thought to have stopped by selecting , stop on access scanning, as that is the only option available.
But i thought ill go a little bit further now and stopped all the norman av services in windows and restarted.
and guess what the problem does not exist anmore
Now ill be busy to solve the norman problem as i do like it and all virusprograms have some kine of problems.....
Thanx again for thinking with me and i know now a lot more about perl then i did before!
Hennie
[Originally posted by exiftool on 2007-06-12 18:26:04-07]
Excellent.
Please post your solution here if you figure out how
to configure Norton (Norman?) Antivirus to solve this conflict.
- Phil
[Originally posted by hharink on 2007-06-18 14:36:25-07]
I have tried to take active scan away from the directory the files are in with no solution. even stopping activescan completely did not help.
I sent an email to Norman (not norton) with the problem explained so waiting for an answer from that.
In the meantime im running AVG antivirus and everything works fine.
If anything comes from norman ill post it here.
Hennie