I'm managing a variety of Linux systems, some older and some more updated, and I often move drives between them. I want a uniform report at boot that lists everything installed and provides hardware details. I'm looking for a way to get a comprehensive logging of all installed packages and hardware information whenever the system starts up. I tried searching online for solutions that could help me automate this, but I'm not sure if this is an existing tool or if I need to write a custom script. Can anyone point me in the right direction?
4 Answers
Don’t forget about using dpkg -l for Debian/Ubuntu or the equivalent command for other distros to list installed packages. You might also need to account for other package managers if you're using extras like snaps or flatpaks.
While it's certainly possible to do this yourself, I'd recommend looking into configuration management tools like Ansible or CFEngine. They can standardize your deployments and gather all necessary info easily, saving you the hassle of managing these reports manually at every boot.
Exactly! Ansible allows you to specify which facts to gather, making it distro-agnostic. It’s a powerful solution that limits the need for custom scripting.
If boot-time logging isn’t a strict requirement, you could consider running scripts periodically instead. It might simplify the process a lot. Just set a cron job to gather that data at intervals you choose.
You might want to check out cfg2html; it does exactly what you're looking for. It can generate reports about installed packages and hardware configurations automatically!
Right! There's no need to reinvent the wheel when plenty of tools like Zabbix and Prometheus exist for inventory tracking.