Hello Antirez, I've faced to a problem with my dump file. When I migrate my redis server with move my rdb file to another server (Which works just fine on my previous server) It will crash when doing save. (or bgsave)
=== REDIS BUG REPORT START: Cut & paste starting from here ===
13372:C 31 Oct 03:34:26.275 # Redis 4.0.2 crashed by signal: 11
13372:C 31 Oct 03:34:26.275 # Crashed running the instuction at: 0x447ee9
13372:C 31 Oct 03:34:26.275 # Accessing address: 0x1e
13372:C 31 Oct 03:34:26.275 # Failed assertion:
------ STACK TRACE ------ EIP: redis-rdb-bgsave 127.0.0.1:8310(rdbSaveObject+0x319)[0x447ee9]
Backtrace: redis-rdb-bgsave 127.0.0.1:8310(logStackTrace+0x29)[0x467ba9] redis-rdb-bgsave 127.0.0.1:8310(sigsegvHandler+0xa6)[0x468246] /lib/x86_64-linux-gnu/libpthread.so.0(+0xf890)[0x7f93ae6d4890] redis-rdb-bgsave 127.0.0.1:8310(rdbSaveObject+0x319)[0x447ee9] redis-rdb-bgsave 127.0.0.1:8310(rdbSaveKeyValuePair+0xa3)[0x448283] redis-rdb-bgsave 127.0.0.1:8310(rdbSaveRio+0x2dc)[0x4487fc] redis-rdb-bgsave 127.0.0.1:8310(rdbSave+0x78)[0x448bc8] redis-rdb-bgsave 127.0.0.1:8310(rdbSaveBackground+0x7c)[0x448dec] redis-rdb-bgsave 127.0.0.1:8310(bgsaveCommand+0xae)[0x44b09e] redis-rdb-bgsave 127.0.0.1:8310(call+0x96)[0x42afc6] redis-rdb-bgsave 127.0.0.1:8310(processCommand+0x387)[0x42b687] redis-rdb-bgsave 127.0.0.1:8310(processInputBuffer+0x105)[0x43a745] redis-rdb-bgsave 127.0.0.1:8310(aeProcessEvents+0x14d)[0x42562d] redis-rdb-bgsave 127.0.0.1:8310(aeMain+0x2b)[0x4259eb] redis-rdb-bgsave 127.0.0.1:8310(main+0x49f)[0x42282f] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf5)[0x7f93ae33bb45] redis-rdb-bgsave 127.0.0.1:8310[0x422b0f]
------ INFO OUTPUT ------
Server
redis_version:4.0.2 redis_git_sha1:00000000 redis_git_dirty:0 redis_build_id:fef3acae3e65f2b1 redis_mode:standalone os:Linux 3.16.0-4-amd64 x86_64 arch_bits:64 multiplexing_api:epoll atomicvar_api:atomic-builtin gcc_version:4.9.2 process_id:13372 run_id:a60dade18c57e6f512567cacfe07d5d36f0791fa tcp_port:8310 uptime_in_seconds:242 uptime_in_days:0 hz:10 lru_clock:16263019 executable:/usr/local/bin/redis-server config_file:/etc/redis/8310.conf
Clients
connected_clients:1 client_longest_output_list:0 client_biggest_input_buf:0 blocked_clients:0
Memory
used_memory:6142566704 used_memory_human:5.72G used_memory_rss:6341574656 used_memory_rss_human:5.91G used_memory_peak:6176644320 used_memory_peak_human:5.75G used_memory_peak_perc:99.45% used_memory_overhead:298008934 used_memory_startup:765560 used_memory_dataset:5844557770 used_memory_dataset_perc:95.16% total_system_memory:25337892864 total_system_memory_human:23.60G used_memory_lua:37888 used_memory_lua_human:37.00K maxmemory:0 maxmemory_human:0B maxmemory_policy:noeviction mem_fragmentation_ratio:1.03 mem_allocator:jemalloc-4.0.3 active_defrag_running:0 lazyfree_pending_objects:0
Persistence
loading:0 rdb_changes_since_last_save:0 rdb_bgsave_in_progress:0 rdb_last_save_time:1509435001 rdb_last_bgsave_status:ok rdb_last_bgsave_time_sec:-1 rdb_current_bgsave_time_sec:-1 rdb_last_cow_size:0 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:2 total_commands_processed:0 instantaneous_ops_per_sec:0 total_net_input_bytes:33 total_net_output_bytes:49 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:0 evicted_keys:0 keyspace_hits:0 keyspace_misses:0 pubsub_channels:0 pubsub_patterns:0 latest_fork_usec:0 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:387caca42a59a7d4837005097523592b356d39f2 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:1.23 used_cpu_user:21.47 used_cpu_sys_children:0.00 used_cpu_user_children:0.00
Commandstats
Cluster
cluster_enabled:0
Keyspace
db0:keys=5667692,expires=97026,avg_ttl=140830574297
Comment From: antirez
Hello, it's very hard to investigate the issue with the information at hand there, we know that there was a crash, and because of the address that generated the problem, which is 0x1e (30 in radix 10), it could be that a structure NULL pointer is deferenced somewhere or something like that. Are you able to trigger the problem again? In such a case, you could attach GDB to the process, and see where it crashes, this gives use a few more clues, like the key type, the exact place where it crashes and so forth. Another problem I've is that I think the above bug report is not complete AFAIK, it should dump some big hex blob I cannot see, and that would be very useful. Please could you include the full stack trace?
Comment From: antirez
p.s. this could also be related to hardware problems so a memory check could be useful.
Comment From: danitfk
Hey there, I've sent an email with a config file and RDB file. Also, I've added GDB result.
Thanks