Before you can back up or restore IBM® Db2® Warehouse, both IBM Spectrum Protect client and
IBM Spectrum Protect server must be configured
for LAN-free operations.
Before you begin
Important: In order to run LAN-Free operations, contact IBM Support for initial setup
and then continue with the following steps.
- Run the following commands from either the administrative command-line client
dsmadmc on the IBM Spectrum Protect server or the IBM Spectrum Protect Operations Center, by using the command builder:
https://< IBM_Spectrum_Protect_Server_IP>:11090/oc/login
If you do not have the IBM Spectrum Protect Operations Center configured, configure it as in Configuring the Operations Center. For installation
process, see Installing the Operations Center.
- Only the administrator of IBM Spectrum Protect server should configure IBM Spectrum Protect server for all the LAN-free operations.
- Register IBM Spectrum Protect Client to IBM Spectrum Protect Server as described in REGISTER NODE (Register a node).
The REGISTER
NODE command accepts many parameters, but you must register only the node name and the
password of the node.
- Do not enable client-side data compression or client-side data deduplication when you do
LAN-free backups.
Command:
register node <nodename> <nodepassword> backdel=yes maxnummp=<# of sessions allowed to access tsm server from this node>
Example:
register node node0101-fab passw0rd backdel=yes maxnummp=10
Important: You need to register all the nodes that are part of the container.
Procedure
-
Ensure that the external storage is mounted as a GPFS file system and is accessible by both IBM Spectrum Protect server and IBM Spectrum Protect storage agent, which runs on the client, with both read/write permissions.
-
Ensure that IBM Spectrum Protect server is set up for server-to-server communication by confirming that its server name, server password, hl address, and ll address are specified.
If IBM Spectrum Protect server isn’t set up for server-to-server communication, run the following commands for server-server communication, including LAN-free sharing and library sharing:
set servername <IBMSpectrumProtectServerName>
set serverpassword <IBMSpectrumProtectServerPassword>
set serverhladdress <IBMSpectrumProtectServerIPaddress>
set serverlladdress <IBMSpectrumProtectServerTCPport>
Example:
set servername tsminst1
set serverpassword passw0rd
set serverhladdress 9.88.356.21
set serverlladdress 1500
-
Depending on how many nodes your system has, define each LAN-free Storage Agent on the IBM Spectrum Protect server by running the following command:
DEFINE SERVER <storage_agent_name> serverpassword=<set password> hladdress=<server/storage agent ip address> lladdress=<based on number set in above command>
Example:
DEFINE SERVER node0101_sta serverpassword=passw0rd hladdress=9.32.216.140 lladdress=1500
DEFINE SERVER refers to the storage agent name that pertains to each node, not
the IBM Spectrum Protect Server name.
-
Define a device class and storage pool that is used for LAN-free traffic. It can’t be a
container pool and deduplication can’t be enabled because a LAN-free usage and data deduplication
aren’t compatible. If you use a devclass file, this file must be on a shared
file system (GPFS/Scale) and you must set the
shared=yes parameter.
-
Define device class:
DEFINE DEVCLASS <device class name> devtype=<type> directory=<newly mounted filesystem on TSM SERVER> shared=yes mountlimit=<maximum number of files that can be opened simultaneously for input and output> maxcap=<max size of any data storage files assigned to stg pool in dev class>
mountlimit number should be minimum of however many MLNs there are in total
in Db2.
Example:
DEFINE DEVCLASS shared_file_dc devtype=file directory=/external_mnt/SAN shared=yes mountlimit=30 maxcap=5g
For
more information:
DEFINE DEVCLASS (Define a FILE device class)More than one
directory or file system can be used on this type of device class, for capacity and performance
reasons. The server and LAN-Free clients must mount the same directories and filesystems.
To
see all the logical drives the define devclass created, issue query
drive.
-
Define storage pool:
DEFINE STGPOOL <Storage pool name> <device class> maxscratch=<max # of scratch volumes> pooltype=primary collocate=<specify which candidate keeps data> reusedelay=<specifies # of days that must elapse after all files are deleted from a volume to rewrite to it>
Example:
DEFINE STGPOOL shared_file_SP shared_file_dc maxscratch=500 pooltype=primary collocate=node reusedelay=1
For
more information:
DEFINE STGPOOL (Define a primary storage pool assigned to sequential
access devices)The maxscratch parameter controls how many volumes can
be created on the file system. The volumes are of the size that is specified in the
maxcap parameter in the define devclass command. Attempt to
set a maxscratch that would use around 85-90% of the free file system space.
That way, if you begin to fill the file system, you can increase the maxscratch
to get a little more data into the storage pool, as you attempt to either add capacity or clean it
up. When the storage pool is fixed, you can set the maxscratch value such that
you will use no more than 85-90% of its free space.
-
Create a domain that can write to that pool.
- Define policy domain: DEFINE DOMAIN (Define a new policy domain)
- Define policy set: DEFINE POLICYSET (Define a policy set)
- Update registered nodes:
update node <registered node name> domain=<newly created domain name to associate with node>
Example:
update node node0101-fab domain=DB2_Backups
If you already have an existing policy domain, update the existing one. The nodes
that are backup LAN-free must belong to this newly created/updated domain.
-
Define a library.
-
The IBM Spectrum Protect Server needs to
communicate to the Storage Agent how to write to the storage pool, by telling it what path it can
use to write to the shared location. For every logical drive, you need a path definition. The server
keeps tracks to the paths of all the shared logical and physical drives. DEFINE PATH (Define a path when the destination is a
drive)
Note:
The following command needs to be done for however many drives are set, which were set in step
4 under the
mountlimit parameter. For example, if you set mountlimit
to 30, you’ll run command 30 times, 1 time per each drive.
You must define paths on the IBM Spectrum
Protect server by using the disk device names as seen by the storage agent on each client
system that is
/external_mnt/SAN
.
Important: On Integrated Analytics System the path to use is path or mount point of the
IBM Spectrum Scale (GPFS) file system inside each container.
DEFINE PATH <storage_agent_name> <drive name_#> srctype=<source type> desttype=<destination type> device=<device type> library=<library name> directory=/external_mnt/SAN
.
.
DEFINE PATH <storage_agent_name> <drive name_#> srctype=<source type> desttype=<destination type> device=<device type> library=<library name> directory=/external_mnt/SAN
Example for a system with a limit of 30 mount
points:
DEFINE PATH node0101_sta shared_file_dc1 srctype=server desttype=drive device=file library=shared_file_dc directory=/external_mnt/SAN
.
.
DEFINE PATH node0101_sta shared_file_dc30 srctype=server desttype=drive device=file library=shared_file_dc directory=/external_mnt/SAN
-
Configure the Storage Agent on the IBM Spectrum Protect Client side.
Log into the docker container:
ssh bluadmin@<nodename> -p 50022
-
On the Integrated Analytics System (IIAS) appliance, run the
following commands:
- Log in to the docker container:
ssh bluadmin@<nodename> -p 50022
- Issue command to validate the server and storage agent are communicating:
netstat -an | grep :1500
This command shows the TCP/IP port.
-
On IBM Spectrum Protect server, run the following commands to test if the configuration is completed successfully:
- Show the number of sessions from Spectrum Storage Agent. The number depends on the number of
configured Spectrum Storage Agents.
q sess
- Show the other side of the settings for IBM Spectrum Protect server and Spectrum Storage Agent. This command routes the q sess command to the Spectrum Storage Agent that is
specified by
sta_name.
sta_name:q sess
- Check whether Spectrum Storage Agent is pinged successfully, where sta_name
is the name of Spectrum Storage
Agent.
ping server sta_name
- Check whether IBM Spectrum Protect server is pinged successfully, where sta_name is the name of Spectrum Storage Agent, and name is the name of IBM Spectrum Protect server.
sta_name:ping server name
If any of these tests fails, update the security for the node session for all nodes by running
the following command:
update node nodename from client side sessionsecurity=transitional
Results
You can now use IBM Spectrum Protect client to back up and restore data in a LAN-free environment.