More Win10 Problems

Started by slink, February 08, 2018, 11:53:34 AM

Previous topic - Next topic

slink

Hi

I've moved from Win7 to Win10 and trying to setup my exiftool scheduled tasks but unfortunately I can't get exiftool to work at all.  I've followed the instructions, renamed to exiftool.exe (file extension not hidden) and placed it in my C:\Windows folder but have encountered several problems.   

As per some suggestions on the forum, I've disabled Defender, set exclusions (file and temp folder) and recreated the temp folder but nothing has worked.  One thing I haven't tried was the suggestion to change the temp folder location using some setex command but it wasn't clear how to do that.

On first run, I get this:

C:\Users\NUC>exiftool
assertion failed: open my_prog
assertion failed: MZ magic bytes
assertion failed: PE header
assertion failed: IMAGE_NT_OPTIONAL_HDR_MAGIC


On second run I get nothing at all, just straight back to the command prompt.

Looking in the temp folder I saw a cache folder with only two files in it, exiftool.exe and a dll.  Trying to run this version of exiftool produced this error:

The C:\Users\NUC\AppData\Local\Temp\par-4e5543\cache-da39a3ee5e6b4b0d3255bfef95601890afd80709\exiftool.exe application cannot be run in Win32 mode.

Sensing that was an incomplete version I cleared out the temp and tried again but the same cycle happened, temp folder with two files in it.  I tried a third time running as an admin, same thing. 

So, I cleared it out again, redownloaded the executable version, renamed it and this time launched it as an admin from the Explorer window rather than the command line.  This time I got the manual and then when I went to the temp folder I saw a much more complete set of files.  However, running exiftool from the C:\Windows path still does nothing and if I run it from the temp folder I get the following:

C:\Users\NUC\AppData\Local\Temp\par-4e5543\cache-exiftool-10.78>exiftool.exe
Can't locate Win32.pm in @INC (you may need to install the Win32 module) (@INC contains: .) at -e line 488.
BEGIN failed--compilation aborted at -e line 639.


I'm reluctant to try the alternative method of downloading Perl as I want to keep this install of Win10 as clean as possible but I will if there's no other solution.  I'm on the latest 1709 build of Win10, fully updated.

Thanks
Isaac





Phil Harvey

Hi Isaac,

Wow.  I wish Windows 10 wasn't such a pain in the ass.

When you got the ExifTool manual while running as admin from Explorer, it was working properly.

I think you just need to set the properties so it is always run as admin, and it should work from the command line.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

slink

ah yes, I was so close!

After it ran successfully from Explorer I went to the command line as an administrator and ran it but it didn't work.  Just nothing.  I gave up at that  point but this time I started again, cleared out all the temp stuff, got it working from Explorer and then went the properties of the EXE and ticked the box to always run as an Administrator.  Now it works :)

I also have Defender exclusion for the executable and the temp path.

Thanks!

MOL

I've been on Win 10 (64bit) for ages and my software uses ExifTool in stay_open mode utilizing pipes.  Never encountered a malfunction of ExifTool, even with Defender enabled.  I'm logged in as administrator, though, and I don't meddle with the installation path when a new version of exiftool.exe (already renamed!) is run for the first time.  It's all on default settings.  There must be something else that is messing up your system.  What language setting are you using?

-Uwe

Phil Harvey

I would be surprised it this problem was related to language settings, but it is possible I guess.

There are certainly some versions of Windows Defender that have caused problems.

But this problem I think is related to permissions and user privileges.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

MOL

Unless this is caused by a bug similar to the one that was introduced last year (see link below), I have my doubts that it is a permission related problem.  The default installation folder c:\users\username\appdata\local\temp is always accessible to the currently logged in user.

https://support.microsoft.com/en-us/help/4045251/incorrect-default-user-profile-permissions

-Uwe

slink

Definitely seems privilege related.  I have a single account on the machine which is a local administrator but Win10 still requires elevation for exiftool to function correctly.  If you turn off UAC as part of your setup then that might explain why you're not seeing this problem.

I've not tried using it on Win10 before but I am on the latest 1709 creators update, fully patched with all the updates/features.

MOL

I'm on the same version as you.  The difference between our setups seems to be that you install ExifTool in C:\Windows and I don't.  Have you tried a non-system folder yet?

-Uwe

MOL

Isaac, have you found the problem?

-Uwe

mk05

Hi there! Googling for this problem I landed here and although the thread is a little old, I'd like to give my two cents. Moving the exiftool executable to a folder where it can write seems to solve the issue. I guess that, as the program saves the original after processing, it needs to check it can create a new file in the same folder as the program resides (and not from where it is run).

Phil Harvey

Odd.  ExifTool shouldn't be trying to write anything into the directory of the executable.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

obetz

the assertion seems to come from the PAR packer.

Maybe it depends also on the Perl environment (ActivePerl, Strawberry...) and the PAR-Packer version used to build exiftool.exe.

Putting exiftool.exe in the Windows folder or even System32 folder (see "Extracting GPS data in dec deg to txt file" thread) is not a good idea, anyway.

Users shouldn't misuse Windows folders just to avoid an entry in the "path" environment variable.

Running as administrator or with elevated rights may cure symptoms but doesn't solve problems. I'm afraid it introduces other problems, e.g. access rights to the files created by exiftools.