Description

This article addresses an issue where the /var partition on Juniper devices reaches high utilization or becomes full due to large configuration database files in the /var/rundb directory. This condition may trigger system alarms and negatively impact configuration management operations, including delays or timeouts during commit and configuration comparison actions.

Symptoms

  • Minor RE 0 /var partition usage is high [or] Major RE 0 /var partition full system alarms.
  • Configuration comparisons (show | compare) fail, or experience extended delays or timeouts.
  • Configuration changes (commit) may fail to take effect.

Solution

Frequent load replacement operations can cause database size on disk can grow although the actual configuration size is less. This may result in Minor RE 0 /var partition usage is high [or] Major RE 0 /var partition is full system alarms. It can also lead to failed or delayed configuration comparisons (show | compare) and may cause commit operations to fail.

 

The following shell commands can be used to assess /var partition usage:

  • df -h /var                                                               # Check overall usage of the /var partition
  • du -xah /var | sort -rh | head -5                          # Lists the 5 largest files/directories in /var
  • du -xah /var/rundb | sort -rh | head -5               # Lists the 5 largest files/directories in /var/rundb

 

Resizing the configuration database reduces the size of the bloated juniper.db file to its expected size, freeing up disk space and resolving configuration comparison delays. Any commit operation performed after the database resize will also reduce the sizes of the associated files — juniper.data, juniper.data+, and juniper.save — further decreasing disk usage.

 

Recovery CLI Commands:

  • request system configuration database resize
  • configure
  • show | compare
  • commit

 

Example: 

  • juniper.db, juniper.save, juniper.data, juniper.data+ are each occupying 80 MB
  • Configuration database resize reduces the juniper.db from 80 MB to 1.5 MB
  • A commit following the configuration resize reduces the other database files referenced. 
  • The /var utilization drops from 90% to 18%, freeing over 300 MB of disk space. 
  • Storage alarms and configuration comparison/commit issues are resolved. 

root@qfx5200:RE:0% df -h /var
Filesystem     Size    Used   Avail Capacity  Mounted on
/dev/ada1p1    475M    394M     43M    90%  /.mount/var        

root@qfx5200:RE:0% du -xah /var | sort -rh | head -20
393M    /var
391M    /var/rundb
 80M    /var/rundb/juniper.save
 80M    /var/rundb/juniper.db
 80M    /var/rundb/juniper.data+
 80M    /var/rundb/juniper.data
 44M    /var/rundb/render.db
 
 
{master:0} 
root@qfx5200> show system configuration database usage
Maximum size of the database: 409.99 MB
Current database size on disk: 80.00 MB
Actual database usage: 79.68 MB
Available database space: 330.31 MB

{master:0}
root@qfx5200> request system configuration database resize
Configuration database resized

{master:0}
root@qfx5200> show system configuration database usage
Maximum size of the database: 409.99 MB
Current database size on disk: 1.50 MB
Actual database usage: 1.49 MB
Available database space: 408.51 MB

{master:0}
root@qfx5200> configure

{master:0}[edit]
root@qfx5200# show | compare

{master:0}[edit]
root@qfx5200# commit and-quit

{master:0}
root@j02-34> start shell

root@qfx5200:RE:0% df -h /var
Filesystem     Size    Used   Avail Capacity  Mounted on
/dev/ada1p1    475M    85M     390M    18%    /.mount/var        

Modification History

2025-07-20 : Article Created