Skip to content
Snippets Groups Projects
Commit d7e13b73 authored by Jérôme Charaoui's avatar Jérôme Charaoui :telescope:
Browse files

howto/ganeti: update iSCSI instance creation (team#40734)

parent 1c508ad6
No related branches found
No related tags found
No related merge requests found
...@@ -164,12 +164,12 @@ initiator properly setup](howto/new-machine-cymru#iscsi-initiator-setup), and th ...@@ -164,12 +164,12 @@ initiator properly setup](howto/new-machine-cymru#iscsi-initiator-setup), and th
setup](howto/new-machine-cymru#san-management-tools-setup). It also assumes you are familiar with the `SMcli` tool, see setup](howto/new-machine-cymru#san-management-tools-setup). It also assumes you are familiar with the `SMcli` tool, see
the [storage servers documentation](howto/new-machine-cymru#storage-servers) for an introduction on that. the [storage servers documentation](howto/new-machine-cymru#storage-servers) for an introduction on that.
This assumes you are creating a 500GB VM, partitioned on the Linux 0. review the current storage allocation configuration
host, *not* on the iSCSI volume. TODO: change those instructions to
create one volume per partition, so that those can be resized more
easily. The following is how `tb-build-03` was setup.
1. create the disk on the SAN and assign it to the host group: /usr/local/sbin/tpo-show-san-disks
1. create a dedicated disk group and virtual disk on the SAN and assign it to
the host group:
puppet agent --disable "creating a SAN disk" puppet agent --disable "creating a SAN disk"
$EDITOR /usr/local/sbin/tpo-create-san-disks $EDITOR /usr/local/sbin/tpo-create-san-disks
...@@ -193,13 +193,13 @@ easily. The following is how `tb-build-03` was setup. ...@@ -193,13 +193,13 @@ easily. The following is how `tb-build-03` was setup.
} }
3. propagate the magic to all nodes in the cluster: 3. propagate the magic to all nodes in the cluster:
gnt-cluster command "puppet agent -t ; iscsiadm -m node --rescan ; multipath -r" gnt-cluster command "puppet agent -t ; iscsiadm -m node --rescan ; multipath -r"
4. confirm that multipath works, it should look something like this": 4. confirm that multipath works, it should look something like this":
root@chi-node-01:~# multipath -ll root@chi-node-01:~# multipath -ll
web-chi-03-srv (36782bcb00063c6a500000d67603f7abf) dm-20 DELL,MD32xxi test-01 (36782bcb00063c6a500000d67603f7abf) dm-20 DELL,MD32xxi
size=500G features='5 queue_if_no_path pg_init_retries 50 queue_mode mq' hwhandler='1 rdac' wp=rw size=500G features='5 queue_if_no_path pg_init_retries 50 queue_mode mq' hwhandler='1 rdac' wp=rw
|-+- policy='round-robin 0' prio=6 status=active |-+- policy='round-robin 0' prio=6 status=active
| |- 11:0:0:4 sdi 8:128 active ready running | |- 11:0:0:4 sdi 8:128 active ready running
...@@ -211,7 +211,7 @@ easily. The following is how `tb-build-03` was setup. ...@@ -211,7 +211,7 @@ easily. The following is how `tb-build-03` was setup.
`- 8:0:0:4 sdm 8:192 active ghost running `- 8:0:0:4 sdm 8:192 active ghost running
root@chi-node-01:~# root@chi-node-01:~#
and the device `/dev/mapper/web-chi-03` should exist. and the device `/dev/mapper/test-01` should exist.
6. adopt the disks in Ganeti: 6. adopt the disks in Ganeti:
...@@ -222,28 +222,28 @@ easily. The following is how `tb-build-03` was setup. ...@@ -222,28 +222,28 @@ easily. The following is how `tb-build-03` was setup.
--net 0:ip=pool,network=gnt-chi-01 \ --net 0:ip=pool,network=gnt-chi-01 \
--no-ip-check \ --no-ip-check \
--no-name-check \ --no-name-check \
--disk 0:adopt=/dev/disk/by-id/dm-name-tb-build-03-root \ --disk 0:adopt=/dev/disk/by-id/dm-name-web-chi-03 \
--disk 1:adopt=/dev/disk/by-id/dm-name-tb-build-03-swap,name=swap \ --backend-parameters memory=8g,vcpus=2 \
--disk 2:adopt=/dev/disk/by-id/dm-name-tb-build-03-srv \ test-01.torproject.org
--backend-parameters memory=16g,vcpus=8 \
tb-build-03.torproject.org
NOTE: the actual node must be manually picked because the `hail` NOTE: the actual node must be manually picked because the `hail`
allocator doesn't seem to know about block devices. allocator doesn't seem to know about block devices.
NOTE: mixing DRBD and iSCSI volumes on a single instance is not supported.
7. at this point, the VM probably doesn't boot, because for some 7. at this point, the VM probably doesn't boot, because for some
reason the `gnt-instance-debootstrap` doesn't fire when disks are reason the `gnt-instance-debootstrap` doesn't fire when disks are
adopted. so you need to reinstall the machine, which involves adopted. so you need to reinstall the machine, which involves
stopping it first: stopping it first:
gnt-instance shutdown --timeout=0 tb-build-03 gnt-instance shutdown --timeout=0 test-01
gnt-instance reinstall tb-build-03 gnt-instance reinstall test-01
HACK: the current installer fails on weird partionning errors, see HACK: the current installer fails on weird partionning errors, see
[upstream bug 13](https://github.com/ganeti/instance-debootstrap/issues/13). We applied [patch 14](https://github.com/ganeti/instance-debootstrap/pull/14) on `chi-node-04` [upstream bug 13](https://github.com/ganeti/instance-debootstrap/issues/13).
and sent it upstream for review before committing to maintaining We applied [patch 17](https://github.com/ganeti/instance-debootstrap/pull/17)
this in Debian or elsewhere. It should be tested on other installs on `chi-node-01` and sent it upstream for review before committing to
beforehand as well. maintaining this in Debian or elsewhere.
From here on, follow the [next steps](#next-steps) above. From here on, follow the [next steps](#next-steps) above.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment