Closed fordjp closed 10 years ago
Did you try the following?
mongoctl install-mongodb 2.4.3
Yes - the install works fine, but then running mongoctl list-versions does not show the file as an option, nor does mongoctl start work.
Hmm .. that's surprising. If the install does succeed, afterwards mongoctl list-versions
should indeed display that as an installed version available on your machine. Could you perhaps attach the output from that sequence of two commands?
Once we can establish mongoctl has installed & is aware of 2.4.3, then we can tackle why it won't start it! :)
mongoctl install 2.4.3
Running install for linux 64bit to mongoDBInstallationsDirectory=/usr/local/mongo Downloading mongodb-linux-x86_64-2.4.3.tgz... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 90.0M 100 90.0M 0 0 111M 0 --:--:-- --:--:-- --:--:-- 111M Extracting mongodb-linux-x86_64-2.4.3.tgz... mongodb-linux-x86_64-2.4.3/README mongodb-linux-x86_64-2.4.3/THIRD-PARTY-NOTICES mongodb-linux-x86_64-2.4.3/GNU-AGPL-3.0 mongodb-linux-x86_64-2.4.3/bin/mongodump mongodb-linux-x86_64-2.4.3/bin/mongorestore mongodb-linux-x86_64-2.4.3/bin/mongoexport mongodb-linux-x86_64-2.4.3/bin/mongoimport mongodb-linux-x86_64-2.4.3/bin/mongostat mongodb-linux-x86_64-2.4.3/bin/mongotop mongodb-linux-x86_64-2.4.3/bin/mongooplog mongodb-linux-x86_64-2.4.3/bin/mongofiles mongodb-linux-x86_64-2.4.3/bin/bsondump mongodb-linux-x86_64-2.4.3/bin/mongoperf mongodb-linux-x86_64-2.4.3/bin/mongosniff mongodb-linux-x86_64-2.4.3/bin/mongod mongodb-linux-x86_64-2.4.3/bin/mongos mongodb-linux-x86_64-2.4.3/bin/mongo Moving extracted folder to /usr/local/mongo Deleting archive mongodb-linux-x86_64-2.4.3.tgz MongoDB 2.4.3 installed successfully!
mongoctl list-versions
2.0.7 /usr/local/mongo/mongodb-linux-x86_64-2.0.7 2.2.3 /usr/local/mongo/mongodb-linux-x86_64-2.2.3
mongoctl start $(hostname)
ERROR: Unable to find a compatible 'mongod' executable for version 2.4.3 .Here is your enviroment:
$PATH=/usr/share/centrifydc/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/home/mylogin/bin
$MONGO_HOME=None
mongoDBInstallationsDirectory=/usr/local/mongo (in mongoctl.config)
Thanks for that extra info. To me it looks like it's not actually putting the extracted files where it says it is. My first thought was perhaps a permissions issue -- i.e., are you running as a user than can alter /usr/local/mongo contents. But I just verified (I think) that mongoctl will not report success in this case; it fails with an error when i remove write permission from my install dir.
That's easy to check tho: Is the 'mongodb-linux-x86_64-2.4.3
' subdir indeed now present in your /usr/local/mongo
dir?
I think the problem is that the mongodb version string is different now:
/usr/local/mongo/mongodb-linux-x86_64-2.4.3/bin/mongod --version
db version v2.4.3 Wed May 22 15:21:54.491 git version: fe1743177a5ea03e91e0052fb5e2cb2945f6d95f
The regex command expects a ','
re_expr = "v?((([0-9]+)\.([0-9]+)\.([0-9]+))([^, ]*))"
removing the last part might fix it
re_expr = "v?((([0-9]+)\.([0-9]+)\.([0-9]+)))"
That does stand to reason, as that version file is the only recent change in the repo (which I made yesterday). I thought it was innocuous enough, as that file has had things like "2.2.2" and "2.2.3" previously with no apparent ill effects. But maybe not!
That regex looks to me like it expects 0 or more instances of anything but a comma or a space to round out the version string; a comma or space will end (delimit) it. As I think about it, that's probably to accomodate cases like a "2.2.4-rc0" release. But let me trace through the interaction a little more carefully...
For the regular expression, mongoctl applies it on the first output line of "mongod --version". See this commit https://github.com/mongolab/mongoctl/commit/ea9e2eabe0e8983e8a6ce4bf780b6be3db8d39f9
fordjp,
It might be that your mongoctl is not up to date?
Can you please try force upgrading mongoctl and try list-versions again?
sudo pip install --upgrade mongoctl --force-reinstall
Awesome! works like a charm!
Thanks Robert
Argh! Must remember to check vital signs on admit! Thanks, Abdul.
Robert, thanks for using mongoctl & reaching out when you encountered a hitch. Glad you're up and running again!
Best regards, TD
Latest stable MongoDB version updated to 2.4.9
Today we tried to upgrade to mongo v 2.4.3, but were unable to do so using mongoctl. We soon realized that this is because the value of the file mongo_latest_stable_version.txt is 2.2.4! Please update asap.