Skip to content

illumos build broken on syscall.Mmap again #8466

Closed
@bahamat

Description

@bahamat

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

Activity

bahamat

bahamat commented on Jun 8, 2017

@bahamat
Author

This is similar to #4787.

jwilder

jwilder commented on Jun 13, 2017

@jwilder
Contributor

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

bahamat commented on Jun 14, 2017

@bahamat
Author

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

bahamat

bahamat commented on Jun 15, 2017

@bahamat
Author

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
self-assigned this
on Jun 21, 2017
jwilder

jwilder commented on Jun 21, 2017

@jwilder
Contributor

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

bahamat

bahamat commented on Jun 22, 2017

@bahamat
Author

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

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

    Participants

    @jwilder@bahamat

    Issue actions

      illumos build broken on syscall.Mmap again · Issue #8466 · influxdata/influxdb