export PATH=$PATH:${HOME}/.cabal/bin
export PKG_CONFIG_PATH=/opt/X11/lib/pkgconfig
brew install --upgrade cairo
brew install cabal-install
cabal install cabal-install
cabal update
cabal install alex
cabal install gtk2hs-buildtools
cabal install timeplot splot
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 | |
| # | |
| # ./generate-node.sh -p 8087 -P 192.168.1.201 -h 8098 -H 192.168.1.201 -d 8099 -D 192.168.1.201 -s riak_kv_eleveldb_backend /mnt/riak/bin/riak /data/solid/riak | |
| while [ "${1:0:1}" = "-" -a "${#1}" -eq 2 ]; do | |
| case ${1:1:1} in | |
| p) | |
| shift | |
| pb_port="$1" | |
| shift |
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
| extract () { | |
| if [ -f $1 ] ; then | |
| case $1 in | |
| *.tar.bz2) tar xvjf $1 && cd $(basename "$1" .tar.bz2) ;; | |
| *.tar.gz) tar xvzf $1 && cd $(basename "$1" .tar.gz) ;; | |
| *.tar.xz) tar Jxvf $1 && cd $(basename "$1" .tar.xz) ;; | |
| *.bz2) bunzip2 $1 && cd $(basename "$1" /bz2) ;; | |
| *.rar) unrar x $1 && cd $(basename "$1" .rar) ;; | |
| *.gz) gunzip $1 && cd $(basename "$1" .gz) ;; | |
| *.tar) tar xvf $1 && cd $(basename "$1" .tar) ;; |
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 | |
| # | |
| # ./generate-node.sh -p 8087 -P 192.168.1.201 -h 8098 -H 192.168.1.201 -d 8099 -D 192.168.1.201 -s riak_kv_eleveldb_backend /mnt/riak/bin/riak /data/solid/riak | |
| while [ "${1:0:1}" = "-" -a "${#1}" -eq 2 ]; do | |
| case ${1:1:1} in | |
| p) | |
| shift | |
| pb_port="$1" | |
| shift |
[/basho/ansible-riak-common%]git checkout origin/riak-2.0-repos
Note: checking out 'origin/riak-2.0-repos'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
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
| %% Get the state for the local node | |
| %% The get_my_ring function really returns the ring | |
| %% plus other state information about the cluster. | |
| {ok, State} = riak_core_ring_manager:get_my_ring(). | |
| %% Get number of partitions | |
| riak_core_ring:num_partitions(State). | |
| %% Get the names of custom buckets | |
| riak_core_ring:get_buckets(State). |
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
| %% Get the state for the local node | |
| %% The get_my_ring function really returns the ring | |
| %% plus other state information about the cluster. | |
| {ok, State} = riak_core_ring_manager:get_my_ring(). | |
| %% Get number of partitions | |
| riak_core_ring:num_partitions(State). | |
| %% Get the names of custom buckets | |
| riak_core_ring:get_buckets(State). |
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/env python | |
| # -*- coding: utf-8 -*- | |
| # | |
| # ----------------------------------------------------------------------------- | |
| # plotiostat.py, Copyright Bjoern Olausson | |
| # ----------------------------------------------------------------------------- | |
| # This program is free software; you can redistribute it and/or modify | |
| # it under the terms of the GNU General Public License as published by | |
| # the Free Software Foundation; either version 2 of the License, or | |
| # (at your option) any later version. |
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/env python | |
| """ | |
| Example usage: | |
| [~%]dategrep.py -s "2014-08-04 05:04:03.376" -e "2014-08-04 05:04:03.593" < ~/Downloads/riak@10.x.233.35-riak-debug/logs/platform_log_dir/console.log | |
| 2014-08-04 05:04:03.376 [info] <0.9440.850>@riak_repl_keylist_client:wait_for_fullsync:94 Full-sync with site "misc_foo_prod2" starting; 1 partitions. | |
| 2014-08-04 05:04:03.376 [info] <0.9440.850>@riak_repl_keylist_client:request_partition:121 Full-sync with site "misc_foo_prod2"; starting fullsync for 1141798154164767904846628775559596109106197299200 | |
| 2014-08-04 05:04:03.376 [info] <0.9440.850>@riak_repl_keylist_client:request_partition:127 Full-sync with site "misc_foo_prod2"; building keylist for 1141798154164767904846628775559596109106197299200, 0 remain | |
| 2014-08-04 05:04:03.587 [info] <0.9441.850>@riak_repl_fullsync_helper:handle_cast:307 Sorting keylist "/var/lib/riak/riak_repl/work/45095927/misc_foo_prod2-10.x.38.11:9080-10.x.38.23:53914/1141798154164767904846628775559596109106197299200.ours.sterm" |
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
| Path | |
| ``` | |
| i=.`/riak.logs.cloudstoragea08/2014-08-07T15:47:49.540310/console.log.2014-07-31-05 | |
| ``` | |
| Extract the base directory name | |
| ``` | |
| echo ${${i:2}%%/*} | |
| ``` |