更改套接字文件位置
更改套接字文件位置。
Redis 企业软件 |
---|
默认套接字文件位置
Redis Enterprise Software 中的套接字文件有两个默认位置:
-
/tmp
- 在早于 5.2.2 的 Redis Enterprise Software 版本的全新安装中 -
/var/opt/redislabs/run
- 在 Redis Enterprise Software 版本 5.2.2 及更高版本的全新安装中注意:如果您运行任何维护过程来删除/tmp
目录。
当您将 Redis Enterprise Software 从早期版本升级到 5.2.2 或更高版本时,默认情况下,套接字文件不会移动到新位置。您需要在安装过程中指定套接字文件的位置。
在安装过程中指定套接字文件位置
要在新安装期间指定套接字文件位置,请按照在 Linux 上安装 Redis Enterprise Software 的说明进行作,但请使用-s
安装脚本选项:
sudo ./install.sh -s </path/to/socket/files>
Change socket file location for an existing cluster
Directly changing the socket file location directly is not supported for bootstrapped nodes. If you need to change the socket file location for an existing cluster, use one of the following methods instead:
Replace nodes
To change the socket file location for all nodes in a cluster, follow these steps:
-
Install Redis Enterprise Software on a new node with the new socket file location. Follow the Install Redis Enterprise Software on Linux instructions, but use the -s installation script option:
sudo ./install.sh -s </path/to/socket/files>
-
Add the new node to the existing cluster.
-
Remove a node with the old socket file location.
-
Repeat the previous steps until all nodes with the old socket file location have been replaced.
Migrate cluster using Replica Of
To migrate an existing cluster to a new cluster with a different socket file location:
-
Create a new cluster with the new socket file location. To do so, follow the Install Redis Enterprise Software on Linux instructions, but use the -s
installation script option:
sudo ./install.sh -s </path/to/socket/files>
-
Use Replica Of to migrate your databases from the original cluster to the new cluster. For detailed steps, see the procedure to configure Replica Of with different Redis Enterprise clusters.
On this page