在Debian上运行sar时出现以下情况
Cannot open /var/log/sysstat/sa03: No such file or directory
Please check if data collecting is enabled

解决方法:
1 vi /etc/default/sysstat 修改为ENABLED=“true”

此时运行 systemctl restart sysstat 出现以下error
Failed to restart sysstat.service: Unit sysstat.service is masked.
2 运行 systemctl unmask sysstat
3 运行 systemctl start sysstat
此时在运行 sar -P ALL 查看每个CPU核的负载


本文介绍了解决Debian系统中使用sar命令时遇到的文件缺失错误,并提供了详细的步骤来确保数据收集功能正常工作。
12万+

被折叠的 条评论
为什么被折叠?



