# Backup AX from script?

**URL:** <https://community.a10networks.com/t/backup-ax-from-script/65>\
**Category:** ADC - Application Delivery\
**Created:** [August 11, 2011, 11:54pm UTC](https://community.a10networks.com/t/backup-ax-from-script/65 "2011-08-11T23:54:10Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![rvandermey](https://avatars.discourse-cdn.com/v4/letter/r/ecccb3/32.png) [@rvandermey](https://community.a10networks.com/u/rvandermey)\
**Post date:** [August 11, 2011, 11:54pm UTC](https://community.a10networks.com/t/backup-ax-from-script/65/1 "2011-08-11T23:54:10Z")

</div>

**Posted by rvandermey**

Does anyone have a way to backup an AX via a script? I’d like to schedule a daily backup of the config. I’ve tried using plink.exe to automate an ssh session but I’m not having any luck.

This is what I see when I use -v for verbose output:

Connecting to 172.25.85.250 port 22 Server version: SSH-2.0-OpenSSH\_5.8 Using SSH protocol version 2 We claim version: SSH-2.0-PuTTY\_Release\_0.61 Using Diffie-Hellman with standard group “group14” Doing Diffie-Hellman key exchange with hash SHA-1 Host key fingerprint is: ssh-rsa 2048 4c:e6:58:3c:f1:f8:3e:a3:40:76:f5:07:72:61:37:18 Initialised AES-256 CBC client-\>server encryption Initialised HMAC-SHA1 client-\>server MAC algorithm Initialised AES-256 CBC server-\>client encryption Initialised HMAC-SHA1 server-\>client MAC algorithm Using username “admin”. Access granted Opened channel for session Started a shell/command /a10/bin/rimacli: invalid option – c Server sent command exit status 255 Disconnected: All channels closed

---

<div class="post-metadata">

**Author:** ![mischa](https://avatars.discourse-cdn.com/v4/letter/m/b9bd4f/32.png) [@mischa](https://community.a10networks.com/u/mischa)\
**Post date:** [August 12, 2011, 12:05am UTC](https://community.a10networks.com/t/backup-ax-from-script/65/2 "2011-08-12T00:05:12Z")

</div>

**Posted by mischa**

In 2.6.1 you can do that from the AX itself:

(config)#backup periodically system ? day Specify interval days hour Specify interval hours log Backup log files week Specify interval weeks

(config)#backup periodically system day 1 ? use-mgmt-port Use management port as source port tftp: Remote file path of tftp: file system(Format: tftp://host/file) ftp: Remote file path of ftp: file system(Format: ftp://[user@]host[:port]/file) scp: Remote file path of scp: file system(Format: scp://[user@]host/file) rcp: Remote file path of rcp: file system(Format: rcp://[user@]host/file)

---

<div class="post-metadata">

**Author:** ![rvandermey](https://avatars.discourse-cdn.com/v4/letter/r/ecccb3/32.png) [@rvandermey](https://community.a10networks.com/u/rvandermey)\
**Post date:** [August 12, 2011, 12:06am UTC](https://community.a10networks.com/t/backup-ax-from-script/65/3 "2011-08-12T00:06:36Z")

</div>

**Posted by rvandermey**

Thank you for the help setting up our automated backups. It works great.

I have another question. We have two AX2500’s in a VCS cluster, and I wondered if the backup file includes the configuration for both AX2500’s. So I opened the tar file and found that it only includes configuration files for one of the two.

This may be adequate because most of the configuration is shared among both AX2500’s, but I wonder if there’s a way to backup the /etc/network/ifconfig.eth0 file for example from both AS2500 units.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex002/uploads/a10_community/original/1X/bb9f186d33804d3044a0374e589f49fdf3be1328.png) [@system](https://community.a10networks.com/u/system)\
**Post date:** [August 12, 2011, 12:07am UTC](https://community.a10networks.com/t/backup-ax-from-script/65/4 "2011-08-12T00:07:22Z")

</div>

**Posted by ddesmit** When you have 2 or more devices in a Virtual Chassis (VCS) the configuration on AXs is synched between all the AX devices in real time. In other words, each AX is aware of: . the “shared config” (VIP, SNAT, etc) . but also the “individual config” (IP@, hostname, etc) When you configure “backup periodically” on the VCS-Master, than command is also done on all VCS-Blades (AXs). So you should have a system backup on your FTP server from all the AXs. _Note: Do a “show backup” on all AXs to validate it._ Dimitri

---

<div class="post-metadata">

**Author:** ![rvandermey](https://avatars.discourse-cdn.com/v4/letter/r/ecccb3/32.png) [@rvandermey](https://community.a10networks.com/u/rvandermey)\
**Post date:** [August 12, 2011, 12:07am UTC](https://community.a10networks.com/t/backup-ax-from-script/65/5 "2011-08-12T00:07:52Z")

</div>

**Posted by rvandermey**

Thanks again. Your response made me look more at the documentation. My problem was I was specifying the file name. Now that I specify only the folder name in the url, it get a file from each AX2500 because they give it a unique file name that includes the name of the AX2500.

So now I’m trying to test the restore process.

restore use-mgmt-port scp://a10bkup@(ip address)/logs/A10Configs/MIOKA10AX25002\_backup\_period\_2011-09-25-13-07-11.tar.gz

This is what I get:

…0 minutes 5 seconds Incorrect restore file format Failed to restore system files

Any ideas? I has to be the correct format because that’s the backup file that the backup command produced. ???

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex002/uploads/a10_community/original/1X/bb9f186d33804d3044a0374e589f49fdf3be1328.png) [@system](https://community.a10networks.com/u/system)\
**Post date:** [August 12, 2011, 12:08am UTC](https://community.a10networks.com/t/backup-ax-from-script/65/6 "2011-08-12T00:08:33Z")

</div>

**Posted by ddesmidt**

Hello,

That’s actually a bug that has been recently found by QA in our new 2.6.1 “backup periodically” feature. I’m sure it will be fixed soon. You can also open an A10 support bug to track it.

Thanks and sorry for the inconvenience, Dimitri

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex002/uploads/a10_community/original/1X/bb9f186d33804d3044a0374e589f49fdf3be1328.png) [@system](https://community.a10networks.com/u/system)\
**Post date:** [November 1, 2011, 7:41pm UTC](https://community.a10networks.com/t/backup-ax-from-script/65/7 "2011-11-01T19:41:58Z")

</div>

**Posted by ddesmidt**

Hello,

That’s actually a bug that has been recently found by QA in our new 2.6.1 “backup periodically” feature. I’m sure it will be fixed soon. You can also open an A10 support bug to track it.

Thanks and sorry for the inconvenience, Dimitri

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex002/uploads/a10_community/original/1X/bb9f186d33804d3044a0374e589f49fdf3be1328.png) [@system](https://community.a10networks.com/u/system)\
**Post date:** [November 2, 2011, 7:42pm UTC](https://community.a10networks.com/t/backup-ax-from-script/65/8 "2011-11-02T19:42:41Z")

</div>

**Posted by ddesmidt** FYI this will be fixed in the 2.6.1-P2. _Note: I validated it in our 2.6.1-P2 candidate._ Dimitri

---

<div class="post-metadata">

**Author:** ![vincent119](https://avatars.discourse-cdn.com/v4/letter/v/e36b37/32.png) [@vincent119](https://community.a10networks.com/u/vincent119)\
**Post date:** [June 11, 2014, 4:09am UTC](https://community.a10networks.com/t/backup-ax-from-script/65/9 "2014-06-11T04:09:46Z")

</div>

use axpi backup config  
look it

> **[A10 backup script for aXAPI version 2.1](https://vincent119.blogspot.com/2014/03/a10-backup-script-for-axapi-version-21.html)**
