Automating Inventory with FusionInventory Agent — Best Practices
1. Deployment strategy
- Use packages (deb/rpm/MSI) for managed installs; prefer your distribution’s package or FusionInventory’s maintained repos to prebuilts.
- Automate wide rollout via configuration management (Ansible/Puppet/Chef), SCCM, Chocolatey, or AD GPO (MSI + MST).
- Staged rollout: test on lab → pilot group → full fleet.
2. Central configuration
- Preconfigure agent.cfg (or registry keys on Windows) with server URL(s), tags, proxy, and TLS/CA settings before deployment.
- Use consistent tags to map devices to locations/groups for targeted policies and reporting.
3. Secure communications
- Use HTTPS and validate server certificates; deploy a CA cert to agents if using internal CA.
- Avoid disabling SSL checks in production. If proxying, ensure proxy trusts the server certificate.
4. Inventory frequency & load planning
- Default schedule: inventory every 24 hours for large fleets; shorten to 6–12 hours only if necessary.
- Stagger schedules (randomized start windows or group-based offsets) to avoid server overload.
- Monitor server capacity (CPU, DB I/O, web workers) and scale (vertical/horizontal) before increasing agent frequency.
5. Tasks selection & performance
- Enable only needed tasks (hardware/software by default; enable network discovery, SNMP, nmap only where required).
- Avoid expensive tasks (full network scans, deep file scans) on every run — schedule them off-hours or by tag.
- Limit home/virtual detection scans on user endpoints to reduce disk/CPU impact.
6. Authentication & access control
- Use agent credentials or tokens per environment; rotate credentials periodically.
- Least privilege: run agent with an account that has only required permissions.
7. Logging, monitoring & alerting
- Centralize logs (syslog/Windows Event Forwarding) for troubleshooting and trend analysis.
- Enable debug only temporarily. Collect normal logs and enable debug for reproduction.
- Alert on failed check-ins rates, sudden inventory drops, or spike in error logs.
8. Updates & lifecycle
- Keep agents up to date—automate upgrades via your package manager or management tool.
- Test new agent versions in a pilot before full deployment.
- Document rollback steps for problematic upgrades.
9. Integration with CMDB/ITSM
- Map tags and fields to GLPI/OCS or your CMDB fields consistently.
- Automate synchronization and reconcile duplicates using unique identifiers (MAC, serial, asset tag).
- Use workflows for new device onboarding and change detection (e.g., new software alerts).
10. Troubleshooting checklist (quick)
- Confirm agent connectivity to server URL (curl/wget or Test-NetConnection).
- Check agent logs for errors (agent.cfg location or Windows registry).
- Verify certificate chain and proxy settings.
- Run local inventory (–local) to validate data collection.
- Compare agent version and task modules; enable debug only if needed.
11. Example defaults (reasonable assumptions)
- Inventory interval: 24 hours
- Stagger window: 0–120 minutes randomized per host group
- Enabled tasks: hardware, software, network interfaces
- TLS: Enforce certificate validation with internal CA deployed to agents
If you want, I can generate:
- A sample agent.cfg for Linux/Windows with secure defaults, or
- A PowerShell/Ansible snippet to deploy and preconfigure FusionInventory Agent across a Windows or Linux fleet.
Leave a Reply