Description

The following KB gives details of how request system software rollback works

1.) Initiate a Software rollback command and see how it functions
2) If the image is added to the device afterwards proceed to rollback then reboot to see if it loads with same version i.e staged version upgrade is cancelled or not

Solution

1.) Initiate a Software rolback and see how it functions

labroot@jtac-qfx5120-48y-8c-r2074> show version
localre:
--------------------------------------------------------------------------
Hostname: jtac-qfx5120-48y-8c-r2074
Model: qfx5120-48y-8i
Junos: 22.4R2-S2.6
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Current running version on QFX5120 i.e 22.4R2-S2.6 
 
JUNOS OS Kernel 64-bit [20230810.9da3819_builder_stable_12_224]

{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> show system software rollback
localre:
--------------------------------------------------------------------------
Image: qfx-5e-21.4R3-S7.8.202406070933 available for rollback.
         >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>Image available for rollback 21.4R3-S7.8
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> request system software rollback
localre:
--------------------------------------------------------------------------
Initiating rollback on the Host.
Rolling back to qfx-5e-21.4R3-S7.8.202406070933 image   
              >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>Rollback initiated
 
Rollback staged to image qfx-5e-21.4R3-S7.8.202406070933.             >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>21.4R3 is the new staged image on the device
Reboot the system to complete installation!
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> request system software rollback   
localre:
--------------------------------------------------------------------------
Initiating rollback on the Host.                           
           >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Again Rollback initiated
 
Rollback of the staged upgrade is complete.                           >>>>>>>>>>>>>>>>>>>>>>>>>>> Rollback of the staged image i.e 21.4R3 completed , which means now there is no staged image on the device
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> request system reboot   
          >>>>>>>>>>>>>>>>>>>>>> now initiated reboot to verify that device will load with same version that is running on it
Reboot the system ? [yes,no] (no) yes
 
                                                                              
*** System shutdown message from labroot@jtac-qfx5120-48y-8c-r2074 ***      
 
System going down in 1 minute  
                                               
 
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>Device booted with same version i.e 22.4R2-S2.6
 
 
2) To add the image afterwards proceed to rollback then reboot to see if it loads with same version
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> request system software add /var/tmp/jinstall-host-qfx-5e-x86-64-21.4R3-S7.8-secure-signed.tgz no-validate force-host >>>>>>>>>>>>>>>>>>New Junos version added 21.4R3
Verified jinstall-host-qfx-5e-x86-64-21.4R3-S7.8-secure-signed signed by PackageProductionECP256_2024 method ECDSA256+SHA256
Forcing the Host Upgrade for Non Issu updates...
Pushing Junos image package to the host...
Installing /var/tmp/install-media-qfx-5e-junos-21.4R3-S7.8-secure.tgz
Extracting the package ...
 ;;;
upgrade_platform: Staging of /var/tmp/jinstall-qfx-5e-junos-21.4R3-S7.8-secure-linux.tgz completed
upgrade_platform: System need *REBOOT* to complete the upgrade
upgrade_platform: Run upgrade_platform with option -r | --rollback to rollback the upgrade
 
Host OS upgrade staged. Reboot the system to complete installation!
 
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> show log install
2024-06-19 20:56:25 IST mgd[15449]: /usr/libexec/ui/package -X rollback
<output>
Initiating rollback o
upgrade_platform: Checksum verified and OK...
1062851 blocks
upgrade_platform: Staging of /var/tmp/jinstall-qfx-5e-junos-21.4R3-S7.8-secure-linux.tgz completed >>>>>>>>>>>>>>21.4R3 is the new staged image on the device
upgrade_platform: System need *REBOOT* to complete the upgrade
upgrade_platform: Run upgrade_platform with option -r | --rollback to rollback the upgrade
 
Host OS upgrade staged. Reboot the system to complete installation!

 
</output>
<package-result>0</package-result>     
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> request system software rollback
>>>>>>>>>>>>>>>>>>>>>>>>>>Rollback initiated
localre:
--------------------------------------------------------------------------
Initiating rollback on the Host.
 
Rollback of the staged upgrade is complete
.>>>>>>>>>>>>>>>>>>Rollback of the staged image i.e 21.4R3 completed ,which means now there is no staged image on the device
 
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> show version
localre:
--------------------------------------------------------------------------
Hostname: jtac-qfx5120-48y-8c-r2074
Model: qfx5120-48y-8c
Junos: 22.4R2-S2.6

{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> request system reboot
Reboot the system ? [yes,no] (no) yes   
        >>>>>>>>>>>>>>>>>now initiated reboot to verify that device will load with same version that is running on it
 
                                                                              
*** System shutdown message from labroot@jtac-qfx5120-48y-8c-r2074 ***      
 
System going down in 1 minute              
{master:0}
labroot@jtac-qfx5120-48y-8c-r2074> show version
localre:
--------------------------------------------------------------------------
Hostname: jtac-qfx5120-48y-8c-r2074
Model: qfx5120-48y-8c
Junos: 22.4R2-S2.6   
               >>>>>>>>>>>>>>>>>>>>>>>>>>>Device rebooted with same version I.e 22.4R2-S2.6
JUNOS OS Kernel 64-bit [20230810.9da3819_builder_stable_12_224]
JUNOS OS libs [20230810.9da3819_builder_stable_12_224]





 

Modification History

2024-07-18: Article validated
2024-06-29 : Article Created