Description

When copying the file from Juniper portal using the file copy command, the switch will report "No space left on device"

Symptoms

Customer observing below error while copy the Junos code from Juniper portal.

root@QFX> file copy "https://cdn.juniper.net/software/junos/25.2R1/jinstall-host-qfx-5e-x86-64-25.2R1.9-secure-signed.tgz?SM_USER=user@juniper.net&__gda__=1756840043_29786aa589da87a05d42faf449c05929" /var/tmp/jinstall-host-qfx-5e-x86-64-23.4R2-S1.3-secure-signed.tgz routing-instance mgmt_junos

/var/tmp//...transferring.file.........3o8f1m/100% of 1609 MB 3067 kBps 00m00s
/.mount/var/tmp: write failed, filesystem is full
cp: /var/tmp/jinstall-host-qfx-5e-x86-64-23.4R2-S1.3-secure-signed.tgz: No space left on device
error: put-file failed
error: could not send local copy of file

Solution

    To isolate the issue, we need to use the stagging directory when using "file copy command" .

    The /tmp stagging directory  is ~5.4gb , this will hold the 2x times when using the file copy command, the destination directory can be either /tmp or /var/tmp/jinstall... (/var/tmp is preferred) , once the file is copied to stagging directory, It will transfer it to the destination directory.

     

    
    root@QFX> file copy "https://cdn.juniper.net/software/junos/25.2R1/jinstall-host-qfx-5e-x86-64-25.2R1.9-secure-signed.tgz?SM_USER=user@juniper.net&__gda__=1756840043_29786aa589da87a05d42faf449c05929" /var/tmp/jinstall-host-qfx-5e-x86-64-25.2R1.9-secure-signed.tgz staging-directory /tmp/ routing-instance mgmt_junos 
    /tmp//...transferring.file.........enr0H2/jins100% of 1564 MB 2609 kBps 10m13s#

     

    If the issue still present, please check the following 

    • Check the storage is there any issue, try to clear the storage using "request system storage cleanup" command.
    • If the issue still persists, please copy the code into /tmp and proceed with upgrade.

     

    root@QFX> file copy "https://cdn.juniper.net/software/junos/25.2R1/jinstall-host-qfx-5e-x86-64-25.2R1.9-secure-signed.tgz?SM_USER=user@juniper.net&__gda__=1756837965_7b0c6f4fb5e1f6c2bf8a1e04a7af4ecf" /tmp/jinstall-host-qfx-5e-x86-64-25.2R1.9-secure-signed.tgz staging-directory /tmp/ routing-instance mgmt_junos 
    
    /tmp//...transferring.file.........jh9z2x/jins100% of 1564 MB 2630 kBps 10m08s#
    
    {master:0}
    root@QFX> #

    Modification History

    2024-08-28 : Article Created

    2025-09-09 : Added additional outputs and font corrections.