Score:0

Why does IIS PHP not recognize PhpRedis when it exists and is added correctly?

us flag

Before you read:

I currently have a PHP script which simply adds Redis (using PhpRedis).

<?php
    $redis = new Redis ();
?>

This creates a "500 Internal Server Error" message. Upon inspecting PHP 7.4 x64's logs, despite being located here, loading the page triggers the error:

[06-Aug-2021 15:54:13 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library 'php_redis.dll' (tried: C:\Program Files\PHP\v7.4\ext\php_redis.dll (The specified module could not be found.), C:\Program Files\PHP\v7.4\ext\php_php_redis.dll.dll (The specified module could not be found.)) in Unknown on line 0

It is not searching in the wrong place or not added because of these entries in php.ini:

[WebPIChanges]
extension_dir="C:\Program Files\PHP\v7.4\ext\"
...
[ExtensionList]
extension=php_redis.dll
...

IIS can detect the redis plugin in the extension manager and states that it is enabled.

This issue occurs in v7.4. I have tried this in v8.0, and I still face the same issues. PhpRedis 5.3.4 provides a v7.4 DLL, still the same issue with no dependencies made aware of.

Score:0
us flag

Issue resolved. My compiled version of PHP did not support thread safety features, therefore I must either compile a version with thread safety or use the NTS version of PhpRedis.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.