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

Can't go get / go install in official Docker image #224

Closed
DairyDTP opened this issue Aug 6, 2015 · 2 comments
Closed

Can't go get / go install in official Docker image #224

DairyDTP opened this issue Aug 6, 2015 · 2 comments

Comments

@DairyDTP
Copy link

DairyDTP commented Aug 6, 2015

Given this Dockerfile

FROM golang:1.4.2
RUN go get github.com/mattn/go-sqlite3

running

go build .

will hang for a many minutes at a very high load, then crash:

# github.com/mattn/go-sqlite3
gcc: internal compiler error: Killed (program cc1)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.9/README.Bugs> for instructions.
@DairyDTP
Copy link
Author

DairyDTP commented Aug 6, 2015

Can't reproduce on a fresh Ubuntu VM, with identical docker image.

@zebaz
Copy link

zebaz commented Dec 11, 2016

I've experienced the same issue on a machine with only 256MB RAM.

I've noticed that while compiling, gcc will take up to 160MB of RAM to compile /go-sqlite3/sqlite3-binding.c (the fact that it's around 200000 lines of code, doesn't help I guess).

After checking dmesg, I noticed Linux killed the cc process due to running out of memory
(Out of memory: Kill process 16181 (cc1) ), resulting in a gcc: internal compiler error.

For those running into similar problems, I would advise to free up memory by killing processes and use go install github.com/mattn/go-sqlite3 instead of go get to compile the package once, after which it can be re-used without recompiling the full sqlite3 c bindings.

gjrtimmer added a commit to gjrtimmer/go-sqlite3 that referenced this issue May 26, 2018
Compile Section Closes mattn#175
Compile Section Closes mattn#201
Compile Section Closes mattn#206
Compile Section Closes mattn#404
Compile Section Closes mattn#217
Compile Section Closes mattn#224
Compile Section Closes mattn#234
Compile Section Closes mattn#242
Feature table Closes mattn#255
Description Section Closes mattn#232
Golang:1.6 not supported Closes mattn#272
Golang:1.5 not supported + compilation section Closes mattn#283
usleep Implemented Closes mattn#285
FAQ Section Closes mattn#289
Compile Section closes mattn#295
FAQ Section Closes mattn#305
PR339 Closes mattn#318 mattn#321
Compilation Section Closes mattn#341
PR407 Closes mattn#364
Feature `sqlite_vtable` Closes mattn#393
Compile Section Closes mattn#416
sqlite_trace feature Closes mattn#433
Compilation Section Closes mattn#435
Compilation Section Closes mattn#443
Golang:1.6 Not Supported Closes mattn#445
Compilation Section Closes mattn#451
Compilation Section Closes mattn#467
Compilation Section Closes mattn#491
Compilation Section Closes mattn#495
Compilation Section Closes mattn#505
Compilation Section Closes mattn#557
Compilation Section Closes mattn#560
@mattn mattn closed this as completed in c9394b1 May 27, 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

2 participants