Forum Discussion

F5user13_114603's avatar
Nov 14, 2017
Solved

Backup LTM ASM and APM log files to external FTP or tape drive

Hi,

 

Is it possible to backup all ltm, asm and apm logs stored under the /var/log/ltm folder in the BIG-IP to an external FTP or tape drive.

 

Can anyone please share their inputs.

 

  • You can write bash scrip like below

    File name: script.sh

            !/bin/bash
            $1 is the file name
            usage:this_script script.sh 
            HOST='your host'
            USER="your user"
            PASSWD="pass"
            FILE="/var/log/*"
            FTPFILE=/FTP/LOG/
    
            ftp -n $HOST <
    
    
    Schedule crontab
            0 06 * * * /bin/execute/this/script.sh          
    

3 Replies

  • You can do this with a bash script and a cron job to schedule packaging up the files and sending to your preferred destination.

     

    Are you not able to use a Syslog server, this would be a more sensible approach?

     

  • You can write bash scrip like below

    File name: script.sh

            !/bin/bash
            $1 is the file name
            usage:this_script script.sh 
            HOST='your host'
            USER="your user"
            PASSWD="pass"
            FILE="/var/log/*"
            FTPFILE=/FTP/LOG/
    
            ftp -n $HOST <
    
    
    Schedule crontab
            0 06 * * * /bin/execute/this/script.sh