<p>WARNING: This may be broken n 6.1.0h firmware.  I&#8217;m looking into it.  For now, I&#8217;m running an expect script from a remote host to do these backups.</p>
<p>The following will backup your switch config over FTP to a remote server daily. If you have to replace your switch, you can just do a configdownload after getting it on the network to restore all your settings.</p>
<p>To make this happen, I created a short shell script to upload into the cron directory on the switch.  You can transfer this file via SCP.  I had problems with FileZilla&#8217;s SCP, so I copied it from another host, which worked fine.  Just put this in a file and upload it to /etc/cron.daily/ on the switch.</p>
<pre><code>#!/bin/sh

# configbackup
#
# Author: Patrick Vaughan - 7-1-09
#
# Purpose:
#       Do a configupload to a remote FTP server.  This process does a backup
#           from AD 255, so as to get all the Zoning configuration.
#
# Change Log:
#
# License:
#   Copyright (C) 2009  Patrick Vaughan
#
#    This program is free software: you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation, either version 3 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.

DEST_HOST="<strong>192.168.1.1</strong>"
DEST_USER="<strong>ftp_user</strong>"
DEST_DIR="<strong>/export/sansw</strong>"
HOSTNAME=`/bin/hostname`
PASSWORD="<strong>password</strong>"

/fabos/link_abin/ad --exec 255 "/fabos/link_sbin/configupload -p ftp "$DEST_HOST","$DEST_USER","$DEST_DIR/$HOSTNAME.cfg","$PASSWORD"" > /dev/null

exit</code></pre>
{"id":212,"date":"2009-06-23T16:41:48","date_gmt":"2009-06-23T20:41:48","guid":{"rendered":"http:\/\/patrickv.info\/wordpress\/?p=212"},"modified":"2009-06-23T16:41:48","modified_gmt":"2009-06-23T20:41:48","slug":"automatically-backup-the-brocade-config-via-ftp","status":"publish","type":"post","link":"https:\/\/rootuser.ninja\/index.php\/2009\/06\/23\/automatically-backup-the-brocade-config-via-ftp\/","title":{"rendered":"Automatically backup the Brocade config via FTP"},"content":{"rendered":"<p>WARNING: This may be broken n 6.1.0h firmware.  I&#8217;m looking into it.  For now, I&#8217;m running an expect script from a remote host to do these backups.<\/p>\n<p>The following will backup your switch config over FTP to a remote server daily. If you have to replace your switch, you can just do a configdownload after getting it on the network to restore all your settings.<\/p>\n<p>To make this happen, I created a short shell script to upload into the cron directory on the switch.  You can transfer this file via SCP.  I had problems with FileZilla&#8217;s SCP, so I copied it from another host, which worked fine.  Just put this in a file and upload it to \/etc\/cron.daily\/ on the switch.<\/p>\n<pre><code>#!\/bin\/sh\n\n# configbackup\n#\n# Author: Patrick Vaughan - 7-1-09\n#\n# Purpose:\n#       Do a configupload to a remote FTP server.  This process does a backup\n#           from AD 255, so as to get all the Zoning configuration.\n#\n# Change Log:\n#\n# License:\n#   Copyright (C) 2009  Patrick Vaughan\n#\n#    This program is free software: you can redistribute it and\/or modify\n#    it under the terms of the GNU General Public License as published by\n#    the Free Software Foundation, either version 3 of the License, or\n#    (at your option) any later version.\n#\n#    This program is distributed in the hope that it will be useful,\n#    but WITHOUT ANY WARRANTY; without even the implied warranty of\n#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n#    GNU General Public License for more details.\n#\n#    You should have received a copy of the GNU General Public License\n#    along with this program.  If not, see <http:\/\/www.gnu.org\/licenses\/>.\n\nDEST_HOST=\"<strong>192.168.1.1<\/strong>\"\nDEST_USER=\"<strong>ftp_user<\/strong>\"\nDEST_DIR=\"<strong>\/export\/sansw<\/strong>\"\nHOSTNAME=`\/bin\/hostname`\nPASSWORD=\"<strong>password<\/strong>\"\n\n\/fabos\/link_abin\/ad --exec 255 \"\/fabos\/link_sbin\/configupload -p ftp \"$DEST_HOST\",\"$DEST_USER\",\"$DEST_DIR\/$HOSTNAME.cfg\",\"$PASSWORD\"\" > \/dev\/null\n\nexit<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":null,"protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7,1],"tags":[],"class_list":["post-212","post","type-post","status-publish","format-standard","hentry","category-san-notes","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/posts\/212","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/comments?post=212"}],"version-history":[{"count":0,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/posts\/212\/revisions"}],"wp:attachment":[{"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/media?parent=212"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/categories?post=212"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rootuser.ninja\/index.php\/wp-json\/wp\/v2\/tags?post=212"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}