NMIS Server Backup Procedures
NMIS Configuration Backup
NMIS includes a built-in configbackup job that runs automatically via the nmisd daemon every 24 hours.
What it backs up
Item | Path | Description |
|---|---|---|
Active configuration | conf/ | Config.nmis, plugins, scripts, custom settings |
Default configuration | conf-default/ | Default templates and reference configs |
Custom models | models-custom/ | Custom SNMP device models |
Default models | models-default/ | Default SNMP device models |
Node export | conf/all_nodes.json | JSON export of all node configs from MongoDB |
System cron | /etc/cron* | All system cron files, plus root and nmis user crontabs |
What it does NOT back up
MongoDB database (only exports node configs to JSON)
RRD performance data files
OMK product configurations (opCharts, opConfig, opEvents, etc.)
Log files
Where backups are stored
Backups are written to /usr/local/nmis9/backups/ (configurable via <nmis_backups> in Config.nmis).
Filename format: nmis-config-backup-YYYY-MM-DD-HHMM.tar.gz
Old backups are automatically purged after 30 days by the purge job.
Configuration
These settings can be adjusted in conf/Config.nmis:
Setting | Default | Description |
|---|---|---|
schedule_configbackup | 86400 (24 hours) | How often the backup runs (seconds) |
abort_configbackup_after | 900 (15 minutes) | Timeout before the job is aborted |
priority_configbackup | 0.3 | Job priority (0-1 scale, lower = less urgent) |
purge_backup_after | 2592000 (30 days) | How long to retain backup files |
Manual trigger
To run a backup manually:
bin/nmis-cli act=schedule job.type=configbackup
Pre-Upgrade Backup
During NMIS upgrades, the installer automatically offers to create a full installation backup (excluding the database) at ~/nmis-backup-YYYY-MM-DD.tgz.
This is handled by the installer_hooks/20-pre-backup script.