All of the user data that exists at any time in your Mobility system also exists in GroupWise. Therefore, if there is a problem with your Mobility system, you can always resynchronize in order to restore your user data to a current working state.
However, you can back up your entire Mobility system in order to preserve the Mobility Service software, configuration files, certificate files, and database.
Before you get started, understand the following:
Use your backup software of choice to back up the following directories on your Mobility server:
Directory |
Description |
---|---|
/opt/novell/datasync |
Mobility Service software |
/etc/datasync |
Configuration files |
/var/lib/datasync |
Certificate files |
Use a PostgreSQL-supported backup solution to back up the Mobility Service database in the following directory:
/var/lib/pgsql
Decide how you want to back up the data:
Stopping your Mobility system before backing it up is the safest way to ensure a completely consistent backup.
In a terminal window on the Mobility server, become root by entering su - and the root password.
Create a directory for storing your backup files, for example:
mkdir /var/gmsbackup
Create a script similar to the following:
#!/bin/bash # back up stopped Mobility system gms stop systemctl stop postgresql.service # tar -czvpf /var/gmsbackup/pgsql.tgz /var/lib/pgsql tar -czvpf /var/gmsbackup/vardatasync.tgz /var/lib/datasync tar -czvpf /var/gmsbackup/optdatasync.tgz /opt/novell/datasync tar -czvpf /var/gmsbackup/etcdatasync.tgz /etc/datasync # systemctl start postgresql.service gms start
For example, you could create a script named gmsbackup.sh in the /opt/novell/datasync directory.
Add execute permissions to the backup script:
chmod +x script_name.sh
Execute the backup script.
Change to the directory where you backed up the Mobility files to verify that the .tgz files were successfully created.
For convenience, you might want to back up your Mobility system while it is still running.
In a terminal window on the Mobility server, become root by entering su - and the root password.
Create a script to back up the Mobility Service database:
Create a file named .pgpass in the root user’s home directory (/root).
Put the following contents in the .pgpass file.
*:*:*:datasync_user:database_password
The Mobility Service database user is datasync_user. The Mobility Service database password was established during installation.
Create a database backup script similar to the following, using the pg_dump command to back up just the Mobility Service databases:
#!/bin/bash # back up Mobility Service database pg_dump -U datasync_user mobility > /tmp/mobility.out pg_dump -U datasync_user datasync > /tmp/datasync.out /usr/bin/bzip2 /tmp/mobility.out /usr/bin/bzip2 /tmp/datasync.out
For example, you could create a database backup script named gmsdbbackup.sh in the /opt/novell/datasync directory.
Add execute permissions to the backup script:
chmod +x script_name.sh
Execute the backup script.
Create a script to back up the Mobility Service directories:
Create a directory for storing your backup files, for example:
mkdir /var/gmsbackup
Use the following script to back up the rest of your Mobility system while it is sill running:
#!/bin/bash # back up running Mobility system tar -czvpf /var/gmsbackup/vardatasync.tgz /var/lib/datasync tar -czvpf /var/gmsbackup/optdatasync.tgz /opt/novell/datasync tar -czvpf /var/gmsbackup/etcdatasync.tgz /etc/datasync
For example, you could create a script named gmsdirbackup.sh in the /opt/novell/datasync directory.
Add execute permissions to the backup script:
chmod +x script_name.sh
Execute the backup script.
Change to the directory where you backed up the Mobility files to verify that the .tgz files were successfully created.
To restore your Mobility system: