• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

Bug Report "File creation failed" and the analysis result included

zjlywjh001

New Member
Joined
Feb 15, 2019
Messages
4 (0.02/day)
Recently I encountered the problem of gpu-z that it always shows a "file creation failed" Error on version later than 2.8.0.
err1.PNG

Though this kind of error does not affect the running of the gpu-z 2.16.0 and later, but if this error occored the software will offer a error computing support information in the software:
err2.PNG

The last line, the four ticks will be randomly disappeared when the above error occurs. For example, If the "File creation failed" window occurs twice ,the four ticks will randomly remains only two.
I searched all the webs, but nobody konws why this error occurs.
And Most important for me, when I run the latest version of 3dmark, because of the error of gpu-z the test will stuck on the "collecting system information" stage.


So I do some reverse engineering on the software.
First unpack the upx, and use IDA to disassemble the software and see how this error occurs.

After some analysis , I found that it seemed that after the version 2.9.0, the program will always create a file with the same name called "GPUQuery_External.exe" for different compute tests.
So the program will delete the file after every test.
But the problem comming.. emmmmm..

The previous WaitForSingleObject function only wait for 2.71 seconds.
In some condition the new process can't quit normally, It seemed that the process just remains on the background.
So when try next stage, The delete operation will failed, It will also cause the "Open" and "Write" operation to throw an exception.

In the end, this error occurs..

err3.PNG


I hope this bug will be fixed soon, It has exists thorough 2.9-2.16.
I'll be glad if my 3dmark runs good...
 
Last edited:

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
Excellent investigation. The problem is that I haven't found a way to reproduce that error.

When does it happen on your system? During high load? or at startup?
 

zjlywjh001

New Member
Joined
Feb 15, 2019
Messages
4 (0.02/day)
Excellent investigation. The problem is that I haven't found a way to reproduce that error.

When does it happen on your system? During high load? or at startup?
At first GPU-Z works fine on my system for a long time.
But from same day (Maybe Microsoft pushed some update to me) , I can hardly start gpu-z normally without this error.
From that moment on, I have very low probability to execute gpu-z without this error, seems 1 in 20 times to be normal.
My windows version is 1809.
 
Joined
Apr 28, 2011
Messages
633 (0.21/day)
Location
Botevgrad, Bulgaria, Europe
System Name Main PC/OldPC/3rd PC
Processor Intel Core i7-3770K Ivy Bridge/Core i5-3470 Ivy Bridge/Core i3-4330 Haswell
Motherboard ASUS P8Z77-V/ASRock Z68 Pro3 Gen1/ASUS H81M2
Cooling Cooler Master Hyper 212 EVO/Intel Box cooler/Intel Box cooler
Memory 32GB Corsair Vengeance/32GB ADATA/16GB ADATA
Video Card(s) SAPPHIRE R9 290 Tri-X OC 4GB/MSI RX 480 8GB/SAPPHIRE R9 390 8GB
Storage 2x1TB ADATA SSDs in RAID0+3 HDDs/2xCrucial 1TB SSDs in RAID0+3 HDDs/Samsung 1TB SSD+8TB+4TB HDDs
Display(s) Philips 274E5QHAB@HDMI + Philips 273EQH@DVI (both 27")
Case Fractal Design Define R4 Titanium
Audio Device(s) Kenwood Mini HiFi system/Microlab speakers/Philips HDMI (main)+LG TV monitor HDMI + Apple headphones
Power Supply Cooler Master Silent ProM 600 W (modular)
Mouse Microsoft Ergonomic Sculpt Desktop 2.0 (combo)@Razer Goliath mousepad (Medium speed)
Keyboard Microsoft Ergonomic Sculpt Desktop 2.0 (combo)
Software Win10 64-bit (Main PC v.1809 RTM Enterprise/2nd PC v.1903 Insider Preview Pro/3rd PC - same as 2nd)
Antivirus blocking extra file? What antivirus do you use?
 
Joined
Apr 28, 2011
Messages
633 (0.21/day)
Location
Botevgrad, Bulgaria, Europe
System Name Main PC/OldPC/3rd PC
Processor Intel Core i7-3770K Ivy Bridge/Core i5-3470 Ivy Bridge/Core i3-4330 Haswell
Motherboard ASUS P8Z77-V/ASRock Z68 Pro3 Gen1/ASUS H81M2
Cooling Cooler Master Hyper 212 EVO/Intel Box cooler/Intel Box cooler
Memory 32GB Corsair Vengeance/32GB ADATA/16GB ADATA
Video Card(s) SAPPHIRE R9 290 Tri-X OC 4GB/MSI RX 480 8GB/SAPPHIRE R9 390 8GB
Storage 2x1TB ADATA SSDs in RAID0+3 HDDs/2xCrucial 1TB SSDs in RAID0+3 HDDs/Samsung 1TB SSD+8TB+4TB HDDs
Display(s) Philips 274E5QHAB@HDMI + Philips 273EQH@DVI (both 27")
Case Fractal Design Define R4 Titanium
Audio Device(s) Kenwood Mini HiFi system/Microlab speakers/Philips HDMI (main)+LG TV monitor HDMI + Apple headphones
Power Supply Cooler Master Silent ProM 600 W (modular)
Mouse Microsoft Ergonomic Sculpt Desktop 2.0 (combo)@Razer Goliath mousepad (Medium speed)
Keyboard Microsoft Ergonomic Sculpt Desktop 2.0 (combo)
Software Win10 64-bit (Main PC v.1809 RTM Enterprise/2nd PC v.1903 Insider Preview Pro/3rd PC - same as 2nd)
Don't close. Just tell us which one it is!
You may need to add a file or folder exception to the antivirus rules/settings.
 

zjlywjh001

New Member
Joined
Feb 15, 2019
Messages
4 (0.02/day)
Don't close. Just tell us which one it is!
You may need to add a file or folder exception to the antivirus rules/settings.
I have done some test with W1zzard. This error is some timing issues, so it is hard to reproduce. I think W1zzard will solve this soon. :)
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
I have done some test with W1zzard. This error is some timing issues, so it is hard to reproduce. I think W1zzard will solve this soon. :)
Thanks a lot! Your testing was very helpful.

