• Resolved keramikoch

    (@keramikoch)


    Dear Litespeed Plugin Support,

    I do have 2 multisites installed on the same server.
    1. Plugins Ins, Themes everthing –> Redis works
    2. No Plug-Ins apart from litespeed, standard theme –> Redis connection fails

    The Hosting Company Redis works 100% from the server site – it must be something on my wordpress installation (like blocking a connection). But i deavtivated all plug-ins (also wordfence) like I said above.
    I also checke wp-config and htaccess (there is nothing unusual).

    I also gave the two redis instances different database IDs (1 and 2).

    Question 1:
    Do you have any idea why Redis does not work on 2. ? WordPress Core and Litespeed Plugin Version are the same (the newest)

    Question 2:
    In the debug.log I get the error: PHP Deprecated: urldecode(): Passing null to parameter #1 ($string) of type string is deprecated in …./public_html/wp-content/plugins/litespeed-cache/src/control.cls.php on line 528

    Could that be linked to the problem with Redis?

    Thanks in advance!

    • This topic was modified 1 year, 4 months ago by keramikoch.
    • This topic was modified 1 year, 4 months ago by keramikoch.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support qtwrk

    (@qtwrk)

    wait a second , did you say , on same server , one site works , one site doesn’t ?

    did you set the port number correct ?

    please try this standalone PHP connection test script , see what it shows

    <?php
    
    $redis = new Redis();
    $redis->connect('localhost', 6379);  # change if needed
    $redis->auth('password');
    $redis->select('2');  # 2 for ID 
    
    if ($redis->ping()) {
     echo "PONG";
    }
    
    

    no , it’s not related to redis.

    Thread Starter keramikoch

    (@keramikoch)

    Hi @qtwrk:
    Exactly, to be more specific:
    2 WordPress Multisites on one Account on one Shared Server (fast one).
    1 Works with Redis Litespeed Plugin, 1 does not.

    I had to adapt your script to work with a UNIX socket but it works:

    <?php
    
    $redis = new Redis();
    $redis->connect('/home/myaccountname/.redis/redis.sock');  // Connect using Unix socket
    
    // Optionally, if authentication is required, you can use the auth command
    // $redis->auth('password');
    
    $redis->select(2);  // Selecting the database ID, if needed
    
    if ($redis->ping()) {
        echo "PONG";
    } else {
        echo "Cannot connect to Redis";
    }
    
    ?>

    And now when I upload it and start it in the browser it is: “PONG”

    Thread Starter keramikoch

    (@keramikoch)

    Ok :)) I found was a misspelling of the account name in Redis Socke in the Plug-In :() Thanks for the help anyway.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Redis Connection Fails’ is closed to new replies.