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

illumos build broken on syscall.Mmap again #8466

Closed
bahamat opened this issue Jun 8, 2017 · 6 comments
Closed

illumos build broken on syscall.Mmap again #8466

bahamat opened this issue Jun 8, 2017 · 6 comments
Assignees
Labels

Comments

@bahamat
Copy link

bahamat commented Jun 8, 2017

Bug report

System info:

  • InfluxDB version: 1.3.0 (according to CHANGELOG.md)
  • operating system: SmartOS (illumos) 2017Q1 base-64 image
  • Go version: go version go1.8 solaris/amd64

Steps to reproduce:

GOPATH=${PWD}
PATH=${GOPATH}/bin:$(PATH)
go get golang.org/x/sys/unix
go get github.com/sparrc/gdm
go get github.com/influxdata/influxdb
( cd src/github.com/influxdata/influxdb; gdm restore )
go clean github.com/influxdata/influxdb/...
go install github.com/influxdata/influxdb/...

Expected behavior:

Successful build

Actual behavior:

Build error

go clean github.com/influxdata/influxdb/...
go install github.com/influxdata/influxdb/...
# github.com/influxdata/influxdb/pkg/mmap
src/github.com/influxdata/influxdb/pkg/mmap/mmap_unix.go:30: undefined: syscall.Mmap
src/github.com/influxdata/influxdb/pkg/mmap/mmap_unix.go:42: undefined: syscall.Munmap
Makefile:8: recipe for target 'bin/influxdb' failed
make: *** [bin/influxdb] Error 2
@bahamat
Copy link
Author

bahamat commented Jun 8, 2017

This is similar to #4787.

@jwilder
Copy link
Contributor

jwilder commented Jun 13, 2017

There is an mmap_solaris.go in the repo which is the fix for #4787, but it looks like your OS is using the unix one for some reason.

mmap_unix.go has:

// +build !windows,!plan9,!solaris

mmap_solaris.go has:

// +build solaris

Maybe try GOOS=solaris go install github.com/influxdata/influxdb/...? Perhaps the build constraints need to specify illumos as well?

@bahamat
Copy link
Author

bahamat commented Jun 14, 2017

Ok, I'll try setting GOOS=solaris when I get a chance to try it again.

@bahamat
Copy link
Author

bahamat commented Jun 15, 2017

Simply setting GOOS doesn't help. It fails with the same error.

The fix for #4787 has a mmap_solaris.go specifically for the tsdb package. The error I'm getting is in pkg/mmap.

I made an attempt at duplicating the mmap_solaris.go file in pkg/mmap, which I think made progress, but still ultimately fails. The error I get now is:

# github.com/influxdata/influxdb/tsdb/index/tsi1
src/github.com/influxdata/influxdb/tsdb/index/tsi1/index_file.go:80: undefined: mmap.Map
src/github.com/influxdata/influxdb/tsdb/index/tsi1/index_file.go:97: undefined: mmap.Unmap
src/github.com/influxdata/influxdb/tsdb/index/tsi1/index_files.go:156: undefined: mmap.Unmap
src/github.com/influxdata/influxdb/tsdb/index/tsi1/log_file.go:104: undefined: mmap.Map
src/github.com/influxdata/influxdb/tsdb/index/tsi1/log_file.go:153: undefined: mmap.Unmap
src/github.com/influxdata/influxdb/tsdb/index/tsi1/log_file.go:866: undefined: mmap.Unmap
src/github.com/influxdata/influxdb/tsdb/index/tsi1/series_block.go:975: undefined: mmap.Map

@jwilder jwilder self-assigned this Jun 21, 2017
@jwilder jwilder added the review label Jun 21, 2017
@jwilder
Copy link
Contributor

jwilder commented Jun 21, 2017

@bahamat Can you try building from #8514? It should resolve the compilation issue now.

@bahamat
Copy link
Author

bahamat commented Jun 22, 2017

I've confirmed that I can build after this commit.
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants