• Summary: Automated process to move appliance backup files to external storage.
  • Symptoms: Drive faulure, SAN failure or database corruption.
  • Cause: Appliance process ony backs up to local storage.
  • Steps to resolve issue:

A script which leverages Windows FTP can be used to automatically copy the two backup files off the KBox into a directory with a date-based name. Set up details are below:

1) Enable FTP by going to KBOX Settings ->Security Settings -> click [Edit Mode] -> check off “Enable backup via FTP” -> click “Set Security Options”.

2) On the Windows machine, copy the files to and create a directory where the backups are to be saved (example C:\KBoxBackup).

3) Create a text file named "backup.txt" which contains the following:

open <kbox> (name or IP of your KBox)
type binary
mget kbox_*

replace “kbox” with the name or IP address of the KBOX (for example “open KBox1000).  Make no other changes to the file and save the file to the directory (example C:\KBoxBackup\backup.txt).  Rename "backup.txt" to "backup.scr".

4) Create a text file named "bkupkbox.bat" which contains the following:

@echo off
set scrptloc=%cd%

if "%1%"=="" goto usage

cd %1

for /F "usebackq tokens=2-4 delims=^/ " %%p in (`date /t`) do mkdir %%r%%p%%q
for /F "usebackq tokens=2-4 delims=^/ " %%p in (`date /t`) do cd %%r%%p%%q
echo backing up to %cd%
"%systemroot%\system32\ftp.exe" -s:"%scrptloc%\backup.scr"

goto end

echo usage:
echo    bkupkbox dir
echo examples:
echo    bkupkbox .
echo    bkupkbox \\server\share
echo    bkupkbox d:\

cd "%scrptloc%"
@echo on 

and save the file to the root directory where backup.scr is located (example C:\KBoxBackup\bkupkbox.bat).

5) Open a command prompt and navigate to the folder being used (example C:\KBoxBackup).

6) To run the backup, type in the following:


replacing the example of C:\KBoxBackup with the folder created in step 2.

7) The batch file will run the script (.scr file) and pull the backup files into the folder with the days date added (examplee: C:\KBoxBackup\20120211\).

These files will not truncate so it is important to delete the files on a regular basis so it does not fill the FTP destination.

For reference, the ftp commands to test manually are:

open <kbox> (name or IP of your KBox)
type binary
mget kbox_*

For the script to run automatically on a regular basis, the Windows Task Scheduler may be used to accomplish the task.

** These directions are for Windows 7, other Windows operating systems may have slightly different options. If you need assistance please use Support.Microsoft.Com for assistance in using the Task Scheduler. **

1) Go to (All) Programs ->Accessories ->System Tools ->Task Scheduler.

2) In the Task Scheduler tool bar click on “Action” then “Create Basic Task…”.

3) Type a name for the task (like “KBox Backups”) and a description then click “Next”.

4) Select the time for the script to run, then click “Next”.

5) Select the time for the task to run, then click “Next”.

6) Select “Start Program” then click “Next”.

7) Click “Browse” and navigate to the folder containing “bkupkbox.bat” (example C:\KBoxBackup\bkupkbox.bat).

8) In both the “Add arguments” and the “Start in” fields type in the folder path to where the “bkupkbox.bat” file is located (example C:\KBoxBackup), then click “Next”.

9) Click “Finish”.

10) Test by selecting “Task Scheduler Library” on the left hand pane, right click on the name of the task for the backup and select “Run”.

 ** If this fails to run please contact us via your normal support channel. We will be able to give support for the backup and for the scripts we provide as well as best effort support for the Task Scheduler part. **