Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
Fetching contributors…

Cannot retrieve contributors at this time

executable file 17 lines (14 sloc) 0.294 kB
#!/bin/bash
repair()
{
A=`stat ${1}/data/mongod.lock | sed -ne 's/^ Size: \([0-9]\+\) .*/\1/p'`
if [ $A -ne 0 ]; then
rm ${1}/data/mongod.lock
/var/vcap/packages/mongodb/bin/mongod --repair -f ${1}/mongodb.conf
fi
}
cd /var/vcap/store/mongodb
for i in `ls .`
do
repair $i
done
Jump to Line
Something went wrong with that request. Please try again.