Open tombolala opened 6 years ago
Hi Thomas, This is probably because of a storage problem in your openshift cluster. The rating-mongodb service is using a persistant volume claim that is called rating-mongodb-pv (see https://github.com/jbossdemocentral/coolstore-microservice/blob/stable-ocp-3.10/openshift/templates/coolstore-deployments-template.yaml#L957)
You can investigate it a bit more by issuing oc get pvc rating-mongodb-pv
To verify you can override the storage claim of the mongodb using the following command:
oc volumes dc/rating-mongodb --name=mongodb-data --add -t emptyDir --overwrite -n <project-name>
and then delete the claim with the following command:
oc delete pvc rating-mongodb-pv -n <project-name>
After that the mongodb instance should start correctly (it will redeploy automatically)
Cheers Thomas
Just change the replicas=1 in the deployment config, it will start up just fine.
Hi,
my second mongodb service is not deploying. First one is running, but second aborts - this happens on OpenShift 3.7 cluster.
First service is catalog-mongodb => Waiting for MongoDB daemon up => MongoDB daemon is up
Second one fails (rating-mongodb) 2018-10-23T06:49:02.645+0000 I STORAGE [initandlisten] exception in initAndListen: 98 Unable to lock file: /var/lib/mongodb/data/mongod.lock errno:11 Resource temporarily unavailable. Is a mongod instance already running?, terminating
Ok, apparently there is already the catalog-mongodb running and both pods are on /var/lib/mongodb/data This is, however, running fine on my Notebook with Minishift:
Thanx in advance, Thomas