Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

header-navigation
keyboard_arrow_up
close
keyboard_arrow_left
Junos CLI Reference
Table of Contents Expand all
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

file show

date_range 19-Nov-23

Syntax

content_copy zoom_out_map
file show filename
<encoding (base64 | raw)>

Description

Display the contents of a file.

Options

filename

Name of a file. For a routing matrix, the file name must include the chassis information.

encoding (base64 | raw)

(Optional) Encode file contents with base64 encoding or show raw text.

Required Privilege Level

maintenance

Output Fields

When you enter this command, you are provided feedback on the status of your request.

Sample Output

file show

content_copy zoom_out_map
user@host> file show /var/log/messages
Apr 13 21:00:08 dev1 /kernel: so-1/1/2: loopback suspected; going to standby.
Apr 13 21:00:40 dev1 /kernel: so-1/1/2: loopback suspected; going to standby.
Apr 13 21:02:48 dev1 last message repeated 4 times
Apr 13 21:07:04 dev1 last message repeated 8 times
Apr 13 21:07:13 dev1 /kernel: so-1/1/0: Clearing SONET alarm(s) RDI-P
Apr 13 21:07:29 dev1 /kernel: so-1/1/0: Asserting SONET alarm(s) RDI-P
...

file show (Routing Matrix)

content_copy zoom_out_map
user@host> file show lcc0-re0:/var/tmp/.gdbinit
lcc0-re0:
--------------------------------------------------------------------------
####################################################################
# Settings
####################################################################
 
set print pretty
 
####################################################################
# Basic stuff
####################################################################
 
define msgbuf
        printf "%s", msgbufp->msg_ptr
end
# hex dump of a block of memory
# usage: dump address length
define dump
   p $arg0, $arg1
   set $ch = $arg0
   set $j = 0
   set $n = $arg1
   while ($j < $n)
        #printf "%x %x ",&$ch[$j],$ch[$j]
        printf "%x ",$ch[$j]
        set $j = $j + 1
        if (!($j % 16))
                printf "\n"
        end
   end
end

Release Information

Command introduced before Junos OS Release 7.4.

footer-navigation