This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash -x | |
| NC='\033[0m' # No Color | |
| RED='\033[1;31m' | |
| GREEN='\033[1;32m' | |
| YELLOW='\033[1;33m' | |
| if [ "$#" -lt 2 ]; then | |
| echo -e "${RED}Please provide disk and NVMe!${NC}" | |
| exit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| VERSION='1.0.1' | |
| USER=node-exporter | |
| SERVICE=node-exporter | |
| ADDRESS=${1} | |
| # Remove repository version if exists | |
| sudo apt purge -y prometheus-node-exporter |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/local/bin/python3 | |
| # Ceph data collection and aggregation tool | |
| # Version 1.0 Oct 24, 2019 | |
| # Christian Huebner cchuebner@gmail.com chuebner@mirantis.com @ossarchitect | |
| #from __future__ import print_function | |
| import sys | |
| import tarfile | |
| import json |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| echo "Collecting Ceph cluster data." | |
| echo "This script must be run on a monitor node." | |
| if [ "${CUSTOMER}" == '' ]; then CUSTOMER="default"; fi | |
| if [ "${CLUSTERNAME}" == '' ]; then CLUSTERNAME="cluster"; fi | |
| if [ "$#" -lt 2 ]; then echo "Using customer \"${CUSTOMER}\" and cluster name \"${CLUSTERNAME}\". These values can be modified by seting the \$CUSTOMER and \$CLUSTERNAME shell variables\nor calling the script with $0 <CUSTOMER> <CLUSTERNAME>\n"; else CUSTOMER=${1}; CLUSTERNAME=${2}; fi | |
| DATE=$(date "+%Y-%m-%d") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| NC='\033[0m' # No Color | |
| RED='\033[1;31m' | |
| GREEN='\033[1;32m' | |
| YELLOW='\033[1;33m' | |
| function initnvme { | |
| echo -e "${YELLOW}Initializing disk ${1}${NC}" | |
| sgdisk --zap-all /dev/${1} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| " Turn on syntax highlighting. | |
| syntax on | |
| " Set status line display | |
| set statusline=%F%m%r%h%w\ [FORMAT=%{&ff}]\ [TYPE=%Y]\ [POS=%l,%v][%p%%]\ [BUFFER=%n]\ %{strftime('%c')} | |
| " Encoding | |
| set encoding=utf-8 | |
| " Highlight matching search patterns |