Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

header-navigation
keyboard_arrow_up
close
keyboard_arrow_left
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

Ensure Sufficient Disk Space for Upgrades

date_range 20-Dec-24

The amount of free disk space necessary to upgrade a device with a new version of Junos OS Evolved can vary from one release to another. Check the software version you are installing to determine the free disk space requirements, and then clear enough disk space for the upgrade.

If the /soft, /var, or /data directories are at 90% capacity or more, the device does not have enough storage space to install a software package. If the amount of storage space on a device is insufficient for installing Junos OS Evolved, you might receive a warning similar to the following messages, that a file system is low on free disk space:

WARNING: The /soft filesystem is low on free disk space.

WARNING: This package requires 1075136k free, but there is only 666502k available.

When the system file storage space on the device is full, rebooting the device does not solve the problem. The following error message displays during a typical operation on the device after the file storage space is full: user@host> configure /soft: write failed, filesystem is full

  1. To determine the amount of free disk space on the device, issue the show system storage command. The command output displays statistics about the amount of free disk space in the device's file system.

    For example:

    content_copy zoom_out_map
    user@host> show system storage
    fpc0:
    --------------------------------------------------------------------------
    Filesystem              Size       Used      Avail  Capacity   Mounted on
    /dev/root                30M        30M          0      100%  /run/initramfs
    /dev/ram1p2             4.9G       586M       4.0G       13%  /soft
    /dev/ram1p5              93M        19M        68M       22%  /data
    /dev/ram1p7             2.7G        66M       2.4G        3%  /var
    /dev/loop0              379M       2.3M       353M        1%  /data/var/external
    devtmpfs                 16G          0        16G        0%  /dev
    [...output truncated...]
    
    fpc1:
    --------------------------------------------------------------------------
    Filesystem              Size       Used      Avail  Capacity   Mounted on
    /dev/root                30M        30M          0      100%  /run/initramfs
    /dev/ram1p2             4.9G       586M       4.0G       13%  /soft
    /dev/ram1p5              93M        19M        68M       22%  /data
    /dev/ram1p7             2.7G        42M       2.5G        2%  /var
    /dev/loop0              379M       2.3M       353M        1%  /data/var/external
    devtmpfs                 16G          0        16G        0%  /dev
    [...output truncated...]
    
    re0:
    --------------------------------------------------------------------------
    Filesystem              Size       Used      Avail  Capacity   Mounted on
    /dev/root                34M        34M          0      100%  /run/initramfs
    /dev/sda2                32G        10G        21G       34%  /soft
    /dev/sda5               3.0G       179M       2.6G        7%  /data
    /dev/sda7               145G       4.5G       134G        4%  /var
    /dev/loop0               15G        38M        14G        1%  /data/var/external
    devtmpfs                 32G          0        32G        0%  /dev
    /tmp                     32G          0        32G        0%  /run/initramfs/uswitch/tmp
    /dev/loop1              517M       517M          0      100%  /run/initramfs/uswitch/data/hashes/8e6065a478c593473cd390245274128f1a5885e8
    /dev/loop2               29M        29M          0      100%  /run/initramfs/uswitch/data/hashes/244e2161887b001792709ec078f864c966baca88
    /dev/loop3               36M        36M          0      100%  /run/initramfs/uswitch/data/hashes/4cad203feb9c1bd4a903f03503a6777509e4031d
    /dev/loop4               10M        10M          0      100%  /run/initramfs/uswitch/data/hashes/5f9454b8d26e33715373f621d16c9c752e3ff57b
    /dev/loop5               46M        46M          0      100%  /run/initramfs/uswitch/data/hashes/182901abd18cefe6f63397bcbb6f2a8238d38a9b
    /dev/loop6              9.8M       9.8M          0      100%  /run/initramfs/uswitch/data/hashes/c08bb2c69ae7ff2446bdcb32011a03a4a53c5585
    /dev/loop7               58M        58M          0      100%  /run/initramfs/uswitch/data/hashes/c92e70dc394c01bf5a2a9d06ffcc25ba673286d1
    /dev/loop8               34M        34M          0      100%  /run/initramfs/uswitch/data/hashes/90fdfeec1bab47c19641d636598a4205bbb7949d
    /dev/loop9              8.2M       8.2M          0      100%  /run/initramfs/uswitch/data/hashes/3874cf9fea904b2d5d3f6920671864bdc05130a2
    /dev/loop10              34M        34M          0      100%  /run/initramfs/uswitch/data/hashes/35afa8ff63aded42bd23444b672dcd33b922898c
    /dev/loop11             7.0M       7.0M          0      100%  /run/initramfs/uswitch/data/hashes/15684de48b2a621a98afaf9619026dd81cdf74bd
    /dev/loop12             4.5M       4.5M          0      100%  /run/initramfs/uswitch/data/hashes/2d75968c5d882c86b38015fc93fe9e148e226407
    /dev/loop13             148M       148M          0      100%  /run/initramfs/uswitch/data/hashes/ccb0c8af3d4b26bddf9ccc047aa7e76d34e31387
    uswitchd                7.0M       7.0M          0      100%  /run/initramfs/uswitch/data/junos-evo-install-ptx-x86-64-21.2I20210315015050-EVO__cd-builder/uswitch
    unionfs                 3.0G       186M       2.6G        7%  /
    /dev/sda1               196M        19M       178M       10%  /boot
    /dev/sda6               984M       1.5M       916M        1%  /data/config
    /tmp                     32G        68K        32G        1%  /tmp
    tmpfs                    32G        28M        32G        1%  /run
    tmpfs                    32G       123M        32G        1%  /dev/shm
    tmpfs                    32G          0        32G        0%  /sys/fs/cgroup
    tmpfs                   6.3G          0       6.3G        0%  /run/user/0
    
    re1:
    --------------------------------------------------------------------------
    Filesystem              Size       Used      Avail  Capacity   Mounted on
    /dev/root                34M        34M          0      100%  /run/initramfs
    /dev/sda2                32G        10G        21G       34%  /soft
    /dev/sda5               3.0G       321M       2.5G       12%  /data
    /dev/sda7               145G       3.0G       135G        3%  /var
    /dev/loop0               15G        38M        14G        1%  /data/var/external
    devtmpfs                 32G          0        32G        0%  /dev
    [...output truncated...]
    
  2. If the amount of free disk space on a device is insufficient for installing Junos OS Evolved, you can clean up the file storage on the device by deleting the system files or unnecessary software images. You can use either the request system storage cleanup or the request system software delete operational mode command, or both, depending on where you need to clear space.
    1. Issue the request system storage cleanup operational mode command on the primary Routing Engine to delete system files in the /var directory for all Routing Engines in a system, usually system-log and trace files.

      The list of files to be deleted displays:

      content_copy zoom_out_map
      user@host> request system storage cleanup
      List of files to delete:
      
               Size Date         Name
          11B Oct 28 23:40 /var/jail/tmp/alarmd.ts
        92.4K Jan 11 17:12 /var/log/chassisd.0.gz
        92.4K Jan 11 06:06 /var/log/chassisd.1.gz
        92.5K Jan 10 19:00 /var/log/chassisd.2.gz
        92.5K Jan 10 07:53 /var/log/chassisd.3.gz
        92.2K Jan 10 15:00 /var/log/hostlogs/auth.log.1.gz
        92.2K Jan  1 18:45 /var/log/hostlogs/auth.log.2.gz
        92.1K Jan  4 17:30 /var/log/hostlogs/auth.log.3.gz
        92.2K Jan  1 18:45 /var/log/hostlogs/auth.log.4.gz
        79.0K Jan 12 01:59 /var/log/hostlogs/daemon.log.1.gz
        78.8K Jan 11 23:15 /var/log/hostlogs/daemon.log.2.gz
        78.7K Jan 11 20:30 /var/log/hostlogs/daemon.log.3.gz
        79.1K Jan 11 17:44 /var/log/hostlogs/daemon.log.4.gz
        59.1K Jan 11 21:59 /var/log/hostlogs/debug.1.gz
        59.2K Jan 11 17:44 /var/log/hostlogs/debug.2.gz
        59.2K Jan 11 13:29 /var/log/hostlogs/debug.3.gz
        59.3K Jan 11 09:14 /var/log/hostlogs/debug.4.gz
       186.6K Oct 20 16:31 /var/log/hostlogs/kern.log.1.gz
       238.3K Jan 11 23:15 /var/log/hostlogs/lcmd.log.1.gz
       238.4K Jan 11 17:30 /var/log/hostlogs/lcmd.log.2.gz
       238.6K Jan 11 11:45 /var/log/hostlogs/lcmd.log.3.gz
       238.5K Jan 11 06:00 /var/log/hostlogs/lcmd.log.4.gz
       372.5K Jan 11 17:00 /var/log/hostlogs/syslog.1.gz
       372.5K Jan 11 04:45 /var/log/hostlogs/syslog.2.gz
       371.9K Jan 10 16:30 /var/log/hostlogs/syslog.3.gz
       372.7K Jan 10 04:15 /var/log/hostlogs/syslog.4.gz
        10.1K Jan 12 02:03 /var/log/messages.0.gz
        55.1K Jan  6 21:25 /var/log/messages.1.gz
        81.5K Dec  1 21:30 /var/log/messages.2.gz
      
      Delete these files ? [yes,no] (no)    

      Enter the option yes to delete the files.

    2. Before you can clean up unnecessary software images in the /soft and /data directories for all Routing Engines in a system, you must first find out what images exist on the device, using the show system software list operational mode command.
      content_copy zoom_out_map
      -------------------------------
      node: fpc0
      -------------------------------
      Active boot device is primary: /dev/ram1
      List of installed version(s) :
      
          '-' running version
          '>' next boot version after upgrade/downgrade
          '<' rollback boot version
      
       -   junos-evo-install-ptx-x86-64-20.4-202103151929.0-EVO - [2021-03-17 12:18:07]
      -------------------------------
      node: re0
      -------------------------------
      Active boot device is primary: /dev/sda
      List of installed version(s) :
      
          '-' running version
          '>' next boot version after upgrade/downgrade
          '<' rollback boot version
      
       <   junos-evo-install-ptx-x86-64-20.4-202103121629.0-EVO - [2021-03-17 11:22:40]
       -   junos-evo-install-ptx-x86-64-20.4-202103151929.0-EVO - [2021-03-17 10:50:39]
           junos-evo-install-ptx-x86-64-20.4-202103131143.0-EVO - [2021-03-16 16:12:38]
           junos-evo-install-ptx-x86-64-20.4-202103141559.0-EVO - [2021-03-15 17:26:42]
      -------------------------------
      node: re1
      -------------------------------
      Active boot device is primary: /dev/sda
      List of installed version(s) :
      
          '-' running version
          '>' next boot version after upgrade/downgrade
          '<' rollback boot version
      
       <   junos-evo-install-ptx-x86-64-20.4-202103121629.0-EVO - [2021-03-17 11:25:03]
       -   junos-evo-install-ptx-x86-64-20.4-202103151929.0-EVO - [2021-03-17 10:50:39]
           junos-evo-install-ptx-x86-64-20.4-202103131143.0-EVO - [2021-03-16 16:14:55]
           junos-evo-install-ptx-x86-64-20.4-202103141559.0-EVO - [2021-03-15 17:57:05]

      You can delete software images one at a time or you can delete all software images except for the current and rollback images. These commands delete the images on all Routing Engines in the system.

      • To delete the software images one at a time, issue the request system software delete image-name operational mode command for each image you need to delete. If you delete this image, you cannot downgrade to this particular version of the software. You cannot delete the currently running software version. Use the force option to delete the rollback software image.
      • Starting in Junos OS Evolved Release 20.4R2, to delete all software images except for the current and rollback images, issue the request system software delete archived operational mode command. This command fails when a next-boot software image is on the Routing Engine; a new software image was installed, but the device has not yet been rebooted to finish the installation process.
        content_copy zoom_out_map
        user@host-re0> request system software delete archived
        ALERT:  This command will delete all archived SW versions except current and rollback.
                Do you want to proceed? [yes,no] (no) yes
        
        Software delete in progress...
        re0: Executing Software delete...
        re0: Cannot delete junos-evo-install-ptx-x86-64-20.4-202103141559.0-EVO - It is the current version
        re0: Rollback or scratch install
        re0: Removing version junos-evo-install-ptx-x86-64-20.4-202103150459.0-EVO...
        re0: Removing version junos-evo-install-ptx-x86-64-20.4-202103111254.0-EVO...
        re1: Removing version junos-evo-install-ptx-x86-64-20.4-202103150459.0-EVO...
        re1: Removing version junos-evo-install-ptx-x86-64-20.4-202103111254.0-EVO...
        Image deletion succeeded.
footer-navigation