sysstat is the package that you will need to install in order to get the sar
# apt-get install sysstat
Note: After you install the package, you will get the below error as you will need to configure sysstat to collect data.
# sar
Cannot open /var/log/sysstat/sa12: No such file or directory
Please check if data collecting is enabled in /etc/default/sysstat
Steps Configure sysstat
- Open /etc/default/sysstat configuration file and set the ENABLED flag to true.
root@ubuntu # nano /etc/default/sysstat
# # Default settings for /etc/init.d/sysstat, /etc/cron.d/sysstat # and /etc/cron.daily/sysstat files # # Should sadc collect system activity informations? Valid values # are "true" and "false". Please do not put other values, they # will be overwritten by debconf! ENABLED="true"
- Restart the sysstat service
root@ubuntu # service sysstat restart * Starting the system activity data collector sadc
Note: The default setting to collect stats in activity reports is every 10 minutes everyday, you can change it by editing the cron expression in /etc/cron.d/sysstat config file.
-
Have Questions? Post them here!
More Posts related to Linux,
- [Fix] Linux - bash: useradd: command not found
- Calculate days between dates using dateutils ddiff command
- pwd Command - Print Working Directory
- Rename a directory using Linux/Unix command
- How to go to the End of File in Nano Editor
- How to tar.gz a directory or folder Command
- How to remove/delete a directory in Linux/macOs
- How to Display content of a file in Terminal Screen?
- ls command sort by file size [Linix/UNIX/macOS/bash]
- How to Copy Entire Directory to another Directory in Linux
- 3 ways to clear screen on Linux Terminal
- Command to check Last Login or Reboot History of Users and TTYs
- How to check uptime of Linux/Unix/macOS system/server using console command?
- How to backup a file in Linux/Unix
- Command to know the installed Debian version?
- Check SSH/OpenSSH version Command
- 3 Commands to stop Nginx Server
- Linux: Create a New User and Password and Login Example
- How to install npm on Ubuntu
- How to List All Users in Linux
- How to Get the List of Shells on Linux
- Fix - ssh-copy-id no identities found error
- Installing and using unzip Command to unzip a zip file using Terminal
- scp: ssh: connect to host xxxx port 22: Connection refused Error
- zsh hello world example
More Posts:
- [fix] NullPointerException Cannot Invoke findById because Repository is null - Java Spring - Java
- JavaScript : Get current page address - JavaScript
- Its almost time - Apple Event September 10 10 am PDT ⚡️ - Apple
- You can now Transfer Facebook Posts to Google Photos, Docs, Checkout how! - News
- How to create Toast messages in Android? - Android
- M1/M2 Mac VirtualBox Unsupported hardware architecture detected! - MacOS
- How to make jsfiddle bootstrap ready - CSS
- Android: Unknown error code during application install : - Android