Title: Socket Error On Read Socket
Last modified: May 5, 2023

---

# Socket Error On Read Socket

 *  Resolved [americanoffroads](https://wordpress.org/support/users/americanoffroads/)
 * (@americanoffroads)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/socket-error-on-read-socket/)
 * Hello, After website sitting for 12-24 hours clearing customer sessions or redis
   cache causes the site to crash and gives. Was happening on 2.3 and also on 2.4
    - Status: Connected
    - Client: PhpRedis (v5.3.7)
    - Drop-in: Valid
    - Disabled: No
    - Ping: 1
    - Errors: []
    - PhpRedis: 5.3.7
    - Relay: Not loaded
    - Predis: 2.1.2
    - Credis: Not loaded
    - PHP Version: 7.4.33
    - Plugin Version: 2.4.1
    - Redis Version: 6.0.6
    - Multisite: No
    - Metrics: Enabled
    - Metrics recorded: 2300
    - Filesystem: Working
    - Global Prefix: “wp_”
    - Blog Prefix: “wp_”
    - WP_REDIS_PREFIX: “eip2H_object_cache_americanoffroads.com”
    - WP_CACHE_KEY_SALT: “eip2H_object_cache_americanoffroads.com”
    - WP_REDIS_PLUGIN_PATH: “/var/www/americanoffroads.com/htdocs/wp-content/plugins/
      redis-cache”
    - WP_REDIS_SELECTIVE_FLUSH: true
    - Global Groups: [
    -  “blog-details”,
    -  “blog-id-cache”,
    -  “blog-lookup”,
    -  “global-posts”,
    -  “networks”,
    -  “rss”,
    -  “sites”,
    -  “site-details”,
    -  “site-lookup”,
    -  “site-options”,
    -  “site-transient”,
    -  “users”,
    -  “useremail”,
    -  “userlogins”,
    -  “usermeta”,
    -  “user_meta”,
    -  “userslugs”,
    -  “redis-cache”,
    -  “blog_meta”
    - ]
    - Ignored Groups: [
    -  “counts”,
    -  “plugins”,
    -  “themes”,
    -  “theme_json”
    - ]
    - Unflushable Groups: []
    - Groups Types: {
    -  “blog-details”: “global”,
    -  “blog-id-cache”: “global”,
    -  “blog-lookup”: “global”,
    -  “global-posts”: “global”,
    -  “networks”: “global”,
    -  “rss”: “global”,
    -  “sites”: “global”,
    -  “site-details”: “global”,
    -  “site-lookup”: “global”,
    -  “site-options”: “global”,
    -  “site-transient”: “global”,
    -  “users”: “global”,
    -  “useremail”: “global”,
    -  “userlogins”: “global”,
    -  “usermeta”: “global”,
    -  “user_meta”: “global”,
    -  “userslugs”: “global”,
    -  “redis-cache”: “global”,
    -  “counts”: “ignored”,
    -  “plugins”: “ignored”,
    -  “themes”: “ignored”,
    -  “blog_meta”: “global”,
    -  “theme_json”: “ignored”
    - }
    - Drop-ins: [
    -  “advanced-cache.php v by “,
    -  “Redis Object Cache Drop-In v2.4.1 by Till Krüss”
    - ]
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fsocket-error-on-read-socket%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Plugin Author [Till Krüss](https://wordpress.org/support/users/tillkruess/)
 * (@tillkruess)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/socket-error-on-read-socket/#post-16714324)
 * Thanks for reporting this. Are you monitoring your `redis` process? Does it run
   out of memory after 12-24 hours? Can you post your `redis-cli INFO` output?
 *  Thread Starter [americanoffroads](https://wordpress.org/support/users/americanoffroads/)
 * (@americanoffroads)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/socket-error-on-read-socket/#post-16714675)
 * Here is the output:
 *     ```wp-block-code
       redis_version:6.0.6redis_git_sha1:00000000redis_git_dirty:0redis_build_id:d463d609620685c0redis_mode:standaloneos:Linux 5.4.0-148-generic x86_64arch_bits:64multiplexing_api:epollatomicvar_api:atomic-builtingcc_version:9.3.0process_id:3971162run_id:6bba9fbba1619469e0c5ff82373305de878295a9tcp_port:6379uptime_in_seconds:41906uptime_in_days:0hz:10configured_hz:10lru_clock:5583737executable:/usr/bin/redis-serverconfig_file:/etc/redis/redis.conf
   
       # Clientsconnected_clients:5client_recent_max_input_buffer:2client_recent_max_output_buffer:0blocked_clients:0tracking_clients:0clients_in_timeout_table:0
   
       # Memoryused_memory:1540721576used_memory_human:1.43Gused_memory_rss:1585147904used_memory_rss_human:1.48Gused_memory_peak:1791419552used_memory_peak_human:1.67Gused_memory_peak_perc:86.01%used_memory_overhead:31733074used_memory_startup:802040used_memory_dataset:1508988502used_memory_dataset_perc:97.99%allocator_allocated:1541096784allocator_active:1573212160allocator_resident:1600700416total_system_memory:16786857984total_system_memory_human:15.63Gused_memory_lua:412672used_memory_lua_human:403.00Kused_memory_scripts:944used_memory_scripts_human:944Bnumber_of_cached_scripts:2maxmemory:1782579200maxmemory_human:1.66Gmaxmemory_policy:allkeys-lfuallocator_frag_ratio:1.02allocator_frag_bytes:32115376allocator_rss_ratio:1.02allocator_rss_bytes:27488256rss_overhead_ratio:0.99rss_overhead_bytes:-15552512mem_fragmentation_ratio:1.03mem_fragmentation_bytes:44468840mem_not_counted_for_evict:0mem_replication_backlog:0mem_clients_slaves:0mem_clients_normal:84930mem_aof_buffer:0mem_allocator:jemalloc-5.1.0active_defrag_running:0lazyfree_pending_objects:0
   
       # Persistenceloading:0rdb_changes_since_last_save:244rdb_bgsave_in_progress:0rdb_last_save_time:1683305048rdb_last_bgsave_status:okrdb_last_bgsave_time_sec:6rdb_current_bgsave_time_sec:-1rdb_last_cow_size:2408448aof_enabled:0aof_rewrite_in_progress:0aof_rewrite_scheduled:0aof_last_rewrite_time_sec:-1aof_current_rewrite_time_sec:-1aof_last_bgrewrite_status:okaof_last_write_status:okaof_last_cow_size:0module_fork_in_progress:0module_fork_last_cow_size:0
   
       # Statstotal_connections_received:44260total_commands_processed:10335872instantaneous_ops_per_sec:0total_net_input_bytes:20478671506total_net_output_bytes:151765704163instantaneous_input_kbps:0.00instantaneous_output_kbps:0.00rejected_connections:0sync_full:0sync_partial_ok:0sync_partial_err:0expired_keys:519expired_stale_perc:0.00expired_time_cap_reached_count:0expire_cycle_cpu_milliseconds:3080evicted_keys:145423keyspace_hits:20061149keyspace_misses:805436pubsub_channels:0pubsub_patterns:0latest_fork_usec:36660migrate_cached_sockets:0slave_expires_tracked_keys:0active_defrag_hits:0active_defrag_misses:0active_defrag_key_hits:0active_defrag_key_misses:0tracking_total_keys:0tracking_total_items:0tracking_total_prefixes:0unexpected_error_replies:0
   
       # Replicationrole:masterconnected_slaves:0master_replid:11b189e23a2581445004f581adfcf80ee7e9c43dmaster_replid2:0000000000000000000000000000000000000000master_repl_offset:0second_repl_offset:-1repl_backlog_active:0repl_backlog_size:1048576repl_backlog_first_byte_offset:0repl_backlog_histlen:0
   
       # CPUused_cpu_sys:384.824559used_cpu_user:227.312600used_cpu_sys_children:82.795809used_cpu_user_children:650.217919
   
       # Modules
   
       # Clustercluster_enabled:0
   
       # Keyspacedb0:keys=543642,expires=18697,avg_ttl=3866585177
       ```
   
 *  Plugin Author [Till Krüss](https://wordpress.org/support/users/tillkruess/)
 * (@tillkruess)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/socket-error-on-read-socket/#post-16715202)
 *     ```wp-block-code
       maxmemory_policy:allkeys-lfu
       used_memory_dataset_perc:97.99%
       ```
   
 * These two are standing out. You’re using near 100% of your Redis memory and using`
   allkeys-lfu` which will cause CPU load.
 * I’d suggest allocating more memory to the Redis Server to ensure you don’t pressure
   it around 100%.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Socket Error On Read Socket’ is closed to new replies.

 * ![](https://ps.w.org/redis-cache/assets/icon-256x256.gif?rev=2568513)
 * [Redis Object Cache](https://wordpress.org/plugins/redis-cache/)
 * [Support Threads](https://wordpress.org/support/plugin/redis-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/redis-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/redis-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/redis-cache/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Till Krüss](https://wordpress.org/support/users/tillkruess/)
 * Last activity: [3 years, 1 month ago](https://wordpress.org/support/topic/socket-error-on-read-socket/#post-16715202)
 * Status: resolved