moved to https://github.com/yano3/kankara/blob/master/elasticsearch/monitoring.md
- Elasticsearch の様子を知るのに便利な様々な API がある。
- これらを参照する Elasticsearch プラグインや各種モニタリングツール (mackerel, munin, etc.) のプラグインが開発されている。
- API 間で重複する内容があったり、似ているようで異なるものがあったりするので使い分けに注意。
diff --git a/build_config.rb b/build_config.rb | |
index 13751f2..9faddba 100644 | |
--- a/build_config.rb | |
+++ b/build_config.rb | |
@@ -8,6 +8,10 @@ MRuby::Build.new('host') do |conf| | |
cc.flags << ENV['NGX_MRUBY_CFLAGS'] if ENV['NGX_MRUBY_CFLAGS'] | |
end | |
+ conf.linker do |linker| | |
+ linker.option_library << ' -lstdc++' |
diff --git src/http/ngx_http_mruby_filter.c src/http/ngx_http_mruby_filter.c | |
index 91e8e00..e90642d 100644 | |
--- src/http/ngx_http_mruby_filter.c | |
+++ src/http/ngx_http_mruby_filter.c | |
@@ -34,7 +34,7 @@ static mrb_value ngx_mrb_set_filter_body(mrb_state *mrb, mrb_value self) | |
body = mrb_funcall(mrb, body, "to_s", 0, NULL); | |
} | |
- ctx->body = (u_char *)mrb_str_to_cstr(mrb, body); | |
+ ctx->body = (u_char *)RSTRING_PTR(body); |
2016/12/16 01:01:37 [error] 3153#3153: *1 mrb_run failed: return 500 HTTP status code to client: error: /etc/nginx/conf.d/filter.rb:3: string contains null byte (ArgumentError), client: 10.0.2.2, server: _, request: "GET /filter HTTP/1.1", host: "localhost:20080" | |
2016/12/15 11:40:34 [error] 4579#4579: *1 mrb_run failed: return 500 HTTP status code to client: error: /etc/nginx/conf.d/nigari.rb:12: string contains null byte (ArgumentError) while sending to client, client: 10.0.2.2, server: _, request: "GET /nigari?4 HTTP/1.1", upstream: "http://127.0.0.1:80/orig?4", host: "localhost:20080" |
{ | |
nginx_version: Server::server_version, | |
mruby_version: MRUBY_VERSION, | |
ngx_mruby_version: Server::module_version, | |
} |
moved to https://github.com/yano3/kankara/blob/master/elasticsearch/monitoring.md
moved to https://github.com/yano3/kankara/blob/master/elasticsearch/cluster.md
$ brew install elasticsearch (git)-[master]
==> Downloading https://download.elasticsearch.org/elasticsearch/release/org/elasticsearch/distribution/tar/elasticsearch/2.1.0/elasticsearch-2.1.0.tar.gz
######################################################################## 100.0%
==> Caveats
Data: /usr/local/var/elasticsearch/elasticsearch_xxxxxxxxxx/
Logs: /usr/local/var/log/elasticsearch/elasticsearch_xxxxxxxxxx.log
Plugins: /usr/local/Cellar/elasticsearch/2.1.0_1/libexec/plugins/
Config: /usr/local/etc/elasticsearch/
$ brew install tuntap | |
==> Downloading https://homebrew.bintray.com/bottles/tuntap-20111101.mavericks.bottle.tar.gz | |
######################################################################## 100.0% | |
==> Pouring tuntap-20111101.mavericks.bottle.tar.gz | |
==> Caveats | |
In order for TUN/TAP network devices to work, the tun/tap kernel extensions | |
must be installed by the root user: | |
sudo cp -pR /usr/local/Cellar/tuntap/20111101/Library/Extensions/tap.kext /Library/Extensions/ | |
sudo cp -pR /usr/local/Cellar/tuntap/20111101/Library/Extensions/tun.kext /Library/Extensions/ |
bundle config build.nokogiri --use-system-libraries
$ brew install redis | |
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/redis-2.8.11.mavericks.bottle.tar.gz | |
######################################################################## 100.0% | |
==> Pouring redis-2.8.11.mavericks.bottle.tar.gz | |
==> Caveats | |
To have launchd start redis at login: | |
ln -sfv /usr/local/opt/redis/*.plist ~/Library/LaunchAgents | |
Then to load redis now: | |
launchctl load ~/Library/LaunchAgents/homebrew.mxcl.redis.plist | |
Or, if you don't want/need launchctl, you can just run: |