This is indeed a timing issue. GPU-Z renames the Query_External EXE after it has started it (so other GPU-Z instances can run at the same time). The problem was that CreateProcess() didn't fully start the process and the rename immediately after it could fail. I added some delay now, which fixes it.
 
Joined
Feb 8, 2008
Messages
8 (0.00/day)
Sorry to revive this, but I'm getting the same error, first time was a day or so ago, and the error exists when launching GPU-Z 2.22.0 (and 2.21.0).

I did not do the bug testing/dissection as the OP did, but the error is exactly the same as they described.
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
and it worked before? Does the directory exist where it's trying to put the file? Or disk full maybe?
 
Joined
Feb 8, 2008
Messages
8 (0.00/day)
Thanks for your response!

It's running directly from the folder it was downloaded to, which is where it's been running from for a year now. Nothing new here. The file GPUQuery_External (.exe?) exists in the appdata/temp folder and is 0 bytes in size, and is read-only.
 

Attachments

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
Aha! Try removing the readonly flag. If that doesn't work, delete the file
 
Joined
Feb 8, 2008
Messages
8 (0.00/day)
Deleted the file, that eliminated the error when loading GPU-Z. Odd! Thanks for your help.
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
Yeah no idea why it would get marked as readonly, GPU-Z certainly didn't do that
 
Joined
Feb 8, 2008
Messages
8 (0.00/day)
Anddddd...its back again. The GPUQuery_External file exists and is 0 in size, same as my original posted image. If I delete the file, gpuz continues on with no further errors.
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
and it's read-only again?
 

Solaris17

Dainty Moderator
Staff member
Joined
Aug 16, 2005
Messages
20,661 (4.04/day)
Location
Florida
System Name Venslar
Processor I9 7980XE
Motherboard MSI x299 Tomahawk Arctic
Cooling EK Custom
Memory 32GB Corsair DDR4 3000mhz
Video Card(s) Nvidia Titan RTX
Storage 2x 2TB Micron SSDs | 1x ADATA 128SSD | 1x Drevo 256SSD | 1x 1TB 850 EVO | 1x 250GB 960 EVO
Display(s) 3x AOC Q2577PWQ (2k IPS)
Case Inwin 303 White (Thermaltake Ring 120mm Purple accent)
Audio Device(s) Realtek ALC 1220 on Audio-Technica ATH-AG1
Power Supply Seasonic 1050W Snow
Mouse Roccat Kone Aimo White
Keyboard Ducky Shine 6 Snow White
Software Windows 10 x64 Pro
Just throwing in my 2c but I know some AV and some protection mechanisms in windows 10 will prevent execution from temp to help stop malware.

I haven’t looked into this, but maybe it does this by marking them readonly?
 

W1zzard

Administrator
Staff member
Joined
May 14, 2004
Messages
19,429 (3.49/day)
Processor Core i7-4790K
Memory 16 GB
Video Card(s) GTX 1080
Display(s) 30" 2560x1600 + 19" 1280x1024
Software Windows 7
Just throwing in my 2c but I know some AV and some protection mechanisms in windows 10 will prevent execution from temp to help stop malware.

I haven’t looked into this, but maybe it does this by marking them readonly?
Read only can be executed just fine
 
Joined
Feb 8, 2008
Messages
8 (0.00/day)
"Remove readonly attribute from temporary files before trying to delete " from new version 2.23 release notes, AHA! Will try this now and report back.

YES! 2.33 Fixed it!
 
Top