Description

This article explains how to delete a core file from the host shell. 

Symptoms

The host crash files are located on the host OS node and and not the /var/tmp/ on the Junos OS.

​root@qfx5200-32C> show system core-dumps    
localre:
--------------------------------------------------------------------------
-rw-r--r--  1 root  wheel    9529524 Apr 28 06:31 /var/tmp/dcpfe0.dcpfe.12530.1616749990.core.tgz
total files: 1
Host Crash Info:
--------------------------------------------------------------------------
-rw-r--r--  1 root  root      9529524 Apr 28 06:34 /var/tmp/corefiles/dcpfe0.dcpfe.12530.1616749990.core.tgz  <-- This is the file we want to delete 
 

Solution

There are 2 way to delete this from the host crash folder:

  1. From CLI using the "request app-engine cleanup" command 
  2. From Host shell using Linux "rm" command  
     

CLI Method

​root@qfx5200-32C> show system core-dumps    
localre:
--------------------------------------------------------------------------
-rw-r--r--  1 root  wheel    9529524 Apr 28 06:31 /var/tmp/dcpfe0.dcpfe.12530.1616749990.core.tgz
total files: 1
Host Crash Info:
--------------------------------------------------------------------------
-rw-r--r--  1 root  root          9529524 Apr 28 06:34 /var/tmp/corefiles/dcpfe0.dcpfe.12530.1616749990.core.tgz
{master:0}
root@qfx5200-32C> request app-engine cleanup member 0    <-- specify the member if this is a Virtual Chassis setup 
localre:
--------------------------------------------------------------------------

Compute cluster: default-cluster

  Compute node: default-node                    
   Cleanup (/var/tmp)
   =======

{master:0}
root@qfx5200-32C> show system core-dumps                 
localre:
--------------------------------------------------------------------------
-rw-r--r--  1 root  wheel    9529524 Apr 28 06:31 /var/tmp/dcpfe0.dcpfe.12530.1616749990.core.tgz
total files: 1
Host Crash Info:
------------------------------------------------------
No corefiles present on the host.

Host Shell Method

​{master:0}
root@qfx5200-32C> show system core-dumps 
localre:
--------------------------------------------------------------------------
-rw-r--r--  1 root  wheel    9529524 Apr 28 06:31 /var/tmp/dcpfe0.dcpfe.12530.1616749990.core.tgz
total files: 1
Host Crash Info:
--------------------------------------------------------------------------
-rw-r--r--  1 root  root          9529524 Apr 28 06:34 /var/tmp/corefiles/dcpfe0.dcpfe.12530.1616749990.core.tgz
{master:0}
root@qfx5200-32C> request app-engine host-shell 
Last login: Wed Apr 28 06:37:51 PDT 2021 from qfx5200-32C on pts/2

root@qfx5200-32C-node:~# 
root@qfx5200-32C-node:~# 
root@qfx5200-32C-node:~# cd /var/crash
root@qfx5200-32C-node:/var/crash# ls
dcpfe0.dcpfe.12530.1616749990.core.tgz
root@qfx5200-32C-node:/var/crash# rm dcpfe0.dcpfe.12530.1616749990.core.tgz 
root@qfx5200-32C-node:/var/crash# exit
logout
rlogin: connection closed

{master:0}
root@qfx5200-32C> show system core-dumps 
localre:
--------------------------------------------------------------------------
-rw-r--r--  1 root  wheel    9529524 Apr 28 06:31 /var/tmp/dcpfe0.dcpfe.12530.1616749990.core.tgz
total files: 1
Host Crash Info:
------------------------------------------------------
No corefiles present on the host.