Skip to content

Instantly share code, notes, and snippets.

@jhoblitt
jhoblitt / inv_to_file_sd.rb
Created May 9, 2024 21:47
Recursively extract the hostnames from an ansible inventory file and construct as prometheus sd file.
#!/bin/env ruby
require 'yaml'
require 'json'
inv = YAML.load_file('auto_inventory.yml')
def find_hosts(parent, h, output)
h.each {|k, v|
if v.is_a?(Hash)
@jhoblitt
jhoblitt / ceph_mds_possible_mem_leak.md
Created July 7, 2023 15:35
A ceph 17.2.6 mds suspected of leaking memory...
[root@rook-ceph-mds-auxtel-a-dfdfb685f-sdpmd ceph]# ceph daemon mds.auxtel-a heap stats 
mds.auxtel-a tcmalloc heap stats:------------------------------------------------
MALLOC:    11869592120 (11319.7 MiB) Bytes in use by application
MALLOC: +            0 (    0.0 MiB) Bytes in page heap freelist
MALLOC: +    582126792 (  555.2 MiB) Bytes in central cache freelist
MALLOC: +      6150656 (    5.9 MiB) Bytes in transfer cache freelist
MALLOC: +      3751680 (    3.6 MiB) Bytes in thread cache freelists
MALLOC: +     75235328 (   71.8 MiB) Bytes in malloc metadata
MALLOC:   ------------
@jhoblitt
jhoblitt / CHANGELOG.md
Last active March 14, 2023 20:26
lsst-it/lsst-control github_changelog_generator
@jhoblitt
jhoblitt / multisite-setup-test.md
Last active September 28, 2022 15:43
Ceph multisite replication configuration using rook fails without manually commiting period

ceph multisite setup

All test clusters are running:

  • k8s v1.23.7-rancher1-1
  • rook 1.10.1
  • ceph 17.2.3

Two baremetal clusters are being used for testing.

@jhoblitt
jhoblitt / gist:153f93284c60356e4540087a68794593
Created July 23, 2020 20:06
comcam-fp01 -> starlight-dtn
[jhoblitt@comcam-fp01 ~]$ for i in $(seq 1 10); do iperf3 -V -c starlight-dtn.ncsa.illinois.edu -p 5002; done
iperf 3.1.7
Linux comcam-fp01.ls.lsst.org 3.10.0-957.el7.x86_64 #1 SMP Thu Nov 8 23:39:32 UTC 2018 x86_64
Control connection MSS 1448
Time: Thu, 23 Jul 2020 20:03:18 GMT
Connecting to host starlight-dtn.ncsa.illinois.edu, port 5002
Cookie: comcam-fp01.ls.lsst.org.1595534598.0
TCP MSS: 1448 (default)
[ 4] local 139.229.150.3 port 47428 connected to 141.142.141.66 port 5002
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
@jhoblitt
jhoblitt / gist:1bac667207e6bf2d01447de6b80091e7
Created July 23, 2020 18:03
comcam-arctl01 -> starlight-dtn
[jhoblitt@comcam-arctl01 ~]$ for i in $(seq 1 10); do iperf3 -V -c starlight-dtn.ncsa.illinois.edu -p 5002 -B 139.229.140.4; done
iperf 3.1.7
Linux comcam-arctl01.ls.lsst.org 3.10.0-1062.9.1.el7.x86_64 #1 SMP Fri Dec 6 15:49:49 UTC 2019 x86_64
Control connection MSS 8948
Time: Thu, 23 Jul 2020 18:01:07 GMT
Connecting to host starlight-dtn.ncsa.illinois.edu, port 5002
Cookie: comcam-arctl01.ls.lsst.org.159552726
TCP MSS: 8948 (default)
[ 4] local 139.229.140.4 port 55004 connected to 141.142.141.66 port 5002
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
@jhoblitt
jhoblitt / gist:707368afde90ff54d5fd05fdd2394b0b
Created July 23, 2020 17:37
ls-dtn01 -> 141.142.238.247
[jhoblitt@ls-dtn01 ~]$ for i in $(seq 1 10); do iperf3 -V -c 141.142.238.247 -p 5000; done
iperf 3.1.7
Linux ls-dtn01.ls.lsst.org 3.10.0-1062.12.1.el7.x86_64 #1 SMP Tue Feb 4 23:02:59 UTC 2020 x86_64
Control connection MSS 1448
Time: Thu, 23 Jul 2020 17:33:40 GMT
Connecting to host 141.142.238.247, port 5000
Cookie: ls-dtn01.ls.lsst.org.1595525620.3310
TCP MSS: 1448 (default)
[ 4] local 139.229.146.14 port 46300 connected to 141.142.238.247 port 5000
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
[jhoblitt@ls-dtn01 ~]$ for i in $(seq 1 10); do iperf3 -V -c starlight-dtn.ncsa.illinois.edu -p 5002; done
iperf 3.1.7
Linux ls-dtn01.ls.lsst.org 3.10.0-1062.12.1.el7.x86_64 #1 SMP Tue Feb 4 23:02:59 UTC 2020 x86_64
Control connection MSS 1448
Time: Thu, 23 Jul 2020 17:17:00 GMT
Connecting to host starlight-dtn.ncsa.illinois.edu, port 5002
Cookie: ls-dtn01.ls.lsst.org.1595524620.3765
TCP MSS: 1448 (default)
[ 4] local 139.229.146.14 port 42374 connected to 141.142.141.66 port 5002
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
@jhoblitt
jhoblitt / gist:8614e00266afa387cc1f8cfa7348a88b
Created July 23, 2020 17:16
ls-dtn01 -> 141.142.238.247
[jhoblitt@ls-dtn01 ~]$ iperf3 -c 141.142.238.247 -p 5000 -V
iperf 3.1.7
Linux ls-dtn01.ls.lsst.org 3.10.0-1062.12.1.el7.x86_64 #1 SMP Tue Feb 4 23:02:59 UTC 2020 x86_64
Control connection MSS 1448
Time: Thu, 23 Jul 2020 17:14:23 GMT
Connecting to host 141.142.238.247, port 5000
Cookie: ls-dtn01.ls.lsst.org.1595524463.3614
TCP MSS: 1448 (default)
[ 4] local 139.229.146.14 port 41944 connected to 141.142.238.247 port 5000
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
@jhoblitt
jhoblitt / ipa.md
Created November 1, 2019 19:31
Setting user ssh keys under freeipa

Set a ssh public key

-sh-4.2$ ls
id_rsa_github2.pub  id_rsa_github.pub
-sh-4.2$ ipa user-mod jhoblitt-comcam --sshpubkey="$(cat id_rsa_github.pub)"
-------------------------------
Modified user "jhoblitt-comcam"
-------------------------------