1

I'm running a website on a VPS running Centos 6.5 and am having some issues. I'm new to serveradmin so just learning. atop was already installed on our machine and it's working. I wanted to go in and analyse the historical logs but there is nothing in /var/log/atop/, the atop directory is there but is empty.

I thought that it's configured to create logs by default? The man pages are here: http://linux.die.net/man/1/atop

I changed the cron -> /etc/cron.d/atop from

0 0 * * * root /etc/rc.d/init.d/atop condrestart > /dev/null 2>&1 || :

to

0 0 * * * root /etc/atop/atop.daily

Should this get the log file working?

Any pointers would really help. I'm looking to see if my cpu usage is going crazy at a certain point or I'm running out of RAM which is why i'm using atop.

Thanks.

sciurus
  • 12,678
  • 2
  • 31
  • 49
user23744
  • 13
  • 1
  • 3

1 Answers1

2

Put /etc/cron.d/atop back to

0 0 * * * root /etc/rc.d/init.d/atop condrestart > /dev/null 2>&1 || :

Run

chkconfig atop on
service atop start
sciurus
  • 12,678
  • 2
  • 31
  • 49
  • Thanks a lot sciurus, it's working now and the log files are being created. So atop wasn't configured to run automatically on startup and that's what chkconfig atop on did? Does it matter about these runlevels? It's on for the default 2-5 alright. – user23744 Jun 11 '14 at 12:02
  • Yes, it wasn't configured to run on boot and chkconfig enabled it. Yes, running on those runlevels is good. – sciurus Jun 12 '14 at 01:42
  • and any idea how to limit the size of logs atop creates? check [here](http://serverfault.com/questions/775540/how-to-make-atop-create-less-log-files) – Aquarius Power May 08 '16 at 23:19