That's strange, haven't seen that one yet.
We can tackle it in 1 of 2 ways:
1) do a restore to prior to upgrade status and then run upgrade again with rhn-optional in place (some data lost no doubt)
2) edit subcomponents/install, remove nagiosql from the line starting "for pkg in nagioscore..." then try the upgrade again (should be no data lost)
You choose
Upgrade from XI 2012R1.2 to XI 2014R1.4 still shows old ver
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
-
luniversity
- Posts: 56
- Joined: Mon Dec 10, 2012 9:39 am
Re: Upgrade from XI 2012R1.2 to XI 2014R1.4 still shows old
Well I've never done either one. For a restore, I assuming I would use the /usr/local/nagiosxi/scripts/restore_xi.sh? Is there anything special I need to do?
Mike Westmoreland
Lamar University
Lamar University
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: Upgrade from XI 2012R1.2 to XI 2014R1.4 still shows old
Nope. cd to the scripts directory before running the restore.sh - we sometimes call other scripts relatively instead of absolutely.
so
Just make sure to choose the last one created before the original upgrade attempt.
so
Code: Select all
cd /usr/local/nagiosxi/scripts
./restore_xi.sh /store/backups/nagiosxi/14########.tar.gz-
luniversity
- Posts: 56
- Joined: Mon Dec 10, 2012 9:39 am
Re: Upgrade from XI 2012R1.2 to XI 2014R1.4 still shows old
Y'all are alright. I think that did the trick. I ran the restore, re-ran the upgrade and logged into the web interface, all the components have green check mark and Nagios XI 2014R2.6 shows up in the bottom corner. Thanks for the quick responses too. I think I'm good to go.
Mike Westmoreland
Lamar University
Lamar University
Re: Upgrade from XI 2012R1.2 to XI 2014R1.4 still shows old
Let's try the following - open the "/tmp/nagiosxi/subcomponents/nagiosql/db_upgrades.php" file in a text editor, and comment out the lines 26 through 42 by placing "//" in front of each line. Example:
Save, exit and try to run the upgrade script again.
Code: Select all
//if(intval($oldversion) < 304) {
// if(db_connect_select($dba)) {
// $query = "ALTER TABLE tbl_user ADD COLUMN locale VARCHAR(6) DEFAULT 'en_EN'";
// if(!mysql_query($query)) {
// echo "NagiosQL failed to update user table!\n".mysql_error()."\n";
// exit(1);
// }
// else {
// echo "NagiosQL user table updated successfully!\n";
// exit(0);
// }
// }
// else {
// "Unable to connect to NagiosQL database!\n";
// exit(1);
// }
//}Be sure to check out our Knowledgebase for helpful articles and solutions!
-
luniversity
- Posts: 56
- Joined: Mon Dec 10, 2012 9:39 am
Re: Upgrade from XI 2012R1.2 to XI 2014R1.4 still shows old
Hey lmiltchev,
Thanks you for the suggestion but we've already resolved the issue. I just needed to make the "RHEL Server Optional" RHN channel available to the system so that it could install php-mbstring package. I restored Nagios from my backup and re-ran the upgrade script. It worked beautifully. Thanks for the help. This thread can be completed.
Thanks you for the suggestion but we've already resolved the issue. I just needed to make the "RHEL Server Optional" RHN channel available to the system so that it could install php-mbstring package. I restored Nagios from my backup and re-ran the upgrade script. It worked beautifully. Thanks for the help. This thread can be completed.
Mike Westmoreland
Lamar University
Lamar University