Permissions error when starting instances
kasperisager opened this issue · 5 comments
Hiya!
I'm experiencing a rather strange issue where my mongo instances won't start due to permission errors:
err: /Stage[main]//Mongodb::Mongod[mongod]/Service[mongod_mongod]/ensure: change from stopped to running failed: Could not start Service[mongod_mongod]: Execution of '/etc/init.d/mongod_mongod start' returned 1: at /tmp/vagrant-puppet/modules-0/mongodb/manifests/mongod.pp:66
I've checked the permissions on the init script and they're 0755
as per the Puppet setup. Any idea what might be happening?
What does it say in the MongoDB log? It could be that the data directory is missing or has wrong permissions , or that an old .lock file is present or something completely different. Check the logs. That will give you more insights.
The issue is a failed chown
within the init script. Running it manually with sudo
inside the VM works, but Vagrant doesn't seem to be able to run it.
So this seems to be a vagrant issue and none of this puppet module.
Alright, thanks for clearing that up!
Maybe chown isn't set in your PATH, try to set the whole path to chwon in the init scrip.