Unable to edit/create hosts following 0.8.7b upgrade

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
AndrewRobinson
Posts: 13
Joined: Mon Dec 04, 2006 6:18 am

Unable to edit/create hosts following 0.8.7b upgrade

Post by AndrewRobinson »

Upgraded to 0.8.7b and now everytime I edit or create a host I get Error: Save Failed

All I can see in the log that MIGHT cause this:

02/13/2008 01:13:22 PM - CMDPHP: Poller[0] ERROR: A DB Exec Failed!, Error:'1064', SQL:"REPLACE INTO settings (name, value) VALUES ('url_path', 'cacti\')'

Any help please!!
User avatar
fmangeant
Cacti Guru User
Posts: 2345
Joined: Fri Sep 19, 2003 8:36 am
Location: Sophia-Antipolis, France
Contact:

Post by fmangeant »

Hi

do you use the Monitor plugin ?
[size=84]
[color=green]HOWTOs[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15353]Install and configure the Net-SNMP agent for Unix[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=26151]Install and configure the Net-SNMP agent for Windows[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=28175]Graph multiple servers using an SNMP proxy[/url][/list]
[color=green]Templates[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15412]Multiple CPU usage for Linux[/url]
[*][url=http://forums.cacti.net/viewtopic.php?p=125152]Memory & swap usage for Unix[/url][/list][/size]
User avatar
TheGrudge
Posts: 37
Joined: Tue Feb 27, 2007 12:51 pm

Post by TheGrudge »

I also have problems upgrading from 0.8.7a->b.
I get the following error in the upgrade dialog:
Upgrade results:

WARNING: One or more of the SQL queries needed to upgraded your Cacti installation has failed. Please see below for more details. Your Cacti MySQL user must have SELECT, INSERT, UPDATE, DELETE, ALTER, CREATE, and DROP permissions. You should try executing the failed queries as 'root' to ensure that you do not have a permissions problem.

0.8.7a -> 0.8.7b

[Fail] ALTER TABLE `graph_templates_item` ADD INDEX `task_item_id` ( `task_item_id` )

[Success] ALTER TABLE `data_input_data` ADD INDEX `t_value`(`t_value`)
I downloaded the 0.8.7b archive, unpacked it, copied the original database for running the new cacti in a testing environment, copied all RRD files, installed the plugin arch, installed the 4 plugins (settings,update,monitor,thold) and setup the config. But now I get the above error.
The database user has all privileges and is also able to alter tables.
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

What if you run the query by hand, I suspect the index already exists.

If so, then that error is a non-issue.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
User avatar
TheGrudge
Posts: 37
Joined: Tue Feb 27, 2007 12:51 pm

Post by TheGrudge »

Oh one more thing: I installed all 3 patches for 0.8.7a before, so maybe these patches already changed some database tables?
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Patches never change the database. But, a plugin might have.. :)
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
User avatar
fmangeant
Cacti Guru User
Posts: 2345
Joined: Fri Sep 19, 2003 8:36 am
Location: Sophia-Antipolis, France
Contact:

Post by fmangeant »

For the "Save Failed" error when saving a device, which seems to be Monitor 0.8.2 related, Jimmy posted that earlier :
cigamit wrote:Click the monitor tab (after giving yourself permissions) and then try to save a device. It seems the setup table function for it doesn't run until you click the tab, I've found that before and already have a fix for it, just haven't released it yet.
It worked for me.
[size=84]
[color=green]HOWTOs[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15353]Install and configure the Net-SNMP agent for Unix[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=26151]Install and configure the Net-SNMP agent for Windows[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=28175]Graph multiple servers using an SNMP proxy[/url][/list]
[color=green]Templates[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15412]Multiple CPU usage for Linux[/url]
[*][url=http://forums.cacti.net/viewtopic.php?p=125152]Memory & swap usage for Unix[/url][/list][/size]
AndrewRobinson
Posts: 13
Joined: Mon Dec 04, 2006 6:18 am

Post by AndrewRobinson »

fmangeant wrote:For the "Save Failed" error when saving a device, which seems to be Monitor 0.8.2 related, Jimmy posted that earlier :
It worked for me.
And it worked for me too, thank you :)
User avatar
TheGrudge
Posts: 37
Joined: Tue Feb 27, 2007 12:51 pm

Post by TheGrudge »

Running the ALTER TABLE query gives me the following error:
#1061 - Duplicate key name 'task_item_id'
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

Yep, index already exists, I would not worry about the upgrade error.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
User avatar
TheGrudge
Posts: 37
Joined: Tue Feb 27, 2007 12:51 pm

Post by TheGrudge »

Hmmm something is not working out here. Every URL in the new 0.8.7b install is mapped to something like
When I log into the new cacti installation, no CSS is loaded and if I click on Console, the above mapping is taking place, so I get a "file not found" error.

I set the
$config['url_path'] = '/cacti-test/';
varibale, but it is not working. What happened here? Never had problems when upgrading cacti. Maybe the plugin arch or a plugin is mapping those urls wrong?
User avatar
fmangeant
Cacti Guru User
Posts: 2345
Joined: Fri Sep 19, 2003 8:36 am
Location: Sophia-Antipolis, France
Contact:

Post by fmangeant »

Do you use plugin arch 2.0 ?
[size=84]
[color=green]HOWTOs[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15353]Install and configure the Net-SNMP agent for Unix[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=26151]Install and configure the Net-SNMP agent for Windows[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=28175]Graph multiple servers using an SNMP proxy[/url][/list]
[color=green]Templates[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15412]Multiple CPU usage for Linux[/url]
[*][url=http://forums.cacti.net/viewtopic.php?p=125152]Memory & swap usage for Unix[/url][/list][/size]
User avatar
TheGrudge
Posts: 37
Joined: Tue Feb 27, 2007 12:51 pm

Post by TheGrudge »

yes...
User avatar
fmangeant
Cacti Guru User
Posts: 2345
Joined: Fri Sep 19, 2003 8:36 am
Location: Sophia-Antipolis, France
Contact:

Post by fmangeant »

See my other post

I had to add

Code: Select all

$config['url_path'] = '/cacti/';
at the bottom of include/plugins.php
[size=84]
[color=green]HOWTOs[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15353]Install and configure the Net-SNMP agent for Unix[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=26151]Install and configure the Net-SNMP agent for Windows[/url]
[*][url=http://forums.cacti.net/viewtopic.php?t=28175]Graph multiple servers using an SNMP proxy[/url][/list]
[color=green]Templates[/color] :
[list][*][url=http://forums.cacti.net/viewtopic.php?t=15412]Multiple CPU usage for Linux[/url]
[*][url=http://forums.cacti.net/viewtopic.php?p=125152]Memory & swap usage for Unix[/url][/list][/size]
User avatar
TheGrudge
Posts: 37
Joined: Tue Feb 27, 2007 12:51 pm

Post by TheGrudge »

Ah ok, it's working now...
Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests