Uploading the active log file to a network location using the CLI

Prev Next

This topic describes how to use CLI commands to upload the active log file to a network location. For a full list of logging commands and the usage and parameters, see the CLI Command Reference.

Prerequisites
  • Admin access

To upload the active log file to a network location:
  1. Go to CLI configuration mode:

    hostname > enable
    hostname # configure terminal
  2. To upload the active log file to a specified network location using file transfer protocol (FTP), trivial file transfer protocol (TFTP), secure copy (SCP) or SSH file transfer protocol (SFTP), use the following command:

    hostname (config) # logging files upload current <uploadURL>

    The <uploadURL> parameter specifies the protocol and file location.

    • ftp://<domain>/<path>/<fileName>

    • tftp://<domain>/path>/<fileName>

    • scp://<username>[:<password>]@<hostname>/<path>/<fileName>

    • sftp://<domain>/<path>/<fileName>

    Note

    For the SCP protocol, you also specify the credentials. You can enter the password in the command line, or you can enter it when you are prompted at the CLI.

    The following example uses SCP to upload the active log file to logs/FE_log.gz:

    hostname (config) # logging files upload current scp://it123@example.com/logs/FireEye_log.gz
    Password (if required): ***********
  3. Verify your changes:

    hostname (config) # show log files
  4. Save your changes.

    hostname (config) # write memory