How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Questions about Wine on Linux
Locked
hopperman
Level 2
Level 2
Posts: 17
Joined: Wed Nov 03, 2021 9:53 am

How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by hopperman »

I am using Debian 11 Bullseye 64 bit and wine 5.0.3 However, I installed wine32 with 32 bit OS support (i.e. using dpkg's architecture support codes).
In summary I had working wine32.

I tried to install daemon-tools 4.0 and it asks something about "stpd" and "kernel support", since I did not understand, I said yes, but daemon tools setup crashes due to errors. Then, wine started to crash for creating and loading drivers! :(

What I understood that then, :( , daemon tools ask me whether use (or emulate I am not sure) stpd service of winehq to create mounted images.

Then I did :
1. mount .iso file to "/media/user/ISO/" folder as read only
2. goto that folder : cd /media/user/ISO
3. there is a setup.exe there and I tried to run it : wine setup.exe
4. I got error below :

wine setup.exe
001d:err:ntdll:RtlpWaitForCriticalSection section 0x7be9e150 "loader.c: loader_section" wait timed out in thread 001d, blocked by 001b, retrying (60 sec)
000f:err:service:process_send_command receiving command result timed out
002a:err:ntoskrnl:ZwLoadDriver failed to create driver L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\sptd": c0000142
0021:err:service:process_send_command service protocol error - failed to read pipe r = 0 count = 0!
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
003d:err:winediag:MIDIMAP_drvOpen No software synthesizer midi port found, Midi sound output probably won't work.

What I understood from error is :
1. wine could not access to Q driver, since it gives "failed to create driver error", but I can access to it under ~/.wine/dosdevices/q:

2. I had a screenshot of wine regedit :
[img][attachment=0]wineRegedit.png[/attachment][/img]

3. I also used winetricks -q dotnet40 but does not worked.
4. How can I correct or re-load working "stpd" service of winehq without uninstallling everything(i.e. wine and wine32 libraries?)
Any help is appreciated.
Attachments
wineRegedit.png
hopperman
Level 2
Level 2
Posts: 17
Joined: Wed Nov 03, 2021 9:53 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by hopperman »

In the title I made a mistake : it is no t stpd service but "sptd" service, sorry for misspelling.
Then I solved the main problem :

[url]https://daemonpro-help.com/additionally ... _problems/[/url]

shows that, the problem is due to sptd service added to registry.
I did :
1. wine regedit
2. delete sptd key
3. rerun wine setup.exe
4. error reduced to :

001d:err:ntdll:RtlpWaitForCriticalSection section 0x7be9e150 "loader.c: loader_section" wait timed out in thread 001d, blocked by 001b, retrying (60 sec)
000f:err:service:process_send_command receiving command result timed out
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
wine: Read access denied for device L"\\??\\Q:\\", FS volume label and serial are not available.
0036:err:winediag:MIDIMAP_drvOpen No software synthesizer midi port found, Midi sound output probably won't work.

which means that,
[code]002a:err:ntoskrnl:ZwLoadDriver failed to create driver L"\\Registry\\Machine\\System\\CurrentControlSet\\Services\\sptd": c0000142
0021:err:service:process_send_command service protocol error - failed to read pipe r = 0 count = 0! [/code]

was removed which was due to daemon tool's sptd service !
However MIDIMAP_drvOpen error continues, does anybody knows about it?
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by jkfloris »

Short answer: Daemon-tools tries to install a Windows driver to mimic a virtual CD drive. Installing this type of driver is not supported by Wine.
Why do you need Deamon-tools? There are probably other solutions.
hopperman
Level 2
Level 2
Posts: 17
Joined: Wed Nov 03, 2021 9:53 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by hopperman »

jkfloris : I had a short answer : The easiest path is the path you well known. I knew daemon tools before so I just tried to install it :)
I am now stuck at MIDIMAP_drvOpen error, do you know how to solve it by chance? I am trying to install The Sims 2 game to Linux by wine. However, setup gives above MIDI error and when in the selection of installation folder dialog it stucks ! There are two choice buttons : next and exit, when I pressed either buttons it asks me "are you want to quit installation?" It is annoying ! I installed dotnet40 by using winetricks. However, nothing changed... error over error...
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by jkfloris »

The MIDIMAP error only indicates that midi sounds are not working. I don't expect the installation to crash on that.
Does the Sims 2 need .Net 4.0?
Based on the AppDB, can you try the installation in a clean wineprefix with wine-staging 6.20 and dxvk as the only winetrick?
hopperman
Level 2
Level 2
Posts: 17
Joined: Wed Nov 03, 2021 9:53 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by hopperman »

Hi jkfloris,

I even could not install The sims 2 before, but today I realized my error : WinXP !

I used :
1. winecfg
2. change default environment to Windows7
3. Then start installation of The Sims 2 from CD's,,, and wola! I could install the game successfully!

Then I faced with new error :

"Direct3D returned an error : D3DERR_INVALIDCALL!"

I could not find a solution to apply ! I tried to your solution :

1. I tried to install a package in a wiki page of Debian but I got an error at the beginning :
by using :

sudo wget -nc https://dl.winehq.org/wine-builds/winehq.key

but retult is error :
--2021-11-09 19:53:08-- https://dl.winehq.org/wine-builds/winehq.key
dl.winehq.org (dl.winehq.org) analyzing... 151.101.114.217
dl.winehq.org (dl.winehq.org)[151.101.114.217]:443 connecting... connection established.
ERROR: `dl.winehq.org' the certificate is not secure.

2. Then I skip to dxvk by myself ! But I The Sims 2 Error changed to :

info: Game: Sims2.exe
info: DXVK: v1.9.2
info: Found built-in config:
info: Effective configuration:
info: d3d9.customVendorId = 10de
info: d3d9.disableA8RT = True
info: d3d9.customDeviceId = 0091
info: d3d9.customDeviceDesc = GeForce 7800 GTX
info: d3d9.supportX4R4G4B4 = False
info: d3d9.maxAvailableMemory = 2048
info: d3d9.memoryTrackTest = True
info: d3d9.swvpFloatCount = 384
info: d3d9.swvpIntCount = 16
info: d3d9.swvpBoolCount = 16
info: Built-in extension providers:
info: Win32 WSI
info: OpenVR
info: OpenXR
info: OpenVR: could not open registry key, status 2
info: OpenVR: Failed to locate module
info: Required Vulkan extension VK_KHR_surface not supported
terminate called after throwing an instance of 'dxvk::DxvkError'

abnormal program termination

Also before that, I learned that installing dxvk requires wine 5.8 or more ! But mine is just wine5.0.3. So they are not compatible with each other...

How can I solve error #1 to install wine 6.20 staging?
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by jkfloris »

--2021-11-09 19:53:08-- https://dl.winehq.org/wine-builds/winehq.key
dl.winehq.org (dl.winehq.org) analyzing... 151.101.114.217
dl.winehq.org (dl.winehq.org)[151.101.114.217]:443 connecting... connection established.
ERROR: `dl.winehq.org' the certificate is not secure.
Most likely this is a temporary error. If the error continues to occur, please create a new forum post under the section "Website Issues".
hopperman
Level 2
Level 2
Posts: 17
Joined: Wed Nov 03, 2021 9:53 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by hopperman »

Hi jkfloris,
I think I am near the solution :)
What I did and got new error:
1. as you said, it was a temporary error, I could get repo and could install successfully wine-stating 6.20 for Debian bullseye
2. I installed dxvk by using winetricsk dxvk
3. Then I start winecfg and then start Sims2 it gives me :

info: Game: Sims2.exe
info: DXVK: v1.9.2
info: Found built-in config:
info: Effective configuration:
info: d3d9.customVendorId = 10de
info: d3d9.disableA8RT = True
info: d3d9.customDeviceId = 0091
info: d3d9.customDeviceDesc = GeForce 7800 GTX
info: d3d9.supportX4R4G4B4 = False
info: d3d9.maxAvailableMemory = 2048
info: d3d9.memoryTrackTest = True
info: d3d9.swvpFloatCount = 384
info: d3d9.swvpIntCount = 16
info: d3d9.swvpBoolCount = 16
info: Built-in extension providers:
info: Win32 WSI
info: OpenVR
info: OpenXR
info: OpenVR: could not open registry key, status 2
info: OpenVR: Failed to locate module
info: Enabled instance extensions:
info: VK_KHR_get_surface_capabilities2
info: VK_KHR_surface
info: VK_KHR_win32_surface
warn: Skipping Vulkan 1.0 adapter: llvmpipe (LLVM 11.0.1, 128 bits)
warn: DXVK: No adapters found. Please check your device filter settings and Vulkan setup.
info: Process set as DPI aware
011c:fixme:imm:ImeSetActiveContext (0x3fc76d8, 1): stub
011c:fixme:imm:ImmReleaseContext (0001008C, 03FC76D8): stub
0084:fixme:imm:ImeSetActiveContext (0x6afdd8, 0): stub
0084:fixme:imm:ImmReleaseContext (00010020, 006AFDD8): stub

and then, window opened :

[attachment=0]vulkanError.png[/attachment]

What does that mean?
By the way I am using ATI graphics card(ATI Radeon HD4350), not NVIDIA.
Also i got vulkaninfo output as txt file but I could not upload , website gives me invalid extension error.

What should I do now?
Attachments
vulkanError.png
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: How to solve stpd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by jkfloris »

By the way I am using ATI graphics card(ATI Radeon HD4350)
Unfortunately, this graphics card does not have vulkan support. So you can't use dxvk.
Rename or delete the ~./wine folder and try to install the Sims 2 without dxvk.
Also read the tips on the AppDB.
hopperman
Level 2
Level 2
Posts: 17
Joined: Wed Nov 03, 2021 9:53 am

[SOLVED] Re: How to solve sptd service Error "ntoskrnl:ZwLoadDriver failed to create driver"

Post by hopperman »

Hi jkfloris,
Thanks! I solved my winehq problem.

I did :

1. winecfg
2. In the Libraries Tab > I found that lots of dx9xx.dll files are changed with native ones(not built in types which are provided by wine). Then I remove all of them.
3. use wine Sims2.exe

Wola! It works ... Until the body shop ! and inside the game all graphic objects are distorted...
However, I think the hard part is solved... The rest is game specific...

Where can I get support about Sims2 in wine? Can I use these forum pages or is AppDB page comment section is active?

Thanks again !
Locked