RedisShake迁移同步工具
阿里开源项目地址:
https://github.com/alibaba/RedisShake
程序下载地址:
https://github.com/alibaba/RedisShake/releases
下载最新程序,里面包含了配置文件
https://github.com/alibaba/RedisShake/releases/download/release-v2.0.3-20200724/redis-shake-v2.0.3.tar.gz
tar xf redis-shake-v2.0.3.tar.gz redis-shake-v2.0.3
配置文件 egrep -v "^$|^#" redis-shake.conf conf.version = 1 id = redis-shake log.file = log.level = info pid_path = system_profile = 9310 http_profile = 9320 parallel = 32 source.type = standalone source.address = 0.0.0.0:6379 #需要同步的本地地址 source.password_raw = #本地redis的认证密码 source.auth_type = auth source.tls_enable = false source.rdb.input = local source.rdb.parallel = 0 source.rdb.special_cloud = target.type = standalone target.address = xxx.xxx.xxx.xxx:6379 #云redis地址和端口 target.password_raw = #目标云redis的认证密码 target.auth_type = auth target.db = -1 target.tls_enable = false target.rdb.output = local_dump target.version = fake_time = key_exists = none filter.db.whitelist = filter.db.blacklist = filter.key.whitelist = filter.key.blacklist = filter.slot = filter.lua = false big_key_threshold = 524288000 metric = true metric.print_log = false sender.size = 104857600 sender.count = 4095 #默认值,可以根据需求进行调整, sender.delay_channel_size = 65535 keep_alive = 0 scan.key_number = 50 scan.special_cloud = scan.key_file = qps = 200000 resume_from_break_point = false replace_hash_tag = false
开始同步,同步时间取决于网络,文件大小决定
./redis-shake.linux -type=sync -conf=./redis-shake.conf
同步模式
参考地址:https://github.com/alibaba/RedisShake/wiki/%E5%BF%AB%E9%80%9F%E5%BC%80%E5%A7%8B%EF%BC%9A%E6%95%B0%E6%8D%AE%E8%BF%81%E7%A7%BB
使劲折腾才会有更好的结果!!!!
如有不对请不吝赐教,感谢!
转载请注明出处!