Comments (9)
Thanks for the note -- I'm checking this out now.
from db2-docker.
So, now for some reason the initial setup fails for me, whereas before setup would finish but the database wouldn't start.
Removing sysctl -w kernel.shmmax=18446744073709551615
shouldn't affect that, though, because it didn't run until after the initial build.
At what point does the build break on your machine?
from db2-docker.
The first sign of an error was found when trying to start a newly created instance with db2start:
$ db2start
SQL1042C An unexpected system error occurred
Here is an explanation from a member of the DB2 team (my knowledge in this space is pretty limited).
A couple of flags to the open Unix system call are disabled on AUFS to enforce copy on write. DB2 happens to use one of those flags when running instances, specifically O_DIRECT. Although installation is possible on AUFS, creating and using a DB2 instance is not.
The root cause of the error was due to the failure of an open call with O_DIRECT supplied as one of the flags. The fix is to mount a Docker volume to the DB2 instance's home directory. The volume will have a ext4 filesystem, one that readily accepts calls to open with O_DIRECT specified.
from db2-docker.
Another solution to this problem is to switch the docker storage backend from AUFS to devicemapper:
http://muehe.org/posts/switching-docker-from-aufs-to-devicemapper/
I was initially using a dated RHEL box as a host system which apparently had devicemapper as default storage backend. When hosting this image on a recent Ubuntu system, I experienced the same issue and the fix was either to use an externally mounted volume or switch to devicemapper.
from db2-docker.
So, is this more of a Docker issue than an issue with this particular container? Can we include either fix in the Dockerfile?
from db2-docker.
I have not dug further into this over the past week or so but so far all I have found are solutions that are containable within the dockerFile. Perhaps there are startup options with DB2 that can be explored. I think this is a good topic for the docker-dev IRC.
from db2-docker.
After doing a little more testing (whew, has it been two months already?!?!) I agree with @rieske that the solution is to switch the Docker backend. I don't know if you can switch the backend per-Dockerfile. I'm using boot2docker at the moment and it looks like it's a one-or-the-other decision.
This seems to confirm that DB2 is picky about its filesystem: http://xcoolwinds.wordpress.com/2013/05/20/db2-doesnt-start-on-linux/
from db2-docker.
Btw if you do not want to switch to devicemapper, you can also use btrfs storage backend which is probably a much better alternative (had many problems with devicemapper).
A pretty easy and good tutorial can be found here: https://meta.discourse.org/t/rough-notes-getting-btrfs-working-on-digital-ocean/20246
Hope this helps.
from db2-docker.
@deeky666 Appreciate it!
from db2-docker.
Related Issues (10)
- DB2 install archive ADD should be step 1
- DB2 create statement - Slow Performance HOT 8
- Fix memory errors in Docker 1.2.0 HOT 2
- Upload to Docker registry
- Error on instalation HOT 2
- DB2 docker image HOT 1
- Error on build HOT 5
- Starting DB2 in docker container with limited privileges HOT 1
- unable to create a folder in the /var/custom
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from db2-docker.