I have been trying for hours to import a .RDB Redis database file into a new installation on my local machine. I have followed all the steps on * stating to basically drop the dump.rdb into the installation folder (i.e. what it's condifured to read in the .conf file. See first screenshot).
几个小时以来,我一直在尝试将. rdb Redis数据库文件导入到本地机器上的新安装中。我已经执行了*上的所有步骤,说明基本上要删除转储。将rdb放入安装文件夹(也就是在.conf文件中读取的条件。看到第一个截图)。
I make sure that the redis server is not running when I place the file, and when re-start the server and I open redis-cli and do something like keys *
it's saying that there's nothing. What's going on? All of my .conf settings are default settings
当我放置文件时,我确保redis服务器没有运行,当我重新启动服务器并打开redis-cli并做一些类似keys的事情时,它说什么都没有。这是怎么呢我所有的。conf设置都是默认设置
1 个解决方案
#1
2
The following line from your log suggests that the RDB is indeed loaded:
从您的日志中可以看出,RDB确实已加载:
[9480] 07 Jun 10:34:11.290 * DB loaded from disk: 3.540 seconds
And this line begotten from INFO
tells the whole thing:
从INFO衍生出来的这句话告诉我们:
db2:keys=457985,expires=0,avg_ttl=0
Your keys are sitting in the database numbered 2, so to access them you'll need to issue the following command upon connecting to Redis:
您的密钥位于编号为2的数据库中,因此要访问它们,您需要在连接到Redis时发出以下命令:
SELECT 2
BTW - numbered (a.k.a. "shared") Redis database is a bad habit that you should stop practicing. If you're looking for the reasons why (except this little mixup), read here: https://redislabs.com/blog/benchmark-shared-vs-dedicated-redis-instances
顺便说一句,编号(或称。“共享”)Redis数据库是一个坏习惯,你应该停止练习。如果您正在寻找原因(除了这个小错误),请阅读这里:https://redislabs.com/blog/benchmark-shared-vs-献身-redis-instances
#1
2
The following line from your log suggests that the RDB is indeed loaded:
从您的日志中可以看出,RDB确实已加载:
[9480] 07 Jun 10:34:11.290 * DB loaded from disk: 3.540 seconds
And this line begotten from INFO
tells the whole thing:
从INFO衍生出来的这句话告诉我们:
db2:keys=457985,expires=0,avg_ttl=0
Your keys are sitting in the database numbered 2, so to access them you'll need to issue the following command upon connecting to Redis:
您的密钥位于编号为2的数据库中,因此要访问它们,您需要在连接到Redis时发出以下命令:
SELECT 2
BTW - numbered (a.k.a. "shared") Redis database is a bad habit that you should stop practicing. If you're looking for the reasons why (except this little mixup), read here: https://redislabs.com/blog/benchmark-shared-vs-dedicated-redis-instances
顺便说一句,编号(或称。“共享”)Redis数据库是一个坏习惯,你应该停止练习。如果您正在寻找原因(除了这个小错误),请阅读这里:https://redislabs.com/blog/benchmark-shared-vs-献身-redis-instances