Problem Description
I want to back up my Websense filtering policies
and configuration information. Which files should I back up? How should I
perform the backup?
Resolution
Websense software includes a command-line Backup
Utility that makes it easy to back up your Websense software settings
and policy data, and to revert to a previous configuration. Data saved
by the utility can also be used to import Websense configuration
information after an upgrade.
The Websense Backup Utility saves:
Backup files are given the name "wsbackup_yyyy-mm-dd_hhmmss.tar.gz", where yyyy-mm-dd represents the date and hhmmss represents the time that the file was created. The file is placed in the directory that you specify when running or scheduling the backup.
Here, the backup is scheduled to run at 1:31 a.m. on Monday, Wednesday, and Friday, regardless of date, every month of the year. The backup file is stored in the "z:\backups\ws" directory.
Refer to any crontab reference for more information about valid scheduling parameters.
The Websense Backup Utility saves:
- Global configuration information, including client and policy data, stored in the Policy Database.
- Local configuration information, such as Filtering Service and Log Server settings, stored by each Policy Server.
- Websense component initialization and configuration files.
Backup files are given the name "wsbackup_yyyy-mm-dd_hhmmss.tar.gz", where yyyy-mm-dd represents the date and hhmmss represents the time that the file was created. The file is placed in the directory that you specify when running or scheduling the backup.
To run an immediate backup:
- Open a command prompt on any machine that includes Websense filtering and reporting components.
- Navigate to the appropriate directory:
- Windows:
C:\Program Files\Websense\bin
(by default) - Linux:
/opt/Websense
(by default)
- Windows:
- Enter the following command:
- Windows:
wsbackup -b -d <directory>
- Linux:
./WebsenseTools -b -b -d <directory>
- Windows:
To schedule backups:
IMPORTANT |
On some operating systems, attempts to use the "-s"
parameter to schedule backups fail. One workaround is to use a script to
run a standard backup ("-b" parameter) at regular intervals. This
article will be updated when more information is available. |
---|
- Open a command prompt on any machine that includes Websense filtering and reporting components.
- Navigate to the appropriate directory:
- Windows:
C:\Program Files\Websense\bin
(by default) - Linux:
/opt/Websense
(by default)
- Windows:
- Enter the following command:
- Windows:
wsbackup -s -t "<minute> <hour> <day_of_month> <month> <day_of_week>" -d <directory>
- Linux:
./WebsenseTools -b -s -t "<minute> <hour> <day_of_month> <month> <day_of_week>" -d <directory>
- Windows:
wsbackup -s -t "31 1 * * 1,3,5" -d z:\backups\ws
Here, the backup is scheduled to run at 1:31 a.m. on Monday, Wednesday, and Friday, regardless of date, every month of the year. The backup file is stored in the "z:\backups\ws" directory.
Variable | Information |
---|---|
<minute> |
0 - 59 Specify the precise minute to start the backup. |
<hour> |
0 - 23 Specify the general hour of the day to start the backup. |
<day_of_month> |
1 - 31 Specify the date to perform the backup. If you schedule a backup for days 29 - 31, the utility uses the standard substitution procedure for the operating system in months that do not include that date. |
<month> |
1 - 12 Specify the month to perform the backup. |
<day_of_week> |
0 - 6 Specify a day of the week. 0 represents Sunday. |
Related Articles:
Notes & Warnings
- Do not store your backup files in the Websense bin directory. Store them in a safe location that is included in your organization's regular backup processes.
- Make sure that all administrators are logged out of Websense Manager before initiating a backup.
- When specifying a directory for the backup file, do not include a trailing slash ("C:\wsbackupfiles" not "C:\backups\").