65 lines
4.0 KiB
Markdown
65 lines
4.0 KiB
Markdown
---
|
|
subtitle: Normal Run
|
|
header-img: img/header_img/server.jpg
|
|
date: 2018-03-07 09:50:12
|
|
description: Spectrum Protect Server in a Docker Container - Normal Run
|
|
related:
|
|
- { page: "index", title: "Containerising SP" }
|
|
- { page: "firstrun", title: "Initial Container Setup" }
|
|
- { page: "upgrade", title: "Upgrading SP" }
|
|
- { page: "recover", title: "Recoverying the SP Database" }
|
|
---
|
|
# Normal Run of a Spectrum Protect Server (in a container)
|
|
> **NOTES**:
|
|
> * The storage used in the example below is from the host filesystems, passed to the container with Docker's `-v` option.
|
|
> * This implementation is using DISK or CLOUD storage pool storage. While accessing tape should be possible, I havent explored what is required for that to work.
|
|
|
|
## Configuration
|
|
Our configuration will use these defaults
|
|
|
|
```bash Container Variables
|
|
TSM_DB=/srv/sp/database
|
|
TSM_USER=/srv/sp/user
|
|
TSM_DATA=/srv/sp/data
|
|
```
|
|
|
|
* **TSM_DB** is where the TSM Database will be stored on the Docker Host, and will be passed to the container with `-v $TSM_DB:/database`
|
|
* **TSM_USER** is where the TSM Instance user's home directory is on the Docker Host, and will be passed to the container with `-v $TSM_USER:/tsm`
|
|
* **TSM_DATA** is where the TSM Disk based storage pools are stored on the Docker Host, and will be passed to the container with `-v $TSM_DATA:/data`
|
|
If data is stored in a cloud pool, then this would be where the acceleration pool is holding data before it gets sent to the cloud.
|
|
|
|
# Normal Run
|
|
|
|
Starting SP for normal operations.
|
|
|
|
`docker run --detach=true --hostname=tsm --interactive=false -v $TSM_USER:/tsm -v $TSM_DB:/database -v $TSM_DATA:/data --memory=16g -p 1500:1500 -p 1543:1543 --privileged=true --rm=false --restart=no --tty=false --name=spectrumprotect ibm/spectrumprotect:8.1.4`
|
|
|
|
```tsm Expected Startup, viewable by doing docker log -f spectrumprotect
|
|
ANR7800I DSMSERV generated at 16:03:41 on Nov 17 2017.
|
|
|
|
IBM Spectrum Protect for Linux/x86_64
|
|
Version 8, Release 1, Level 4.000
|
|
|
|
Licensed Materials - Property of IBM
|
|
...
|
|
ANR8200I TCP/IP Version 4 driver ready for connection with clients on port
|
|
1500.
|
|
ANR2560I Schedule manager started.
|
|
ANR2825I License audit process 1 completed successfully - 0 nodes audited.
|
|
ANR0985I Process 1 for AUDIT LICENSE running in the BACKGROUND completed with
|
|
completion state SUCCESS at 04:09:10.
|
|
ANR0993I Server initialization complete.
|
|
IBM Spectrum Protect:SERVER1>
|
|
```
|
|
|
|
You should now be able to connect with the Admin Client.
|
|
|
|
**NOTES**:
|
|
* For Spectrum Protect you need to use `--privileged=true`. From what I have worked out, DB2 needs this. I did find some notes on DB2 in docker [here](https://www.ibm.com/developerworks/data/library/techarticle/dm-1602-db2-docker-trs/index.html), and tried these options without using `--privileged=true` but DB2 still reported some errors.
|
|
I dont think it is an issue running SP in privileged mode, but if you do find a solution to have it run without full privileges, I would be interested ;)
|
|
The link above has some important tips regarding DB2 memory and the `--memory=` setting.
|
|
* When defining your DISK based storage pools (or STGPOOLDIR for your cloud pools), remember the path to your "data" is `/data` inside the container. If you use another path, you will loose that data when the container is destroyed.
|
|
* You should be able to run many SP instances on the same host (or swarm) even at different version levels. In container, they can all respond to port 1500, and outside the container, they'll need to have unique ports eg: `-p 1501:1500`, `-p 1502:1500`, etc. (Just remember to think about resource requirements and potential resource contention.)
|
|
* Use the same `--hostname=` setting that you used when running the *init* steps above. DB2 is sensitive to hostname changes.
|
|
* Spectrum Scale makes a great persistent storage filesytem for Docker containers, and gives you great optoins for Specturm Protect. For example, you could move SP to different hosts very easily (stop on hosta, start on hostb - if both hosts see the same Spectrum Scale file system and your database/data are on it).
|