https://github.com/maxboro/sys-log
System resources logging for Linux
https://github.com/maxboro/sys-log
lua lua-script resource-monitor system-resource system-resource-monitor
Last synced: 10 months ago
JSON representation
System resources logging for Linux
- Host: GitHub
- URL: https://github.com/maxboro/sys-log
- Owner: maxboro
- License: mit
- Created: 2025-01-18T10:37:15.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-19T09:36:28.000Z (over 1 year ago)
- Last Synced: 2025-04-05T19:48:40.353Z (about 1 year ago)
- Topics: lua, lua-script, resource-monitor, system-resource, system-resource-monitor
- Language: Lua
- Homepage:
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## Description
System resource logging for Linux.
Measurements performed each second.
Metrics tracked:
- CPU utilization
- RAM used
## How to run
```bash
lua main.lua
```
## Example
```terminal
Sat Jan 18 13:23:45 2025 | CPU Utilization: 1.7%, RAM Utilization: 533 MB
Sat Jan 18 13:23:46 2025 | CPU Utilization: 1.6%, RAM Utilization: 533 MB
Sat Jan 18 13:23:48 2025 | CPU Utilization: 7.7%, RAM Utilization: 532 MB
Sat Jan 18 13:23:49 2025 | CPU Utilization: 3.3%, RAM Utilization: 532 MB
Sat Jan 18 13:23:50 2025 | CPU Utilization: 3.1%, RAM Utilization: 532 MB
Sat Jan 18 13:23:51 2025 | CPU Utilization: 3.2%, RAM Utilization: 532 MB
Sat Jan 18 13:23:52 2025 | CPU Utilization: 3.2%, RAM Utilization: 531 MB
Sat Jan 18 13:23:54 2025 | CPU Utilization: 0%, RAM Utilization: 531 MB
Sat Jan 18 13:23:55 2025 | CPU Utilization: 3.3%, RAM Utilization: 531 MB
Sat Jan 18 13:23:56 2025 | CPU Utilization: 4.7%, RAM Utilization: 531 MB
Sat Jan 18 13:23:57 2025 | CPU Utilization: 0%, RAM Utilization: 530 MB
Sat Jan 18 13:23:58 2025 | CPU Utilization: 4.8%, RAM Utilization: 530 MB
```
## Dependencies
This project requires the following dependencies:
- **Lua 5.x** (tested with Lua 5.4.7)
- **LuaSocket**: A Lua library for networking and utility functions
- **LuaFileSystem**: A Lua library developed to complement the set of functions related to file systems
### Installation Instructions
#### Install Lua and LuaRocks
On Ubuntu/Debian:
```bash
sudo apt update
sudo apt install lua5.3 luarocks
sudo apt-get install lua-filesystem
```