The MySQL Graph Collection - Version 2.0!
Moderators: Developers, Moderators
-
- Posts: 11
- Joined: Fri Jan 28, 2005 9:41 pm
- Location: USA
- Contact:
Can't get this to work
I gotta figure this one out :
at the command line:
[root@linuxserver scripts]# php -q /opt/administration/cacti/scripts/mysql_stats.php handler localhost cactiuser "myhardpsswd" delete:4024 read_first:16901 read_key:197801 read_next:133943 read_prev:0 read_rnd:135120 read_rnd_next:824705 update:1238 write:127007
all permissions working fine this should work??????
Cacti log says :
01/28/2005 08:15:04 AM - SYSTEM STATS: Time: 3.2767 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/28/2005 08:15:03 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 08:15:03 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 08:10:04 AM - SYSTEM STATS: Time: 3.2612 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/28/2005 08:10:04 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 08:10:03 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
needless to say graphs are empty
Graph import went well and I'm using "cactiuser" as apposed to cactiuser@localhost, but tryed both ways.
tryed entering manualy into data template : php -q /opt/administration/cacti/scripts/mysql_stats.php command localhost cactiuser "myhardpswd"
This produced one 5 minute post on graph but then stopped
Don't know what to do next kind of a newb, help to get this work would be appreciated, Thanks
at the command line:
[root@linuxserver scripts]# php -q /opt/administration/cacti/scripts/mysql_stats.php handler localhost cactiuser "myhardpsswd" delete:4024 read_first:16901 read_key:197801 read_next:133943 read_prev:0 read_rnd:135120 read_rnd_next:824705 update:1238 write:127007
all permissions working fine this should work??????
Cacti log says :
01/28/2005 08:15:04 AM - SYSTEM STATS: Time: 3.2767 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/28/2005 08:15:03 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 08:15:03 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 08:10:04 AM - SYSTEM STATS: Time: 3.2612 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/28/2005 08:10:04 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 08:10:03 AM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
needless to say graphs are empty
Graph import went well and I'm using "cactiuser" as apposed to cactiuser@localhost, but tryed both ways.
tryed entering manualy into data template : php -q /opt/administration/cacti/scripts/mysql_stats.php command localhost cactiuser "myhardpswd"
This produced one 5 minute post on graph but then stopped
Don't know what to do next kind of a newb, help to get this work would be appreciated, Thanks
- Attachments
-
- mysql_prob.JPG (166.15 KiB) Viewed 34073 times
-
- Posts: 11
- Joined: Fri Jan 28, 2005 9:41 pm
- Location: USA
- Contact:
run as webuser
sorry to ask this but what would the syntax be for this, the system will not let me logout and log back in at the command line as cactiuser?????
-
- Posts: 11
- Joined: Fri Jan 28, 2005 9:41 pm
- Location: USA
- Contact:
Figured out the easy stuff
Figured ou the shell access prob but I honestly did not expect this:
bash-2.05a$ php -q /opt/administration/cacti/scripts/mysql_stats.php handler localhost cactiuser "mypswd"
delete:7586 read_first:25962 read_key:332347 read_next:227497 read_prev:0 read_rnd:237011 read_rnd_next:1143641 update:1964 write:232608
It worked (by the way this is a freh install of 8.6c)
still cluless I''ve given "cactiuser all the privaleges on can give and flushed.
bash-2.05a$ php -q /opt/administration/cacti/scripts/mysql_stats.php handler localhost cactiuser "mypswd"
delete:7586 read_first:25962 read_key:332347 read_next:227497 read_prev:0 read_rnd:237011 read_rnd_next:1143641 update:1964 write:232608
It worked (by the way this is a freh install of 8.6c)
still cluless I''ve given "cactiuser all the privaleges on can give and flushed.
-
- Posts: 11
- Joined: Fri Jan 28, 2005 9:41 pm
- Location: USA
- Contact:
Still no luck
Tryed making the additional user cacti@127.0.0.1 but to no avail
01/28/2005 07:40:03 PM - SYSTEM STATS: Time: 3.1523 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/28/2005 07:40:03 PM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
01/28/2005 07:40:03 PM - SYSTEM STATS: Time: 3.1523 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/28/2005 07:40:03 PM - CMDPHP: Poller[0] Host[1] WARNING: Result from CMD not valid. Partial Result: Error: MySQL connect
-
- Posts: 11
- Joined: Fri Jan 28, 2005 9:41 pm
- Location: USA
- Contact:
No problem
I appreciate your help, yes I did this multiple times reinstalled/templates etc...............
-
- Posts: 11
- Joined: Fri Jan 28, 2005 9:41 pm
- Location: USA
- Contact:
Sorry for all the trouble..
Figured it out I guess upgraded to MySQL 4.0.23 and things seem to be working good. Still have one problem with the querycache graph.
log file reads :
1/29/2005 09:30:05 PM - SYSTEM STATS: Time: 4.1625 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/29/2005 09:25:04 PM - SYSTEM STATS: Time: 4.1703 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/29/2005 09:20:04 PM - SYSTEM STATS: Time: 4.1569 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
GOOD
log file reads :
1/29/2005 09:30:05 PM - SYSTEM STATS: Time: 4.1625 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/29/2005 09:25:04 PM - SYSTEM STATS: Time: 4.1703 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
01/29/2005 09:20:04 PM - SYSTEM STATS: Time: 4.1569 s, Method: cmd.php, Processes: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2
GOOD
- Attachments
-
- query_cache.JPG (185.42 KiB) Viewed 33996 times
Still trying to get this working, but i cant.
Here is the error of my poller :
01/31/2005 03:08:20 PM - CMDPHP: Poller[0] Host[2] WARNING: Result from CMD not valid. Partial Result:
When i run the script in console :
root@bretserv:/usr/local/apache2/secacti/scripts# php mysql_stat.php command localhost USER PASS
change_db:220122 delete:4499500 insert:4577368 select:4040935 update:314024
As you can see, the script is working, but why in cacti it isnt? I tried with every damn user , even nobody and the script works every time.
Why then i'm getting empty graph?
Here is the error of my poller :
01/31/2005 03:08:20 PM - CMDPHP: Poller[0] Host[2] WARNING: Result from CMD not valid. Partial Result:
When i run the script in console :
root@bretserv:/usr/local/apache2/secacti/scripts# php mysql_stat.php command localhost USER PASS
change_db:220122 delete:4499500 insert:4577368 select:4040935 update:314024
As you can see, the script is working, but why in cacti it isnt? I tried with every damn user , even nobody and the script works every time.
Why then i'm getting empty graph?
Hope this helps someone.
I found, in the Data Input Methods of, for example, "MySQL - Thread statistics", by swopping the <username> and the <password> within the command string it all seems to work.
Example:
Maybe some explanation from the experts?
Cheers
Byron
I found, in the Data Input Methods of, for example, "MySQL - Thread statistics", by swopping the <username> and the <password> within the command string it all seems to work.
Example:
to<path_php_binary> -q <path_cacti>/scripts/mysql_stats.php thread <hostname> <username> <password>
Looking at the mysql_stats.php, logically, my way shouldn't work, but it does.<path_php_binary> -q <path_cacti>/scripts/mysql_stats.php thread <hostname> <password> <username>
Maybe some explanation from the experts?
Cheers
Byron
-
- Cacti User
- Posts: 51
- Joined: Tue Apr 27, 2004 11:43 am
- Location: Duesseldorf, Germany
- Contact:
maybe this is the problem? (sorry again)note that the fields are sorted unnormal (first password, then username)...
sorry for that question
Last edited by ottob on Wed Feb 02, 2005 5:16 am, edited 1 time in total.
Who is online
Users browsing this forum: No registered users and 5 guests