Skip to content

Instantly share code, notes, and snippets.

for file in /proc/*/status ; do awk '/VmSwap|Name/{printf $2 " " $3}END{ print ""}' $file; done | sort -k 2 -n -r | less
cat master_events.log |jq -c '.|select(.bucket=="default" and (.type=="vbucketMoveDone" or .type=="vbucketMoveStart"))' | jq -c -s 'group_by(.vbucket) | .[] | select(length % 2 == 1) | sort_by(.ts)'
{ 'by_id': { 'id1': {many, fields, of, data, ...},
'id2': {otther fields, of, data, ...},
...
},
'ordering': [id1, id2, ...]
}
Good:
017-05-05T17:41:37.495654+01:00 NOTICE (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - (vb 511) Creating stream with start seqno 0 and end seqno 8
2017-05-05T17:41:37.495833+01:00 INFO (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - (vb 511) Transitioning from pending to backfilling
2017-05-05T17:41:37.495861+01:00 NOTICE (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - ActiveStream::scheduleBackfill_UNLOCKED: after not(DISKONLY || reschedule)(vb 511): curChkSeqno:1 backfillEnd:0 tryBackfill:1
2017-05-05T17:41:37.496025+01:00 NOTICE (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - ActiveStream::scheduleBackfill_UNLOCKED (vb 511): Considering backfill - backfillStart:1 backfillEnd:0tryBackfill:1
2017-05-05T17:41:37.496187+01:00 INFO (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (pr
Good:
017-05-05T17:09:46.012276+01:00 NOTICE (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - (vb 511) Creating stream with start seqno 0 and end seqno 8
2017-05-05T17:09:46.012526+01:00 INFO (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - (vb 511) Transitioning from pending to backfilling
2017-05-05T17:09:46.012575+01:00 NOTICE (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - ActiveStream::scheduleBackfill_UNLOCKED: after not(DISKONLY || reschedule)(vb 511): curChkSeqno:1 backfillEnd:0 tryBackfill:1
2017-05-05T17:09:46.012956+01:00 NOTICE (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - ActiveStream::scheduleBackfill_UNLOCKED (vb 511): Considering backfill - backfillStart:1 backfillEnd:0tryBackfill:1
2017-05-05T17:09:46.013364+01:00 INFO (beer-sample) DCP (Producer) eq_dcpq:mapreduce_view: beer-sample _design/beer (prod/main) - (vb 511)
@daverigby
daverigby / IRC op deop
Created December 6, 2016 10:38
IRC op / deop
/cs op #couchbase Dave_R
/cs deop #couchbase Dave_R
https://github.com/couchbaselabs/couchbase-python-cffi
requirements.txt
================
couchbase==2.0.7
git+https://github.com/couchbaselabs/couchbase-python-cffi.git
code
====
CommandLine: "C:\Program Files\Couchbase\Server\bin\mcstat.exe"
The call to LoadLibrary(ext) failed, Win32 error 0n2
"The system cannot find the file specified."
Please check your debugger configuration and/or network access.
The call to LoadLibrary(exts) failed, Win32 error 0n2
"The system cannot find the file specified."
Please check your debugger configuration and/or network access.
The call to LoadLibrary(uext) failed, Win32 error 0n2
"The system cannot find the file specified."
Please check your debugger configuration and/or network access.
#include <cstdio>
#include <cstdlib>
#include <queue>
void* operator new(std::size_t sz) {
std::printf("global op new called, size = %zu\n",sz);
return std::malloc(sz);
}
void operator delete(void* ptr) noexcept
{

Keybase proof

I hereby claim:

  • I am daverigby on github.
  • I am daverigby (https://keybase.io/daverigby) on keybase.
  • I have a public key whose fingerprint is 5702 9A50 6162 1BBC 8575 FBCE 22F7 9EBF 0B58 C89B

To claim this, I am signing this object: