Last active
August 29, 2015 14:08
-
-
Save lulezi/38b059195a51aad1b518 to your computer and use it in GitHub Desktop.
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
5:skylight::api::http::live: curl; version=7.37.1; protocols=[http, https] | |
5:skylight::api::http::live: http config; CAPath=/usr/lib/ssl/certs | |
5:skylight::api::http::live: http config; CAFile=/home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem | |
5:skylight::c_api: starting Skylight instrumenter | |
5:skylight::instrumenter: starting instrumenter; state=Stopped; config=Config { authentication: mHaxwKS8BJlMSyJSqLHQBWN-ojt7J-6NBnm-89z4vVw, validate_authentication: false, lazy_start: true, version: 0.4.0, ssl_cert_dir: /usr/lib/ssl/certs, ssl_cert_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem, daemon_executable_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/native/x86_64-linux/skylightd, daemon_sockdir_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp } | |
I, [2014-11-04T23:25:24.882297 #19099] INFO -- : unlinking existing socket=/home/foerderapp/www/spa.foerderapp.ch/current/tmp/sockets/unicorn.sock | |
I, [2014-11-04T23:25:24.882629 #19099] INFO -- : listening on addr=/home/foerderapp/www/spa.foerderapp.ch/current/tmp/sockets/unicorn.sock fd=12 | |
I, [2014-11-04T23:25:24.900540 #19107] INFO -- : worker=0 ready | |
I, [2014-11-04T23:25:24.902583 #19099] INFO -- : master process ready | |
I, [2014-11-04T23:25:24.904647 #19110] INFO -- : worker=1 ready | |
I, [2014-11-04T23:25:24.907879 #19113] INFO -- : worker=2 ready | |
5:skylight::instrumenter: submitting trace to instrumenter; state=Ready, config=InstrumenterConfig { lazy_start: true, validate_auth: false, bootstrap_config: true } | |
~~~~~~~~~~ TRACE ~~~~~~~~~~~~ | |
- 0p; start=0; dur=2312; event=app.rack.request | |
+ 1 + 8 | |
- 1p; start=931; dur=1356; event=app.controller.request | |
+ 2 + 3 + 4 + 5 + 6 + 7 | |
- 2p; start=1358; dur=4; event=db.sql.query | |
- 3p; start=1374; dur=2; event=db.sql.query | |
- 4p; start=1464; dur=2; event=db.sql.query | |
- 5p; start=1558; dur=3; event=db.sql.query | |
- 6p; start=1896; dur=2; event=db.sql.query | |
- 7p; start=2015; dur=2; event=db.sql.query | |
- 8p; start=2312; dur=0; event=noise.gc | |
~~~~~~~~~~ - ~~~~~~~~~~~~ | |
5:skylight::ipc::client: preparing IPC client | |
5:skylight::ipc::client: pre-spawn attempt jitter; sleep=146ms | |
5:skylight::ipc::client: executing daemon command; exec=/home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/native/x86_64-linux/skylightd; env=[(SKYLIGHT_AUTHENTICATION, mHaxwKS8BJlMSyJSqLHQBWN-ojt7J-6NBnm-89z4vVw), (SKYLIGHT_VALIDATE_AUTHENTICATION, false), (SKYLIGHT_LAZY_START, true), (SKYLIGHT_VERSION, 0.4.0), (SKYLIGHT_SSL_CERT_DIR, /usr/lib/ssl/certs), (SKYLIGHT_SSL_CERT_PATH, /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem), (SKYLIGHT_DAEMON_EXEC_PATH, /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/native/x86_64-linux/skylightd), (SKYLIGHT_PIDFILE_PATH, /home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp/skylight.pid), (SKYLIGHT_SOCKDIR_PATH, /home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp), (SKYLIGHT_IPC_MAX_MESSAGE_SIZE, 5242880), (LD_LIBRARY_PATH, /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/native/x86_64-linux), (RUST_LOG, skylight=5)] | |
5:skylight::ipc::client: daemon not started yet; elapsed=35835nanos; timeout=5s | |
INFO:skylight::ipc::daemon: starting skylightd; version=0.4.0+17128bb | |
5:skylight::ipc::daemon: bootstrapping daemon; config=Config { authentication: mHaxwKS8BJlMSyJSqLHQBWN-ojt7J-6NBnm-89z4vVw, validate_authentication: false, lazy_start: true, version: 0.4.0, ssl_cert_dir: /usr/lib/ssl/certs, ssl_cert_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem, daemon_executable_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/native/x86_64-linux/skylightd, daemon_pidfile_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp/skylight.pid, daemon_sockdir_path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp, daemon_max_message_size: 5242880 } | |
5:skylight::api::http::live: curl; version=7.37.1; protocols=[http, https] | |
5:skylight::api::http::live: http config; CAPath=/usr/lib/ssl/certs | |
5:skylight::api::http::live: http config; CAFile=/home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem | |
5:skylight::api::http::live: curl; version=7.37.1; protocols=[http, https] | |
5:skylight::api::http::live: http config; CAPath=/usr/lib/ssl/certs | |
5:skylight::api::http::live: http config; CAFile=/home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem | |
INFO:skylight::ipc::daemon: starting agent Skylight daemon | |
5:skylight::ipc::daemon: daemon pidfile lock acquired; lock=Lock { lock: Lock { pidfile: Pidfile { pid: 19120 }, path: /home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp/skylight.pid } } | |
5:skylight::ipc::daemon: daemon UDS server bound | |
5:skylight::batching: initializing batcher; config=BatchingConfig { tick: 250ms, queue: 10, sample_size: 100, max_unique_endpoints: 500, flush_interval: 5s, clear_endpoints_interval: 24hr } | |
5:skylight::reporting: session token expired -- refreshing | |
5:skylight::api::http::live: Http::get; url=https://auth.skylight.io/agent?hostname=elage01; auth=Some(mHaxwKS8BJlMSyJSqLHQBWN-ojt7J-6NBnm-89z4vVw) | |
* Hostname was NOT found in DNS cache | |
* Trying 23.21.73.59... | |
5:skylight::ipc::client: daemon started; pid=19120; iteration=2 | |
5:skylight::ipc::client: attempting to connect to daemon; pid=19120 | |
5:skylight::ipc::client: found daemon sockfile; path=/home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp/skylight-19120.sock | |
5:skylight::ipc::client: connecting to UDS; path=/home/foerderapp/www/spa.foerderapp.ch/releases/3/tmp/skylight-19120.sock | |
5:skylight::ipc::client: connected to Skylight daemon | |
5:skylight::ipc::daemon: IPC client connected | |
5:skylight::ipc::daemon: handling msg; hello=Hello { 0.4.0+17128bb, /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/native/x86_64-linux/skylightd, [] } | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::batching: handling message | |
5:skylight::batching: handling trace envelope | |
* Connected to auth.skylight.io (23.21.73.59) port 443 (#0) | |
* successfully set certificate verify locations: | |
* CAfile: /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem | |
CApath: /usr/lib/ssl/certs | |
* SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256 | |
* Server certificate: | |
* subject: OU=Domain Control Validated; OU=EssentialSSL Wildcard; CN=*.skylight.io | |
* start date: 2013-12-31 00:00:00 GMT | |
* expire date: 2015-03-01 23:59:59 GMT | |
* subjectAltName: auth.skylight.io matched | |
* issuer: C=GB; ST=Greater Manchester; L=Salford; O=COMODO CA Limited; CN=EssentialSSL CA | |
* SSL certificate verify ok. | |
> GET /agent?hostname=elage01 HTTP/1.1 | |
Host: auth.skylight.io | |
Accept: */* | |
Authorization: mHaxwKS8BJlMSyJSqLHQBWN-ojt7J-6NBnm-89z4vVw | |
x-skylight-agent-version: 0.4.0 | |
< HTTP/1.1 200 OK | |
* Server Cowboy is not blacklisted | |
< Server: Cowboy | |
< Date: Tue, 04 Nov 2014 22:25:25 GMT | |
< Connection: keep-alive | |
< Strict-Transport-Security: max-age=31536000 | |
< X-Frame-Options: SAMEORIGIN | |
< X-Xss-Protection: 1; mode=block | |
< X-Content-Type-Options: nosniff | |
< Content-Type: application/json; charset=utf-8 | |
< Etag: "60c20095bef228fa5f5318f6d957c18f" | |
< Cache-Control: max-age=0, private, must-revalidate | |
< X-Request-Id: 30da37a6-835c-4b37-8406-4b62657a055f | |
< X-Runtime: 0.017466 | |
< Transfer-Encoding: chunked | |
< Via: 1.1 vegur | |
< | |
* Connection #0 to host auth.skylight.io left intact | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::batching: flushing batch | |
5:skylight::api::http::live: Http::post; url=https://agent.skylight.io/report; auth=Some(IIbW5dVQ/27zW5TN/ZE/BMsnoTnpS+wIKVRF4/+8SK5hcHBzPXZUNTdSZUxnVTVoMCZyb2xlPWFnZW50JnY9MSZleHBpcmVzX2F0PTE0MTUxNTA3MjY=); content-type=application/x-skylight-report-v2; deflate=false | |
* Hostname was NOT found in DNS cache | |
5:skylight::ipc::client: message sent successfully | |
* Trying 54.209.69.168... | |
* Connected to agent.skylight.io (54.209.69.168) port 443 (#0) | |
* successfully set certificate verify locations: | |
* CAfile: /home/foerderapp/www/spa.foerderapp.ch/releases/3/vendor/bundle/ruby/2.1.0/gems/skylight-0.4.0/lib/skylight/data/cacert.pem | |
CApath: /usr/lib/ssl/certs | |
* SSL connection using TLSv1.0 / AES256-SHA | |
* Server certificate: | |
* subject: OU=Domain Control Validated; OU=EssentialSSL Wildcard; CN=*.skylight.io | |
* start date: 2013-12-31 00:00:00 GMT | |
* expire date: 2015-03-01 23:59:59 GMT | |
* subjectAltName: agent.skylight.io matched | |
* issuer: C=GB; ST=Greater Manchester; L=Salford; O=COMODO CA Limited; CN=EssentialSSL CA | |
* SSL certificate verify ok. | |
> POST /report HTTP/1.1 | |
Host: agent.skylight.io | |
Accept: */* | |
x-skylight-agent-version: 0.4.0 | |
Authorization: IIbW5dVQ/27zW5TN/ZE/BMsnoTnpS+wIKVRF4/+8SK5hcHBzPXZUNTdSZUxnVTVoMCZyb2xlPWFnZW50JnY9MSZleHBpcmVzX2F0PTE0MTUxNTA3MjY= | |
Transfer-Encoding: chunked | |
Content-Type: application/x-skylight-report-v2 | |
< HTTP/1.1 200 OK | |
< Date: Tue, 04 Nov 2014 22:25:31 GMT | |
< Content-Type: text/plain | |
< Content-Length: 7 | |
< | |
* Connection #0 to host agent.skylight.io left intact | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully | |
5:skylight::ipc::client: message sent successfully |
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
I, [2014-11-04T22:31:04.284063 #16817] INFO -- : executing ["/home/foerderapp/.rvm/gems/ruby-2.1.3/bin/unicorn_rails", "-c", "/home/foerderapp/www/spa.foerderapp.ch/current/config/unicorn.rb", "-E", "production", "-D", {11=>#<Kgio::UNIXServer:fd 11>}] (in /home/foerderapp/www/spa.foerderapp.ch/releases/3) | |
I, [2014-11-04T22:31:04.284370 #16817] INFO -- : forked child re-executing... | |
I, [2014-11-04T22:31:04.570659 #16817] INFO -- : inherited addr=/home/foerderapp/www/spa.foerderapp.ch/current/tmp/sockets/unicorn.sock fd=11 | |
I, [2014-11-04T22:31:04.571083 #16817] INFO -- : Refreshing Gem list | |
I, [2014-11-04T22:31:06.464795 #16827] INFO -- : worker=1 ready | |
I, [2014-11-04T22:31:06.468434 #16817] INFO -- : master process ready | |
I, [2014-11-04T22:31:06.471215 #16824] INFO -- : worker=0 ready | |
I, [2014-11-04T22:31:06.477631 #16830] INFO -- : worker=2 ready | |
I, [2014-11-04T22:31:06.661526 #12212] INFO -- : reaped #<Process::Status: pid 12219 exit 0> worker=0 | |
I, [2014-11-04T22:31:06.661843 #12212] INFO -- : reaped #<Process::Status: pid 12222 exit 0> worker=1 | |
I, [2014-11-04T22:31:06.662118 #12212] INFO -- : reaped #<Process::Status: pid 12225 exit 0> worker=2 | |
I, [2014-11-04T22:31:06.662320 #12212] INFO -- : master complete | |
I, [2014-11-04T22:39:08.598958 #17055] INFO -- : executing ["/home/foerderapp/.rvm/gems/ruby-2.1.3/bin/unicorn_rails", "-c", "/home/foerderapp/www/spa.foerderapp.ch/current/config/unicorn.rb", "-E", "production", "-D", {11=>#<Kgio::UNIXServer:fd 11>}] (in /home/foerderapp/www/spa.foerderapp.ch/releases/3) | |
I, [2014-11-04T22:39:08.599305 #17055] INFO -- : forked child re-executing... | |
I, [2014-11-04T22:39:08.883309 #17055] INFO -- : inherited addr=/home/foerderapp/www/spa.foerderapp.ch/current/tmp/sockets/unicorn.sock fd=11 | |
I, [2014-11-04T22:39:08.883802 #17055] INFO -- : Refreshing Gem list | |
I, [2014-11-04T22:39:10.900676 #17062] INFO -- : worker=0 ready | |
I, [2014-11-04T22:39:10.902640 #17065] INFO -- : worker=1 ready | |
I, [2014-11-04T22:39:10.914448 #17055] INFO -- : master process ready | |
I, [2014-11-04T22:39:10.921247 #17068] INFO -- : worker=2 ready | |
I, [2014-11-04T22:39:11.099386 #16817] INFO -- : reaped #<Process::Status: pid 16824 exit 0> worker=0 | |
I, [2014-11-04T22:39:11.099657 #16817] INFO -- : reaped #<Process::Status: pid 16827 exit 0> worker=1 | |
I, [2014-11-04T22:39:11.099786 #16817] INFO -- : reaped #<Process::Status: pid 16830 exit 0> worker=2 | |
I, [2014-11-04T22:39:11.099846 #16817] INFO -- : master complete |
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
PP_PATH = File.expand_path(File.dirname(__FILE__)).split('/')[0..-2].join('/') | |
worker_processes 3 | |
working_directory APP_PATH | |
# This loads the application in the master process before forking | |
# worker processes | |
# Read more about it here: | |
# http://unicorn.bogomips.org/Unicorn/Configurator.html | |
preload_app true | |
timeout 30 | |
# This is where we specify the socket. | |
# We will point the upstream Nginx module to this socket later on | |
listen APP_PATH + "/tmp/sockets/unicorn.sock", :backlog => 64 | |
pid APP_PATH + "/tmp/pids/unicorn.pid" | |
# Set the path of the log files inside the log folder of the testapp | |
stderr_path APP_PATH + "/log/unicorn.log" | |
stdout_path APP_PATH + "/log/unicorn.log" | |
before_fork do |server, worker| | |
# This option works in together with preload_app true setting | |
# What is does is prevent the master process from holding | |
# the database connection | |
defined?(ActiveRecord::Base) and | |
ActiveRecord::Base.connection.disconnect! | |
old_pid = "#{server.config[:pid]}.oldbin" | |
if old_pid != server.pid | |
begin | |
sig = (worker.nr + 1) >= server.worker_processes ? :QUIT : :TTOU | |
Process.kill(sig, File.read(old_pid).to_i) | |
rescue Errno::ENOENT, Errno::ESRCH | |
end | |
end | |
end | |
after_fork do |server, worker| | |
# Here we are establishing the connection after forking worker | |
# processes | |
defined?(ActiveRecord::Base) and | |
ActiveRecord::Base.establish_connection | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment