├── .gitignore ├── shared ├── bin │ ├── stop-ceph.sh │ ├── setup-nfs.sh │ ├── reload-cephadm.sh │ ├── reload-dashboard.sh │ ├── npm-start.sh │ ├── make-frontend.sh │ ├── setup-proxy.sh │ ├── build-frontend.sh │ ├── setup-modules.sh │ ├── fetch-pr.sh │ ├── start-ceph.sh │ ├── setup-ceph.sh │ ├── mimic │ │ └── setup-ceph.sh │ ├── create-dashboard-rgw-user.sh │ ├── nautilus │ │ └── setup-ceph.sh │ └── setup-cephadm.sh ├── docker │ ├── install-chrome.sh │ └── install-omz.sh └── zsh │ ├── binds.plugin.zsh │ ├── dash.plugin.zsh │ └── .zshrc ├── prometheus ├── rules │ ├── README.md │ └── alert.rules └── prometheus.yml ├── grafana ├── ceph-dashboards.yaml ├── datasource.yaml ├── grafana_ssl_cert.crt ├── grafana_ssl_cert.key └── grafana.ini ├── alertmanager └── config.yml ├── shibboleth ├── files │ ├── start.sh │ ├── metadata-providers.xml │ ├── ldap.properties │ ├── shibboleth2.xml │ └── jetty-ssl-context.xml └── Dockerfile ├── haproxy └── haproxy.cfg ├── Dashboards ├── README.md ├── cephfs-overview.json ├── pool-detail.json ├── radosgw-detail.json ├── radosgw-overview.json ├── osd-device-details.json ├── pool-overview.json └── osds-overview.json ├── mimic.Dockerfile ├── pacific.Dockerfile ├── setup.sh ├── nautilus.Dockerfile ├── Dockerfile ├── octopus.Dockerfile ├── docker-compose.yml └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | .idea/ 2 | -------------------------------------------------------------------------------- /shared/bin/stop-ceph.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph/build 6 | ../src/stop.sh 7 | -------------------------------------------------------------------------------- /shared/bin/setup-nfs.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | zypper -n install nfs-ganesha nfs-ganesha-ceph nfs-ganesha-rados-grace nfs-ganesha-rados-urls 6 | -------------------------------------------------------------------------------- /shared/bin/reload-cephadm.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph/build 6 | ./bin/ceph mgr module disable cephadm 7 | sleep 5 8 | ./bin/ceph mgr module enable cephadm 9 | -------------------------------------------------------------------------------- /prometheus/rules/README.md: -------------------------------------------------------------------------------- 1 | To temporary test additional alerts simply drop in the file here and start/restart the container to get them applied. Note, the files must be named *.(rules|yml). 2 | -------------------------------------------------------------------------------- /shared/docker/install-chrome.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | wget https://dl.google.com/linux/linux_signing_key.pub 4 | rpm --import linux_signing_key.pub 5 | zypper ar http://dl.google.com/linux/chrome/rpm/stable/x86_64 google 6 | zypper -n in google-chrome-stable -------------------------------------------------------------------------------- /shared/bin/reload-dashboard.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | find /ceph/build/out/ -name "mgr.*.log" -type f -delete 6 | 7 | cd /ceph/build 8 | ./bin/ceph mgr module disable dashboard 9 | sleep 5 10 | ./bin/ceph mgr module enable dashboard 11 | -------------------------------------------------------------------------------- /shared/bin/npm-start.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | setup-proxy.sh 6 | 7 | cd /ceph/src/pybind/mgr/dashboard/frontend 8 | source /ceph/build/src/pybind/mgr/dashboard/node-env/bin/activate 9 | npm ci --unsafe-perm 10 | 11 | npm start -- --disableHostCheck=true 12 | -------------------------------------------------------------------------------- /shared/bin/make-frontend.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph/build/src/pybind/mgr/dashboard 6 | rm -rf node-env 7 | 8 | cd /ceph/src/pybind/mgr/dashboard/frontend 9 | rm -rf dist 10 | rm -rf node_modules 11 | 12 | cd /ceph/build 13 | make mgr-dashboard-frontend-build 14 | -------------------------------------------------------------------------------- /shared/bin/setup-proxy.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph/build 6 | url=`./bin/ceph mgr services | jq .dashboard` 7 | 8 | cd /ceph/src/pybind/mgr/dashboard/frontend 9 | jq '.["/api/"].target'=$url proxy.conf.json.sample | jq '.["/ui-api/"].target'=$url > proxy.conf.json 10 | -------------------------------------------------------------------------------- /grafana/ceph-dashboards.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: 1 2 | 3 | providers: 4 | - name: 'ceph-dashboards' 5 | orgId: 1 6 | folder: '' 7 | type: file 8 | disableDeletion: false 9 | updateIntervalSeconds: 10 #how often Grafana will scan for changed dashboards 10 | options: 11 | path: /var/lib/grafana/dashboards -------------------------------------------------------------------------------- /alertmanager/config.yml: -------------------------------------------------------------------------------- 1 | route: 2 | receiver: 'ceph-dashboard' 3 | group_wait: 1m 4 | group_interval: 1m 5 | repeat_interval: 1m 6 | 7 | receivers: 8 | - name: 'ceph-dashboard' 9 | webhook_configs: 10 | - url: 'http://localhost:4200/api/prometheus_receiver' 11 | - url: 'http://localhost:9099/' 12 | -------------------------------------------------------------------------------- /shared/bin/build-frontend.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph/src/pybind/mgr/dashboard/frontend 6 | source /ceph/build/src/pybind/mgr/dashboard/node-env/bin/activate 7 | npm ci 8 | 9 | npm run build:en-US 10 | 11 | cd /ceph/build 12 | bin/ceph mgr services 13 | 14 | bin/ceph mgr services | jq .dashboard 15 | -------------------------------------------------------------------------------- /shared/bin/setup-modules.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph/build 6 | 7 | bin/ceph dashboard set-grafana-api-url 'http://localhost:3000' 8 | 9 | bin/ceph mgr module enable prometheus 10 | bin/ceph dashboard set-prometheus-api-host 'http://localhost:9090' 11 | bin/ceph dashboard set-alertmanager-api-host 'http://localhost:9093' -------------------------------------------------------------------------------- /shared/bin/fetch-pr.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | ## 4 | # This will fetch, and optionally checkout, a PR from Ceph's github. 5 | # fetch-pr.sh 1234 -c 6 | # the above command will fetch PR #1234 and checkout it. 7 | ## 8 | 9 | set -e 10 | 11 | pr=$1 12 | 13 | cd /ceph 14 | git fetch https://github.com/ceph/ceph.git pull/$pr/head:pr/$pr -f 15 | 16 | case "$2" in 17 | --checkout|-c) git checkout pr/$pr ;; 18 | esac 19 | -------------------------------------------------------------------------------- /shared/docker/install-omz.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | sh -c "$(wget https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O -)" 4 | # sym link for .zshrc 5 | rm /root/.zshrc 6 | ln -s /shared/zsh/.zshrc /root/.zshrc 7 | # sym link for dash.plugin.zsh 8 | mkdir ~/.oh-my-zsh/custom/plugins/dash 9 | ln -s /shared/zsh/dash.plugin.zsh ~/.oh-my-zsh/custom/plugins/dash/dash.plugin.zsh 10 | # sym link for binds.plugin.zsh 11 | mkdir ~/.oh-my-zsh/custom/plugins/binds 12 | ln -s /shared/zsh/binds.plugin.zsh ~/.oh-my-zsh/custom/plugins/binds/binds.plugin.zsh -------------------------------------------------------------------------------- /shared/zsh/binds.plugin.zsh: -------------------------------------------------------------------------------- 1 | #compdef binds 2 | #autoload 3 | 4 | npm () { 5 | DIR=$(pwd) 6 | source /ceph/build/src/pybind/mgr/dashboard/node-env/bin/activate . 7 | cd /ceph/src/pybind/mgr/dashboard/frontend 8 | command npm $@ 9 | deactivate 10 | cd $DIR 11 | } 12 | 13 | npx () { 14 | DIR=$(pwd) 15 | source /ceph/build/src/pybind/mgr/dashboard/node-env/bin/activate . 16 | cd /ceph/src/pybind/mgr/dashboard/frontend 17 | command npx $@ 18 | deactivate 19 | cd $DIR 20 | } 21 | 22 | ceph () { 23 | DIR=$(pwd) 24 | cd /ceph/build 25 | bin/ceph $@ 26 | cd $DIR 27 | } 28 | -------------------------------------------------------------------------------- /shibboleth/files/start.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # LDAP configuration 4 | echo "Waiting for LDAP server" 5 | /wait-for-it.sh openldap:636 --strict 6 | 7 | echo "LDAP server is ready" 8 | 9 | echo -n | openssl s_client -connect openldap:636 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > /opt/shibboleth-idp/credentials/ldap-server.crt 10 | LDAPHOST=`echo -n | openssl s_client -connect openldap:636 | grep 'CN = ' | head -1 | sed -e 's/.*CN = \(.*\)/\1/'` 11 | sed -i -e "s/#LDAPHOST#/$LDAPHOST/g" /opt/shibboleth-idp/conf/ldap.properties 12 | 13 | httpd 14 | shibd -f 15 | $JETTY_HOME/bin/jetty.sh start 16 | tail -f /opt/shibboleth-idp/logs/idp-process.log 17 | -------------------------------------------------------------------------------- /prometheus/prometheus.yml: -------------------------------------------------------------------------------- 1 | global: 2 | scrape_interval: 5s 3 | 4 | scrape_configs: 5 | - job_name: 'prometheus' 6 | static_configs: 7 | - targets: ['localhost:9090'] 8 | - job_name: 'ceph' 9 | static_configs: 10 | - targets: ['localhost:9283'] 11 | - job_name: 'node-exporter' 12 | static_configs: 13 | - targets: ['localhost:9100'] 14 | - job_name: 'prometheus-webhook-snmp' 15 | scrape_interval: 30s 16 | static_configs: 17 | - targets: ['localhost:9099'] 18 | 19 | alerting: 20 | alertmanagers: 21 | - scheme: http 22 | static_configs: 23 | - targets: 24 | - 'localhost:9093' 25 | 26 | rule_files: 27 | - 'rules/*.rules' 28 | - 'rules/*.yml' 29 | -------------------------------------------------------------------------------- /shared/bin/start-ceph.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | find /ceph/build/ -name "mgr.*.log" -type f -delete 6 | 7 | if rpm --quiet --query nfs-ganesha-ceph; then 8 | CEPH_VERSION=$(head -n1 /ceph/src/ceph_release) 9 | if [ $CEPH_VERSION -ge 15 ]; then 10 | export NFS=1 11 | fi 12 | fi 13 | 14 | cd /ceph/build 15 | RGW=1 ../src/vstart.sh -d -n -x 16 | 17 | chmod +r /ceph/build/keyring 18 | 19 | if ./bin/ceph config ls | grep -q mgr/dashboard/log_level; then 20 | ./bin/ceph config set mgr mgr/dashboard/log_level debug 21 | ./bin/ceph config set mgr mgr/dashboard/log_to_file true 22 | ./bin/ceph config set mgr mgr/dashboard/debug true 23 | fi 24 | 25 | setup-proxy.sh 26 | create-dashboard-rgw-user.sh 27 | -------------------------------------------------------------------------------- /shared/zsh/dash.plugin.zsh: -------------------------------------------------------------------------------- 1 | #compdef dash 2 | #autoload 3 | 4 | dash () { 5 | $1.sh 6 | } 7 | 8 | _dash() { 9 | local -a commands 10 | 11 | commands=( 12 | 'build-frontend:Installs npm packages and builds the frontend.' 13 | 'make-frontend:Removes all dashboard generated files and rebuilds it' 14 | 'npm-start:Installs npm packages and starts angular dev server.' 15 | 'reload-dashboard:Disable and enable the mgr module.' 16 | 'setup-ceph:Installs deps and compiles ceph.' 17 | 'setup-proxy:Updates "proxy.conf.json" with the current dashboard url.' 18 | 'start-ceph:Starts a vstart cluster with RGW enabled.' 19 | 'stop-ceph:Stops the vstart cluster.' 20 | 'stop-ceph:Stops the vstart cluster.' 21 | ) 22 | 23 | _describe -t commands 'dash command' commands && ret=0 24 | } 25 | 26 | compdef _dash dash 27 | 28 | -------------------------------------------------------------------------------- /shared/bin/setup-ceph.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | cd /ceph 6 | find . -name \*.pyc -delete 7 | ./install-deps.sh 8 | 9 | ARGS="-DENABLE_GIT_VERSION=OFF -DWITH_TESTS=ON -DWITH_CCACHE=ON $ARGS" 10 | ARGS="-DWITH_PYTHON3=3 -DWITH_RADOSGW_AMQP_ENDPOINT=OFF -DWITH_RADOSGW_KAFKA_ENDPOINT=OFF $ARGS" 11 | 12 | NPROC=${NPROC:-$(nproc --ignore=2)} 13 | 14 | # SSO dependencies 15 | zypper -n install libxmlsec1-1 libxmlsec1-nss1 libxmlsec1-openssl1 xmlsec1-devel xmlsec1-openssl-devel 16 | pip install python3-saml 17 | 18 | if [ "$CLEAN" == "true" ]; then 19 | echo "CLEAN INSTALL" 20 | git clean -fdx 21 | fi 22 | 23 | if [ -d "build" ]; then 24 | git submodule update --init --recursive 25 | cd build 26 | cmake -DBOOST_J=$NPROC $ARGS .. 27 | else 28 | ./do_cmake.sh $ARGS 29 | cd build 30 | fi 31 | 32 | ccache make -j$NPROC 33 | -------------------------------------------------------------------------------- /haproxy/haproxy.cfg: -------------------------------------------------------------------------------- 1 | global 2 | maxconn 4096 3 | log stdout format raw local0 debug 4 | 5 | defaults 6 | log global 7 | option log-health-checks 8 | timeout connect 5s 9 | timeout client 50s 10 | timeout server 450s 11 | 12 | frontend dashboard_front 13 | mode http 14 | bind *:80 15 | option httplog 16 | redirect scheme https code 301 if !{ ssl_fc } 17 | 18 | frontend dashboard_front_ssl 19 | mode tcp 20 | bind *:443 21 | option tcplog 22 | default_backend dashboard_back_ssl 23 | 24 | backend dashboard_back_ssl 25 | mode tcp 26 | balance source 27 | stick-table type ip size 200k expire 30m 28 | stick on src 29 | option httpchk GET / 30 | http-check expect status 200 31 | server x localhost: check-ssl check verify none 32 | server y localhost: check-ssl check verify none 33 | server z localhost: check-ssl check verify none 34 | -------------------------------------------------------------------------------- /shared/bin/mimic/setup-ceph.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | WITH_PYTHON="${WITH_PYTHON:-3}" 6 | 7 | cd /ceph 8 | find . -name \*.pyc -delete 9 | ./install-deps.sh 10 | 11 | ARGS="-DENABLE_GIT_VERSION=OFF -DWITH_TESTS=ON -DWITH_CCACHE=ON $ARGS" 12 | if [ "$WITH_PYTHON" == 3 ]; then 13 | ARGS="-DWITH_PYTHON3=ON -DWITH_PYTHON2=OFF -DMGR_PYTHON_VERSION=3 -DWITH_RADOSGW_AMQP_ENDPOINT=OFF $ARGS" 14 | echo "WITH_PYTHON 3" 15 | else 16 | ARGS="-DWITH_PYTHON3=OFF -DWITH_PYTHON2=ON -DMGR_PYTHON_VERSION=2 -DWITH_RADOSGW_AMQP_ENDPOINT=OFF $ARGS" 17 | echo "WITH_PYTHON 2" 18 | fi 19 | 20 | NPROC=${NPROC:-$(nproc --ignore=2)} 21 | 22 | if [ "$CLEAN" == "true" ]; then 23 | echo "CLEAN INSTALL" 24 | git clean -fdx 25 | fi 26 | 27 | if [ -d "build" ]; then 28 | git submodule update --init --recursive 29 | cd build 30 | cmake -DBOOST_J=$NPROC $ARGS .. 31 | else 32 | ./do_cmake.sh $ARGS 33 | cd build 34 | fi 35 | 36 | ccache make -j$NPROC 37 | 38 | -------------------------------------------------------------------------------- /Dashboards/README.md: -------------------------------------------------------------------------------- 1 | Steps to setup Grafana Dashboard for embedding:- 2 | In a working directory:- 3 | 1. `git clone https://github.com/ceph/ceph.git` 4 | 2. `git clone https://github.com/ricardoasmarques/ceph-dev-docker.git` 5 | 6 | After build and setting up docker for ceph. 7 | 1. To bring node-exporter, prometheus and Grafana services up `docker-compose up` 8 | 9 | Once all the services are up 10 | 1. Login to `localhost:3000` (admin/admin) 11 | 2. Add prometheus as data source 12 | 3. Import json files one by one by clicking `+` on left Dashboard 13 | 14 | Now 15 | 1. Inside `ceph-dev` container, start ceph instance using `start-ceph.sh` 16 | 2. Navigation to build directory `cd /ceph/build` 17 | 3. Enable prometheus Module `./bin/ceph mgr module enable prometheus` 18 | 4. Start web-server at 4200 `npm-start.sh` (this is required because Grafana dashboard doesnt run on https) 19 | 20 | Plugins required for grafana are :- 21 | 1. https://grafana.com/plugins/grafana-piechart-panel 22 | 2. https://grafana.com/plugins/vonage-status-panel 23 | -------------------------------------------------------------------------------- /shared/bin/create-dashboard-rgw-user.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | : ${CEPH_DEV_DOCKER_CONFIG_DIR:="$HOME/.ceph-dev-docker"} 6 | mkdir -p $CEPH_DEV_DOCKER_CONFIG_DIR 7 | 8 | #-------------- 9 | # Configure RGW 10 | #-------------- 11 | 12 | cd /ceph/build 13 | ./bin/radosgw-admin user create --uid=dev --display-name=Developer --system 14 | ./bin/ceph dashboard set-rgw-api-user-id dev 15 | 16 | RGW_ACCESS_KEY="${CEPH_DEV_DOCKER_CONFIG_DIR}/rgw_access_key" 17 | RGW_SECRET_KEY="${CEPH_DEV_DOCKER_CONFIG_DIR}/rgw_secret_key" 18 | ./bin/radosgw-admin user info --uid=dev | jq -jr ".keys[0].access_key" > $RGW_ACCESS_KEY 19 | ./bin/radosgw-admin user info --uid=dev | jq -jr ".keys[0].secret_key" > $RGW_SECRET_KEY 20 | chmod 600 $RGW_ACCESS_KEY 21 | chmod 600 $RGW_SECRET_KEY 22 | 23 | ./bin/ceph dashboard set-rgw-api-access-key -i $RGW_ACCESS_KEY || ./bin/ceph dashboard set-rgw-api-access-key "$(cat $RGW_ACCESS_KEY)" 24 | ./bin/ceph dashboard set-rgw-api-secret-key -i $RGW_SECRET_KEY || ./bin/ceph dashboard set-rgw-api-secret-key "$(cat $RGW_SECRET_KEY)" 25 | -------------------------------------------------------------------------------- /shared/bin/nautilus/setup-ceph.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | WITH_PYTHON="${WITH_PYTHON:-3}" 6 | 7 | cd /ceph 8 | find . -name \*.pyc -delete 9 | ./install-deps.sh 10 | 11 | ARGS="-DENABLE_GIT_VERSION=OFF -DWITH_TESTS=ON -DWITH_CCACHE=ON $ARGS" 12 | if [ "$WITH_PYTHON" == 3 ]; then 13 | ARGS="-DWITH_PYTHON3=ON -DWITH_PYTHON2=OFF -DMGR_PYTHON_VERSION=3 -DWITH_RADOSGW_AMQP_ENDPOINT=OFF $ARGS" 14 | echo "WITH_PYTHON 3" 15 | else 16 | ARGS="-DWITH_PYTHON3=OFF -DWITH_PYTHON2=ON -DMGR_PYTHON_VERSION=2 -DWITH_RADOSGW_AMQP_ENDPOINT=OFF $ARGS" 17 | echo "WITH_PYTHON 2" 18 | fi 19 | 20 | NPROC=${NPROC:-$(nproc --ignore=2)} 21 | 22 | # SSO dependencies 23 | zypper -n install libxmlsec1-1 libxmlsec1-nss1 libxmlsec1-openssl1 xmlsec1-devel xmlsec1-openssl-devel 24 | pip install python3-saml 25 | pip2 install python-saml 26 | 27 | if [ "$CLEAN" == "true" ]; then 28 | echo "CLEAN INSTALL" 29 | git clean -fdx 30 | fi 31 | 32 | if [ -d "build" ]; then 33 | git submodule update --init --recursive 34 | cd build 35 | cmake -DBOOST_J=$NPROC $ARGS .. 36 | else 37 | ./do_cmake.sh $ARGS 38 | cd build 39 | fi 40 | 41 | ccache make -j$NPROC 42 | 43 | -------------------------------------------------------------------------------- /mimic.Dockerfile: -------------------------------------------------------------------------------- 1 | FROM opensuse/leap:15.0 2 | LABEL maintainer="rimarques@suse.com" 3 | 4 | RUN zypper --gpg-auto-import-keys ref 5 | RUN zypper -n dup 6 | RUN zypper -n install \ 7 | aaa_base babeltrace-devel bash bzip2 ccache git \ 8 | google-opensans-fonts iproute2 jq lttng-ust-devel \ 9 | net-tools-deprecated psmisc tar tmux vim wget zsh \ 10 | python python2-pip python3-pip \ 11 | python-devel python3-devel \ 12 | python2-bcrypt python3-bcrypt \ 13 | python2-CherryPy python3-CherryPy \ 14 | python2-Cython python3-Cython \ 15 | python2-pecan python3-pecan \ 16 | python2-PrettyTable python3-PrettyTable \ 17 | python2-pylint python3-pylint \ 18 | python2-pyOpenSSL python3-pyOpenSSL \ 19 | python2-requests python3-requests \ 20 | python2-Routes python3-Routes \ 21 | python2-Werkzeug python3-Werkzeug 22 | 23 | ADD /shared/docker/ /docker 24 | 25 | # Chrome 26 | RUN /docker/install-chrome.sh 27 | ENV CHROME_BIN /usr/bin/google-chrome 28 | 29 | # oh-my-zsh 30 | ENV ZSH_DISABLE_COMPFIX true 31 | RUN /docker/install-omz.sh 32 | 33 | ENV CEPH_ROOT /ceph 34 | 35 | ENV PATH="/shared/bin/mimic:${PATH}" 36 | 37 | VOLUME ["/ceph"] 38 | VOLUME ["/shared"] 39 | 40 | CMD ["zsh"] 41 | -------------------------------------------------------------------------------- /shibboleth/files/metadata-providers.xml: -------------------------------------------------------------------------------- 1 | 2 | 12 | 13 | 16 | 17 | 20 | 21 | -------------------------------------------------------------------------------- /pacific.Dockerfile: -------------------------------------------------------------------------------- 1 | FROM opensuse/leap:15.2 2 | LABEL maintainer="rimarques@suse.com" 3 | 4 | RUN zypper --gpg-auto-import-keys ref 5 | RUN zypper -n dup 6 | RUN zypper -n install \ 7 | iproute2 net-tools-deprecated zsh lttng-ust-devel babeltrace-devel \ 8 | bash vim tmux git aaa_base ccache wget jq google-opensans-fonts psmisc \ 9 | rpm-build smartmontools \ 10 | python python-devel python2-virtualenv \ 11 | python3-pip python3-devel \ 12 | python3-bcrypt \ 13 | python3-CherryPy \ 14 | python3-Cython \ 15 | python3-Jinja2 \ 16 | python3-jsonpatch \ 17 | python3-pecan \ 18 | python3-PrettyTable \ 19 | python3-PyJWT \ 20 | python3-pylint \ 21 | python3-pyOpenSSL \ 22 | python3-PyYAML \ 23 | python3-remoto \ 24 | python3-requests \ 25 | python3-Routes \ 26 | python3-scipy \ 27 | python3-Werkzeug \ 28 | xvfb-run 29 | 30 | ADD /shared/docker/ /docker 31 | 32 | # Chrome 33 | RUN /docker/install-chrome.sh 34 | ENV CHROME_BIN /usr/bin/google-chrome 35 | 36 | # oh-my-zsh 37 | ENV ZSH_DISABLE_COMPFIX true 38 | RUN /docker/install-omz.sh 39 | 40 | ENV CEPH_ROOT /ceph 41 | ENV CYPRESS_CACHE_FOLDER /ceph/build/src/pybind/mgr/dashboard/cypress 42 | 43 | VOLUME ["/ceph"] 44 | VOLUME ["/shared"] 45 | 46 | CMD ["zsh"] 47 | -------------------------------------------------------------------------------- /setup.sh: -------------------------------------------------------------------------------- 1 | WORKSPACE="$(dirname "$(pwd)")" 2 | 3 | NAME="${NAME:-ceph-1}" 4 | CEPH="${CEPH:-$WORKSPACE/ceph}" 5 | CCACHE="${CCACHE:-$WORKSPACE/ceph-ccache}" 6 | VERSION="${VERSION:-master}" 7 | 8 | # Removes old container with same name 9 | docker stop $NAME 10 | docker rm $NAME 11 | 12 | DOCKER_BUILD_OPTS="--pull" 13 | 14 | # Build updated version of the image 15 | case "$VERSION" in 16 | "mimic") 17 | TAG="ceph-dev-docker-mimic" 18 | docker build $DOCKER_BUILD_OPTS -t $TAG -f mimic.Dockerfile . 19 | ;; 20 | "nautilus") 21 | TAG="ceph-dev-docker-nautilus" 22 | docker build $DOCKER_BUILD_OPTS -t $TAG -f nautilus.Dockerfile . 23 | ;; 24 | "octopus") 25 | TAG="ceph-dev-docker-octopus" 26 | docker build $DOCKER_BUILD_OPTS -t $TAG -f octopus.Dockerfile . 27 | ;; 28 | "pacific") 29 | TAG="ceph-dev-docker-pacific" 30 | docker build $DOCKER_BUILD_OPTS -t $TAG -f pacific.Dockerfile . 31 | ;; 32 | *) 33 | TAG="ceph-dev-docker" 34 | docker build $DOCKER_BUILD_OPTS -t $TAG . 35 | ;; 36 | esac 37 | 38 | # Creates a container with all recommended configs 39 | docker run -itd \ 40 | -v $CEPH:/ceph \ 41 | -v $CCACHE:/root/.ccache \ 42 | -v $(pwd)/shared:/shared \ 43 | -v /run/udev:/run/udev:ro \ 44 | -v ~/.ssh:/root/.ssh:ro \ 45 | --privileged \ 46 | --net=host \ 47 | --name=$NAME \ 48 | --hostname=$NAME \ 49 | --add-host=$NAME:127.0.0.1 \ 50 | $TAG 51 | 52 | docker exec -it $NAME zsh 53 | -------------------------------------------------------------------------------- /shibboleth/files/ldap.properties: -------------------------------------------------------------------------------- 1 | idp.authn.LDAP.authenticator = directAuthenticator 2 | idp.authn.LDAP.ldapURL = ldaps://#LDAPHOST#:636 3 | idp.authn.LDAP.useStartTLS = false 4 | idp.authn.LDAP.useSSL = true 5 | idp.authn.LDAP.trustCertificates = %{idp.home}/credentials/ldap-server.crt 6 | idp.authn.LDAP.trustStore = %{idp.home}/credentials/ldap-server.truststore 7 | idp.authn.LDAP.returnAttributes = * 8 | idp.authn.LDAP.dnFormat = cn=%s,dc=example,dc=org 9 | 10 | 11 | idp.attribute.resolver.LDAP.ldapURL = %{idp.authn.LDAP.ldapURL} 12 | idp.attribute.resolver.LDAP.connectTimeout = %{idp.authn.LDAP.connectTimeout:PT3S} 13 | idp.attribute.resolver.LDAP.responseTimeout = %{idp.authn.LDAP.responseTimeout:PT3S} 14 | idp.attribute.resolver.LDAP.baseDN = %{idp.authn.LDAP.baseDN:undefined} 15 | idp.attribute.resolver.LDAP.bindDN = %{idp.authn.LDAP.bindDN:undefined} 16 | idp.attribute.resolver.LDAP.bindDNCredential = %{idp.authn.LDAP.bindDNCredential:undefined} 17 | idp.attribute.resolver.LDAP.useStartTLS = %{idp.authn.LDAP.useStartTLS:true} 18 | idp.attribute.resolver.LDAP.trustCertificates = %{idp.authn.LDAP.trustCertificates:undefined} 19 | idp.attribute.resolver.LDAP.searchFilter = (uid=$resolutionContext.principal) 20 | -------------------------------------------------------------------------------- /grafana/datasource.yaml: -------------------------------------------------------------------------------- 1 | # config file version 2 | apiVersion: 1 3 | 4 | # list of datasources to insert/update depending 5 | # what's available in the database 6 | datasources: 7 | # name of the datasource. Required 8 | - name: Prometheus 9 | # datasource type. Required 10 | type: prometheus 11 | # access mode. proxy or direct (Server or Browser in the UI). Required 12 | access: proxy 13 | # org id. will default to orgId 1 if not specified 14 | orgId: 1 15 | # url 16 | url: http://localhost:9090 17 | # database password, if used 18 | password: 19 | # database user, if used 20 | user: 21 | # database name, if used 22 | database: 23 | # enable/disable basic auth 24 | basicAuth: 25 | # basic auth username 26 | basicAuthUser: 27 | # basic auth password 28 | basicAuthPassword: 29 | # enable/disable with credentials headers 30 | withCredentials: 31 | # mark as default datasource. Max one per org 32 | isDefault: 33 | # fields that will be converted to json and stored in jsonData 34 | jsonData: 35 | graphiteVersion: "1.1" 36 | tlsAuth: false 37 | tlsAuthWithCACert: false 38 | # json object of data that will be encrypted. 39 | secureJsonData: 40 | tlsCACert: "..." 41 | tlsClientCert: "..." 42 | tlsClientKey: "..." 43 | version: 1 44 | # allow users to edit datasources from the UI. 45 | editable: false 46 | -------------------------------------------------------------------------------- /nautilus.Dockerfile: -------------------------------------------------------------------------------- 1 | FROM opensuse/leap:15.1 2 | LABEL maintainer="rimarques@suse.com" 3 | 4 | RUN zypper --gpg-auto-import-keys ref 5 | RUN zypper -n dup 6 | RUN zypper -n install \ 7 | iproute2 net-tools-deprecated zsh lttng-ust-devel babeltrace-devel \ 8 | bash vim tmux git aaa_base ccache wget jq google-opensans-fonts psmisc \ 9 | python python2-pip python3-pip \ 10 | python-devel python3-devel \ 11 | python2-bcrypt python3-bcrypt \ 12 | python2-CherryPy python3-CherryPy \ 13 | python2-Cython python3-Cython \ 14 | python2-Jinja2 python3-Jinja2 \ 15 | python2-pecan python3-pecan \ 16 | python2-PrettyTable python3-PrettyTable \ 17 | python2-PyJWT python3-PyJWT \ 18 | python2-pylint python3-pylint \ 19 | python2-pyOpenSSL python3-pyOpenSSL \ 20 | python2-requests python3-requests \ 21 | python2-Routes python3-Routes \ 22 | python2-Werkzeug python3-Werkzeug 23 | 24 | # temporary fix for error regarding version of tempora 25 | RUN pip2 install tempora==1.8 backports.functools_lru_cache 26 | RUN pip3 install tempora==1.8 backports.functools_lru_cache 27 | 28 | ADD /shared/docker/ /docker 29 | 30 | # Chrome 31 | RUN /docker/install-chrome.sh 32 | ENV CHROME_BIN /usr/bin/google-chrome 33 | 34 | # oh-my-zsh 35 | ENV ZSH_DISABLE_COMPFIX true 36 | RUN /docker/install-omz.sh 37 | 38 | ENV CEPH_ROOT /ceph 39 | 40 | ENV PATH="/shared/bin/nautilus:${PATH}" 41 | 42 | VOLUME ["/ceph"] 43 | VOLUME ["/shared"] 44 | 45 | CMD ["zsh"] 46 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM opensuse/tumbleweed 2 | LABEL maintainer="rimarques@suse.com" 3 | 4 | RUN zypper --gpg-auto-import-keys ref 5 | RUN zypper -n dup 6 | RUN zypper -n install \ 7 | iproute2 net-tools-deprecated zsh lttng-ust-devel babeltrace-devel \ 8 | bash vim tmux git aaa_base ccache wget jq google-opensans-fonts psmisc \ 9 | rpm-build smartmontools \ 10 | python python-devel \ 11 | python3-virtualenv \ 12 | python3-pip python3-devel \ 13 | python3-bcrypt \ 14 | python3-CherryPy \ 15 | python3-Cython \ 16 | python3-Jinja2 \ 17 | python3-pecan \ 18 | python3-PrettyTable \ 19 | python3-PyJWT \ 20 | python3-pylint \ 21 | python3-pyOpenSSL \ 22 | python3-PyYAML \ 23 | python3-remoto \ 24 | python3-requests \ 25 | python3-Routes \ 26 | python3-scipy \ 27 | python3-Werkzeug \ 28 | xvfb-run 29 | 30 | # temporary fix for error regarding version of tempora 31 | RUN pip3 install tempora==1.8 backports.functools_lru_cache 32 | 33 | ADD /shared/docker/ /docker 34 | 35 | # Chrome 36 | RUN /docker/install-chrome.sh 37 | ENV CHROME_BIN /usr/bin/google-chrome 38 | 39 | # oh-my-zsh 40 | ENV ZSH_DISABLE_COMPFIX true 41 | RUN /docker/install-omz.sh 42 | 43 | ENV CEPH_ROOT /ceph 44 | ENV CYPRESS_CACHE_FOLDER /ceph/build/src/pybind/mgr/dashboard/cypress 45 | 46 | VOLUME ["/ceph"] 47 | VOLUME ["/shared"] 48 | 49 | # Temporary fix for scipy issue in diskprection_local -> https://tracker.ceph.com/issues/43447 50 | RUN zypper -n rm python3-scipy && pip3 install scipy==1.3.2 51 | 52 | CMD ["zsh"] 53 | -------------------------------------------------------------------------------- /octopus.Dockerfile: -------------------------------------------------------------------------------- 1 | FROM opensuse/leap:15.2 2 | LABEL maintainer="rimarques@suse.com" 3 | 4 | RUN zypper --gpg-auto-import-keys ref 5 | RUN zypper -n dup 6 | RUN zypper -n install \ 7 | iproute2 net-tools-deprecated zsh lttng-ust-devel babeltrace-devel \ 8 | bash vim tmux git aaa_base ccache wget jq google-opensans-fonts psmisc \ 9 | rpm-build smartmontools \ 10 | python python-devel python2-virtualenv \ 11 | python3-pip python3-devel \ 12 | python3-bcrypt \ 13 | python3-CherryPy \ 14 | python3-Cython \ 15 | python3-Jinja2 \ 16 | python3-jsonpatch \ 17 | python3-pecan \ 18 | python3-PrettyTable \ 19 | python3-PyJWT \ 20 | python3-pylint \ 21 | python3-pyOpenSSL \ 22 | python3-PyYAML \ 23 | python3-remoto \ 24 | python3-requests \ 25 | python3-Routes \ 26 | python3-scipy \ 27 | python3-Werkzeug \ 28 | xvfb-run 29 | 30 | # temporary fix for error regarding version of tempora 31 | RUN pip3 install tempora==1.8 backports.functools_lru_cache 32 | 33 | ADD /shared/docker/ /docker 34 | 35 | # Chrome 36 | RUN /docker/install-chrome.sh 37 | ENV CHROME_BIN /usr/bin/google-chrome 38 | 39 | # oh-my-zsh 40 | ENV ZSH_DISABLE_COMPFIX true 41 | RUN /docker/install-omz.sh 42 | 43 | ENV CEPH_ROOT /ceph 44 | ENV CYPRESS_CACHE_FOLDER /ceph/build/src/pybind/mgr/dashboard/cypress 45 | 46 | VOLUME ["/ceph"] 47 | VOLUME ["/shared"] 48 | 49 | # Temporary fix for scipy issue in diskprection_local -> https://tracker.ceph.com/issues/43447 50 | RUN zypper -n rm python3-scipy && pip3 install scipy==1.3.2 51 | 52 | CMD ["zsh"] 53 | -------------------------------------------------------------------------------- /shibboleth/files/shibboleth2.xml: -------------------------------------------------------------------------------- 1 | 7 | 8 | 9 | 11 | 12 | 14 | 15 | 17 | SAML2 SAML1 18 | 19 | 20 | SAML2 Local 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /grafana/grafana_ssl_cert.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFyTCCA7GgAwIBAgIUVI+Soi04hJ6/g8pwEZTNKxBmhIQwDQYJKoZIhvcNAQEL 3 | BQAwdDELMAkGA1UEBhMCREUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoM 4 | GEludGVybmV0IFdpZGdpdHMgUHR5IEx0ZDEtMCsGA1UECwwkU1VTRSBTb2Z0d2Fy 5 | ZSBTb2x1dGlvbnMgR2VybWFueSBHbWJIMB4XDTE5MTAyNDA5MjI1NFoXDTI0MTAy 6 | MjA5MjI1NFowdDELMAkGA1UEBhMCREUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAf 7 | BgNVBAoMGEludGVybmV0IFdpZGdpdHMgUHR5IEx0ZDEtMCsGA1UECwwkU1VTRSBT 8 | b2Z0d2FyZSBTb2x1dGlvbnMgR2VybWFueSBHbWJIMIICIjANBgkqhkiG9w0BAQEF 9 | AAOCAg8AMIICCgKCAgEAuB3wmc211R3j19gw9Ey/YEaWNomaOA6L6jf+tu+nHLvM 10 | GceT0OGT8H73m5PbqCY0pSUtdWDtPfDecnNL3qM4pPJMKtF8BatMsxVRcV+T+n+k 11 | ERezsjD0MzgWqfhbX5tN8+5PxBPZU60WTOCBBYX7L0elcQEWS/HzUg6q7qLQZUwv 12 | vLsmrxNFPPwMjNE29R83gBAQT0jisFU5QDqbKySjF6TKTuBWWdPPTcOKLLmk/Mq0 13 | XoM8lxWLk27Q4aOTPUhtWakun3F9mxnTghOWtI+WTOGUFmRZ5fnf2Ce2gXhAyBjb 14 | AmcQaDADhe3yxcKrCb0JzyOk6xfFjE90IqLADZ98WXdB0LC13hbVq3riQRjOndWW 15 | l5rOBUO2hfJNXMAe3cew9HV+KBj+ee0HomZBzGxEq+UVRZrUJqfrvUYDCA27XlVZ 16 | LjNSnYhdB98gDJcVn+JGERagE+IS/pfX8q4Vq5UFeykA416RO7zdaMRa3iwEu/uo 17 | Wmlu7ikkziQj0eEhZ9c3t2snJCUNBDUEzsuepMxMIv1YmBC4We57AVTZynLpcPJ7 18 | OUEzXQOq5FORwso/vdZf0+SY7btkHReqAypk0jN+g5jOSj9Dn7z4NYJt4Oiuk5hZ 19 | NL9o0nQ+ZT1KzxvAmYIaG+twasByqIlQO1wlOWkacK/7coEfzDRHo12ha2JnMg8C 20 | AwEAAaNTMFEwHQYDVR0OBBYEFKplnzCyjPolw1LMEq0SueVZZs0aMB8GA1UdIwQY 21 | MBaAFKplnzCyjPolw1LMEq0SueVZZs0aMA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZI 22 | hvcNAQELBQADggIBACvsj7ssAIp4YefzwnDdWn0xd10MGLWz6QkXajZcW4eqSak9 23 | q4qXySKX34t3Ek2LJiNsifksXhjepCZ5nwwwu6A1rNwWSJ65AJm3mzeXaWX+CVQN 24 | 6V6fvBYNRVSwVEzMkdrjI4DvWV0N3/QIDTVleZEbaPWzfWL2pGkuwcAzfeGuuW3s 25 | fe7T5RyuM/fXuWNN1ABZj+bA7XpXQ3vtTri4SyFZVzT3dvL8/imPqcoOzOVSkogu 26 | OqT8TxOxLRNlyue+yTlHcxM7xnztJWwduYsfVNnznPZPlwmtQymQUUuFYezPkkAZ 27 | KOAlPQi2uFes3HiM300GOnxCgHxG/M05Y4JWq7QB/Mdxzz41vH0TgtbVBhSSrhSk 28 | gx6MZCHlaqgA4Nmkf65PoabxRSwN3VU5Es4OgXgtZ7OY70ZY2tEKhomAunB509q/ 29 | Wegj+ma9YjoMliXkUxtzymnTevQhlr5jjgePj468TALE+sjyCgcM/LvkRopGwHRt 30 | omn/UT1zuimboCgAFznRsBx/LqKl718NN41mcQ5xvYfB/uo6d3HGSBIAPTZQ1C6Z 31 | gTfVTUJ7OrMOXkDFZEE7A/YWp5wtsOHwZ3SOYIypvp7uFd6sy33ESQ/D8g9+GOAI 32 | oTHe6TsyKTaBcegruOGFKZtPEw5LPHY6UQcR3SspXgz9com7GqiQe8LjuN0V 33 | -----END CERTIFICATE----- 34 | -------------------------------------------------------------------------------- /shibboleth/files/jetty-ssl-context.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | / 7 | 8 | 9 | 10 | 11 | / 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /prometheus/rules/alert.rules: -------------------------------------------------------------------------------- 1 | groups: 2 | - name: test 3 | rules: 4 | 5 | - alert: load_0 6 | expr: node_load1 > 0 7 | for: 10s 8 | labels: 9 | severity: info 10 | foo: bar 11 | annotations: 12 | summary: "Instance {{ $labels.instance }} load is over 0!" 13 | description: "{{ $labels.instance }} of job {{ $labels.job }} load is over 0!" 14 | 15 | - alert: load_1 16 | expr: node_load1 > 1 and node_load1 < 3 17 | for: 30s 18 | labels: 19 | severity: info 20 | oid: 1.3.6.1.4.1.50495.15.1.2.50.1 21 | annotations: 22 | summary: "Instance {{ $labels.instance }} with load between 1 and 3" 23 | description: "{{ $labels.instance }} of job {{ $labels.job }} with load between 1 and 3." 24 | 25 | - alert: load_2 26 | expr: node_load1 > 2 and node_load1 < 4 27 | for: 25s 28 | labels: 29 | severity: warning 30 | oid: 1.3.6.1.4.1.50495.15.1.2.50.2 31 | annotations: 32 | summary: "Instance {{ $labels.instance }} with load between 2 and 4" 33 | description: "{{ $labels.instance }} of job {{ $labels.job }} with load between 2 and 4." 34 | 35 | - alert: load_3 36 | expr: node_load1 > 3 and node_load1 < 5 37 | for: 20s 38 | labels: 39 | severity: warning 40 | oid: 1.3.6.1.4.1.50495.15.1.2.50.3 41 | annotations: 42 | summary: "Instance {{ $labels.instance }} with load between 3 and 5" 43 | description: "{{ $labels.instance }} of job {{ $labels.job }} with load between 3 and 5." 44 | 45 | - alert: load_4 46 | expr: node_load1 > 4 and node_load1 < 6 47 | for: 15s 48 | labels: 49 | severity: warning 50 | oid: 1.3.6.1.4.1.50495.15.1.2.50.4 51 | annotations: 52 | summary: "Instance {{ $labels.instance }} with load between 4 and 6" 53 | description: "{{ $labels.instance }} of job {{ $labels.job }} with load between 4 and 6." 54 | 55 | - alert: load_5 56 | expr: node_load1 > 5 and node_load1 < 7 57 | for: 10s 58 | labels: 59 | severity: warning 60 | oid: 1.3.6.1.4.1.50495.15.1.2.50.5 61 | annotations: 62 | summary: "Instance {{ $labels.instance }} with load between 5 and 7" 63 | description: "{{ $labels.instance }} of job {{ $labels.job }} with load between 5 and 7." 64 | 65 | - alert: load_6 66 | expr: node_load1 > 6 67 | for: 5s 68 | labels: 69 | severity: critical 70 | oid: 1.3.6.1.4.1.50495.15.1.2.50.6 71 | annotations: 72 | summary: "Instance {{ $labels.instance }} with load over 6 for 10s." 73 | description: "{{ $labels.instance }} of job {{ $labels.job }} with load over 6 for 10s." 74 | -------------------------------------------------------------------------------- /docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '3' 2 | 3 | services: 4 | node-exporter: 5 | user: 'root' 6 | image: 'prom/node-exporter' 7 | volumes: 8 | - '/proc:/host/proc:ro' 9 | - '/sys:/host/sys:ro' 10 | - '/:/rootfs:ro' 11 | network_mode: 'host' 12 | command: ['--path.procfs', '/host/proc', 13 | '--path.sysfs', '/host/sys', 14 | '--collector.filesystem.ignored-mount-points', '^/(sys|proc|dev|host|etc)($$|/)'] 15 | prometheus: 16 | image: 'prom/prometheus' 17 | volumes: 18 | - './prometheus/rules:/etc/prometheus/rules' 19 | - './prometheus/prometheus.yml:/etc/prometheus/prometheus.yml' 20 | container_name: 'prometheus' 21 | network_mode: 'host' 22 | 23 | alertmanager: 24 | image: 'prom/alertmanager' 25 | volumes: 26 | - './alertmanager/:/etc/alertmanager/' 27 | container_name: 'alertmanager' 28 | command: 29 | - '--config.file=/etc/alertmanager/config.yml' 30 | - '--storage.path=/alertmanager' 31 | network_mode: 'host' 32 | 33 | grafana: 34 | image: 'grafana/grafana' 35 | volumes: 36 | - './grafana/ceph-dashboards.yaml:/etc/grafana/provisioning/dashboards/ceph-dashboards.yaml:ro' 37 | - './grafana/datasource.yaml:/etc/grafana/provisioning/datasources/datasource.yaml:ro' 38 | - './grafana/grafana.ini:/etc/grafana/grafana.ini:ro' 39 | - './grafana/grafana_ssl_cert.crt:/etc/grafana/grafana_ssl_cert.crt' 40 | - './grafana/grafana_ssl_cert.key:/etc/grafana/grafana_ssl_cert.key' 41 | - '../ceph/monitoring/grafana/dashboards:/var/lib/grafana/dashboards/:ro' 42 | environment: 43 | GF_INSTALL_PLUGINS: vonage-status-panel,grafana-piechart-panel 44 | container_name: 'grafana' 45 | network_mode: 'host' 46 | 47 | keycloak: 48 | image: jboss/keycloak 49 | environment: 50 | KEYCLOAK_USER: admin 51 | KEYCLOAK_PASSWORD: admin 52 | DB_VENDOR: H2 53 | ports: 54 | - "8080:8080" 55 | 56 | openldap: 57 | image: osixia/openldap:1.2.0 58 | environment: 59 | LDAP_TLS_VERIFY_CLIENT: try 60 | ports: 61 | - "2389:389" 62 | 63 | phpldapadmin: 64 | image: osixia/phpldapadmin:0.7.1 65 | environment: 66 | PHPLDAPADMIN_LDAP_HOSTS: openldap 67 | ports: 68 | - "90:443" 69 | links: 70 | - openldap 71 | 72 | shibboleth: 73 | build: 74 | context: ./shibboleth 75 | dockerfile: Dockerfile 76 | ports: 77 | - "9080:9080" 78 | - "9443:9443" 79 | links: 80 | - openldap 81 | 82 | haproxy: 83 | image: 'haproxy' 84 | volumes: 85 | - './haproxy/haproxy.cfg:/usr/local/etc/haproxy/haproxy.cfg' 86 | network_mode: 'host' 87 | -------------------------------------------------------------------------------- /shared/bin/setup-cephadm.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | refresh=0 6 | 7 | for i in "$@"; do 8 | case $i in 9 | --refresh) 10 | refresh=1 11 | ;; 12 | esac 13 | done 14 | 15 | # Make sure the host SSH directory is mapped into the Docker container. 16 | if [ ! -e "/root/.ssh/id_rsa" -o ! -e "/root/.ssh/id_rsa.pub" ]; then 17 | echo "ERROR: The host SSH directory is not mapped into the Docker container. Make sure to use the command line argument '-v ~/.ssh:/root/.ssh:ro' when starting the Docker container." 18 | exit 1 19 | fi 20 | 21 | # Make sure the SSH configuration of the Vagrant box is available. 22 | if [ ! -e "/ceph/src/pybind/mgr/cephadm/ssh-config" ]; then 23 | echo "ERROR: No ssh-config file found. Make sure to run 'vagrant ssh-config > ssh-config' in the directory 'src/pybind/mgr/cephadm' of your host system." 24 | exit 1 25 | fi 26 | 27 | cd /ceph/build 28 | 29 | # Disable these cephadm stray warnings, otherwise the cluster reports 30 | # health warnings which prevents deploying services. 31 | # This happens because vstart hosts and daemons are not managed by 32 | # cephadm. 33 | # https://docs.ceph.com/en/latest/cephadm/operations/#cephadm-stray-host 34 | bin/ceph config set mgr mgr/cephadm/warn_on_stray_hosts false 35 | #https://docs.ceph.com/en/latest/cephadm/operations/#cephadm-stray-daemon 36 | bin/ceph config set mgr mgr/cephadm/warn_on_stray_daemons false 37 | 38 | bin/ceph config-key set mgr/cephadm/ssh_identity_key -i /root/.ssh/id_rsa 39 | bin/ceph config-key set mgr/cephadm/ssh_identity_pub -i /root/.ssh/id_rsa.pub 40 | 41 | bin/ceph mgr module enable cephadm 42 | bin/ceph orch set backend cephadm 43 | bin/ceph orch status 44 | 45 | bin/ceph cephadm set-ssh-config -i /ceph/src/pybind/mgr/cephadm/ssh-config 46 | 47 | # Remove previous Vagrant box nodes from /etc/hosts. 48 | # http://blog.jonathanargentiero.com/docker-sed-cannot-rename-etcsedl8ysxl-device-or-resource-busy/ 49 | sed --regexp-extended '/(osd|mgr|mon)0$/d' /etc/hosts > /root/hosts.new 50 | cp -f /root/hosts.new /etc/hosts 51 | 52 | # Add the IP addresses of the Vagrant box nodes to the containers /etc/hosts file. 53 | pip install paramiko 54 | python3 <!!g' /opt/shibboleth-idp/conf/attribute-filter.xml 51 | RUN sed -i -e 's/name="urn:oid:0.9.2342.19200300.100.1.1"/name="uid"/g' /opt/shibboleth-idp/conf/attribute-resolver.xml 52 | 53 | ADD files/ldap.properties /opt/shibboleth-idp/conf/ 54 | ADD files/start.sh / 55 | ADD https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh / 56 | RUN chmod +x /wait-for-it.sh 57 | 58 | ENTRYPOINT [ "/start.sh" ] 59 | 60 | -------------------------------------------------------------------------------- /shared/zsh/.zshrc: -------------------------------------------------------------------------------- 1 | # If you come from bash you might have to change your $PATH. 2 | # export PATH=$HOME/bin:/usr/local/bin:$PATH 3 | # Path to your oh-my-zsh installation. 4 | export ZSH="/root/.oh-my-zsh" 5 | 6 | # Set name of the theme to load --- if set to "random", it will 7 | # load a random theme each time oh-my-zsh is loaded, in which case, 8 | # to know which specific one was loaded, run: echo $RANDOM_THEME 9 | # See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes 10 | ZSH_THEME="bira" 11 | 12 | # Set list of themes to pick from when loading at random 13 | # Setting this variable when ZSH_THEME=random will cause zsh to load 14 | # a theme from this variable instead of looking in ~/.oh-my-zsh/themes/ 15 | # If set to an empty array, this variable will have no effect. 16 | # ZSH_THEME_RANDOM_CANDIDATES=( "robbyrussell" "agnoster" ) 17 | 18 | # Uncomment the following line to use case-sensitive completion. 19 | # CASE_SENSITIVE="true" 20 | 21 | # Uncomment the following line to use hyphen-insensitive completion. 22 | # Case-sensitive completion must be off. _ and - will be interchangeable. 23 | # HYPHEN_INSENSITIVE="true" 24 | 25 | # Uncomment the following line to disable bi-weekly auto-update checks. 26 | # DISABLE_AUTO_UPDATE="true" 27 | 28 | # Uncomment the following line to change how often to auto-update (in days). 29 | # export UPDATE_ZSH_DAYS=13 30 | 31 | # Uncomment the following line to disable colors in ls. 32 | # DISABLE_LS_COLORS="true" 33 | 34 | # Uncomment the following line to disable auto-setting terminal title. 35 | # DISABLE_AUTO_TITLE="true" 36 | 37 | # Uncomment the following line to enable command auto-correction. 38 | # ENABLE_CORRECTION="true" 39 | 40 | # Uncomment the following line to display red dots whilst waiting for completion. 41 | # COMPLETION_WAITING_DOTS="true" 42 | 43 | # Uncomment the following line if you want to disable marking untracked files 44 | # under VCS as dirty. This makes repository status check for large repositories 45 | # much, much faster. 46 | # DISABLE_UNTRACKED_FILES_DIRTY="true" 47 | 48 | # Uncomment the following line if you want to change the command execution time 49 | # stamp shown in the history command output. 50 | # You can set one of the optional three formats: 51 | # "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd" 52 | # or set a custom format using the strftime function format specifications, 53 | # see 'man strftime' for details. 54 | # HIST_STAMPS="mm/dd/yyyy" 55 | 56 | # Would you like to use another custom folder than $ZSH/custom? 57 | # ZSH_CUSTOM=/path/to/new-custom-folder 58 | 59 | # Which plugins would you like to load? 60 | # Standard plugins can be found in ~/.oh-my-zsh/plugins/* 61 | # Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ 62 | # Example format: plugins=(rails git textmate ruby lighthouse) 63 | # Add wisely, as too many plugins slow down shell startup. 64 | plugins=( 65 | git npm suse pip colored-man-pages dash binds 66 | ) 67 | 68 | source $ZSH/oh-my-zsh.sh 69 | 70 | # User configuration 71 | 72 | # export MANPATH="/usr/local/man:$MANPATH" 73 | export SOURCE_DATE_EPOCH=946684800 74 | export PATH=${PATH}:/shared/bin 75 | export NG_CLI_ANALYTICS="false" 76 | 77 | # You may need to manually set your language environment 78 | # export LANG=en_US.UTF-8 79 | export LC_ALL=en_US.UTF-8 80 | 81 | # Preferred editor for local and remote sessions 82 | # if [[ -n $SSH_CONNECTION ]]; then 83 | # export EDITOR='vim' 84 | # else 85 | # export EDITOR='mvim' 86 | # fi 87 | 88 | # Compilation flags 89 | # export ARCHFLAGS="-arch x86_64" 90 | 91 | # ssh 92 | # export SSH_KEY_PATH="~/.ssh/rsa_id" 93 | 94 | # Set personal aliases, overriding those provided by oh-my-zsh libs, 95 | # plugins, and themes. Aliases can be placed here, though oh-my-zsh 96 | # users are encouraged to define aliases within the ZSH_CUSTOM folder. 97 | # For a full list of active aliases, run `alias`. 98 | # 99 | # Example aliases 100 | # alias zshconfig="mate ~/.zshrc" 101 | # alias ohmyzsh="mate ~/.oh-my-zsh" 102 | alias cdb='cd /ceph/build' 103 | alias cdbd='cd /ceph/build/src/pybind/mgr/dashboard' 104 | alias cdsd='cd /ceph/src/pybind/mgr/dashboard' 105 | alias activate='source /ceph/build/src/pybind/mgr/dashboard/node-env/bin/activate .' 106 | -------------------------------------------------------------------------------- /Dashboards/cephfs-overview.json: -------------------------------------------------------------------------------- 1 | { 2 | "__requires": [ 3 | { 4 | "type": "grafana", 5 | "id": "grafana", 6 | "name": "Grafana", 7 | "version": "5.0.0" 8 | }, 9 | { 10 | "type": "panel", 11 | "id": "graph", 12 | "name": "Graph", 13 | "version": "5.0.0" 14 | } 15 | ], 16 | "annotations": { 17 | "list": [ 18 | { 19 | "builtIn": 1, 20 | "datasource": "-- Grafana --", 21 | "enable": true, 22 | "hide": true, 23 | "iconColor": "rgba(0, 211, 255, 1)", 24 | "name": "Annotations & Alerts", 25 | "type": "dashboard" 26 | } 27 | ] 28 | }, 29 | "editable": false, 30 | "gnetId": null, 31 | "graphTooltip": 0, 32 | "id": null, 33 | "iteration": 1534386614546, 34 | "links": [], 35 | "panels": [ 36 | { 37 | "collapsed": false, 38 | "gridPos": { 39 | "h": 1, 40 | "w": 24, 41 | "x": 0, 42 | "y": 0 43 | }, 44 | "id": 10, 45 | "panels": [], 46 | "title": "MDS Performance", 47 | "type": "row" 48 | }, 49 | { 50 | "aliasColors": {}, 51 | "bars": false, 52 | "dashLength": 10, 53 | "dashes": false, 54 | "datasource": "$datasource", 55 | "fill": 1, 56 | "gridPos": { 57 | "h": 9, 58 | "w": 12, 59 | "x": 0, 60 | "y": 1 61 | }, 62 | "id": 2, 63 | "legend": { 64 | "avg": false, 65 | "current": false, 66 | "max": false, 67 | "min": false, 68 | "show": true, 69 | "total": false, 70 | "values": false 71 | }, 72 | "lines": true, 73 | "linewidth": 1, 74 | "links": [], 75 | "nullPointMode": "null", 76 | "percentage": false, 77 | "pointradius": 5, 78 | "points": false, 79 | "renderer": "flot", 80 | "seriesOverrides": [], 81 | "spaceLength": 10, 82 | "stack": true, 83 | "steppedLine": false, 84 | "targets": [ 85 | { 86 | "expr": "sum(ceph_objecter_op_r{ceph_daemon=~\"($mds_servers).*\"})", 87 | "format": "time_series", 88 | "intervalFactor": 1, 89 | "legendFormat": "MDS Reads", 90 | "refId": "A" 91 | }, 92 | { 93 | "expr": "sum(ceph_objecter_op_w{ceph_daemon=~\"($mds_servers).*\"})", 94 | "format": "time_series", 95 | "intervalFactor": 1, 96 | "legendFormat": "MDS Writes", 97 | "refId": "B" 98 | } 99 | ], 100 | "thresholds": [], 101 | "timeFrom": null, 102 | "timeShift": null, 103 | "title": "MDS Workload - $mds_servers", 104 | "tooltip": { 105 | "shared": true, 106 | "sort": 0, 107 | "value_type": "individual" 108 | }, 109 | "type": "graph", 110 | "xaxis": { 111 | "buckets": null, 112 | "mode": "time", 113 | "name": null, 114 | "show": true, 115 | "values": [] 116 | }, 117 | "yaxes": [ 118 | { 119 | "format": "none", 120 | "label": null, 121 | "logBase": 1, 122 | "max": null, 123 | "min": "0", 124 | "show": true 125 | }, 126 | { 127 | "format": "short", 128 | "label": null, 129 | "logBase": 1, 130 | "max": null, 131 | "min": null, 132 | "show": true 133 | } 134 | ] 135 | }, 136 | { 137 | "aliasColors": {}, 138 | "bars": false, 139 | "dashLength": 10, 140 | "dashes": false, 141 | "datasource": "$datasource", 142 | "fill": 1, 143 | "gridPos": { 144 | "h": 9, 145 | "w": 12, 146 | "x": 12, 147 | "y": 1 148 | }, 149 | "id": 4, 150 | "legend": { 151 | "avg": false, 152 | "current": false, 153 | "max": false, 154 | "min": false, 155 | "show": true, 156 | "total": false, 157 | "values": false 158 | }, 159 | "lines": true, 160 | "linewidth": 1, 161 | "links": [], 162 | "nullPointMode": "null", 163 | "percentage": false, 164 | "pointradius": 5, 165 | "points": false, 166 | "renderer": "flot", 167 | "seriesOverrides": [], 168 | "spaceLength": 10, 169 | "stack": false, 170 | "steppedLine": false, 171 | "targets": [ 172 | { 173 | "expr": "ceph_mds_server_handle_client_request{ceph_daemon=~\"($mds_servers).*\"}", 174 | "format": "time_series", 175 | "intervalFactor": 1, 176 | "legendFormat": "{{ceph_daemon}}", 177 | "refId": "A" 178 | } 179 | ], 180 | "thresholds": [], 181 | "timeFrom": null, 182 | "timeShift": null, 183 | "title": "Client Request Load - $mds_servers", 184 | "tooltip": { 185 | "shared": true, 186 | "sort": 0, 187 | "value_type": "individual" 188 | }, 189 | "type": "graph", 190 | "xaxis": { 191 | "buckets": null, 192 | "mode": "time", 193 | "name": null, 194 | "show": true, 195 | "values": [] 196 | }, 197 | "yaxes": [ 198 | { 199 | "format": "none", 200 | "label": null, 201 | "logBase": 1, 202 | "max": null, 203 | "min": "0", 204 | "show": true 205 | }, 206 | { 207 | "format": "short", 208 | "label": null, 209 | "logBase": 1, 210 | "max": null, 211 | "min": null, 212 | "show": false 213 | } 214 | ] 215 | } 216 | ], 217 | "refresh": "15s", 218 | "schemaVersion": 16, 219 | "style": "dark", 220 | "tags": [], 221 | "templating": { 222 | "list": [ 223 | { 224 | "current": { 225 | "tags": [], 226 | "text": "default", 227 | "value": "default" 228 | }, 229 | "hide": 0, 230 | "label": "Data Source", 231 | "name": "datasource", 232 | "options": [], 233 | "query": "prometheus", 234 | "refresh": 1, 235 | "regex": "", 236 | "type": "datasource" 237 | }, 238 | { 239 | "allValue": null, 240 | "current": {}, 241 | "datasource": "$datasource", 242 | "hide": 0, 243 | "includeAll": true, 244 | "label": "MDS Server", 245 | "multi": false, 246 | "name": "mds_servers", 247 | "options": [], 248 | "query": "label_values(ceph_mds_inodes, ceph_daemon)", 249 | "refresh": 1, 250 | "regex": "", 251 | "sort": 0, 252 | "tagValuesQuery": "", 253 | "tags": [], 254 | "tagsQuery": "", 255 | "type": "query", 256 | "useTags": false 257 | } 258 | ] 259 | }, 260 | "time": { 261 | "from": "now-1h", 262 | "to": "now" 263 | }, 264 | "timepicker": { 265 | "refresh_intervals": [ 266 | "5s", 267 | "10s", 268 | "15s", 269 | "30s", 270 | "1m", 271 | "5m", 272 | "15m", 273 | "30m", 274 | "1h", 275 | "2h", 276 | "1d" 277 | ], 278 | "time_options": [ 279 | "5m", 280 | "15m", 281 | "1h", 282 | "6h", 283 | "12h", 284 | "24h", 285 | "2d", 286 | "7d", 287 | "30d" 288 | ] 289 | }, 290 | "timezone": "", 291 | "title": "MDS Performance", 292 | "uid": "rRfFzWtik", 293 | "version": 2 294 | } 295 | -------------------------------------------------------------------------------- /Dashboards/pool-detail.json: -------------------------------------------------------------------------------- 1 | { 2 | "__requires": [ 3 | { 4 | "type": "grafana", 5 | "id": "grafana", 6 | "name": "Grafana", 7 | "version": "5.0.0" 8 | }, 9 | { 10 | "type": "panel", 11 | "id": "graph", 12 | "name": "Graph", 13 | "version": "5.0.0" 14 | }, 15 | { 16 | "type": "panel", 17 | "id": "text", 18 | "name": "Text", 19 | "version": "5.0.0" 20 | } 21 | ], 22 | "annotations": { 23 | "list": [ 24 | { 25 | "builtIn": 1, 26 | "datasource": "-- Grafana --", 27 | "enable": true, 28 | "hide": true, 29 | "iconColor": "rgba(0, 211, 255, 1)", 30 | "name": "Annotations & Alerts", 31 | "type": "dashboard" 32 | } 33 | ] 34 | }, 35 | "editable": false, 36 | "gnetId": null, 37 | "graphTooltip": 0, 38 | "id": null, 39 | "iteration": 1534394258671, 40 | "links": [], 41 | "panels": [ 42 | { 43 | "collapsed": false, 44 | "gridPos": { 45 | "h": 1, 46 | "w": 24, 47 | "x": 0, 48 | "y": 0 49 | }, 50 | "id": 16, 51 | "panels": [], 52 | "repeat": null, 53 | "title": "Pool '$pool_name' Performance Details", 54 | "type": "row" 55 | }, 56 | { 57 | "aliasColors": { 58 | "read_op_per_sec": "#3F6833", 59 | "write_op_per_sec": "#E5AC0E" 60 | }, 61 | "bars": false, 62 | "dashLength": 10, 63 | "dashes": false, 64 | "datasource": "$datasource", 65 | "fill": 1, 66 | "gridPos": { 67 | "h": 7, 68 | "w": 12, 69 | "x": 0, 70 | "y": 1 71 | }, 72 | "id": 6, 73 | "legend": { 74 | "avg": false, 75 | "current": false, 76 | "max": false, 77 | "min": false, 78 | "show": true, 79 | "total": false, 80 | "values": false 81 | }, 82 | "lines": true, 83 | "linewidth": 1, 84 | "links": [], 85 | "minSpan": 12, 86 | "nullPointMode": "null as zero", 87 | "percentage": false, 88 | "pointradius": 5, 89 | "points": false, 90 | "renderer": "flot", 91 | "seriesOverrides": [], 92 | "spaceLength": 10, 93 | "stack": true, 94 | "steppedLine": false, 95 | "targets": [ 96 | { 97 | "expr": "(label_replace(irate(ceph_pool_rd[1m]),\"id\",\"$1\",\"pool_id\",\"(.*)\") * on(pool_id) group_left(instance,name) ceph_pool_metadata{name=~\"[[pool_name]]\"})", 98 | "format": "time_series", 99 | "intervalFactor": 1, 100 | "legendFormat": "reads", 101 | "refId": "B" 102 | }, 103 | { 104 | "expr": "(label_replace(irate(ceph_pool_wr[1m]),\"id\",\"$1\",\"pool_id\",\"(.*)\") * on(pool_id) group_left(instance,name) ceph_pool_metadata{name=~\"[[pool_name]]\"})", 105 | "format": "time_series", 106 | "intervalFactor": 1, 107 | "legendFormat": "writes", 108 | "refId": "C" 109 | } 110 | ], 111 | "thresholds": [], 112 | "timeFrom": null, 113 | "timeShift": null, 114 | "title": "Pool '$pool_name' Client IOPS", 115 | "tooltip": { 116 | "shared": true, 117 | "sort": 0, 118 | "value_type": "individual" 119 | }, 120 | "type": "graph", 121 | "xaxis": { 122 | "buckets": null, 123 | "mode": "time", 124 | "name": null, 125 | "show": true, 126 | "values": [] 127 | }, 128 | "yaxes": [ 129 | { 130 | "format": "none", 131 | "label": "", 132 | "logBase": 1, 133 | "max": null, 134 | "min": "0", 135 | "show": true 136 | }, 137 | { 138 | "format": "short", 139 | "label": null, 140 | "logBase": 1, 141 | "max": null, 142 | "min": null, 143 | "show": true 144 | } 145 | ] 146 | }, 147 | { 148 | "aliasColors": { 149 | "read_op_per_sec": "#3F6833", 150 | "write_op_per_sec": "#E5AC0E" 151 | }, 152 | "bars": false, 153 | "dashLength": 10, 154 | "dashes": false, 155 | "datasource": "$datasource", 156 | "fill": 1, 157 | "gridPos": { 158 | "h": 7, 159 | "w": 12, 160 | "x": 12, 161 | "y": 1 162 | }, 163 | "id": 7, 164 | "legend": { 165 | "avg": false, 166 | "current": false, 167 | "max": false, 168 | "min": false, 169 | "show": true, 170 | "total": false, 171 | "values": false 172 | }, 173 | "lines": true, 174 | "linewidth": 1, 175 | "links": [], 176 | "minSpan": 12, 177 | "nullPointMode": "null as zero", 178 | "percentage": false, 179 | "pointradius": 5, 180 | "points": false, 181 | "renderer": "flot", 182 | "seriesOverrides": [], 183 | "spaceLength": 10, 184 | "stack": true, 185 | "steppedLine": false, 186 | "targets": [ 187 | { 188 | "expr": "(label_replace(irate(ceph_pool_rd_bytes[1m]),\"id\",\"$1\",\"pool_id\",\"(.*)\") + on(pool_id) group_left(instance,name) ceph_pool_metadata{name=~\"[[pool_name]]\"})", 189 | "format": "time_series", 190 | "intervalFactor": 1, 191 | "legendFormat": "reads", 192 | "refId": "A" 193 | }, 194 | { 195 | "expr": "(label_replace(irate(ceph_pool_wr_bytes[1m]),\"id\",\"$1\",\"pool_id\",\"(.*)\") + on(pool_id) group_left(instance,name) ceph_pool_metadata{name=~\"[[pool_name]]\"})", 196 | "format": "time_series", 197 | "intervalFactor": 1, 198 | "legendFormat": "writes", 199 | "refId": "C" 200 | } 201 | ], 202 | "thresholds": [], 203 | "timeFrom": null, 204 | "timeShift": null, 205 | "title": "Pool '$pool_name' Client Throughput", 206 | "tooltip": { 207 | "shared": true, 208 | "sort": 0, 209 | "value_type": "individual" 210 | }, 211 | "type": "graph", 212 | "xaxis": { 213 | "buckets": null, 214 | "mode": "time", 215 | "name": null, 216 | "show": true, 217 | "values": [] 218 | }, 219 | "yaxes": [ 220 | { 221 | "format": "decbytes", 222 | "label": "", 223 | "logBase": 1, 224 | "max": null, 225 | "min": "0", 226 | "show": true 227 | }, 228 | { 229 | "format": "short", 230 | "label": null, 231 | "logBase": 1, 232 | "max": null, 233 | "min": null, 234 | "show": false 235 | } 236 | ] 237 | } 238 | ], 239 | "refresh": "15s", 240 | "schemaVersion": 16, 241 | "style": "dark", 242 | "tags": [], 243 | "templating": { 244 | "list": [ 245 | { 246 | "allValue": null, 247 | "current": {}, 248 | "datasource": "$datasource", 249 | "hide": 2, 250 | "includeAll": true, 251 | "label": null, 252 | "multi": false, 253 | "name": "pool_id", 254 | "options": [], 255 | "query": "label_values(ceph_pool_metadata,pool_id)", 256 | "refresh": 1, 257 | "regex": "", 258 | "sort": 1, 259 | "tagValuesQuery": "", 260 | "tags": [], 261 | "tagsQuery": "", 262 | "type": "query", 263 | "useTags": false 264 | }, 265 | { 266 | "current": { 267 | "tags": [], 268 | "text": "default", 269 | "value": "default" 270 | }, 271 | "hide": 0, 272 | "label": "Data Source", 273 | "name": "datasource", 274 | "options": [], 275 | "query": "prometheus", 276 | "refresh": 1, 277 | "regex": "", 278 | "type": "datasource" 279 | }, 280 | { 281 | "allValue": null, 282 | "current": {}, 283 | "datasource": "$datasource", 284 | "hide": 0, 285 | "includeAll": false, 286 | "label": "Pool Name", 287 | "multi": false, 288 | "name": "pool_name", 289 | "options": [], 290 | "query": "label_values(ceph_pool_metadata,name)", 291 | "refresh": 1, 292 | "regex": "", 293 | "sort": 1, 294 | "tagValuesQuery": "", 295 | "tags": [], 296 | "tagsQuery": "", 297 | "type": "query", 298 | "useTags": false 299 | } 300 | ] 301 | }, 302 | "time": { 303 | "from": "now-1h", 304 | "to": "now" 305 | }, 306 | "timepicker": { 307 | "refresh_intervals": [ 308 | "5s", 309 | "10s", 310 | "15s", 311 | "30s", 312 | "1m", 313 | "5m", 314 | "15m", 315 | "30m", 316 | "1h", 317 | "2h", 318 | "1d" 319 | ], 320 | "time_options": [ 321 | "5m", 322 | "15m", 323 | "1h", 324 | "6h", 325 | "12h", 326 | "24h", 327 | "2d", 328 | "7d", 329 | "30d" 330 | ] 331 | }, 332 | "timezone": "browser", 333 | "title": "Ceph Pool Detail", 334 | "uid": "8ypfkWpik", 335 | "version": 11 336 | } 337 | -------------------------------------------------------------------------------- /Dashboards/radosgw-detail.json: -------------------------------------------------------------------------------- 1 | { 2 | "__requires": [ 3 | { 4 | "type": "grafana", 5 | "id": "grafana", 6 | "name": "Grafana", 7 | "version": "5.0.0" 8 | }, 9 | { 10 | "type": "panel", 11 | "id": "grafana-piechart-panel", 12 | "name": "Pie Chart", 13 | "version": "1.3.3" 14 | }, 15 | { 16 | "type": "panel", 17 | "id": "graph", 18 | "name": "Graph", 19 | "version": "5.0.0" 20 | } 21 | ], 22 | "annotations": { 23 | "list": [ 24 | { 25 | "builtIn": 1, 26 | "datasource": "-- Grafana --", 27 | "enable": true, 28 | "hide": true, 29 | "iconColor": "rgba(0, 211, 255, 1)", 30 | "name": "Annotations & Alerts", 31 | "type": "dashboard" 32 | } 33 | ] 34 | }, 35 | "editable": false, 36 | "gnetId": null, 37 | "graphTooltip": 0, 38 | "id": null, 39 | "iteration": 1534386250869, 40 | "links": [], 41 | "panels": [ 42 | { 43 | "collapsed": false, 44 | "gridPos": { 45 | "h": 1, 46 | "w": 24, 47 | "x": 0, 48 | "y": 0 49 | }, 50 | "id": 12, 51 | "panels": [], 52 | "repeat": null, 53 | "title": "RGW Host Detail : $rgw_servers", 54 | "type": "row" 55 | }, 56 | { 57 | "aliasColors": {}, 58 | "bars": false, 59 | "dashLength": 10, 60 | "dashes": false, 61 | "datasource": "$datasource", 62 | "fill": 1, 63 | "gridPos": { 64 | "h": 8, 65 | "w": 6, 66 | "x": 0, 67 | "y": 1 68 | }, 69 | "id": 34, 70 | "legend": { 71 | "avg": false, 72 | "current": false, 73 | "max": false, 74 | "min": false, 75 | "show": true, 76 | "total": false, 77 | "values": false 78 | }, 79 | "lines": true, 80 | "linewidth": 1, 81 | "links": [], 82 | "nullPointMode": "null", 83 | "percentage": false, 84 | "pointradius": 5, 85 | "points": false, 86 | "renderer": "flot", 87 | "seriesOverrides": [], 88 | "spaceLength": 10, 89 | "stack": false, 90 | "steppedLine": false, 91 | "targets": [ 92 | { 93 | "expr": "rate(ceph_rgw_get_initial_lat_sum{ceph_daemon=~\"($rgw_servers)\"}[30s]) / rate(ceph_rgw_get_initial_lat_count{ceph_daemon=~\"($rgw_servers)\"}[30s])", 94 | "format": "time_series", 95 | "intervalFactor": 1, 96 | "legendFormat": "GET", 97 | "refId": "A" 98 | }, 99 | { 100 | "expr": "rate(ceph_rgw_put_initial_lat_sum{ceph_daemon=~\"($rgw_servers)\"}[30s]) / rate(ceph_rgw_put_initial_lat_count{ceph_daemon=~\"($rgw_servers)\"}[30s])", 101 | "format": "time_series", 102 | "intervalFactor": 1, 103 | "legendFormat": "PUT", 104 | "refId": "B" 105 | } 106 | ], 107 | "thresholds": [], 108 | "timeFrom": null, 109 | "timeShift": null, 110 | "title": "$rgw_servers GET/PUT Latencies", 111 | "tooltip": { 112 | "shared": true, 113 | "sort": 0, 114 | "value_type": "individual" 115 | }, 116 | "type": "graph", 117 | "xaxis": { 118 | "buckets": null, 119 | "mode": "time", 120 | "name": null, 121 | "show": true, 122 | "values": [] 123 | }, 124 | "yaxes": [ 125 | { 126 | "format": "s", 127 | "label": null, 128 | "logBase": 1, 129 | "max": null, 130 | "min": "0", 131 | "show": true 132 | }, 133 | { 134 | "format": "short", 135 | "label": null, 136 | "logBase": 1, 137 | "max": null, 138 | "min": null, 139 | "show": false 140 | } 141 | ] 142 | }, 143 | { 144 | "aliasColors": {}, 145 | "bars": false, 146 | "dashLength": 10, 147 | "dashes": false, 148 | "datasource": "$datasource", 149 | "fill": 1, 150 | "gridPos": { 151 | "h": 8, 152 | "w": 7, 153 | "x": 6, 154 | "y": 1 155 | }, 156 | "id": 18, 157 | "legend": { 158 | "avg": false, 159 | "current": false, 160 | "max": false, 161 | "min": false, 162 | "show": true, 163 | "total": false, 164 | "values": false 165 | }, 166 | "lines": true, 167 | "linewidth": 1, 168 | "links": [], 169 | "nullPointMode": "null", 170 | "percentage": false, 171 | "pointradius": 5, 172 | "points": false, 173 | "renderer": "flot", 174 | "seriesOverrides": [], 175 | "spaceLength": 10, 176 | "stack": true, 177 | "steppedLine": false, 178 | "targets": [ 179 | { 180 | "expr": "rate(ceph_rgw_get_b{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 181 | "format": "time_series", 182 | "intervalFactor": 1, 183 | "legendFormat": "GETs", 184 | "refId": "B" 185 | }, 186 | { 187 | "expr": "rate(ceph_rgw_put_b{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 188 | "format": "time_series", 189 | "intervalFactor": 1, 190 | "legendFormat": "PUTs", 191 | "refId": "A" 192 | } 193 | ], 194 | "thresholds": [], 195 | "timeFrom": null, 196 | "timeShift": null, 197 | "title": "Bandwidth by HTTP Operation", 198 | "tooltip": { 199 | "shared": true, 200 | "sort": 0, 201 | "value_type": "individual" 202 | }, 203 | "type": "graph", 204 | "xaxis": { 205 | "buckets": null, 206 | "mode": "time", 207 | "name": null, 208 | "show": true, 209 | "values": [] 210 | }, 211 | "yaxes": [ 212 | { 213 | "decimals": 0, 214 | "format": "bytes", 215 | "label": "", 216 | "logBase": 1, 217 | "max": null, 218 | "min": "0", 219 | "show": true 220 | }, 221 | { 222 | "format": "short", 223 | "label": null, 224 | "logBase": 1, 225 | "max": null, 226 | "min": null, 227 | "show": false 228 | } 229 | ] 230 | }, 231 | { 232 | "aliasColors": { 233 | "GETs": "#7eb26d", 234 | "Other": "#447ebc", 235 | "PUTs": "#eab839", 236 | "Requests": "#3f2b5b", 237 | "Requests Failed": "#bf1b00" 238 | }, 239 | "bars": false, 240 | "dashLength": 10, 241 | "dashes": false, 242 | "datasource": "$datasource", 243 | "fill": 1, 244 | "gridPos": { 245 | "h": 8, 246 | "w": 7, 247 | "x": 13, 248 | "y": 1 249 | }, 250 | "id": 14, 251 | "legend": { 252 | "avg": false, 253 | "current": false, 254 | "max": false, 255 | "min": false, 256 | "show": true, 257 | "total": false, 258 | "values": false 259 | }, 260 | "lines": true, 261 | "linewidth": 1, 262 | "links": [], 263 | "nullPointMode": "null", 264 | "percentage": false, 265 | "pointradius": 5, 266 | "points": false, 267 | "renderer": "flot", 268 | "seriesOverrides": [], 269 | "spaceLength": 10, 270 | "stack": true, 271 | "steppedLine": false, 272 | "targets": [ 273 | { 274 | "expr": "rate(ceph_rgw_failed_req{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 275 | "format": "time_series", 276 | "intervalFactor": 1, 277 | "legendFormat": "Requests Failed", 278 | "refId": "B" 279 | }, 280 | { 281 | "expr": "rate(ceph_rgw_get{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 282 | "format": "time_series", 283 | "intervalFactor": 1, 284 | "legendFormat": "GETs", 285 | "refId": "C" 286 | }, 287 | { 288 | "expr": "rate(ceph_rgw_put{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 289 | "format": "time_series", 290 | "intervalFactor": 1, 291 | "legendFormat": "PUTs", 292 | "refId": "D" 293 | }, 294 | { 295 | "expr": "rate(ceph_rgw_req{ceph_daemon=~\"[[rgw_servers]]\"}[30s]) -\n (rate(ceph_rgw_get{ceph_daemon=~\"[[rgw_servers]]\"}[30s]) +\n rate(ceph_rgw_put{ceph_daemon=~\"[[rgw_servers]]\"}[30s]))", 296 | "format": "time_series", 297 | "intervalFactor": 1, 298 | "legendFormat": "Other", 299 | "refId": "A" 300 | } 301 | ], 302 | "thresholds": [], 303 | "timeFrom": null, 304 | "timeShift": null, 305 | "title": "HTTP Request Breakdown", 306 | "tooltip": { 307 | "shared": true, 308 | "sort": 0, 309 | "value_type": "individual" 310 | }, 311 | "type": "graph", 312 | "xaxis": { 313 | "buckets": null, 314 | "mode": "time", 315 | "name": null, 316 | "show": true, 317 | "values": [] 318 | }, 319 | "yaxes": [ 320 | { 321 | "format": "short", 322 | "label": null, 323 | "logBase": 1, 324 | "max": null, 325 | "min": null, 326 | "show": true 327 | }, 328 | { 329 | "format": "short", 330 | "label": null, 331 | "logBase": 1, 332 | "max": null, 333 | "min": null, 334 | "show": true 335 | } 336 | ] 337 | }, 338 | { 339 | "aliasColors": { 340 | "Failures": "#bf1b00", 341 | "GETs": "#7eb26d", 342 | "Other (HEAD,POST,DELETE)": "#447ebc", 343 | "PUTs": "#eab839" 344 | }, 345 | "breakPoint": "50%", 346 | "cacheTimeout": null, 347 | "combine": { 348 | "label": "Others", 349 | "threshold": 0 350 | }, 351 | "datasource": "$datasource", 352 | "fontSize": "80%", 353 | "format": "none", 354 | "gridPos": { 355 | "h": 8, 356 | "w": 4, 357 | "x": 20, 358 | "y": 1 359 | }, 360 | "id": 23, 361 | "interval": null, 362 | "legend": { 363 | "show": true, 364 | "values": true 365 | }, 366 | "legendType": "Under graph", 367 | "links": [], 368 | "maxDataPoints": 3, 369 | "nullPointMode": "connected", 370 | "pieType": "pie", 371 | "strokeWidth": 1, 372 | "targets": [ 373 | { 374 | "expr": "rate(ceph_rgw_failed_req{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 375 | "format": "time_series", 376 | "intervalFactor": 1, 377 | "legendFormat": "Failures", 378 | "refId": "A" 379 | }, 380 | { 381 | "expr": "rate(ceph_rgw_get{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 382 | "format": "time_series", 383 | "intervalFactor": 1, 384 | "legendFormat": "GETs", 385 | "refId": "B" 386 | }, 387 | { 388 | "expr": "rate(ceph_rgw_put{ceph_daemon=~\"[[rgw_servers]]\"}[30s])", 389 | "format": "time_series", 390 | "intervalFactor": 1, 391 | "legendFormat": "PUTs", 392 | "refId": "C" 393 | }, 394 | { 395 | "expr": "rate(ceph_rgw_req{ceph_daemon=~\"[[rgw_servers]]\"}[30s]) -\n (rate(ceph_rgw_get{ceph_daemon=~\"[[rgw_servers]]\"}[30s]) +\n rate(ceph_rgw_put{ceph_daemon=~\"[[rgw_servers]]\"}[30s]))", 396 | "format": "time_series", 397 | "intervalFactor": 1, 398 | "legendFormat": "Other (DELETE,LIST)", 399 | "refId": "D" 400 | } 401 | ], 402 | "title": "Workload Breakdown", 403 | "type": "grafana-piechart-panel", 404 | "valueName": "current" 405 | } 406 | ], 407 | "refresh": "15s", 408 | "schemaVersion": 16, 409 | "style": "dark", 410 | "tags": [ 411 | "overview" 412 | ], 413 | "templating": { 414 | "list": [ 415 | { 416 | "current": { 417 | "tags": [], 418 | "text": "default", 419 | "value": "default" 420 | }, 421 | "hide": 0, 422 | "label": "Data Source", 423 | "name": "datasource", 424 | "options": [], 425 | "query": "prometheus", 426 | "refresh": 1, 427 | "regex": "", 428 | "type": "datasource" 429 | }, 430 | { 431 | "allValue": null, 432 | "current": {}, 433 | "datasource": "$datasource", 434 | "hide": 0, 435 | "includeAll": true, 436 | "label": null, 437 | "multi": false, 438 | "name": "rgw_servers", 439 | "options": [], 440 | "query": "label_values(ceph_rgw_req, ceph_daemon)", 441 | "refresh": 1, 442 | "regex": "", 443 | "sort": 1, 444 | "tagValuesQuery": "", 445 | "tags": [], 446 | "tagsQuery": "", 447 | "type": "query", 448 | "useTags": false 449 | } 450 | ] 451 | }, 452 | "time": { 453 | "from": "now-1h", 454 | "to": "now" 455 | }, 456 | "timepicker": { 457 | "refresh_intervals": [ 458 | "5s", 459 | "10s", 460 | "15s", 461 | "30s", 462 | "1m", 463 | "5m", 464 | "15m", 465 | "30m", 466 | "1h", 467 | "2h", 468 | "1d" 469 | ], 470 | "time_options": [ 471 | "5m", 472 | "15m", 473 | "1h", 474 | "6h", 475 | "12h", 476 | "24h", 477 | "2d", 478 | "7d", 479 | "30d" 480 | ] 481 | }, 482 | "timezone": "", 483 | "title": "RGW Instance Detail", 484 | "uid": "x5ARzZtmk", 485 | "version": 2 486 | } 487 | -------------------------------------------------------------------------------- /Dashboards/radosgw-overview.json: -------------------------------------------------------------------------------- 1 | { 2 | "__requires": [ 3 | { 4 | "type": "grafana", 5 | "id": "grafana", 6 | "name": "Grafana", 7 | "version": "5.0.0" 8 | }, 9 | { 10 | "type": "panel", 11 | "id": "graph", 12 | "name": "Graph", 13 | "version": "5.0.0" 14 | } 15 | ], 16 | "annotations": { 17 | "list": [ 18 | { 19 | "builtIn": 1, 20 | "datasource": "-- Grafana --", 21 | "enable": true, 22 | "hide": true, 23 | "iconColor": "rgba(0, 211, 255, 1)", 24 | "name": "Annotations & Alerts", 25 | "type": "dashboard" 26 | } 27 | ] 28 | }, 29 | "editable": false, 30 | "gnetId": null, 31 | "graphTooltip": 0, 32 | "id": null, 33 | "iteration": 1534386107523, 34 | "links": [], 35 | "panels": [ 36 | { 37 | "collapsed": false, 38 | "gridPos": { 39 | "h": 1, 40 | "w": 24, 41 | "x": 0, 42 | "y": 0 43 | }, 44 | "id": 2, 45 | "panels": [], 46 | "title": "RGW Overview - All Gateways", 47 | "type": "row" 48 | }, 49 | { 50 | "aliasColors": {}, 51 | "bars": false, 52 | "dashLength": 10, 53 | "dashes": false, 54 | "datasource": "$datasource", 55 | "fill": 1, 56 | "gridPos": { 57 | "h": 7, 58 | "w": 8, 59 | "x": 0, 60 | "y": 1 61 | }, 62 | "id": 29, 63 | "legend": { 64 | "avg": false, 65 | "current": false, 66 | "max": false, 67 | "min": false, 68 | "show": true, 69 | "total": false, 70 | "values": false 71 | }, 72 | "lines": true, 73 | "linewidth": 1, 74 | "links": [], 75 | "nullPointMode": "null", 76 | "percentage": false, 77 | "pointradius": 5, 78 | "points": false, 79 | "renderer": "flot", 80 | "seriesOverrides": [], 81 | "spaceLength": 10, 82 | "stack": false, 83 | "steppedLine": false, 84 | "targets": [ 85 | { 86 | "expr": "avg(rate(ceph_rgw_get_initial_lat_sum[30s]) / rate(ceph_rgw_get_initial_lat_count[30s]))", 87 | "format": "time_series", 88 | "intervalFactor": 1, 89 | "legendFormat": "GET AVG", 90 | "refId": "A" 91 | }, 92 | { 93 | "expr": "avg(rate(ceph_rgw_put_initial_lat_sum[30s]) / rate(ceph_rgw_put_initial_lat_count[30s]))", 94 | "format": "time_series", 95 | "intervalFactor": 1, 96 | "legendFormat": "PUT AVG", 97 | "refId": "B" 98 | } 99 | ], 100 | "thresholds": [], 101 | "timeFrom": null, 102 | "timeShift": null, 103 | "title": "Average GET/PUT Latencies", 104 | "tooltip": { 105 | "shared": true, 106 | "sort": 0, 107 | "value_type": "individual" 108 | }, 109 | "type": "graph", 110 | "xaxis": { 111 | "buckets": null, 112 | "mode": "time", 113 | "name": null, 114 | "show": true, 115 | "values": [] 116 | }, 117 | "yaxes": [ 118 | { 119 | "format": "s", 120 | "label": null, 121 | "logBase": 1, 122 | "max": null, 123 | "min": "0", 124 | "show": true 125 | }, 126 | { 127 | "format": "short", 128 | "label": null, 129 | "logBase": 1, 130 | "max": null, 131 | "min": null, 132 | "show": false 133 | } 134 | ] 135 | }, 136 | { 137 | "aliasColors": {}, 138 | "bars": false, 139 | "dashLength": 10, 140 | "dashes": false, 141 | "datasource": "$datasource", 142 | "fill": 1, 143 | "gridPos": { 144 | "h": 7, 145 | "w": 7, 146 | "x": 8, 147 | "y": 1 148 | }, 149 | "id": 4, 150 | "legend": { 151 | "avg": false, 152 | "current": false, 153 | "max": false, 154 | "min": false, 155 | "show": true, 156 | "total": false, 157 | "values": false 158 | }, 159 | "lines": true, 160 | "linewidth": 1, 161 | "links": [], 162 | "nullPointMode": "null", 163 | "percentage": false, 164 | "pointradius": 5, 165 | "points": false, 166 | "renderer": "flot", 167 | "seriesOverrides": [], 168 | "spaceLength": 10, 169 | "stack": true, 170 | "steppedLine": false, 171 | "targets": [ 172 | { 173 | "expr": "sum by(rgw_host) (label_replace(rate(ceph_rgw_req[30s]), \"rgw_host\", \"$1\", \"ceph_daemon\", \"rgw.(.*)\"))", 174 | "format": "time_series", 175 | "intervalFactor": 1, 176 | "legendFormat": "{{rgw_host}}", 177 | "refId": "A" 178 | } 179 | ], 180 | "thresholds": [], 181 | "timeFrom": null, 182 | "timeShift": null, 183 | "title": "Total Requests/sec by RGW Instance", 184 | "tooltip": { 185 | "shared": true, 186 | "sort": 0, 187 | "value_type": "individual" 188 | }, 189 | "type": "graph", 190 | "xaxis": { 191 | "buckets": null, 192 | "mode": "time", 193 | "name": null, 194 | "show": true, 195 | "values": [] 196 | }, 197 | "yaxes": [ 198 | { 199 | "decimals": 0, 200 | "format": "none", 201 | "label": null, 202 | "logBase": 1, 203 | "max": null, 204 | "min": "0", 205 | "show": true 206 | }, 207 | { 208 | "format": "short", 209 | "label": null, 210 | "logBase": 1, 211 | "max": null, 212 | "min": null, 213 | "show": true 214 | } 215 | ] 216 | }, 217 | { 218 | "aliasColors": {}, 219 | "bars": false, 220 | "dashLength": 10, 221 | "dashes": false, 222 | "datasource": "$datasource", 223 | "description": "Latencies are shown stacked, without a yaxis to provide a visual indication of GET latency imbalance across RGW hosts", 224 | "fill": 1, 225 | "gridPos": { 226 | "h": 7, 227 | "w": 6, 228 | "x": 15, 229 | "y": 1 230 | }, 231 | "id": 31, 232 | "legend": { 233 | "avg": false, 234 | "current": false, 235 | "max": false, 236 | "min": false, 237 | "show": true, 238 | "total": false, 239 | "values": false 240 | }, 241 | "lines": true, 242 | "linewidth": 1, 243 | "links": [], 244 | "nullPointMode": "null", 245 | "percentage": false, 246 | "pointradius": 5, 247 | "points": false, 248 | "renderer": "flot", 249 | "seriesOverrides": [], 250 | "spaceLength": 10, 251 | "stack": true, 252 | "steppedLine": false, 253 | "targets": [ 254 | { 255 | "expr": "label_replace(rate(ceph_rgw_get_initial_lat_sum[30s]),\"rgw_host\",\"$1\",\"ceph_daemon\",\"rgw.(.*)\") / \nlabel_replace(rate(ceph_rgw_get_initial_lat_count[30s]),\"rgw_host\",\"$1\",\"ceph_daemon\",\"rgw.(.*)\")", 256 | "format": "time_series", 257 | "intervalFactor": 1, 258 | "legendFormat": "{{rgw_host}}", 259 | "refId": "A" 260 | } 261 | ], 262 | "thresholds": [], 263 | "timeFrom": null, 264 | "timeShift": null, 265 | "title": "GET Latencies by RGW Instance", 266 | "tooltip": { 267 | "shared": true, 268 | "sort": 0, 269 | "value_type": "individual" 270 | }, 271 | "type": "graph", 272 | "xaxis": { 273 | "buckets": null, 274 | "mode": "time", 275 | "name": null, 276 | "show": true, 277 | "values": [] 278 | }, 279 | "yaxes": [ 280 | { 281 | "decimals": null, 282 | "format": "s", 283 | "label": null, 284 | "logBase": 1, 285 | "max": null, 286 | "min": "0", 287 | "show": false 288 | }, 289 | { 290 | "format": "short", 291 | "label": null, 292 | "logBase": 1, 293 | "max": null, 294 | "min": null, 295 | "show": false 296 | } 297 | ] 298 | }, 299 | { 300 | "aliasColors": {}, 301 | "bars": false, 302 | "dashLength": 10, 303 | "dashes": false, 304 | "datasource": "$datasource", 305 | "description": "Total bytes transferred in/out of all radosgw instances within the cluster", 306 | "fill": 1, 307 | "gridPos": { 308 | "h": 6, 309 | "w": 8, 310 | "x": 0, 311 | "y": 8 312 | }, 313 | "id": 6, 314 | "legend": { 315 | "avg": false, 316 | "current": false, 317 | "max": false, 318 | "min": false, 319 | "show": true, 320 | "total": false, 321 | "values": false 322 | }, 323 | "lines": true, 324 | "linewidth": 1, 325 | "links": [], 326 | "nullPointMode": "null", 327 | "percentage": false, 328 | "pointradius": 5, 329 | "points": false, 330 | "renderer": "flot", 331 | "seriesOverrides": [], 332 | "spaceLength": 10, 333 | "stack": true, 334 | "steppedLine": false, 335 | "targets": [ 336 | { 337 | "expr": "sum(rate(ceph_rgw_get_b[30s]))", 338 | "format": "time_series", 339 | "intervalFactor": 1, 340 | "legendFormat": "GETs", 341 | "refId": "A" 342 | }, 343 | { 344 | "expr": "sum(rate(ceph_rgw_put_b[30s]))", 345 | "format": "time_series", 346 | "intervalFactor": 1, 347 | "legendFormat": "PUTs", 348 | "refId": "B" 349 | } 350 | ], 351 | "thresholds": [], 352 | "timeFrom": null, 353 | "timeShift": null, 354 | "title": "Bandwidth Consumed by Type", 355 | "tooltip": { 356 | "shared": true, 357 | "sort": 0, 358 | "value_type": "individual" 359 | }, 360 | "type": "graph", 361 | "xaxis": { 362 | "buckets": null, 363 | "mode": "time", 364 | "name": null, 365 | "show": true, 366 | "values": [] 367 | }, 368 | "yaxes": [ 369 | { 370 | "format": "bytes", 371 | "label": null, 372 | "logBase": 1, 373 | "max": null, 374 | "min": "0", 375 | "show": true 376 | }, 377 | { 378 | "format": "short", 379 | "label": null, 380 | "logBase": 1, 381 | "max": null, 382 | "min": null, 383 | "show": true 384 | } 385 | ] 386 | }, 387 | { 388 | "aliasColors": {}, 389 | "bars": false, 390 | "dashLength": 10, 391 | "dashes": false, 392 | "datasource": "$datasource", 393 | "description": "Total bytes transferred in/out through get/put operations, by radosgw instance", 394 | "fill": 1, 395 | "gridPos": { 396 | "h": 6, 397 | "w": 7, 398 | "x": 8, 399 | "y": 8 400 | }, 401 | "id": 9, 402 | "legend": { 403 | "avg": false, 404 | "current": false, 405 | "max": false, 406 | "min": false, 407 | "show": true, 408 | "total": false, 409 | "values": false 410 | }, 411 | "lines": true, 412 | "linewidth": 1, 413 | "links": [], 414 | "nullPointMode": "null", 415 | "percentage": false, 416 | "pointradius": 5, 417 | "points": false, 418 | "renderer": "flot", 419 | "seriesOverrides": [], 420 | "spaceLength": 10, 421 | "stack": true, 422 | "steppedLine": false, 423 | "targets": [ 424 | { 425 | "expr": "sum by(rgw_host) (\n (label_replace(rate(ceph_rgw_get_b[30s]), \"rgw_host\",\"$1\",\"ceph_daemon\",\"rgw.(.*)\")) + \n (label_replace(rate(ceph_rgw_put_b[30s]), \"rgw_host\",\"$1\",\"ceph_daemon\",\"rgw.(.*)\"))\n)", 426 | "format": "time_series", 427 | "intervalFactor": 1, 428 | "legendFormat": "{{rgw_host}}", 429 | "refId": "A" 430 | } 431 | ], 432 | "thresholds": [], 433 | "timeFrom": null, 434 | "timeShift": null, 435 | "title": "Bandwidth by RGW Instance", 436 | "tooltip": { 437 | "shared": true, 438 | "sort": 0, 439 | "value_type": "individual" 440 | }, 441 | "type": "graph", 442 | "xaxis": { 443 | "buckets": null, 444 | "mode": "time", 445 | "name": null, 446 | "show": true, 447 | "values": [] 448 | }, 449 | "yaxes": [ 450 | { 451 | "format": "bytes", 452 | "label": null, 453 | "logBase": 1, 454 | "max": null, 455 | "min": "0", 456 | "show": true 457 | }, 458 | { 459 | "format": "short", 460 | "label": null, 461 | "logBase": 1, 462 | "max": null, 463 | "min": null, 464 | "show": true 465 | } 466 | ] 467 | }, 468 | { 469 | "aliasColors": {}, 470 | "bars": false, 471 | "dashLength": 10, 472 | "dashes": false, 473 | "datasource": "$datasource", 474 | "description": "Latencies are shown stacked, without a yaxis to provide a visual indication of PUT latency imbalance across RGW hosts", 475 | "fill": 1, 476 | "gridPos": { 477 | "h": 6, 478 | "w": 6, 479 | "x": 15, 480 | "y": 8 481 | }, 482 | "id": 32, 483 | "legend": { 484 | "avg": false, 485 | "current": false, 486 | "max": false, 487 | "min": false, 488 | "show": true, 489 | "total": false, 490 | "values": false 491 | }, 492 | "lines": true, 493 | "linewidth": 1, 494 | "links": [], 495 | "nullPointMode": "null", 496 | "percentage": false, 497 | "pointradius": 5, 498 | "points": false, 499 | "renderer": "flot", 500 | "seriesOverrides": [], 501 | "spaceLength": 10, 502 | "stack": true, 503 | "steppedLine": false, 504 | "targets": [ 505 | { 506 | "expr": "label_replace(rate(ceph_rgw_put_initial_lat_sum[30s]),\"rgw_host\",\"$1\",\"ceph_daemon\",\"rgw.(.*)\") / \nlabel_replace(rate(ceph_rgw_put_initial_lat_count[30s]),\"rgw_host\",\"$1\",\"ceph_daemon\",\"rgw.(.*)\")", 507 | "format": "time_series", 508 | "intervalFactor": 1, 509 | "legendFormat": "{{rgw_host}}", 510 | "refId": "A" 511 | } 512 | ], 513 | "thresholds": [], 514 | "timeFrom": null, 515 | "timeShift": null, 516 | "title": "PUT Latencies by RGW Instance", 517 | "tooltip": { 518 | "shared": true, 519 | "sort": 0, 520 | "value_type": "individual" 521 | }, 522 | "type": "graph", 523 | "xaxis": { 524 | "buckets": null, 525 | "mode": "time", 526 | "name": null, 527 | "show": true, 528 | "values": [] 529 | }, 530 | "yaxes": [ 531 | { 532 | "decimals": null, 533 | "format": "s", 534 | "label": null, 535 | "logBase": 1, 536 | "max": null, 537 | "min": "0", 538 | "show": false 539 | }, 540 | { 541 | "format": "short", 542 | "label": null, 543 | "logBase": 1, 544 | "max": null, 545 | "min": null, 546 | "show": false 547 | } 548 | ] 549 | } 550 | ], 551 | "refresh": "15s", 552 | "schemaVersion": 16, 553 | "style": "dark", 554 | "tags": [ 555 | "overview" 556 | ], 557 | "templating": { 558 | "list": [ 559 | { 560 | "allValue": null, 561 | "current": {}, 562 | "datasource": "$datasource", 563 | "hide": 2, 564 | "includeAll": true, 565 | "label": null, 566 | "multi": false, 567 | "name": "rgw_servers", 568 | "options": [], 569 | "query": "label_values(ceph_rgw_req, ceph_daemon)", 570 | "refresh": 1, 571 | "regex": "", 572 | "sort": 1, 573 | "tagValuesQuery": "", 574 | "tags": [], 575 | "tagsQuery": "", 576 | "type": "query", 577 | "useTags": false 578 | }, 579 | { 580 | "current": { 581 | "tags": [], 582 | "text": "default", 583 | "value": "default" 584 | }, 585 | "hide": 0, 586 | "label": "Data Source", 587 | "name": "datasource", 588 | "options": [], 589 | "query": "prometheus", 590 | "refresh": 1, 591 | "regex": "", 592 | "type": "datasource" 593 | } 594 | ] 595 | }, 596 | "time": { 597 | "from": "now-1h", 598 | "to": "now" 599 | }, 600 | "timepicker": { 601 | "refresh_intervals": [ 602 | "5s", 603 | "10s", 604 | "15s", 605 | "30s", 606 | "1m", 607 | "5m", 608 | "15m", 609 | "30m", 610 | "1h", 611 | "2h", 612 | "1d" 613 | ], 614 | "time_options": [ 615 | "5m", 616 | "15m", 617 | "1h", 618 | "6h", 619 | "12h", 620 | "24h", 621 | "2d", 622 | "7d", 623 | "30d" 624 | ] 625 | }, 626 | "timezone": "", 627 | "title": "RGW Overview", 628 | "uid": "WAkugZpiz", 629 | "version": 2 630 | } 631 | -------------------------------------------------------------------------------- /grafana/grafana.ini: -------------------------------------------------------------------------------- 1 | ##################### Grafana Configuration Example ##################### 2 | # 3 | # Everything has defaults so you only need to uncomment things you want to 4 | # change 5 | 6 | # possible values : production, development 7 | ;app_mode = production 8 | 9 | # instance name, defaults to HOSTNAME environment variable value or hostname if HOSTNAME var is empty 10 | ;instance_name = ${HOSTNAME} 11 | 12 | #################################### Paths #################################### 13 | [paths] 14 | # Path to where grafana can store temp files, sessions, and the sqlite3 db (if that is used) 15 | ;data = /var/lib/grafana 16 | 17 | # Temporary files in `data` directory older than given duration will be removed 18 | ;temp_data_lifetime = 24h 19 | 20 | # Directory where grafana can store logs 21 | ;logs = /var/log/grafana 22 | 23 | # Directory where grafana will automatically scan and look for plugins 24 | ;plugins = /var/lib/grafana/plugins 25 | 26 | # folder that contains provisioning config files that grafana will apply on startup and while running. 27 | ;provisioning = conf/provisioning 28 | 29 | #################################### Server #################################### 30 | [server] 31 | # Protocol (http, https, socket) 32 | ;protocol = http 33 | 34 | # The ip address to bind to, empty will bind to all interfaces 35 | ;http_addr = 36 | 37 | # The http port to use 38 | http_port = 3000 39 | 40 | # The public facing domain name used to access grafana from a browser 41 | ;domain = localhost 42 | 43 | # Redirect to correct domain if host header does not match domain 44 | # Prevents DNS rebinding attacks 45 | ;enforce_domain = false 46 | 47 | # The full public facing url you use in browser, used for redirects and emails 48 | # If you use reverse proxy and sub path specify full url (with sub path) 49 | ;root_url = http://localhost:3000 50 | 51 | # Log web requests 52 | ;router_logging = false 53 | 54 | # the path relative working path 55 | ;static_root_path = public 56 | 57 | # enable gzip 58 | ;enable_gzip = false 59 | 60 | # https certs & key file 61 | cert_file = /etc/grafana/grafana_ssl_cert.crt 62 | cert_key = /etc/grafana/grafana_ssl_cert.key 63 | 64 | # Unix socket path 65 | ;socket = 66 | 67 | #################################### Database #################################### 68 | [database] 69 | # You can configure the database connection by specifying type, host, name, user and password 70 | # as separate properties or as on string using the url properties. 71 | 72 | # Either "mysql", "postgres" or "sqlite3", it's your choice 73 | ;type = sqlite3 74 | ;host = 127.0.0.1:3306 75 | ;name = grafana 76 | ;user = root 77 | # If the password contains # or ; you have to wrap it with triple quotes. Ex """#password;""" 78 | ;password = 79 | 80 | # Use either URL or the previous fields to configure the database 81 | # Example: mysql://user:secret@host:port/database 82 | ;url = 83 | 84 | # For "postgres" only, either "disable", "require" or "verify-full" 85 | ;ssl_mode = disable 86 | 87 | # For "sqlite3" only, path relative to data_path setting 88 | ;path = grafana.db 89 | 90 | # Max idle conn setting default is 2 91 | ;max_idle_conn = 2 92 | 93 | # Max conn setting default is 0 (mean not set) 94 | ;max_open_conn = 95 | 96 | # Connection Max Lifetime default is 14400 (means 14400 seconds or 4 hours) 97 | ;conn_max_lifetime = 14400 98 | 99 | # Set to true to log the sql calls and execution times. 100 | log_queries = 101 | 102 | # For "sqlite3" only. cache mode setting used for connecting to the database. (private, shared) 103 | ;cache_mode = private 104 | 105 | #################################### Cache server ############################# 106 | [remote_cache] 107 | # Either "redis", "memcached" or "database" default is "database" 108 | ;type = database 109 | 110 | # cache connectionstring options 111 | # database: will use Grafana primary database. 112 | # redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=grafana` 113 | # memcache: 127.0.0.1:11211 114 | ;connstr = 115 | 116 | #################################### Data proxy ########################### 117 | [dataproxy] 118 | 119 | # This enables data proxy logging, default is false 120 | ;logging = false 121 | 122 | # How long the data proxy should wait before timing out default is 30 (seconds) 123 | ;timeout = 30 124 | 125 | # If enabled and user is not anonymous, data proxy will add X-Grafana-User header with username into the request, default is false. 126 | ;send_user_header = false 127 | 128 | #################################### Analytics #################################### 129 | [analytics] 130 | # Server reporting, sends usage counters to stats.grafana.org every 24 hours. 131 | # No ip addresses are being tracked, only simple counters to track 132 | # running instances, dashboard and error counts. It is very helpful to us. 133 | # Change this option to false to disable reporting. 134 | ;reporting_enabled = true 135 | 136 | # Set to false to disable all checks to https://grafana.net 137 | # for new vesions (grafana itself and plugins), check is used 138 | # in some UI views to notify that grafana or plugin update exists 139 | # This option does not cause any auto updates, nor send any information 140 | # only a GET request to http://grafana.com to get latest versions 141 | ;check_for_updates = true 142 | 143 | # Google Analytics universal tracking code, only enabled if you specify an id here 144 | ;google_analytics_ua_id = 145 | 146 | # Google Tag Manager ID, only enabled if you specify an id here 147 | ;google_tag_manager_id = 148 | 149 | #################################### Security #################################### 150 | [security] 151 | # default admin user, created on startup 152 | ;admin_user = admin 153 | 154 | # default admin password, can be changed before first start of grafana, or in profile settings 155 | ;admin_password = admin 156 | 157 | # used for signing 158 | ;secret_key = SW2YcwTIb9zpOOhoPsMm 159 | 160 | # disable gravatar profile images 161 | ;disable_gravatar = false 162 | 163 | # data source proxy whitelist (ip_or_domain:port separated by spaces) 164 | ;data_source_proxy_whitelist = 165 | 166 | # disable protection against brute force login attempts 167 | ;disable_brute_force_login_protection = false 168 | 169 | # set to true if you host Grafana behind HTTPS. default is false. 170 | ;cookie_secure = false 171 | 172 | # set cookie SameSite attribute. defaults to `lax`. can be set to "lax", "strict" and "none" 173 | ;cookie_samesite = lax 174 | 175 | # set to true if you want to allow browsers to render Grafana in a ,