initial notes with nebula networking
commit
c5f13934fe
@ -0,0 +1,41 @@
|
||||
#!/bin/bash
|
||||
|
||||
#mon
|
||||
docker run -d --rm --net=host -v /ceph/mon/etc/ceph:/etc/ceph -v /ceph/mon/var/lib/ceph:/var/lib/ceph -e MON_IP=10.13.37.2 -e CEPH_PUBLIC_NETWORK=10.13.37.0/22 -e CEPH_CLUSTER_NETWORK=10.13.37.0/22 --name ceph_mon docker.io/ceph/daemon:latest-nautilus mon
|
||||
|
||||
|
||||
#mgr
|
||||
mkdir -p /ceph/mgr/etc/ceph/
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/mon/etc/ceph/ceph.client.admin.keyring /ceph/mgr/etc/ceph/
|
||||
docker run -d --rm --net=host -v /ceph/mgr/etc/ceph:/etc/ceph -v /ceph/mgr/var/lib/ceph:/var/lib/ceph --name ceph_mgr docker.io/ceph/daemon:latest-nautilus mgr
|
||||
|
||||
|
||||
#osd
|
||||
mkdir -p /ceph/osd_sdb/etc/ceph/ /ceph/osd_sdb/var/lib/ceph/bootstrap-osd /ceph/osd_sdb/var/lib/ceph/osd
|
||||
(docker exec ceph_mon ceph auth get client.bootstrap-osd) > /ceph/osd_sdb/var/lib/ceph/bootstrap-osd/ceph.keyring
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/osd_sdb/etc/ceph/
|
||||
docker run --rm --net=host --privileged -v /ceph/osd_sdb/etc/ceph:/etc/ceph -v /ceph/osd_sdb/var/lib/ceph:/var/lib/ceph -v /dev:/dev --entrypoint ceph-volume docker.io/ceph/daemon:latest-nautilus lvm prepare --bluestore --dmcrypt --data /dev/sdb
|
||||
|
||||
mkdir -p /ceph/osd_sdc/etc/ceph/ /ceph/osd_sdc/var/lib/ceph/bootstrap-osd /ceph/osd_sdc/var/lib/ceph/osd
|
||||
(docker exec ceph_mon ceph auth get client.bootstrap-osd) > /ceph/osd_sdc/var/lib/ceph/bootstrap-osd/ceph.keyring
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/osd_sdc/etc/ceph/
|
||||
docker run --rm --net=host --privileged -v /ceph/osd_sdc/etc/ceph:/etc/ceph -v /ceph/osd_sdc/var/lib/ceph:/var/lib/ceph -v /dev:/dev --entrypoint ceph-volume docker.io/ceph/daemon:latest-nautilus lvm prepare --bluestore --dmcrypt --data /dev/sdc
|
||||
|
||||
docker run -d --rm --net=host --privileged -v /ceph/osd_sdb/etc/ceph:/etc/ceph -v /ceph/osd_sdb/var/lib/ceph:/var/lib/ceph -v /dev:/dev -e OSD_ID=0 --name osd_sdb docker.io/ceph/daemon:latest-nautilus osd_ceph_volume_activate
|
||||
docker run -d --rm --net=host --privileged -v /ceph/osd_sdc/etc/ceph:/etc/ceph -v /ceph/osd_sdc/var/lib/ceph:/var/lib/ceph -v /dev:/dev -e OSD_ID=1 --name osd_sdc docker.io/ceph/daemon:latest-nautilus osd_ceph_volume_activate
|
||||
|
||||
|
||||
#mds
|
||||
mkdir -p /ceph/osd_sdb/etc/ceph/ /ceph/osd_sdb/var/lib/ceph/bootstrap-mds
|
||||
(docker exec ceph_mon ceph auth get client.bootstrap-mds) > /ceph/mds/var/lib/ceph/bootstrap-mds/ceph.keyring
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/mon/etc/ceph/ceph.client.admin.keyring /ceph/mds/etc/ceph/
|
||||
docker run -d --rm --net=host -v /ceph/mds/etc/ceph:/etc/ceph -v /ceph/mds/var/lib/ceph:/var/lib/ceph -e CEPHFS_CREATE=1 --name ceph_mds docker.io/ceph/daemon:latest-nautilus mds
|
||||
|
||||
#set cephfs autoscaling
|
||||
docker exec ceph_mon ceph mgr module enable pg_autoscaler
|
||||
docker exec ceph_mon ceph osd pool set cephfs_data pg_autoscale_mode on
|
||||
docker exec ceph_mon ceph osd pool set cephfs_metadata pg_autoscale_mode on
|
||||
|
||||
|
||||
#status
|
||||
docker exec ceph_mon ceph status
|
@ -0,0 +1,38 @@
|
||||
#!/bin/bash
|
||||
|
||||
|
||||
#mon
|
||||
#copy ceph.conf,ceph.client.admin.keyring,ceph.mon.keyring manually to /ceph/mon/etc/ceph
|
||||
docker run -d --rm --net=host -v /ceph/mon/etc/ceph:/etc/ceph -v /ceph/mon/var/lib/ceph:/var/lib/ceph -e MON_IP=10.13.37.3 -e CEPH_PUBLIC_NETWORK=10.13.37.0/22 -e CEPH_CLUSTER_NETWORK=10.13.37.0/22 --name ceph_mon docker.io/ceph/daemon:latest-nautilus mon
|
||||
|
||||
|
||||
#mgr
|
||||
mkdir -p /ceph/mgr/etc/ceph/
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/mon/etc/ceph/ceph.client.admin.keyring /ceph/mgr/etc/ceph/
|
||||
docker run -d --rm --net=host -v /ceph/mgr/etc/ceph:/etc/ceph -v /ceph/mgr/var/lib/ceph:/var/lib/ceph --name ceph_mgr docker.io/ceph/daemon:latest-nautilus mgr
|
||||
|
||||
|
||||
#osd
|
||||
mkdir -p /ceph/osd_sdb/etc/ceph/ /ceph/osd_sdb/var/lib/ceph/bootstrap-osd /ceph/osd_sdb/var/lib/ceph/osd
|
||||
(docker exec ceph_mon ceph auth get client.bootstrap-osd) > /ceph/osd_sdb/var/lib/ceph/bootstrap-osd/ceph.keyring
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/osd_sdb/etc/ceph/
|
||||
docker run --rm --net=host --privileged -v /ceph/osd_sdb/etc/ceph:/etc/ceph -v /ceph/osd_sdb/var/lib/ceph:/var/lib/ceph -v /dev:/dev --entrypoint ceph-volume docker.io/ceph/daemon:latest-nautilus lvm prepare --bluestore --dmcrypt --data /dev/sdb
|
||||
|
||||
mkdir -p /ceph/osd_sdc/etc/ceph/ /ceph/osd_sdc/var/lib/ceph/bootstrap-osd /ceph/osd_sdc/var/lib/ceph/osd
|
||||
(docker exec ceph_mon ceph auth get client.bootstrap-osd) > /ceph/osd_sdc/var/lib/ceph/bootstrap-osd/ceph.keyring
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/osd_sdc/etc/ceph/
|
||||
docker run --rm --net=host --privileged -v /ceph/osd_sdc/etc/ceph:/etc/ceph -v /ceph/osd_sdc/var/lib/ceph:/var/lib/ceph -v /dev:/dev --entrypoint ceph-volume docker.io/ceph/daemon:latest-nautilus lvm prepare --bluestore --dmcrypt --data /dev/sdc
|
||||
|
||||
docker run -d --rm --net=host --privileged -v /ceph/osd04/etc/ceph:/etc/ceph -v /ceph/osd04/var/lib/ceph:/var/lib/ceph -v /dev:/dev -e OSD_ID=4 --name osd04 docker.io/ceph/daemon:latest-nautilus osd_ceph_volume_activate
|
||||
docker run -d --rm --net=host --privileged -v /ceph/osd05/etc/ceph:/etc/ceph -v /ceph/osd05/var/lib/ceph:/var/lib/ceph -v /dev:/dev -e OSD_ID=5 --name osd05 docker.io/ceph/daemon:latest-nautilus osd_ceph_volume_activate
|
||||
|
||||
|
||||
#mds
|
||||
mkdir -p /ceph/mds/etc/ceph/ /ceph/mds/var/lib/ceph/bootstrap-mds
|
||||
(docker exec ceph_mon ceph auth get client.bootstrap-mds) > /ceph/mds/var/lib/ceph/bootstrap-mds/ceph.keyring
|
||||
cp -a /ceph/mon/etc/ceph/ceph.conf /ceph/mon/etc/ceph/ceph.client.admin.keyring /ceph/mds/etc/ceph/
|
||||
docker run -d --rm --net=host -v /ceph/mds/etc/ceph:/etc/ceph -v /ceph/mds/var/lib/ceph:/var/lib/ceph -e CEPHFS_CREATE=1 --name ceph_mds docker.io/ceph/daemon:latest-nautilus mds
|
||||
|
||||
|
||||
#status
|
||||
docker exec ceph_mon ceph status
|
Reference in New Issue