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
INFO [AntiEntropyStage:227] 2014-09-28 15:00:41,982 RepairSession.java:171 - [repair #1d30ffe0-474a-11e4-84bd-79f3bc6874b0] Received merkle tree for registrynodedata from /172.16.66.81 | |
ERROR [AntiEntropyStage:227] 2014-09-28 15:00:41,982 CassandraDaemon.java:166 - Exception in thread Thread[AntiEntropyStage:227,5,main] | |
java.lang.ClassCastException: null | |
ERROR [RepairJobTask:3] 2014-09-28 15:00:41,983 RepairJob.java:127 - Error occurred during snapshot phase | |
java.lang.RuntimeException: Could not create snapshot at /172.16.66.81 | |
at org.apache.cassandra.repair.SnapshotTask$SnapshotCallback.onFailure(SnapshotTask.java:77) ~[apache-cassandra-2.1.0.jar:2.1.0] | |
at org.apache.cassandra.net.ResponseVerbHandler.doVerb(ResponseVerbHandler.java:48) ~[apache-cassandra-2.1.0.jar:2.1.0] | |
at org.apache.cassandra.net.MessageDeliveryTask.run(MessageDeliveryTask.java:62) ~[apache-cassandra-2.1.0.jar:2.1.0] | |
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_20] | |
at java.util.concurren |
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
INFO [AntiEntropyStage:6] 2014-09-28 22:27:45,482 RepairSession.java:171 - [repair #e4bf3e70-474d-11e4-a221-2fe2626539ec] Received merkle tree for domain from /172.16.66.81 | |
ERROR [RepairJobTask:1] 2014-09-28 22:27:45,484 RepairJob.java:127 - Error occurred during snapshot phase | |
java.lang.RuntimeException: Could not create snapshot at /172.16.66.81 | |
at org.apache.cassandra.repair.SnapshotTask$SnapshotCallback.onFailure(SnapshotTask.java:77) ~[apache-cassandra-2.1.0.jar:2.1.0] | |
at org.apache.cassandra.net.ResponseVerbHandler.doVerb(ResponseVerbHandler.java:48) ~[apache-cassandra-2.1.0.jar:2.1.0] | |
at org.apache.cassandra.net.MessageDeliveryTask.run(MessageDeliveryTask.java:62) ~[apache-cassandra-2.1.0.jar:2.1.0] | |
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_67] | |
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_67] | |
at java.lang.Thread.run(Thread.java:745) [na:1.7.0_67] | |
ERROR [AntiEntropyStage:6] 2014-09-28 22:27:45,484 C |
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/sh | |
# To put in /etc/cron.daily | |
date=$(date +%Y-%m-%d) | |
cd /var/lib/cassandra/data | |
for dir in $(find -mindepth 2 -maxdepth 2 -type d) | |
do | |
count=$(ls $dir/*-Data.db 2>/dev/null | wc -l) | |
echo ${date}: ${count} >>$dir/sstables_count | |
done |
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
#ifdef SHELL | |
gcc -Wall -Werror $0 && ./a.out | |
exit $? | |
#endif | |
#include <stdio.h> | |
void change_oom_score(int oom_adj) { | |
FILE * fp = fopen("/proc/self/oom_adj", "w"); // Old one (SK20) | |
if ( ! fp ) fp = fopen("/proc/self/oom_score_adj", "w"); // New one |
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
#ifdef SHELL | |
gcc -Wall -Werror $0 && ./a.out | |
exit $? | |
#endif | |
/* | |
Output: | |
Table : 0x7fff03ab7490 | |
Row 0 : 0x7fff03ab7490 | |
Cell 0:0 : 0x7fff03ab7490 |
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
#ifdef SHELL | |
gcc -std=c99 -Wall -Werror $0 && ./a.out | |
exit $? | |
#endif | |
#include <stdio.h> | |
/* | |
Output: |
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
#ifdef SHELL | |
gcc -ansi -g $0 && ./a.out | |
exit 0 | |
#endif | |
#include <stdio.h> | |
#include <string.h> | |
void permutation (char * prefix, char * str) { | |
int n = strlen(str); |
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
[ -f /usr/bin/svn ] || sudo apt-get install subversion -y | |
[ -f /usr/bin/mail ] || sudo apt-get install mailutils -y | |
[ -f /usr/bin/pip ] || sudo apt-get install python-pip -y | |
sudo pip install pygments >/dev/null | |
SVN_NEW=$SVN_REVISION_1 | |
SVN_OLD=$(cat svn_old ||:) | |
echo $SVN_NEW >svn_old | |
svn log $SVN_URL -r $(expr $SVN_OLD + 1 ):$SVN_NEW >logs.txt | |
svn diff $SVN_URL -r $SVN_OLD:$SVN_NEW >diff.txt | |
cat diff.txt | pygmentize -l diff -f html -O noclasses,nobackground -o diff.html |
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/bin/python | |
import pycassa | |
import datetime | |
import json | |
# This is a basic (and yet generic) implementation of time series using pycassa | |
class TimeSerie: | |
def __init__(self, keyspace, subject, sys=None): | |
# To make things easier, we can create the keyspace and column families ourself |
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
ifeq "$(PREFIX)" "" | |
PREFIX=/usr | |
endif | |
ifeq "$(DESTDIR)" "" | |
DESTDIR=/ | |
endif | |
OlderNewer