On Github carmstrong / ceph-days-sf-deis-2015
Chris Armstrong / @carmstrong_afk
FROM ubuntu:14.04 ENV DEBIAN_FRONTEND noninteractive RUN apt-get update && apt-get install -yq curl RUN curl -sSL 'https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc' | apt-key add - RUN echo "deb http://ceph.com/debian-firefly trusty main" > /etc/apt/sources.list.d/ceph.list RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get install -yq ceph
deis-store-daemon.service ab45ad38.../172.17.8.101 loaded active running deis-store-daemon.service b1dfc947.../172.17.8.100 loaded active running deis-store-daemon.service e5ef099b.../172.17.8.102 loaded active running deis-store-gateway.service ab45ad38.../172.17.8.101 loaded active running deis-store-metadata.service ab45ad38.../172.17.8.101 loaded active running deis-store-metadata.service b1dfc947.../172.17.8.100 loaded active running deis-store-metadata.service e5ef099b.../172.17.8.102 loaded active running deis-store-monitor.service ab45ad38.../172.17.8.101 loaded active running deis-store-monitor.service b1dfc947.../172.17.8.100 loaded active running deis-store-monitor.service e5ef099b.../172.17.8.102 loaded active running deis-store-volume.service ab45ad38.../172.17.8.101 loaded active running deis-store-volume.service b1dfc947.../172.17.8.100 loaded active running deis-store-volume.service e5ef099b.../172.17.8.102 loaded active running
etcd_set_default size ${NUM_STORES} etcd_set_default minSize 1 etcd_set_default pgNum ${PG_NUM} etcd_set_default delayStart 15 ceph-authtool /etc/ceph/ceph.client.admin.keyring --create-keyring --gen-key -n client.admin --set-uid=0 --cap mon 'allow *' --cap osd 'allow *' --cap mds 'allow' ceph-authtool /etc/ceph/ceph.mon.keyring --create-keyring --gen-key -n mon. --cap mon 'allow *' fsid=$(uuidgen) monmaptool --create --add ${HOSTNAME} ${HOST} --fsid ${fsid} /etc/ceph/monmap etcdctl --no-sync -C $ETCD set ${ETCD_PATH}/fsid ${fsid} >/dev/null etcdctl --no-sync -C $ETCD set ${ETCD_PATH}/monKeyring < /etc/ceph/ceph.mon.keyring >/dev/null etcdctl --no-sync -C $ETCD set ${ETCD_PATH}/adminKeyring < /etc/ceph/ceph.client.admin.keyring >/dev/null echo "store-monitor: setup complete."
[global] fsid = {{ .deis_store_fsid }} mon initial members = {{ .deis_store_monSetupLock }} mon host = {{ range $index, $mon := .deis_store_hosts }}{{ if $index }}, {{ end }}{{ $mon.Value }}{{ end }} mon addr = {{ range $index, $mon := .deis_store_hosts }}{{ if $index }}, {{ end }}{{ Base $mon.Key }}:6789{{ end }} auth cluster required = cephx auth service required = cephx auth client required = cephx osd pool default size = {{ .deis_store_size }} osd pool default min_size = {{ .deis_store_minSize }} osd pool default pg_num = {{ .deis_store_pgNum }} osd pool default pgp_num = {{ .deis_store_pgNum }} osd recovery delay start = {{ .deis_store_delayStart }} log file = /dev/stdout
$ docker exec -it deis-store-daemon bash root@c4b655efa6d3:/#
$ docker run \ --name deis-store-daemon \ --volumes-from=deis-store-daemon-data \ --rm \ --net host \ deis/store-daemon:v1.4.1
etcdctl set /deis/store/hosts/$COREOS_PRIVATE_IPV4 `hostname`
{{ range $key := .deis_store_hosts }}{{ Base $key.Key }} {{ $key.Value }} {{ end }}
mount: enabling WRITEAHEAD journal mode: checkpoint is not enabled
$ docker run --privileged deis/store-daemon
mount: enabling PARALLEL journal mode: fs, checkpoint is enabled
$ etcdctl get /deis/store/osds/172.17.8.100 2 $ nse deis-store-admin # ceph osd out 2 marked out osd.2. $ docker stop deis-store-daemon $ nse deis-store-admin # ceph osd crush remove osd.2 removed item id 2 name 'osd.2' from crush map # ceph auth del osd.2 updated # ceph osd rm 2 removed osd.2 $ etcdctl rm /deis/store/osds/172.17.8.100 $ etcdctl rm /deis/store/hosts/172.17.8.100 $ docker stop deis-store-monitor $ nse deis-store-admin # ceph mon remove deis-1
* We're hiring!