AlexWebsites Posted November 19, 2017 Posted November 19, 2017 Are there certain settings for redis on the server that are recommended? I'm using memcached and thinking of trying redis on one of my sites.
jair101 Posted November 19, 2017 Posted November 19, 2017 Well noone dares to post even a basic practical information, so I figured I might start. I have 0 experience with redis, so it is a bit of shooting in the dark, no guidelines by all means, I just hope that by posting some numbers I will provoke other, more knowledgeable people to share. My community is around 300k posts, 8k members and about 100-150 people online. It is running on 4core/6GB RAM vps with plenty of resources left. Redis has been running for a few hours. I made these settings: maxmemory 200mb maxmemory-policy allkeys-lru maxmemory-samples 10 All seems fine now, in fact memory consumption is close to 20mb, so I guess not that much is needed overall. The hits/miss stats look fine to me for a cache started from scratch: keyspace_hits:616880 keyspace_misses:6731 I wonder if the fact that worst run took 61x longer should worry me. redis-cli --intrinsic-latency 10 Max latency so far: 4 microseconds. Max latency so far: 7 microseconds. Max latency so far: 35 microseconds. Max latency so far: 36 microseconds. Max latency so far: 47 microseconds. Max latency so far: 51 microseconds. Max latency so far: 68 microseconds. Max latency so far: 72 microseconds. Max latency so far: 114 microseconds. Max latency so far: 118 microseconds. Max latency so far: 136 microseconds. Max latency so far: 197 microseconds. 3091951 total runs (avg latency: 3.2342 microseconds / 3234.20 nanoseconds per run). Worst run took 61x longer than the average latency. Two questions that I am very much interested in finding an answer: - Does it make sense to create a master/slave replication? - Is IPS utilizing only the LRU cache functionalities or other stuff, like php sessions, can also be cached?
AlexWebsites Posted November 20, 2017 Posted November 20, 2017 I just moved one of my sites on 4.2.6 over to redis from memcached and I have to say it feels snappier. I don't know if it's in my head or something, but it feels like pages load a bit faster.
Tom S. Posted November 20, 2017 Posted November 20, 2017 1 hour ago, AlexWebsites said: I just moved one of my sites on 4.2.6 over to redis from memcached and I have to say it feels snappier. I don't know if it's in my head or something, but it feels like pages load a bit faster. It's very easy to have a placebo effect with these kind of things unless there really was a big change. When we are talking milliseconds someone needs to run more scientific tests. Any volunteers?
nodle Posted November 20, 2017 Posted November 20, 2017 Is there anyways we can get an official answer if Redis supports sockets? I would like to try the same as @Ernest Defoe did above but would like an official answer. @Lindy, @Matt ,@Mark, @bfarber. Thanks!
nodle Posted November 21, 2017 Posted November 21, 2017 Still waiting for an official word. A yes it does, or no it doesn't would be sufficient for me. Thanks! @Lindy, @Matt, @Mark, @bfarber.
Management Matt Posted November 21, 2017 Management Posted November 21, 2017 Hi Nodle, I haven't used a socket myself but the set up that I saw on page 1 seems sensible and works similarly to MySQL sockets so I would think that approach is fine.
nodle Posted November 21, 2017 Posted November 21, 2017 1 minute ago, Matt said: Hi Nodle, I haven't used a socket myself but the set up that I saw on page 1 seems sensible and works similarly to MySQL sockets so I would think that approach is fine. Thanks @Matt for the response, I will give it a go later. I appreciate it.
nodle Posted November 21, 2017 Posted November 21, 2017 Just switch to Redis, pretty sure it's working with the socket just fine. I don't think it's a placebo effect either, everything is almost instant to load. It has a more "Snappyness" to it then running on Memcached. So I see why it's the preferred option now.
Thomas P Posted January 15, 2018 Posted January 15, 2018 Any recommendations which redis configuration I should use for redis with IPB 4.2.x? -timeout -tcp-keepalive Any other settings to have an eye on? Memory/cache sizes? Thanks, Thomas
LaCollision Posted May 23, 2018 Posted May 23, 2018 Hi, Up ? That would we great if we could have somme recommandation on what is the best Redis configuration for Invision? Thanks!
j4ss Posted May 25, 2018 Posted May 25, 2018 Hello, Could anyone share redis.conf file? Just installed Redis cache and need configuration.
TSP Posted May 25, 2018 Posted May 25, 2018 On 11/15/2017 at 1:04 PM, Matt said: 4.3 allows you to set up a system where you have one Redis writer, and multiple readers. Hi Matt, After upgrading to 4.3 I'm still unable to configure Redis with multiple readers. What am I missing?
The Old Man Posted May 25, 2018 Posted May 25, 2018 I installed Redis (with the basic configuration) on my Cloud VPS SSD CentOS6.9, with 48 unlocked cores, 32 CPUs, 1.5GB RAM (burstable to 4GB). I installed PHP 7.2, Easy Apache 4, PHP-FPM, Zend Opcache, MariaDB10.2, Innodb. Because the RAM is burstable to 4GB, utilities like Mysqltuner complain about free memory but I've hardly see it go over 1.5GB in the graphs. Not sure if this helps anyone but happy to share: root@vpsxxxxxx [~/redis-stable]# redis-cli info # Server redis_version:4.0.9 redis_git_sha1:00000000 redis_git_dirty:0 redis_build_id:8c9f92a1a46f0f58 redis_mode:standalone os:Linux 2.6.32-042stab127.2 x86_64 arch_bits:64 multiplexing_api:epoll atomicvar_api:sync-builtin gcc_version:4.4.7 process_id:8791 run_id:3f8af954dbb440d81ed0867a8516a9b9bd13fd69 tcp_port:6379 uptime_in_seconds:971976 uptime_in_days:11 hz:10 lru_clock:531973 executable:/root/redis-stable/redis-server config_file: # Clients connected_clients:1 client_longest_output_list:0 client_biggest_input_buf:0 blocked_clients:0 # Memory used_memory:1844000 used_memory_human:1.76M used_memory_rss:3538944 used_memory_rss_human:3.38M used_memory_peak:27685208 used_memory_peak_human:26.40M used_memory_peak_perc:6.66% used_memory_overhead:849950 used_memory_startup:786456 used_memory_dataset:994050 used_memory_dataset_perc:94.00% total_system_memory:1610612736 total_system_memory_human:1.50G used_memory_lua:37888 used_memory_lua_human:37.00K maxmemory:0 maxmemory_human:0B maxmemory_policy:noeviction mem_fragmentation_ratio:1.92 mem_allocator:jemalloc-4.0.3 active_defrag_running:0 lazyfree_pending_objects:0 # Persistence loading:0 rdb_changes_since_last_save:74 rdb_bgsave_in_progress:0 rdb_last_save_time:1527258131 rdb_last_bgsave_status:ok rdb_last_bgsave_time_sec:0 rdb_current_bgsave_time_sec:-1 rdb_last_cow_size:1110016 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 # Stats total_connections_received:47799 total_commands_processed:1015927 instantaneous_ops_per_sec:0 total_net_input_bytes:1999153250 total_net_output_bytes:7169421240 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:31840 expired_stale_perc:0.00 expired_time_cap_reached_count:0 evicted_keys:0 keyspace_hits:944911 keyspace_misses:61674 pubsub_channels:0 pubsub_patterns:0 latest_fork_usec:637 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 # Replication role:master connected_slaves:0 master_replid:be0a8cfc95d24df1493c05f9a53b3eecb2f05f79 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:625.69 used_cpu_user:583.84 used_cpu_sys_children:80.33 used_cpu_user_children:328.80 # Cluster cluster_enabled:0 # Keyspace db0:keys=89,expires=88,avg_ttl=42905187 root@vpsxxxxxx [~/redis-stable]# I recently installed the New Relic free trial, and it shows Redis working. I tried to add configure for each of my 4 website domains in addition to the main site wide PHP app, but it never shows them, only the total usage.
yacenty Posted January 9, 2020 Posted January 9, 2020 Which Redis version is recommended for IPB? 4.0 or 5.0?
Recommended Posts
Archived
This topic is now archived and is closed to further replies.