Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash of Kapacitor 1.0.0 on Windows x64 #916

Closed
stephanstapel opened this issue Sep 17, 2016 · 7 comments
Closed

Crash of Kapacitor 1.0.0 on Windows x64 #916

stephanstapel opened this issue Sep 17, 2016 · 7 comments

Comments

@stephanstapel
Copy link

stephanstapel commented Sep 17, 2016

Hi,

I am more than happy that you finally provide (I know: non supported) Windows binaries.
I installed Kapacitor 1.0.0, followed the Getting Started guide.

My first simple tick script looks like this:

stream
    // Select just the cpu measurement from our example database.
    |from()
        .measurement('disk_C.used_percent')
        .where(lambda: 'host' == 'server')
    |alert()
        .crit(lambda: 'value' >  70)
        // Whenever we get an alert write it to a file.
        .log('alerts.log')

when doing the test run, as described in the getting started using

kapacitor record stream -task cpu_alert -duration 20s

I reliably get the following crash:

panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x48 pc=0x59bff6]

goroutine 80 [running]:
panic(0xd81ae0, 0xc08200a070)
/usr/local/go/src/runtime/panic.go:481 +0x3f4
github.com/influxdata/kapacitor/services/replay.(_Service).doRecordStream(0xc0821ec6e0, 0xc0823a5ce0, 0x24, 0x0, 0x0, 0xecf6ee40f,
0x31496778, 0x1486c60, 0xc08223ac00, 0x1, ...)
/root/go/src/github.com/influxdata/kapacitor/services/replay/service.go:1240 +0x136
github.com/influxdata/kapacitor/services/replay.(_Service).handleRecordStream.func1(0xc0821a2700, 0xc0821ec6e0, 0xc082231a80, 0xc082231fc0, 0xc0823a5ce0, 0x24, 0xc0822a42a0, 0x55, 0x0, 0x0, ...)
/root/go/src/github.com/influxdata/kapacitor/services/replay/service.go:612 +0x156
created by github.com/influxdata/kapacitor/services/replay.(*Service).handleRecordStream
/root/go/src/github.com/influxdata/kapacitor/services/replay/service.go:614 +0x705

I guess this might be a bug in Kapacitor 1.0.0. Is there any chance that I can provide more information so that you can hunt this bug?

@lsitzmann
Copy link

I've got exactly the same problem running kapacitor v 1.1.0 on a windows 7 host.
Will there be any chance to run kapacitor on a windows system soon, or are there special configruations to be set?

@stephanstapel
Copy link
Author

I can confirm that I also still have the bug on Windows 10 x64.

@BRNTZN
Copy link

BRNTZN commented May 10, 2017

Exact same issue here
+1

@ikutsin
Copy link

ikutsin commented May 17, 2017

Mostly the same on Windows 7 x64
Default config, record query to type any type:
kapacitor record query -query "select * from db.rp.measurement limit 2" -type batch

2017/05/17 14:51:59 No configuration provided, using default settings
[run] 2017/05/17 14:51:59 I! Kapacitor starting, version 1.2.0, branch master, commit 5408057
[run] 2017/05/17 14:51:59 I! Go version go1.7.4
[srv] 2017/05/17 14:51:59 I! Kapacitor hostname: localhost
[srv] 2017/05/17 14:51:59 I! ClusterID: 7962b99f-5db4-425b-bb9b-171c9d5d4840 ServerID: a86b41e7-fec0-4e63-8820-89d71fe5c71b
[task_master:main] 2017/05/17 14:51:59 I! opened
[smtp] 2017/05/17 14:51:59 I! Starting SMTP service
[stats] 2017/05/17 14:51:59 I! opened service
[httpd] 2017/05/17 14:51:59 I! Starting HTTP service
[httpd] 2017/05/17 14:51:59 I! Authentication enabled: false
[httpd] 2017/05/17 14:51:59 I! Listening on HTTP: [::]:9092
[run] 2017/05/17 14:51:59 I! Listening for signals
[httpd] ::1 - - [17/May/2017:14:52:00 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 3c552e7b-3af7-11e7-8001-000000000000 311031
[httpd] ::1 - - [17/May/2017:14:52:10 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 423f9d7f-3af7-11e7-8002-000000000000 84008
[httpd] ::1 - - [17/May/2017:14:52:20 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 4833a9b2-3af7-11e7-8003-000000000000 119011
[httpd] ::1 - - [17/May/2017:14:52:30 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 4e301a8c-3af7-11e7-8004-000000000000 276027
[httpd] ::1 - - [17/May/2017:14:52:40 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 54238a7b-3af7-11e7-8005-000000000000 134013
[httpd] ::1 - - [17/May/2017:14:52:50 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 5a19928b-3af7-11e7-8006-000000000000 85008
[httpd] ::1 - - [17/May/2017:14:52:55 +0300] "GET /kapacitor/v1/tasks?dot-view=attributes&fields=type&fields=status&fields=executing&fields=dbrps&limit=100&offset=0&pattern=&replay-id=&script-format=formatted HTTP/1.1" 200 43 "-" "KapacitorClient" 5d3a961c-3af7-11e7-8007-000000000000 3000
[httpd] ::1 - - [17/May/2017:14:53:00 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 601e40fb-3af7-11e7-8008-000000000000 247024
[httpd] ::1 - - [17/May/2017:14:53:10 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 66022024-3af7-11e7-8009-000000000000 82008
[httpd] ::1 - - [17/May/2017:14:53:20 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 6c034c0d-3af7-11e7-800a-000000000000 79007
[httpd] ::1 - - [17/May/2017:14:53:30 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 71f11687-3af7-11e7-800b-000000000000 322032
[httpd] ::1 - - [17/May/2017:14:53:40 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 77e522ba-3af7-11e7-800c-000000000000 84008
[httpd] ::1 - - [17/May/2017:14:53:50 +0300] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 7ddd74c9-3af7-11e7-800d-000000000000 89008
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x20 pc=0x59cd71]

goroutine 134 [running]:
panic(0xb82ec0, 0xc0420060a0)
/usr/local/go/src/runtime/panic.go:500 +0x1af
github.com/influxdata/kapacitor/services/replay.(*Service).saveBatchQuery(0xc04213efd0, 0x0, 0x0, 0xc042134300, 0x0, 0x0)
/root/go/src/github.com/influxdata/kapacitor/services/replay/service.go:1518 +0x41
github.com/influxdata/kapacitor/services/replay.(*Service).doRecordQuery.func4(0xc0421342a0, 0xc04213efd0, 0x0, 0x0, 0xc042134300)
/root/go/src/github.com/influxdata/kapacitor/services/replay/service.go:1423 +0x50
created by github.com/influxdata/kapacitor/services/replay.(*Service).doRecordQuery
/root/go/src/github.com/influxdata/kapacitor/services/replay/service.go:1424 +0x1fd

vlastahajek added a commit to bonitoo-io/kapacitor that referenced this issue Aug 30, 2017
vlastahajek added a commit to bonitoo-io/kapacitor that referenced this issue Aug 31, 2017
nathanielc added a commit that referenced this issue Sep 8, 2017
Fix of the Kapacitor crash on windows when starting recording: issues #902, #916
@ivankudibal
Copy link

I think we can close this as duplicate of #902

@nathanielc
Copy link
Contributor

Agreed, thanks

mbresson pushed a commit to mbresson/kapacitor that referenced this issue Oct 19, 2017
fdhex pushed a commit to fdhex/kapacitor that referenced this issue Jun 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants
@ikutsin @stephanstapel @nathanielc @ivankudibal @BRNTZN @lsitzmann and others