• Hey Till,

    Hope you’re doing well man. I’m noticing these errors (pasted below) in my wordpress logs… and they usually occur a few hours before other database / fatal errors pop up in wordpress, and the site crashes completely… however the site actually crashes because wordpress core functions are being called ‘out of order’, potentially because of inconsistencies in the cache layer.

    Based on my research, it could be that Redis is running out of memory, or according to a 9 year old thread in Github, it could have to do with Redis ‘protected mode’… not sure if you have any ideas on what might be causing this.

    Here’s the actual wordpress error: PHP FatalUncaught Error: Call to undefined function wp_normalize_path()

    Here’s the Redis error:

    RedisException: protocol error, got ‘<‘ as reply type byteStack trace: #0 /wp-content/object-cache.php(1990): Redis->get() #1 /wp-content/object-cache.php(193): WP_Object_Cache->get() #2 /wp-includes/option.php(169): wp_cache_get() #3 /wp-content/plugins/wp-security-audit-log/classes/Helpers/class-settings-helper.php(616): get_option() #4 /wp-content/plugins/wp-security-audit-log/classes/Helpers/class-settings-helper.php(182): WSAL\Helpers\Settings_Helper::get_option_value_internal() #5 /wp-content/plugins/wp-security-audit-log/classes/class-wp-security-audit-log.php(1278): WSAL\Helpers\Settings_Helper::get_option_value() #6 /wp-includes/class-wp-hook.php(324): WpSecurityAuditLog::close_external_connection() #7 /wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters() #8 /wp-includes/plugin.php(517): WP_Hook->do_action() #9 /wp-includes/load.php(1279): do_action() #10 internal function: shutdown_action_hook() #11 {main}Apr 1, 2025 – 00:17:02
    (1 occurrence logged)30OtherRedisException: protocol error, got ‘O’ as reply type byteStack trace: #0 /wp-content/plugins/redis-cache/includes/class-metrics.php(215): Redis->zAdd() #1 /wp-content/plugins/redis-cache/includes/class-metrics.php(138): Rhubarb\RedisCache\Metrics->save() #2 /wp-includes/class-wp-hook.php(324): Rhubarb\RedisCache\Metrics::record() #3 /wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters() #4 /wp-includes/plugin.php(517): WP_Hook->do_action() #5 /wp-includes/load.php(1279): do_action() #6 internal function: shutdown_action_hook() #7 {main}Plugin: Redis Object Cache
    File: /wp-content/plugins/redis-cache/includes/class-metrics.php
    Line: 215

    Here’s another DB error that happens right along with the Redis error:

    DatabaseCommands out of sync; you can’t run this command now for query SELECT option_value FROM 9mxqK9_options WHERE option_name = ‘action_scheduler_lock_async-request-runner’ made by shutdown_action_hook, do_action(‘shutdown’), WP_Hook->do_action, WP_Hook->apply_filters, ActionScheduler_QueueRunner->maybe_dispatch_async_request, ActionScheduler_OptionLock->set, ActionScheduler_OptionLock->get_existing_lock

    Please let me know if you have any ideas or if you provide paid support.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Till Krüss

    (@tillkruess)

    We’ve been trying to tracking this weird PhpRedis protocol error for weeks. I’ll get the author of the library to take a look at this.

    Formatted error:

    RedisException: protocol error, got ‘<‘ as reply type byte
    Stack trace:
    #0 /wp-content/object-cache.php(1990): Redis->get()
    #1 /wp-content/object-cache.php(193): WP_Object_Cache->get()
    #2 /wp-includes/option.php(169): wp_cache_get()
    #3 /wp-content/plugins/wp-security-audit-log/classes/Helpers/class-settings-helper.php(616): get_option()
    #4 /wp-content/plugins/wp-security-audit-log/classes/Helpers/class-settings-helper.php(182): WSAL\Helpers\Settings_Helper::get_option_value_internal()
    #5 /wp-content/plugins/wp-security-audit-log/classes/class-wp-security-audit-log.php(1278): WSAL\Helpers\Settings_Helper::get_option_value()
    #6 /wp-includes/class-wp-hook.php(324): WpSecurityAuditLog::close_external_connection()
    #7 /wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
    #8 /wp-includes/plugin.php(517): WP_Hook->do_action()
    #9 /wp-includes/load.php(1279): do_action()
    #10 internal function: shutdown_action_hook()
    #11 {main}

    Apr 1, 2025 – 00:17:02
    (1 occurrence logged)



    RedisException: protocol error, got ‘O’ as reply type byte
    Stack trace:
    #0 /wp-content/plugins/redis-cache/includes/class-metrics.php(215): Redis->zAdd()
    #1 /wp-content/plugins/redis-cache/includes/class-metrics.php(138): Rhubarb\RedisCache\Metrics->save()
    #2 /wp-includes/class-wp-hook.php(324): Rhubarb\RedisCache\Metrics::record()
    #3 /wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
    #4 /wp-includes/plugin.php(517): WP_Hook->do_action()
    #5 /wp-includes/load.php(1279): do_action()
    #6 internal function: shutdown_action_hook()
    #7 {main}

    Plugin: Redis Object Cache
    File: /wp-content/plugins/redis-cache/includes/class-metrics.php
    Line: 215
    Plugin Author Till Krüss

    (@tillkruess)

    @fightsmarttrav Can you please post:

    1. The full Redis Server INFO output
    2. The version of the PhpRedis extension php --ri redis
    3. All your WP_REDIS_* constants, except authentication / password
    Thread Starter fightsmarttrav

    (@fightsmarttrav)

    I got no results for the php–ri redis command but in query monitor I see: PhpRedis (v6.1.0)
    For constants, I do not have anything defined in wp-config… should I? I assume that ‘constants’ and ‘groups’ are different, please forgive my ignorance. Search for “Redis” in wp config returns no results.
    I do have relay installed and running… not sure if that matters
    Redis-cli info:

    redis_version:6.2.17

    redis_git_sha1:00000000

    redis_git_dirty:0

    redis_build_id:c965117b9db61ace

    redis_mode:standalone

    os:Linux 4.18.0-553.40.1.el8_10.x86_64 x86_64

    arch_bits:64

    monotonic_clock:POSIX clock_gettime

    multiplexing_api:epoll

    atomicvar_api:c11-builtin

    gcc_version:8.5.0

    process_id:1024988

    process_supervised:no

    run_id:bfb47d9224c510d2e49b2f73d691ef01d59b9d5f

    tcp_port:6379

    server_time_usec:1743528079595711

    uptime_in_seconds:1731384

    uptime_in_days:20

    hz:10

    configured_hz:10

    lru_clock:15474831

    executable:/usr/bin/redis-server

    config_file:/etc/redis.conf

    io_threads_active:0

    # Clients

    connected_clients:1

    cluster_connections:0

    maxclients:10000

    client_recent_max_input_buffer:24

    client_recent_max_output_buffer:0

    blocked_clients:0

    tracking_clients:0

    clients_in_timeout_table:0

    # Memory

    used_memory:132182024

    used_memory_human:126.06M

    used_memory_rss:147423232

    used_memory_rss_human:140.59M

    used_memory_peak:1553358552

    used_memory_peak_human:1.45G

    used_memory_peak_perc:8.51%

    used_memory_overhead:895936

    used_memory_startup:811976

    used_memory_dataset:131286088

    used_memory_dataset_perc:99.94%

    allocator_allocated:132339496

    allocator_active:135700480

    allocator_resident:147664896

    total_system_memory:16135036928

    total_system_memory_human:15.03G

    used_memory_lua:30720

    used_memory_lua_human:30.00K

    used_memory_scripts:0

    used_memory_scripts_human:0B

    number_of_cached_scripts:0

    maxmemory:0

    maxmemory_human:0B

    maxmemory_policy:noeviction

    allocator_frag_ratio:1.03

    allocator_frag_bytes:3360984

    allocator_rss_ratio:1.09

    allocator_rss_bytes:11964416

    rss_overhead_ratio:1.00

    rss_overhead_bytes:-241664

    mem_fragmentation_ratio:1.12

    mem_fragmentation_bytes:15304920

    mem_not_counted_for_evict:0

    mem_replication_backlog:0

    mem_clients_slaves:0

    mem_clients_normal:0

    mem_aof_buffer:0

    mem_allocator:jemalloc-5.1.0

    active_defrag_running:0

    lazyfree_pending_objects:0

    lazyfreed_objects:0

    # Persistence

    loading:0

    current_cow_size:0

    current_cow_size_age:0

    current_fork_perc:0.00

    current_save_keys_processed:0

    current_save_keys_total:0

    rdb_changes_since_last_save:46

    rdb_bgsave_in_progress:0

    rdb_last_save_time:1743528058

    rdb_last_bgsave_status:ok

    rdb_last_bgsave_time_sec:0

    rdb_current_bgsave_time_sec:-1

    rdb_last_cow_size:7643136

    aof_enabled:0

    aof_rewrite_in_progress:0

    aof_rewrite_scheduled:0

    aof_last_rewrite_time_sec:-1

    aof_current_rewrite_time_sec:-1

    aof_last_bgrewrite_status:ok

    aof_last_write_status:ok

    aof_last_cow_size:0

    module_fork_in_progress:0

    module_fork_last_cow_size:0

    # Stats

    total_connections_received:624968

    total_commands_processed:1490447167

    instantaneous_ops_per_sec:0

    total_net_input_bytes:20488693013035

    total_net_output_bytes:3374712324759

    instantaneous_input_kbps:0.00

    instantaneous_output_kbps:0.00

    rejected_connections:0

    sync_full:0

    sync_partial_ok:0

    sync_partial_err:0

    expired_keys:138578

    expired_stale_perc:0.00

    expired_time_cap_reached_count:0

    expire_cycle_cpu_milliseconds:84257

    evicted_keys:0

    keyspace_hits:104424843

    keyspace_misses:31463527

    pubsub_channels:0

    pubsub_patterns:0

    latest_fork_usec:3946

    total_forks:5773

    migrate_cached_sockets:0

    slave_expires_tracked_keys:0

    active_defrag_hits:0

    active_defrag_misses:0

    active_defrag_key_hits:0

    active_defrag_key_misses:0

    tracking_total_keys:0

    tracking_total_items:0

    tracking_total_prefixes:0

    unexpected_error_replies:0

    total_error_replies:0

    dump_payload_sanitizations:0

    total_reads_processed:1385500451

    total_writes_processed:945212591

    io_threaded_reads_processed:0

    io_threaded_writes_processed:0

    # Replication

    role:master

    connected_slaves:0

    master_failover_state:no-failover

    master_replid:d622cde4f28b482384c3ae1b8f6d6ce3e11d4922

    master_replid2:0000000000000000000000000000000000000000

    master_repl_offset:0

    second_repl_offset:-1

    repl_backlog_active:0

    repl_backlog_size:1048576

    repl_backlog_first_byte_offset:0

    repl_backlog_histlen:0

    # CPU

    used_cpu_sys:10059.809499

    used_cpu_user:3303.997491

    used_cpu_sys_children:623.692958

    used_cpu_user_children:5194.746291

    used_cpu_sys_main_thread:9877.177250

    used_cpu_user_main_thread:3285.121003

    # Modules

    # Errorstats

    # Cluster

    cluster_enabled:0

    # Keyspace

    db0:keys=1665,expires=30,avg_ttl=29970166

    [root@distracted-williams rocky]# 

    [root@distracted-williams rocky]# 

    php –ri redis

    [root@distracted-williams rocky]# php –ri redis

    Extension ‘redis’ not present.

    [root@distracted-williams rocky]# 

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.