Digital Developer Conference: a FREE half-day online conference focused on AI & Cloud – North America: Nov 2 – India: Nov 9 – Europe: Nov 14 – Asia Nov 23 Register now

Close outline
  • United States
IBM?
  • Site map
IBM?
  • Marketplace

  • Close
    Search
  • Sign in
    • Sign in
    • Register
  • IBM Navigation
IBM Developer Answers
  • Spaces
    • Blockchain
    • IBM Cloud platform
    • Internet of Things
    • Predictive Analytics
    • Watson
    • See all spaces
  • Tags
  • Users
  • Badges
  • FAQ
  • Help
Close

Name

Community

  • Learn
  • Develop
  • Connect

Discover IBM

  • ConnectMarketplace
  • Products
  • Services
  • Industries
  • Careers
  • Partners
  • Support
10.190.13.195

Refine your search by using the following advanced search options.

Criteria Usage
Questions with keyword1 or keyword2 keyword1 keyword2
Questions with a mandatory word, e.g. keyword2 keyword1 +keyword2
Questions excluding a word, e.g. keyword2 keyword1 -keyword2
Questions with keyword(s) and a specific tag keyword1 [tag1]
Questions with keyword(s) and either of two or more specific tags keyword1 [tag1] [tag2]
To search for all posts by a user or all posts with a specific tag, start typing and choose from the suggestion list. Do not use a plus or minus sign with a tag, e.g., +[tag1].
  • Ask a question

DB2 express-c no longer works in Bluemix container after container infrastructure upgrade

270007KHRP gravatar image
Question by annaseg  (0) | May 26, 2016 at 03:00 PM db2containersibmcloud

I'm trying to start the db2 express docker image in a Bluemix container. If I follow the recommended commanded to start the container as a daemon, I get the following error su: cannot create child process: Resource temporarily unavailable. This is because the container attempts to run su - db2inst1 -c "db2start" in the entrypoint script. The troubleshooting guide recommends that I modify /etc/pam.d BUT I am unable to modify this file since the container is not running. I've tried a few solutions to start the container, but I have not found anything yet that works.
- I tried modifying the entrypoint of the container in the cf ic run... command but this does not seem to be a feature of the plugin
- I tried starting the container with cat as the command rather than db2start but the container does not continue running after the entrypoint script.

Any help would be appreciated.

People who like this

  0
Comment
10 |3000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster

2 answers

  • Sort: 
1100007SYV gravatar image
Accepted answer

Answer by Jacob Garcowski (459) | May 27, 2016 at 02:48 PM

Use the following Dockerfile to make an image that has a modified /etc/pam.d/su

 FROM ibmcom/db2express-c:latest
 RUN sed -i 's/session.*include/session        optional/' /etc/pam.d/su

I confirmed I could then run this in the new infrastructure. Below is the output I get from the cf ic logs command:

 %Changing password for user db2inst1.
 8passwd: all authentication tokens updated successfully.
 .SQL1063N  DB2START processing was successful.
 4Could not load host key: /etc/ssh/ssh_host_rsa_key
 6Could not load host key: /etc/ssh/ssh_host_ecdsa_key
 8Could not load host key: /etc/ssh/ssh_host_ed25519_key
Comment

People who like this

  0   Show 3   Share
10 |3000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
270007KHRP gravatar image annaseg (0)   May 27, 2016 at 05:01 PM 0
Share

Thanks for the response, but when I run the command

cf ic run -p 50000:50000 -e DB2INST1_PASSWORD=xxxxxxxxxx -e LICENSE=accept namespace/db2express-c db2start

i get the following from my cf ic logs command:

```$ cf ic logs container %Changing password for user db2inst1. 8passwd: all authentication tokens updated successfully. eNew password: Retype new password: su: cannot create child process: Resource temporarily unavailable ```

the docker image comes from the command: cf ic cpi ibmcom/db2express-c <registry-name>/db2:latest

and the upgrade to the container space is denoted by the command: cf ic info ... Environment Name : prod-dal09-kraken1 ... i was told by the container team that "kraken1" was the new space, before I was on "vizio3"

so, it looks like something about my environment is different than yours. did you do something special to modify your default user permissions?

