Changing SNC serial number in a .fw file

 

 

Get the correct serial from the current SN appliance.

 

[root@sps-xcellis1 scratch]# cat /opt/DXi/system-serialnumber

AV1652CKH00338

 

The BOM.json file holds these serial references.

 

[jmcnerny@srscratch pers]$ zgrep -a AV1709CKG00015 customer-install-1.2.0-26115758-AV1709CKG00015.fw

            "serial-number": "AV1709CKG00015"

        "connect-name": "AV1709CKG00015",

 

Rename the .fw file.

 

[jmcnerny@srscratch pers]$ cp customer-install-1.2.0-26115758-AV1709CKG00015.fw customer-install-1.2.0-26115758-AV1709CKG00015.tar.gz

 

Go into vi and open the .tar.gz file

 

[jmcnerny@srscratch pers]$ vi

               -:n customer-install-1.2.0-26115758-AV1709CKG00015.tar.gz

                    

Select the bom.json file to edit

 

 

 Search and edit the string

 

 

After writing changes in vi the new serial is populated in the BOM.json file.

 

[jmcnerny@srscratch pers]$ zgrep -a new_serial customer-install-1.2.0-26115758-AV1709CKG00015.tar.gz

            "serial-number": "new_serial"

        "connect-name": "new_serial",

 

Change the file name to the new serial with the .fw file extension.

 

[jmcnerny@srscratch pers]$ cp customer-install-1.2.0-26115758-AV1709CKG00015.tar.gz customer-install-1.2.0-26115758-new_serial.fw

 

 

 

 

It maybe possible to just run the failed install with the wrong .fw file and then modify the serial in the bom.json file, rerun the install.  Havent tested yet.

 

[root@sps-xcellis2 scratch]#grep serial-number /var/www/html/bootstrap-1.1.0/temp-upload/customer-install/updates-connect/snconnect/mint/config/bom.json
            "serial-number": "AV1652CKH00338"

[root@sps-xcellis2 scratch]# sed -i 's/AV1652CKH00338/new_serial/g' /var/www/html/bootstrap-1.1.0/temp-upload/customer-install/updates-connect/snconnect/mint/config/bom.json
 

 



This page was generated by the BrainKeeper Enterprise Wiki, © 2018