Juniper troubleshoot commands

#show task memory Memory

#sh system storage

#request system storage cleanup

#admin@ACC008805_EX3200> file copy /var/tmp/pfem.core-tarball.1.tgz ftp://nocirt:O endereço de e-mail address está sendo protegido de spambots. Você precisa ativar o JavaScript enabled para vê-lo./pfem.core-tarball.1.tgz
fetch: /var/tmp/pfem.core-tarball.1.tgz: Permission denied
error: put-file failed
error: could not send local copy of file

#show system core-dumps no-forwarding

#run request support information all-members |no-more |save /var/tmp/RSI

sahmed@ACC008805_EX3200> file archive source /var/tmp/pfem.core-tarball.1.tgz destination /var/log/20120616
/usr/bin/tar: Removing leading `/' from member names

sahmed@ACC008805_EX3200> file list /var/log

sahmed@ACC008805_EX3200> file copy /var/log/20120616.tar ftp://nocirt:O endereço de e-mail address está sendo protegido de spambots. Você precisa ativar o JavaScript enabled para vê-lo./20120616.tar
ftp://nocirt:O endereço de e-mail address está sendo protegido de spambots. Você precisa ativar o JavaScript enabled para vê-lo./20120616.tar100% of 1270 kB   29 kBps 00m00s


JUNIPER HTTP ACCESS
set system services web-management http interface ge-0/0/0.100
set routing-options static route 10.101.2.0/24 next-hop 10.246.130.254

JUNIPER LOG FILE TRANSFER TO FTP SERVER
root@CNN010706_SRX240_SEC% cd /var/tmp
root@CNN010706_SRX240_SEC% ls
Logs_20130207.tar               flowd_octeon.core-tarball.0.tgz install                         rpd.core-tarball.0.tgz
Logs_20130207.tgz               flowd_octeon.core.0.gz          krt_gencfg_filter.txt           spu_kmd_init
cleanup-pkgs.log                gksdchk.log                     ppmd.core-tarball.0.tgz         vi.recover
eedebug_bin_file                gres-tp                         ppmd.core.0.gz

root@CNN010706_SRX240_SEC% ftp 10.245.254.34
Connected to 10.245.254.34.
220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
220-You are user number 1 of 50 allowed.
220-Local time is now 21:10. Server port: 21.
220-This is a private system - No anonymous login
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
Name (10.245.254.34:sahmed): nocirt
331 User nocirt OK. Password required
Password:
230-User nocirt has group access to:  download
230-OK. Current restricted directory is /
230-30 files used (100%) - authorized: 30 files
230 167840 Kbytes used (16%) - authorized: 1022976 Kb
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> put Logs_20130207.tar
local: Logs_20130207.tar remote: Logs_20130207.tar
200 PORT command successful
150 Connecting to port 55291
100% |******************************************************************************************************|  1460 KB    00:00 ETA
550-Quota exceeded: Logs_20130207.tar won't be saved
550-30 files used (100%) - authorized: 30 files
550 167840 Kbytes used (16%) - authorized: 1022976 Kb
1495040 bytes sent in 0.41 seconds (3.47 MB/s)



The examples in this section assume that the following host entries have been defined in the host table:

host mary 172.28.32.156 ftp mike mikePwd
host joe 172.28.32.99 ftp joe jPasswd
Example 1

Copy a remote file to a local file by using the CLI file copy command format. The following command creates or replaces the local file autocfg.scr by copying the remote file autocfg.scr located in the directory ftpDir/scripts on the host mary. The username mike and password mikePwd from the host entry mary are used to access the remote file.

copy mary:ftpDir/scripts/autocfg.scr autocfg.scr
Example 2

Copy a local file to a remote fileby using file copy command format. The following command creates or replaces the remote file shConfigForJoe.txt in the directory ftpDir/results on the host joe by copying the local file shConfig.txt. The username joe and password jPasswd from the host entry joe are used to access the remote file.

copy shConfig.txt joe:ftpDir/results/shConfigForJoe.txt
Example 3

Copy a remote file to a local file by using the URL format, use the hostname to specify the location, and specify the user name and password in the command. The following command creates or replaces the local file autocfg.scr by copying the remote file autocfg.scr located in the directory ftpDir/scripts on the host mary. The username fred and the password passwd in the command are used; the username and password in the host entry are ignored.


copy ftp://fred:passwd@mary/ftpDir/scripts/autocfg.scr autocfg.scr
Example 4

Copy a remote file to a local file by using the URL format, use the hostname to specify the location, specify the user name in the command, and use the default value of the password. The following command creates or replaces the local file autocfg.scr by copying the remote file autocfg.scr located in the directory ftpDir/scripts on the host mary. The username fred from the command and the default password null are used; the username and password in the host entry are ignored.

copy ftp://fred@mary/ftpDir/scripts/autocfg.scr autocfg.scr
Example 5

Copy a remote file to a local file by using the URL format, and use the hostname to specify the location. The protocol TFTP, which does not support usernames or passwords, is the protocol in the URL. The following command creates or replaces the local file autocfg.scr by copying the remote file autocfg.scr located in the directory ftpDir/scripts on the host mary. The protocol specified in the command is used; the protocol for the host entry mary is ignored.

copy tftp://mary/ftpDir/scripts/autocfg.scr autocfg.scr
Example 6

Copy a remote file to a local file by using the URL format, use the hostname to specify the location, and use the username and password from the host entry. The following command creates or replaces the local file autocfg.scr by copying the remote file autocfg.scr located in the directory ftpDir/scripts on the host mary. The username mike and password mikePwd from the host entry are used.

copy ftp://mary/ftpDir/scripts/autocfg.scr autocfg.scr
Example 7

Copy a remote file to a local file by using the URL format. Use the host's IP address to specify the location. The following command creates or replaces the local file autocfg.scr by copying the remote file autocfg.scr located in the directory ftpDir/scripts on the host 172.28.32.156. Use the username fred to access the remote file.

copy ftp://O endereço de e-mail address está sendo protegido de spambots. Você precisa ativar o JavaScript enabled para vê-lo./ftpDir/scripts/autocfg.scr autocfg.scr
Example 8

Copy a local file to a remote file by using the URL format, and use the host's IP address to specify the location. The following command creates or replaces the remote file shConfigJoe.txt in the directory ftpDir/results on the host 172.28.32.156 by copying the local file shConfig.txt. The username joe and the password passwd from the command are used to access the remote file.

copy shConifg.txt ftp://joe:O endereço de e-mail address está sendo protegido de spambots. Você precisa ativar o JavaScript enabled para vê-lo./ftpDir/results/shConfigJoe.txt
Example 9

Redirect the output of a command to a remote file by using the URL format, and use the host's IP address to specify the location. Execute show config, and redirect the output to the remote file shConfigJoe.txt in directory ftpDir/results on host 172.28.32.156 using username joe and password passwd.

show config > ftp://joe:O endereço de e-mail address está sendo protegido de spambots. Você precisa ativar o JavaScript enabled para vê-lo./ftpDir/results/shConfigJoe.txt

 

Fonte: http://netbazic.blogspot.com.br/2012/07/juniper-troubleshoot-commands.html

.