|
|
| Author |
Message |
tbaror
Joined: 05 Jun 2006 Posts: 49
|
Posted: Tue Jul 03, 2007 7:49 am Post subject: SQL ERRORS |
|
|
Hello,
i have just done new fresh install of MACTRACK, when i am trying to add device or site i am getting sql errors as follows below.
please advice.
Thanks in advanced.
********************sql error******************
07/03/2007 04:40:13 PM - CMDPHP: Poller[0] ERROR: SQL Cell Failed "SELECT COUNT(mac_track_devices.device_id) FROM mac_track_sites RIGHT JOIN mac_track_devices ON mac_track_devices.site_id = mac_track_sites.site_id WHERE ((mac_track_devices.hostname like '%%%%' OR mac_track_devices.device_name like '%%%%' OR mac_track_devices.notes like '%%%%'))"
07/03/2007 04:40:13 PM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed "SELECT mac_track_devices.site_id, mac_track_sites.site_name, mac_track_devices.device_id, mac_track_devices.device_name, mac_track_devices.notes, mac_track_devices.hostname, mac_track_devices.snmp_readstring, mac_track_devices.snmp_readstrings, mac_track_devices.snmp_version, mac_track_devices.snmp_port, mac_track_devices.snmp_timeout, mac_track_devices.snmp_retries, mac_track_devices.snmp_status, mac_track_devices.ignorePorts, mac_track_devices.disabled, mac_track_devices.scan_type, mac_track_devices.ips_total, mac_track_devices.ports_total, mac_track_devices.ports_active, mac_track_devices.ports_trunk, mac_track_devices.macs_active, mac_track_devices.last_rundate, mac_track_devices.last_runmessage, mac_track_devices.last_runduration FROM mac_track_sites RIGHT JOIN mac_track_devices ON mac_track_devices.site_id = mac_track_sites.site_id WHERE ((mac_track_devices.hostname like '%%%%' OR mac_track_devices.device_name like '%%%%' OR mac_track_devices.notes like '%%%%')) ORDER BY site_name ASC LIMIT 0,30"
|
|
| Back to top |
|
 |
streaker69 Cacti Pro User
Joined: 27 Mar 2006 Posts: 647 Location: Psychic Amish Network Administrator
|
Posted: Tue Jul 03, 2007 8:52 am Post subject: |
|
|
| Did you import the mactrack sql file?
|
|
| Back to top |
|
 |
tbaror
Joined: 05 Jun 2006 Posts: 49
|
Posted: Tue Jul 03, 2007 10:55 am Post subject: SQL ERRORS |
|
|
| yes i did import it to cacti db
|
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9736 Location: MI, USA
|
Posted: Tue Jul 03, 2007 11:39 am Post subject: |
|
|
What version of MacTrack? Are you sure you have those tables?
TheWitness
|
|
| Back to top |
|
 |
streaker69 Cacti Pro User
Joined: 27 Mar 2006 Posts: 647 Location: Psychic Amish Network Administrator
|
Posted: Tue Jul 03, 2007 6:03 pm Post subject: Re: SQL ERRORS |
|
|
| tbaror wrote: | | yes i did import it to cacti db |
If you don't have it, install phpMyAdmin and verify that all the tables are created.
|
|
| Back to top |
|
 |
tbaror
Joined: 05 Jun 2006 Posts: 49
|
Posted: Wed Jul 04, 2007 2:12 am Post subject: sql errors |
|
|
Hi,
i am using MySql gui tools quey browser, under cacti browser the tables seems to exist.
thanks
| Description: |
|
| Filesize: |
20.89 KB |
| Viewed: |
2443 Time(s) |

|
|
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9736 Location: MI, USA
|
Posted: Wed Jul 04, 2007 3:28 am Post subject: |
|
|
Please answer the other component of my question. Also, did you run the database_upgrade.php script?
TheWitness
|
|
| Back to top |
|
 |
tbaror
Joined: 05 Jun 2006 Posts: 49
|
Posted: Thu Jul 05, 2007 2:21 am Post subject: SQL ERRORS |
|
|
HI,
You right i didnt run database_upgrade.php, now its runing.
another question do i need to replace the files under patch folder?
Thanks
|
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9736 Location: MI, USA
|
Posted: Thu Jul 05, 2007 12:15 pm Post subject: |
|
|
Depends on your Plugin Architecture version.
TheWitness
|
|
| Back to top |
|
 |
apperrault Cacti User
Joined: 16 Feb 2007 Posts: 359 Location: Emeryville, CA
|
Posted: Thu Jul 05, 2007 12:23 pm Post subject: |
|
|
Witness,
I am having some problems with the MacTrack version in the SVN. I have imported the SQL script, i have run the | Code: | | php database_upgrade.php | and i get errors when i run that.
When i click on the MacTrack tab in my Cacti Instance, i get the following:
| Code: |
Fatal error: Cannot redeclare get_dns_from_ip() (previously declared in E:\cacti\plugins\settings\include\functions.php:154) in E:\cacti\plugins\mactrack\lib\mactrack_functions.php on line 1176 |
This is also the same error i get when i try and run database_upgrade.php.
What should i do? Should i delete all MacTrack tables from my MySQL DB and try again?
let me know
app
|
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9736 Location: MI, USA
|
Posted: Thu Jul 05, 2007 12:54 pm Post subject: |
|
|
Edit lib/config.php and edit out the settings plugin. I will let Jimmy Conner know.
TheWitness
|
|
| Back to top |
|
 |
apperrault Cacti User
Joined: 16 Feb 2007 Posts: 359 Location: Emeryville, CA
|
Posted: Thu Jul 05, 2007 12:57 pm Post subject: |
|
|
I did that, and what do you know, it worked.
I wonder if that was also causing my Uptime plugin to not run automatically.
We will have to see.
thanks much
app
|
|
| Back to top |
|
 |
apperrault Cacti User
Joined: 16 Feb 2007 Posts: 359 Location: Emeryville, CA
|
Posted: Thu Jul 05, 2007 1:15 pm Post subject: |
|
|
Well, that fixed the problem i was having with MacTrack, but not with Uptime. I will try and uninstall that plugin and re-install it.
One other question, one earlier versions of MacTrack, you had a list of some of the common Device Types, but now it appears that is gone, and I have to create them all manually. Do you have that old list. For the most part, i used those as templates for other, similar items.
If you have that available, it would be great.
Thanks much
app
|
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9736 Location: MI, USA
|
Posted: Thu Jul 05, 2007 1:29 pm Post subject: |
|
|
More than likely, I will patch MacTrack.
TheWitness
|
|
| Back to top |
|
 |
TheWitness Developer
Joined: 14 May 2002 Posts: 9736 Location: MI, USA
|
Posted: Thu Jul 05, 2007 2:28 pm Post subject: |
|
|
| If you sync your MacTrack SVN, you should be all set now adding the settings plugin back in.
|
|
| Back to top |
|
 |
|