This file contains 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
tail -100000 mongod.log | gawk -F' ' '{print $NF}' | grep ms$ | sed 's/ms//g' |sort -n | tail -20 | xargs -I {} grep {}ms$ mongod.log |
This file contains 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
redis-cli KEYS "*" | xargs redis-cli DEL |
This file contains 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
Dirty and not safe but ok for ditry stuff. | |
db.CollectionOne.find().forEach(function(d){ db.getSiblingDB('ther-db').CollectionTwo.insert(d); }); |
This file contains 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
du -sch * | sort -h -r |
This file contains 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
cd /opt/graphite/webapp/graphite | |
python ./manage.py shell | |
P | |
(InteractiveConsole) | |
>>> from django.contrib.auth.models import User | |
>>> users = User.objects.all() | |
>>> users | |
[<User: graphite>, <User: default>] | |
>>> users[0].set_password('password-here') | |
>>> users[0].save() |
This file contains 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
USEFUL GRAPHS TO GO |
This file contains 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
cat php.ini.ucf-old | sed '/^;/ d' | sed '/^\[/ d' | sed '/^$/d' | sort > php.old |
This file contains 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
curl -s -u coldclimate "https://api.github.com/repos/canddi/canddi/pulls/114/commits" | jq '.[] | {sha}' |
This file contains 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
for i in `seq 1 170`; do RESULT=`curl -s -u username:password "https://api.github.com/repos/owner/repo/pulls/${i}" | jq '.base | {ref}'| grep ref`; echo "${i}:${RESULT}";done |
This file contains 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
sudo netstat -lntp |
OlderNewer