1100007SYV gravatar image Jacob Garcowski (459) annaseg (0)   May 31, 2016 at 12:25 PM 0
Share

Just to clarify, I didn't just copy the image, I built a new one with a Dockerfile, so cf ic cpi won't work.

Create a new directory create a Dockerfile with the following in it:

  FROM ibmcom/db2express-c:latest
  RUN sed -i 's/session.*include/session        optional/' /etc/pam.d/su

Then run from that directory

 cf ic build -t db2sufix .

Then you should be able to do the following (replacing your namespace and DB2INST1_PASSWORD of preference)

 cf ic run -p 50000:50000 -e DB2INST1_PASSWORD=xxxxxxxxxxx -e LICENSE=accept namespace/db2sufix db2start

Note: I answered earlier before properly switching to kraken, so there is a chance you read an early edit of my answer without the Dockerfile information.

270007KHRP gravatar image annaseg (0) Jacob Garcowski (459)   Jun 03, 2016 at 01:39 PM 0
Share

building the docker file with the above Dockerfile in the cwd worked. thanks a million!

270007KHRP gravatar image

Answer by annaseg (0) | May 27, 2016 at 05:05 PM

dW Answers!!! the ui keeps telling me nothing happened then posting the comment :-(

Comment

People who like this

  0   Share
10 |3000 characters needed characters left characters exceeded
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster

Follow this question

90 people are following this question.

Answers

Answers & comments

Related questions

Cannot start DB2 image in IBM Container 1 Answer

Pulling repository registry.ng.bluemix.net gives Authentication Failure 2 Answers

Does Db2 on Cloud or Db2 Hosted support Fluid Query or federation? 1 Answer

Will Bluemix eventually run Docker Containers with Diego instead of docker engine ? 1 Answer

Container crashes on startup. How do I debug? 0 Answers

  • Contact
  • Privacy
  • IBM Developer Terms of use
  • Accessibility
  • Report Abuse
  • Cookie Preferences

Powered by AnswerHub

Authentication check. Please ignore.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • API Connect
  • Analytic Hybrid Cloud Core
  • Application Performance Management
  • Appsecdev
  • BPM
  • Blockchain
  • Business Transaction Intelligence
  • CAPI
  • CAPI SNAP
  • CICS
  • Cloud Analytics
  • Cloud Automation
  • Cloud Object Storage
  • Cloud marketplace
  • Collaboration
  • Content Services (ECM)
  • Continuous Testing
  • Courses
  • Customer Experience Analytics
  • DB2 LUW
  • Data and AI
  • DataPower
  • Decision Optimization
  • DevOps Build
  • DevOps Services
  • Developers IBM MX
  • Digital Commerce
  • Digital Experience
  • Finance
  • Global Entrepreneur Program
  • Hadoop
  • Hybrid Cloud Core
  • Hyper Protect
  • IBM Cloud platform
  • IBM Design
  • IBM Forms Experience Builder
  • IBM Maximo Developer
  • IBM StoredIQ
  • IBM StoredIQ-Cartridges
  • IIDR
  • ITOA
  • InformationServer
  • Integration Bus
  • Internet of Things
  • Kenexa
  • Linux on Power
  • LinuxONE
  • MDM
  • Mainframe
  • Messaging
  • Node.js
  • ODM
  • Open
  • PartnerWorld Developer Support
  • PowerAI
  • PowerVC
  • Predictive Analytics
  • Product Insights
  • PureData for Analytics
  • Push
  • QRadar App Development
  • Run Book Automation
  • Search Insights
  • Security Core
  • Storage
  • Storage Core
  • Streamsdev
  • Supply Chain Business Network
  • Supply Chain Insights
  • Swift
  • UBX Capture
  • Universal Behavior Exchange
  • UrbanCode
  • WASdev
  • WSRR
  • Watson
  • Watson Campaign Automation
  • Watson Content Hub
  • Watson Marketing Insights
  • dW Answers Help
  • dW Premium
  • developerWorks Sandbox
  • developerWorks Team
  • Watson Health
  • More
  • Tags
  • Questions
  • Users
  • Badges