Description

An unexpected power outage occurred on NFX250, and the vSRX VNF was created with the factory default configuration. The configuration had to be restored from a backup. All other components were fine.​

Symptoms

Cache setting is 'none' for data, configuration block device. In case of a power outage, there is the possibility that the config virtual block caches will not be flushed to the disk which may cause config disk corruption.

Example 15.1X49-D78.4:

    <disk type='file' device='disk'>
      <driver name='qemu' type='qcow2' cache='<span style="color:blue">/>
      <source file='/junos/images/0/vjunos-config.img'/>
      <target dev='vdc' bus='virtio'/>
      <alias name='virtio-disk2'/>
      

Solution

The writethrough cache function has been added to Junos OS 18.4 and later images. The recommendation is to upgrade the vSRX to a fixed version.

The recommended device-cache configuration for vSRX is writethrough . This is for vSRX2 and vSRX3. For other vendor VNF's, it is recommended to clarify with the vendor what the driver-cache mechanism should be for that type of VNF.  

To enable writethrough cache function on Junos 18.4 and higher:

set virtual-network-functions vsrx-Name image driver-cache writethrough

Modification History

2020-04-21: Updated Solution field with fixed version.