Skip to content

Instantly share code, notes, and snippets.

View JaySon-Huang's full-sized avatar
🤔

JaySon JaySon-Huang

🤔
  • PingCAP
  • CN
View GitHub Profile
@JaySon-Huang
JaySon-Huang / calc_pg_in_osd.py
Created August 28, 2018 06:18 — forked from hnuzhoulin/calc_pg_in_osd.py
calculate the the distribution of pg in OSD
#!/usr/bin/env python
import sys
import os
import json
cmd = '''
ceph pg dump | awk ' /^pg_stat/ { col=1; while($col!="up") {col++}; col++ } /^[0-9a-f]+\.[0-9a-f]+/ {print $1,$col}'
'''
body = os.popen(cmd).read()
SUM = {}
for line in body.split('\n'):
@JaySon-Huang
JaySon-Huang / git.md
Last active August 29, 2015 14:07 — forked from suziewong/git.md

github的多人协作

  1. github上你可以用别人的现成的代码 直接 git clone 即可了

  2. 然后你也想改代码或者贡献代码咋办?

Fork