anduin revised this gist . Go to revision
1 file changed, 1 insertion, 1 deletion
notes.md
@@ -114,7 +114,7 @@ scp /etc/ceph/ceph.pub root@node2:/root/.ssh/authorized_keys | |||
114 | 114 | scp /etc/ceph/ceph.pub root@node3:/root/.ssh/authorized_keys | |
115 | 115 | ``` | |
116 | 116 | ||
117 | - | 三台全部都安装好ceph-common | |
117 | + | 在主机上安装好ceph-common | |
118 | 118 | ||
119 | 119 | ```bash | |
120 | 120 | apt install -y ceph-common |
anduin revised this gist . Go to revision
1 file changed, 1 insertion, 1 deletion
notes.md
@@ -114,7 +114,7 @@ scp /etc/ceph/ceph.pub root@node2:/root/.ssh/authorized_keys | |||
114 | 114 | scp /etc/ceph/ceph.pub root@node3:/root/.ssh/authorized_keys | |
115 | 115 | ``` | |
116 | 116 | ||
117 | - | 都安装好ceph-common | |
117 | + | 三台全部都安装好ceph-common | |
118 | 118 | ||
119 | 119 | ```bash | |
120 | 120 | apt install -y ceph-common |
anduin revised this gist . Go to revision
1 file changed, 3 insertions, 1 deletion
notes.md
@@ -9,7 +9,9 @@ | |||
9 | 9 | ||
10 | 10 | 三个 node 全部都插一块 **新的** 大硬盘。假如是 `/dev/sdb` 。 | |
11 | 11 | ||
12 | - | 三个 node 最好是物理服务器,ceph 喜欢摸到真实的硬盘。(当然你非要用虚拟机也没什么问题,但是你都建设好虚拟机的存储系统了,为什么还需要 ceph ???) | |
12 | + | 三个 node 最好是物理服务器,ceph 喜欢摸到真实的硬盘。 | |
13 | + | ||
14 | + | > 当然你非要用虚拟机也没什么问题,但是你都建设好虚拟机的存储系统了,为什么还需要 ceph ??? | |
13 | 15 | ||
14 | 16 | 三个 node 之间没有防火墙,网是通的。 | |
15 | 17 |
anduin revised this gist . Go to revision
1 file changed, 1 insertion, 1 deletion
notes.md
@@ -9,7 +9,7 @@ | |||
9 | 9 | ||
10 | 10 | 三个 node 全部都插一块 **新的** 大硬盘。假如是 `/dev/sdb` 。 | |
11 | 11 | ||
12 | - | 三个 node 最好是物理服务器,ceph 喜欢摸到真实的硬盘。 | |
12 | + | 三个 node 最好是物理服务器,ceph 喜欢摸到真实的硬盘。(当然你非要用虚拟机也没什么问题,但是你都建设好虚拟机的存储系统了,为什么还需要 ceph ???) | |
13 | 13 | ||
14 | 14 | 三个 node 之间没有防火墙,网是通的。 | |
15 | 15 |
anduin revised this gist . Go to revision
1 file changed, 5 insertions, 4 deletions
notes.md
@@ -13,14 +13,14 @@ | |||
13 | 13 | ||
14 | 14 | 三个 node 之间没有防火墙,网是通的。 | |
15 | 15 | ||
16 | - | 三个 node 你都需要使用 root 用户来执行命令。 | |
16 | + | 三个 node 你都需要使用 root 用户来执行命令。`sudo su` | |
17 | 17 | ||
18 | 18 | > 虽然在 root 用户下面敲命令不是 Linux 的正确用法,但是 ceph 不喜欢非 root 用户。我承认这是它设计的不好。 | |
19 | 19 | ||
20 | 20 | ## 开启root ssh | |
21 | 21 | ||
22 | 22 | ```bash | |
23 | - | sudo vim /etc/ssh/sshd_config | |
23 | + | vim /etc/ssh/sshd_config | |
24 | 24 | ``` | |
25 | 25 | ||
26 | 26 | 将里面的 `PermitRootLogin` 改成 `yes`,将 `PasswordAuthentication` 改成 `yes` | |
@@ -28,13 +28,12 @@ sudo vim /etc/ssh/sshd_config | |||
28 | 28 | 是的,这非常不优雅。ceph 喜欢用 root ssh 到各个 node 上一顿跑命令。但是它就是这么设计的。 | |
29 | 29 | ||
30 | 30 | ```bash | |
31 | - | sudo systemctl restart ssh sshd | |
31 | + | systemctl restart ssh sshd | |
32 | 32 | ``` | |
33 | 33 | ||
34 | 34 | ## 改好密码 | |
35 | 35 | ||
36 | 36 | ```bash | |
37 | - | sudo su | |
38 | 37 | passwd | |
39 | 38 | ``` | |
40 | 39 | ||
@@ -64,6 +63,8 @@ rm -rvf /swarm-vol | |||
64 | 63 | rm -rvf /var/no-direct-write-here/gluster-bricks | |
65 | 64 | ``` | |
66 | 65 | ||
66 | + | 当然,如果你是新服务器,新盘,那没有这码子事儿。直接继续就行了。 | |
67 | + | ||
67 | 68 | ## 清空老盘 | |
68 | 69 | ||
69 | 70 | 将老盘彻底抹除。抹除前记得备份。 |
anduin revised this gist . Go to revision
1 file changed, 3 insertions, 1 deletion
notes.md
@@ -13,7 +13,9 @@ | |||
13 | 13 | ||
14 | 14 | 三个 node 之间没有防火墙,网是通的。 | |
15 | 15 | ||
16 | - | 三个 node 你都需要使用 root 用户来执行命令。ceph 不喜欢非 root 用户。我承认这是它设计的不好。 | |
16 | + | 三个 node 你都需要使用 root 用户来执行命令。 | |
17 | + | ||
18 | + | > 虽然在 root 用户下面敲命令不是 Linux 的正确用法,但是 ceph 不喜欢非 root 用户。我承认这是它设计的不好。 | |
17 | 19 | ||
18 | 20 | ## 开启root ssh | |
19 | 21 |
anduin revised this gist . Go to revision
1 file changed, 2 insertions
notes.md
@@ -13,6 +13,8 @@ | |||
13 | 13 | ||
14 | 14 | 三个 node 之间没有防火墙,网是通的。 | |
15 | 15 | ||
16 | + | 三个 node 你都需要使用 root 用户来执行命令。ceph 不喜欢非 root 用户。我承认这是它设计的不好。 | |
17 | + | ||
16 | 18 | ## 开启root ssh | |
17 | 19 | ||
18 | 20 | ```bash |
anduin revised this gist . Go to revision
No changes
anduin revised this gist . Go to revision
1 file changed, 7 insertions, 1 deletion
notes.md
@@ -1,5 +1,7 @@ | |||
1 | 1 | ||
2 | - | 这里将在 3 台 node 上安装 ceph。三台 node 的 hostname 分别是: | |
2 | + | 这里将在 3 台 node 上安装 ceph。 | |
3 | + | ||
4 | + | 三台 node 的 hostname 分别是: | |
3 | 5 | ||
4 | 6 | * node1 | |
5 | 7 | * node2 | |
@@ -7,6 +9,10 @@ | |||
7 | 9 | ||
8 | 10 | 三个 node 全部都插一块 **新的** 大硬盘。假如是 `/dev/sdb` 。 | |
9 | 11 | ||
12 | + | 三个 node 最好是物理服务器,ceph 喜欢摸到真实的硬盘。 | |
13 | + | ||
14 | + | 三个 node 之间没有防火墙,网是通的。 | |
15 | + | ||
10 | 16 | ## 开启root ssh | |
11 | 17 | ||
12 | 18 | ```bash |
anduin revised this gist . Go to revision
1 file changed, 1 insertion, 1 deletion
notes.md
@@ -85,7 +85,7 @@ rm get-docker.sh | |||
85 | 85 | curl --silent --remote-name --location https://github.com/ceph/ceph/raw/octopus/src/cephadm/cephadm | |
86 | 86 | chmod +x cephadm | |
87 | 87 | mkdir -p /etc/ceph | |
88 | - | ./cephadm bootstrap --mon-ip $MYIP | |
88 | + | ./cephadm bootstrap --mon-ip $MYIP # MYIP 是你的内网 IP 地址。 | |
89 | 89 | ``` | |
90 | 90 | ||
91 | 91 | 等90秒,别忘了复制输出的内容。 |