More CPU Usage consuming by cacti in my dedicated server !
Moderators: Developers, Moderators
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
More CPU Usage consuming by cacti in my dedicated server !
Hi Guys,
I have installed cacti 0.8.8a version in my dedicated server. Everything is ok like plotting,etc.. but it consumes more cpu usage on my server. can you please update what is the reason for this ?
Server info :
Cent OS : 6.4(Final)
8 Core CPU
8GB RAM
Let me know if you need any other info.
Thanks,
Gugan,
I have installed cacti 0.8.8a version in my dedicated server. Everything is ok like plotting,etc.. but it consumes more cpu usage on my server. can you please update what is the reason for this ?
Server info :
Cent OS : 6.4(Final)
8 Core CPU
8GB RAM
Let me know if you need any other info.
Thanks,
Gugan,
-
- Cacti Pro User
- Posts: 613
- Joined: Tue Aug 29, 2006 4:09 pm
- Location: NL
Re: More CPU Usage consuming by cacti in my dedicated server
more than what?gugansankar wrote:it consumes more cpu usage
Maintainer of cacti in Debian (and Ubuntu).
Cacti 1.* is now officially supported on Debian Stretch via Debian backports
FAQ Ubuntu and Debian differences
Generic cacti debugging
Cacti 1.* is now officially supported on Debian Stretch via Debian backports
FAQ Ubuntu and Debian differences
Generic cacti debugging
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
It consumes above 90 % in my new dedicated server. But in my old server, it doesn't use this much cpu usage.
Problem came only after migrated the cacti to this new dedicated server.
Old server details :
OS : Centos 5.7
8 Core CPU
8GB RAM
Cacti 0.8.8a
spine 0.8.8.a
New dedicated server details :
OS : Centos 6.4
8 core CPU
8GB RAM
Cacti 0.8.8a
Spine 0.8.8a
Please help me on this
Thanks,
Gugan.K
Problem came only after migrated the cacti to this new dedicated server.
Old server details :
OS : Centos 5.7
8 Core CPU
8GB RAM
Cacti 0.8.8a
spine 0.8.8.a
New dedicated server details :
OS : Centos 6.4
8 core CPU
8GB RAM
Cacti 0.8.8a
Spine 0.8.8a
Please help me on this
Thanks,
Gugan.K
Re: More CPU Usage consuming by cacti in my dedicated server
Make sure you are using Spine instead of cmd.php (in the Settings tab). Also, try using the Boost plug-in.
-John
-John
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
Hi,
yes, i am using spine poller for cacti polling. And one more thing, after i searched something serious in google and final found one solution that helped me only in half percentage.
=====
cat /etc/my.cnf
.....
innodb_file_per_table=1
local-infile=0
open_files_limit=10240
query_cache_size=16M
join_buffer_size=512K
thread_cache_size=8
table_cache=512
I have added the above entry in my my.cnf file. now the CPU usage reduced from 90 % to 70 %. So can anyone please tell me which one makes my cpu usage reduced. Is there any possible to decrease my CPU usage to 5-10 % ?
Note : once i stopped my cacti process(poller process in cron), Server CPU usage comes down to 5 % of maximum.
Thanks,
Gugan.K
yes, i am using spine poller for cacti polling. And one more thing, after i searched something serious in google and final found one solution that helped me only in half percentage.
=====
cat /etc/my.cnf
.....
innodb_file_per_table=1
local-infile=0
open_files_limit=10240
query_cache_size=16M
join_buffer_size=512K
thread_cache_size=8
table_cache=512
I have added the above entry in my my.cnf file. now the CPU usage reduced from 90 % to 70 %. So can anyone please tell me which one makes my cpu usage reduced. Is there any possible to decrease my CPU usage to 5-10 % ?
Note : once i stopped my cacti process(poller process in cron), Server CPU usage comes down to 5 % of maximum.
Thanks,
Gugan.K
Re: More CPU Usage consuming by cacti in my dedicated server
When you run top, what program does is report as the CPU hog?
-John
-John
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
Mysqld and php(poller.php) comsumes more cpu usage on my server.
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
5209 root 20 0 213m 24m 7684 S 46.8 0.3 0:04.44 /usr/bin/php /usr/share/cacti-snmpspine/poller.php
51222 mysql 20 0 4262m 59m 4988 S 20.9 0.8 260:44.78 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql --log-error=/var/log/mysqld.l
5215 root 20 0 203m 7004 2360 S 2.7 0.1 0:00.33 /usr/local/spine/bin/spine 0 87
Thanks
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
5209 root 20 0 213m 24m 7684 S 46.8 0.3 0:04.44 /usr/bin/php /usr/share/cacti-snmpspine/poller.php
51222 mysql 20 0 4262m 59m 4988 S 20.9 0.8 260:44.78 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql --log-error=/var/log/mysqld.l
5215 root 20 0 203m 7004 2360 S 2.7 0.1 0:00.33 /usr/local/spine/bin/spine 0 87
Thanks
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
Can anyone please help on the above issue ?
Regards,
GK
Regards,
GK
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Re: More CPU Usage consuming by cacti in my dedicated server
For comparing. it makes sense to use same my.cnf as in your "old" server. E.g. innodb parameters make no sense for cacti, as it is using MyISAM (at least by default)gugansankar wrote:Hi,
yes, i am using spine poller for cacti polling. And one more thing, after i searched something serious in google and final found one solution that helped me only in half percentage.
=====
cat /etc/my.cnf
.....
innodb_file_per_table=1
local-infile=0
open_files_limit=10240
query_cache_size=16M
join_buffer_size=512K
thread_cache_size=8
table_cache=512
I have added the above entry in my my.cnf file. now the CPU usage reduced from 90 % to 70 %. So can anyone please tell me which one makes my cpu usage reduced. Is there any possible to decrease my CPU usage to 5-10 % ?
Note : once i stopped my cacti process(poller process in cron), Server CPU usage comes down to 5 % of maximum.
Thanks,
Gugan.K
R.
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
This is my old and New server /etc/my.cnf entries,
Od Server my.cnf file,
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1
max_connections=500
# Disabling symbolic-links is recommended to prevent assorted security risks;
# to do so, uncomment this line:
# symbolic-links=0
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
New Server my.cnf file,.
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
max_connections=800
innodb_file_per_table=1
local-infile=0
open_files_limit=10240
query_cache_size=16M
join_buffer_size=512K
thread_cache_size=8
table_cache=512
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
You have new mail in /var/spool/mail/root
Please advice me what are the differences on the above entry.
Regards,
GK
Od Server my.cnf file,
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1
max_connections=500
# Disabling symbolic-links is recommended to prevent assorted security risks;
# to do so, uncomment this line:
# symbolic-links=0
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
New Server my.cnf file,.
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
max_connections=800
innodb_file_per_table=1
local-infile=0
open_files_limit=10240
query_cache_size=16M
join_buffer_size=512K
thread_cache_size=8
table_cache=512
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
You have new mail in /var/spool/mail/root
Please advice me what are the differences on the above entry.
Regards,
GK
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Re: More CPU Usage consuming by cacti in my dedicated server
You can find the differences when using diff against both files.
Apart from max_connections, ths first one looks quite standard. And increasing max_connections is a good move.
The "new" parms seen in the second one are tuning related and not necessarily bad. MySQL tuning is beyond the scope of this forum. You may find some other user posts providing their my.cnf settings. But mostly without explaining why any parameter has been changed. It might be a better idea to discuss this in any MySQL forum/mailing list.
Yes, we have tuned our MySQL as well, but I'm far away from being able to explain every move. For me, it was a bit of fiddeling around (MySQL admins: don't shout at me).
R.
Apart from max_connections, ths first one looks quite standard. And increasing max_connections is a good move.
The "new" parms seen in the second one are tuning related and not necessarily bad. MySQL tuning is beyond the scope of this forum. You may find some other user posts providing their my.cnf settings. But mostly without explaining why any parameter has been changed. It might be a better idea to discuss this in any MySQL forum/mailing list.
Yes, we have tuned our MySQL as well, but I'm far away from being able to explain every move. For me, it was a bit of fiddeling around (MySQL admins: don't shout at me).
R.
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
Ok.If the DB related thing are out of scope means, why server utilizing high cpu usage once dump the database from old server to new server.
Is there any OS related differences, because now i tried to dump the one more server which has an old server architecture where as i didn't face this problem.
Can you please advice me reg this ?
This is my hardware details,
Old server details :
OS : Centos 5.7
8 Core CPU
8GB RAM
Cacti 0.8.8a
spine 0.8.8.a
New dedicated server details :
OS : Centos 6.4
8 core CPU
8GB RAM
Cacti 0.8.8a
Spine 0.8.8a
Thanks,
GK
Is there any OS related differences, because now i tried to dump the one more server which has an old server architecture where as i didn't face this problem.
Can you please advice me reg this ?
This is my hardware details,
Old server details :
OS : Centos 5.7
8 Core CPU
8GB RAM
Cacti 0.8.8a
spine 0.8.8.a
New dedicated server details :
OS : Centos 6.4
8 core CPU
8GB RAM
Cacti 0.8.8a
Spine 0.8.8a
Thanks,
GK
- gandalf
- Developer
- Posts: 22383
- Joined: Thu Dec 02, 2004 2:46 am
- Location: Muenster, Germany
- Contact:
Re: More CPU Usage consuming by cacti in my dedicated server
Are both servers using 64 bit architecture?
Did you recompile spine on the new server?
R.
Did you recompile spine on the new server?
R.
-
- Posts: 13
- Joined: Sat Sep 07, 2013 12:30 am
Re: More CPU Usage consuming by cacti in my dedicated server
Everything is same in new server as old one except OS version.
Old server : Centos 5.8
New server : Centos 6.4
As you asked, Architecture is same in both servers(64 bit architecture).
Thanks
GK
Old server : Centos 5.8
New server : Centos 6.4
As you asked, Architecture is same in both servers(64 bit architecture).
Thanks
GK
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: More CPU Usage consuming by cacti in my dedicated server
Also, what kind of storage do both systems have? Cacti (rrdtool) is heavy on i/o.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Who is online
Users browsing this forum: No registered users and 3 guests