TSM DB2 & log
TSM Database version 5.5 and earlier
This information has been moved to a separate page as TSM 5.x is now out of support¬†TSM 5.x
Basic database structure
TSM uses a DB2 relational database. This means it can be much bigger than the old legacy database, does not neeed database audits and will automatically re-organise itself if required. Software database mirroring is no longer supported.¬†
As the database is DB2, it is possible to connect to it directly, outside of TSM and run query commands. To do this in a Windows environment, follow this procedure:
In a UNIX or Linux environment, the process is:
After you connect to the database, you can run DB2 select commands. For example to get the list of all table indexes that are used by the Tivoli Storage Manager server, run the following command :
To get a list of indexes that are used by a specific table, use the tabname parameter to identify the table name. For example, to get a list of indexes that used by the BACKUP_OBJECTS table, run the following command :
To get a list of table names, run the following command :
Database sizing and tuning
The database can exist in up to 128 directories or 'containers' to use the correct DB2 term. The data is striped evenly across the directories and the containers do not require an initial format before they can be used. The Q DBSPACE output below shows a database striped over 3 containers.
When a TSM database is initially created on multiple file systems, that database will be spread equally over all the file systems. However if you add an extra file system to the database space using the 'extend dbs' command, DB2 will not rebalance the database to spread the data equally. This means that if some of the original file spaces were 100% full, they will still be 100% full after the new filespace is added and this could cause the TSM to stop.¬†
At a quiet time, log into the DB2 command line with the DB2 administrator userid and run these commands
The tables that IBM mention in the technote are SYSCATSPACE, USERSPACE1, LARGESPACE1, LARGEIDXSPACE1, IDXSPACE1, SYSTOOLSPACE. It can take about 30 minutes to rebalance a large tablespace. When all tablespaces have done the rebalance and execute the following commands to reduce the same list of tablespaces :
After the rebalance/reduce, the file systems should be equally utilized and none should be full
The maximum database size for TSM 6.3 and TSM 7.1 is 4TB, and 2TB for TSM 6.2. The DB2 database is largely self tuning, so there is no requirement for DB2 tuning skills. A new parameter, DBMEMPERCENT, replaces the old BUFFPOOLSIZE. This set of buffers contains much more data than the old buffer so the recommendation is to set its size to unlimited. In fact, TSM/DB2 will try to change it to unlimited on startup.
Deduplication reduces the amount of storage space used for backups, but this comes at the cost of increased database space as TSM must track the metadata needed to reconstitute deduplicated data. There is no exact formula for working out that database increase, but it is possible to estimate the database size impact.
Deduplication data is stored in 'chunks' of variable size, but the average size is about 100k. Each chunk uses about 490 bytes in the database, and then another 190 bytes if it is copied to a copy storage pool. Compare that with the normal overhead of 200 bytes needed to store metadata for every copy of every file backed up.¬†
So it would appear reasonably easy to estimate your database size, all you need to know is backup file count and the number of bytes in your storage pools. However it is not quite as easy as this, as the first set of chunks that are created are called 'base chunks' and they are not automatically expired when that file is deleted, as other files may be linked to them. Worst case, and very unlikely, is that this effect could double the chunk count.
So, considering an enterprise that is managing 20TB of data, with the primary storage pool deduplicated, and a copy storage pool that is not deduplicated.¬†
IBM provides a pearl script that provides details on how your database handles deduplication content, once you have been running dedup for a while. Search the IBM site for tsm_dedup_stats.pl and you should find it.¬†
The database uses DB2 relational consistency rules to prevent incorrect data from entering, and is self auditing. The database will aslo run automatic 'runstats' from time to time. This is a DB2 feature that optimises storage paths through the database to improve performance.¬†
Recovery log sizing and tuning
TSM has three recovery logs.¬†
The log files form part of the TSM database, and unlike the legacy TSM database there is no need to create and format log volumes. The logmode is equivalent to legacy roll-forward. In DB2 terms, these are archive logs, not circular logs. This means that the log files can fill up, so log file management is still required. You can specify a failover log for the Archive log to help prevent this, but the Active log cannot failover and the size is fixed between 2GB and 128GB, so don't allocate all the space that you have available for the Active log, keep some in reserve for emergencies.¬†
If the Active log fills up and the server stops, the process to get your TSM server up again is:
DSMSERV DISPLAY LOG - to check the current log status¬†
The archive logs should be automatically deleted after a full database backup completes, but in some cases this might not happen and then the archive logs will continue to grow until the filespace is full.¬†
and check the output, which should have the default values set like this.
Once the number of backups specified by the NUM_DB_BACKUPS is reached, the old backups are marked as expired and will be deleted by the next database backup. The AUTO_DEL_REC_OBJ parameter specifies whether the database log files, backup images, and load copy images associated with those backups should be deleted at the same time. These parameters cannot be changed from within TSM by a TSM administrator and should not be changed from the DB2 command line, but left at the default values.
If you get a LOGREAD388 error, then the TSM server will crash. This error happens when a recovery log volume becomes corrupted. If this happens to you, your first option should be to check your operating system error logs. If they indicate that a file system has corruption errors or disk errors, get your system administrator to check out the operating system and see if the error can be fixed there.
Your next option is to check to see if your logs are mirrored, and if so then tell TSM to use the mirror copy. From an OS command line issue the command below and check the output
this will tell you if the logs are mirrored if the command shows more than one copy for the log files. If they are mirrored, then add the option¬†
If this fails, then you will probably have to restore your database to the latest backup, but you might want to contact IBM for further advice first.
You may want to change the location of the achive logs, maybe because you have added a bigger file system and this is usually quite easy.
If you really need to, or even just want to, it is possible to update DB2 directly to change the log location. You should really ask your IBM support rep for advice before you start, but an outline process would go like.
Activity, Schedule and Event logs
The TSM server stores information about server and client activity in three places; the Activity Log, The Events Log and the Summary Log. The Activity Log tells you everything that is happening on the TSM server, the Events log details all the activity that is triggered by the TSM server Scheduler, including both Admin and Client schedules. The Summary Log, as the name suggests, stores summary data of things like expiration, reclamation, backups and restores. Since TSM 6.0 all three of these logs are stored in the TSM database so they use database space and can cause problems if they hold too much data. To find out how many days worth of data they are holding, run the QUERY STATUS command and look for lines like
You can change these default entries using the SET command as shown below. The numbers are for illustration purposes and should not be considered as recommendations. Most people stick with the defaults. If you increase them, then monitor the impact on database size.
If you want to to know exactly how much data is held in the event and summary tables, you could try the following (rather complicated) queries that appeared in IBM tech notes in 2014. You need to run them from a DB2 command line, not the TSM command line, so you initialy connect to the TSM database then run the queries like this
Backing up the TSM Database
It is very important that your TSM database is regularily backed up using TSM commands, so it can be recovered if it gets corrupted. Most sites take 2 types of backup, an on-site copy to disk and an off-site copy to tape. The location of TSM database backup files are stored in the volume history, so it is essential at a minimum that you backup both the volume history file, and the TSM database. It is also a good idea to backup the device config file at the same time.¬†
Where the classname in the command points to a sequential access device class, either disk or tape. This will default to an incremental backup that will use scratch tapes and the command line will not hang while the backup runs. You can change these defaults by using parameters
Scratch=No means don't use scratch tapes and then you have to tell TSM which volumes to use with a VOLumenames='csv_volume_list' parameter
Wait=No means the command will wait until the database backup completes before it moves on to the next task. This is typically used in automated server management scripts.
The TYPE parameter is used to decide what tpe of backup to take. Options are Type=Full, Type=Incremental or Type=DBSnapshot.
A Full backup will copy the entire TSM database and will then truncate the TSM server active and archive logs.¬†
BACKUP DEVCONFIG command backups up the device class definitions, library definitions, drive definitions and exit definitions. You must have this information available to restore the Tivoli Storage Manager database.¬†
with an optional Filenames= parameter where you can tell TSM where to store the backups. If you don't use the Filenames parameter, then TSM looks for the filename that is contained in the server options file, under the DEVCONFIG option.
The BACKUP VOLHISTORY command saves history records for database backup and dump volumes, and information about lots of other volumes, for instance Volumes removed by using the DELETE VOLUME command or during reclamation of scratch volumes.¬†
with an optional Filenames= parameter where you can tell TSM where to store the backups. If you don't use the Filenames parameter, then TSM looks for the filename that is contained in the server options file, under the VOLUMEHISTORY option.
There is one thing to be aware of, if you start poking about in the db2diag.log file for the DB2 system that the TSM server runs on. You might see error messages like
This is just the DB2 health monitor warning that the database config is set to AUTO_DB_BACKUP = OFF as DB2 thinks it should be managing database backups. TSM needs to manage its own database backups so it can update the volume history file when backups run, so AUTO_DB_BACKUP should be set to OFF and this is working as designed. As long as you are scheduling database backups through TSM, the ADM10502W messages can be ignored.
Restoring the TSM Database
The restore process will depend on what you need to achieve and where you are starting from. Three major scenarios exist;
Taking these three in turn.
Restoring a server database to its most current state
Assuming the active and archive logs are intact, all backups exist and all the files and directories for the database still exist, the restore process is simply halt the server then from the O/S command line, issue the command
Restoring a server database to a point in time
This is a little more complex. You need the latest full backup and the latest incremental backup from before the point in time. You also need the Server options file and the Volume history file, but note that the volume history file is wiped by the restore process, so take a copy of it before you start. If necessary, re-create your database and recovery log directories.¬†
The server will then find the last full backup from the volume history file and restore it, then work its way through any incremental backups create before the date and time specified above. However, the problem is that as you have wound the database back to a previous time, it is now out of step with the data in the storage pools, as migration and expiration might have run after the backup. Your old volume history file has a record of all volume usage, so take a look at it and pull out a list of all volumes that were changed after the point in time restore. What you are looking for is volume statuses of STGREUSE (updates) STGNEW (added volumes) and STGDELETE (removed volumes) - you can do this while you are waiting for the restore to run.
Run an AUDIT VOLUME command with the FIX=YES parameter against all your disk volumes, and all tape volumes marged as reused or deleted. If storage pool volumes were added after the backup you will need to add them again.
If the audit cannot find a backup file, it will be permanently lost and so copied again on the next backup. If the file exists in a copy storage pool, it will be marked as 'damaged', so you will need to run the RESTORE STGPOOL command to get those files restored from the copy. If you don't have any backups, the ultimate cleanup is to run DELETE VOLUME with the DISCARD=YES parameter, but this will delete your backup data.
You will also need to run an AUDIT LIBRARY command to fix any tape volume anomalies.
Disaster Recovery issues
A disaster recovery restore adds another layer of complexity. First you need to rebuild your server, hopefully from a SYSBAK or MKSYSB that puts all the relevant code back exactly as it was. If you do need to re-install TSM then note that the IBM manuals specifically state that 'The restore operation must be done by a Tivoli Storage Manager server at a code level that is the same as that on the server that was backed up - This means that the server code level can not change at all - not even by a patch level'.
You will probably then need to define your tape library, at least one drive, and paths using DEFINE LIBRARY, DEFINE DRIVE and DEFINE PATH commands. At this point you should have a TSM system ready for restore, so you can follow whichever of the 2 options above is appropriate.
Best practice for Database and Storage Pool disks
The following are some of the 'Best Practices' recommendations from IBM for setting up DB disk volumes for TSM Servers
Use fast, low latency disks for the Database, use SSD if you can afford it. Avoid the slower internal disks included by default in most AIX servers, and avoid consumer grade PATA/SATA disks. Use faster disks for the Active Logs too. Do not mix active logs with disks containing the DB, archive logs, or system files such as page or swap space. Slower disks for archive logs and failover archive logs can be used, if needed.
Use multiple database containers. For an average size DB, it is recommended to use at least 4 containers initially for the DB. Larger TSM servers, or TSM servers planning on using data deduplication, should have up to 8 containers or more. You should plan for growth with additional containers up front as adding containers later can result in an imbalance of IO and create hot spots.¬†
There should be a ratio of one database directory, array, or LUN for each inventory expiration process.
The block size for the DB varies depending on the tablespace, most are 16K, but a few are 32K. Segment/strip sizes on disk subsystems should be 64K or 128K.
If you use RAID, then define all your LUNs with the same size and type. Don't mix 4+1 RAID5 and 4+2 RAID6 together. RAID10 will outperform RAID for heavy write workloads, but costs twice as much. RAID1 is good for active logs.
Smaller capacity disks are better than larger ones if they have the same rotational speed. Have containers on disks that have the same capacity and IO characteristics. don't mix 10K and 15K drives for the DB containers.
Cache subsystem 'readahead' is good to use for the active logs; it helps in archiving them faster. Disk subsystems detect readahead on a LUN by LUN basis. If you have multiple reads going against a LUN, then this detection fails. So several smaller LUNs are better than a few large ones, but too many LUNS can be harder to manage.
However it is very difficult to given generic rules about disk configuration as this very much depends on what type of disks you are using.
High end disk subsystems such as the EMC DMX, the HDS VSP and the IBM DS8000 have very large front end cache to speed up performance, and stripe data in a way that makes it difficult to separate data by physical spindle. The IBM XIV takes this virtualisation to a higher level again. To get the best performance from these devices you want enough LUNs to spread the IO and get readahead cahce benefit, but not so many that they become difficlult to manage. For the XIV, consider using a queue depth of 64 per HBA to get best advantage of the parallelism capabilities.
Don't stripe your data using logical volumes, let the hardware do the striping. As a rule of thumb, consider using 50GB volumes for DISK pools and 25GB volumes for file pools. Define the same number of volumes per LUN as the RAID type to make up the LUN, so for example with 4+1 RAID5, define 4*50GB volumes per LUN, then each LUN will use 250GB, with effective capacity of 200GB.
The¬†Unix Tips¬†section contains some detail on how to use VMSTAT and IOSTAT commands to investigate potential disk bottlenecks.
Using DB2 commands on a TSM server
IBM's design model for TSM v6 and upwards is to store TSM metadata in a DB2 database, without the TSM administrators needing to know anything about DB2 and how to manage it. It is now becoming obvious that a TSM Administrator does need to know a bit of DB2, but it would always be wise to contact IBM for advice before running base DB2 cvommands. If you have a test 'sandpit' system that you can try things out on, then here are a few DB2 commands that might be useful.¬†
AUTHORISING A USERID TO BE ABLE TO START THE TSM SERVER
The TSM DB2 system is 'owned' by the userid that installed it, and normally only that userid has the administration authority needed to manage the DB2 database, including the ability to start the TSM service. However you can give access to another userid using DB2 commands. Open up a command line as the TSM instance owner by right clicking on it and taking the 'run as' option. You will need the instance owner userid and password to do this. Once you have the command line, type the following commands
Userid TSM_ADMIN can now be used to stop and start the TSM services
Recovering from a full archive log
Under tsm 6.x, the archive and active log directories can fill up, and if they do, the server will shut down. To prevent this, you need to make sure you trigger a FULL database backup once the archive log hits a threshold, but if the worst happens and the log files do fill up, you need a recovery process.
If this happens then you cannot use TSM commands to move the logs into bigger directories, as you cannot start TSM. What you need to do is create temporary logs elsewhere, then prune the archive log using native DB2 commands. However, remember that the archive log will hold enough information to wind back through the last 2 full backups, so you need to run 2 full backups to clear it down.
It is possible to query what is happening while a database recovery is in progress with the db2pd utility, a DB2 diagnostic tool that is provided with the TSM server installation code. You simply run this as a command from the shell prompt, like this:
To check out what is happening with a database recovery, run
STARTING AND STOPPING AUTO RUNSTATS
Runstats is used to optimise access paths through the TSM tables and should normally be set to run automatically as required. However if runstats starts automatically when the TSM is started up after a database upgrade, it can cause performance problems to the extent that no-one can log into the system.¬†
Now runstats will not start automatically when you restart TSM server. However you need runstats to keep your database optimised, so once you are happy that your TSM server is up and running, submit the following commands to the DB2 instance for your TSM server and Runstats will resume normal processing.
SOME OTHER POTENTIALLY USEFUL COMMANDS
You can enter any DB2 command from the DB2 command line, including SQL queries and commands that update or delete the database, so be careful. Some of the query commands could be useful for investigating TSM problems
The following commands require you to be logged in with adminstrator authority and connected to a database
Automatic Database reorganisation issues
TSM should automatically tune and manage its database. However this might not always work. One problem that you might see is that your database grows a lot faster than you might have expected, even though you are running expiration and the number of objects in the database is not growing by much. Apart from consuming space, this growth can also cause performance problems.
DB2 should have a feature called 'reclaimable storage' which according to IBM can 'consolidate in-use extents below the high water mark and return unused extents in your table space to the system for reuse'. A problem can arise if you originally installed TSM 6.1 as that used DB2 9.5 tablespaces and they do not have the reclaimable storage feature. If you then upgraded your TSM to higher levels, you will still be using DB2 9.5. You could get in touch with IBM and obtain the scripts that will allow you to upgrade DB2 to release 9.7. The issue is that the scripts must be run while the server is halted and generally require ten to thirty hours to run, and sometimes much longer.
If you installed TSM 6.2 then things are a bit better, as that used DB2 9.7, and that release did include reclaimable storage. However even then you might still not be able to reuse freed up space, as if your workload is high, the database reorg utility can conflict with your regular housekeeping. Large deduplicated storage pools can be an especial problem.
How does TSM reclaimable storage work?
TSM checks via DB2 to see which tables and indexes need to be reorganised, then it works through the list and processes the tables one at a time. It can take a long time to reorganise a large table, possibly a month or more. The process will be paused at the end of the daily reorg window, then restarted when the next daily window starts. When each table reorg is complete, TSM will run a RUNSTATS agains the table to optimise its performance. Once all the tables and indexes are reorganised, TSM will then wait at least 20 days before it starts the process again.¬†
How do I know if TSM reclaimable storage is running?
The easiest way is to check the server log for messages¬†
What control do I have over what reclaimable storage does?
In general, the more current your level of TSM, the better control you have. Some of the options below might not be valid for older releases of TSM.
The default position is that reorganisation can run 24 hours a day, but you can use options REORGBEGINTIME hh:mm and REORGDURATION nn to control when reorganisation starts, and how long it runs for. The 'nn' parameter is hours. You should aim to schedule reorg activity at a time when server utilisation is low. Things to avoid are intense backup and archive processing, and expiration, migration, or reclamation.
ALLOWREORGTABLE and ALLOWREORGINDEX can be set to 'NO' or 'YES'. The default values are YES for Table reorg and NO for Index reorg. Index reorg really needs to run at a quiet time, and if you enable it you must set the server option DB_DB2_KEEPTABLELOCK NO as it can cause database deadlocks (this is the default for TSM v6.3 onwards). Also, unlike Table reorg, Index reorg cannot be paused but if necessary it can be cancelled from a DB2 command line. I suggest you discuss options with IBM before enabling ALLOWREORGINDEX and DB_DB2_KEEPTABLELOCK NO as there are several factors to consider.
Three other options are DISABLEREORGTable, DISABLEREORGIndex and DISABLEREORGCleanupindex. These options can be used to prevent reorganisation from running against problem tables. The first 2 options take a list of tables as a parameter, while DISABLEREORGCleanupindex will only accept BF_BITFILE_EXTENTS.
Investigating Problems with the Server Instance
The first place to start is the TSM Active log, but if you need to go deeper, then the DB2 logs can be useful. However finding those logs can be a challenge as the location can depend on the the OS platform or even the OS release level. The best way to be sure you have the correct log is to check the DIAGPATH variable in DB2.¬†
The DB2diag.log contains information like database backups, table reorganizations, memory management messages, start and stop of TSM server and hardware information logged at instance start time, as well as error and warning messages.
Sometimes when investigation TSM server problems, the DB2 terminology does not quite match TSM so the error messages in the DB2 logs can look a bit strange. For example, Tivoli Storage Manager refers to 'transactions' which DB2 calls to 'units of work' (UOW). Tivoli Storage Manager uses select statements where DB2 uses SQL and are also sometimes referred to as DML, or data manipulation language statements.
Another potentially useful file is the startup trace log dsmupgdx.trc, which is located in c:\program files\tivoli\tsm for Windows or /opt/tivoli/tsm/server for UNIX and Linux servers. If you get database startup problems it's alwayus worth checking the file to see if any useful error messages exist.
Some TSM errors messages are very generic and more investigation is needed to pinpoint the problem. An example is 'ANR8503E A failure occurred in writing to volume'. To investigate this you need to enable a TSM server trace. To do this, enter the following commands from the TSM server command line
The open the trace file and look at the messages that were written out just before the error.
You might sometimes see an error message, 'ANR2981E Database backup terminated due to environment or setup issue related to file access - DB2 sqlcode -2033 sqlerrmc 106.' The messages in the DB2 log file are a bit confusing, and will be something like
A possible cause is that the DSMI variables are not defined correctly in the DB2 user profile. This is found in /sqllib/userprofile in UNIX/Linux systems. The script variables should be set as
Sometimes after a problem, DB2 goes into crash recovery mode and the TSM server appears to be hung. DB2 crash recovery can take a long time. If your TSM server is hung, check your DB2 db2diag.log for a message like
Then log into DB2 as the instance owner and run the command 'db2 list utilities show detail'. If Crash Recovery is active, the message will tell you how much work it needs to do, so you can estimate how much longer it will take. Some of the sample output of this command is shown below.
Errors on Database Startup
Your first point of call should be to raise an incident with TSM support and get advice on your problem. However the following might help.
When trying to start up TSM the following error message can appear "ANR0170E - Error detected, database restart required", and you may see errors in the actlog a bit like
ANR0171I dbieval.c(874): Error detected on 3:2, database in evaluation mode.¬†
The resolution is to restart DB2 manually with the RESTART command. Open up a DB2 command line window as explained above then issue the following
You might have to run the restart command a few times before the issue is resolved. If this does not fix the problem you probably need to contact IBM Support, although you can use the db2dart command to run a database analysis. This generates a report file that would be useful for IBM support.
Another possible message is 'ANR0151W Database manager fails to start'. This problem can occur after a database crash, maybe due to a hardware issue. If the database will not start up with the dsmserv command and you see errors like
The problem is that some Inter Process Communication (IPC) tasks are still active and are locking out resources. You need to cancel the DB2 instance then remove the IPC resoures. Log on with the Tivoli Storage Manager server instance user ID and run the following command to stop the DB2 instance
Check to see if there are outstanding IPC resources that are associated with the instance
Clean up any IPC resources that are associated with the instance
Verify whether there are outstanding IPC resources that were not removed by the ipclean command.
If there are outstanding IPC resources associated to the instance, use the following commands to remove them
Once all outstanding IPC resources have been removed, you should be able to restart the Tivoli Storage Manager server.
On Windows, a TSM server might fail to start after an upgrade with the error¬†
The DB2 license file is called db2ese.lic and was shipped with your TSM server package. Its location will depend on where you extracted the server package, but assuming you extracted to a directory d:\tsm_extract\, you will find it in the following directory, where DB2_x.x corresponds to your DB2 version number.¬†
Run the 'db2licm -l' command again and now you should see
and you should be able to start your TSM Server instance normally.
AIX Maximum Number of Processes
You may see a database backup failing on an AIX server with an error like 'ANR2968E Database backup terminated. DB2 sqlcode: -2033. DB2 sqlerrmc: 292' If this error is not corrected the recovery log will fill up and crash the server. You may also see a message like 'Insufficient AIX system resource' in the db2diag log file.
The API error code 192 means that the API was unable to 'fork' or create a process to do its database backup. AIX has a parameter called maxuproc which limits the maximum number of processes that a user is allowed per user, and this value should be increased.
To see what value is set, use the command
and to change the value use the command below, selecting a value that is suitable for your server.
Effect of Deduplication on Database size
Deduplication will save a lot of backend storage, but it does this at the expense of increasing the size of the TSM database because the TSM database has to store and track the metadata that is required to manage the deduplication. The exact amount of extra space required is difficult to calculate up front, as it depends on your average 'deduplication chunk size' and this will vary depending on how well your data deduplicates. IBM suggests an typical chunk size of 100,000 bytes, and provides some scripts that you can run to measure your exact average chunk size once you have deduplication working. Each chunk needs 490 bytes of metadata to describe the data in the primary pool, and another 190 bytes for the data in each copy pool.
A starting point is to estimate your database size without deduplication, and to do this you use the formula¬†
To calculate the deduplication overhead, use the formula below to get the number of chunks¬†
Running this formula on an existing server with a 135GB database predicted an increase of 105GB with deduplication, which is not a trivial amount.
Moving a TSM database hosted on Windows
If you run your TSM server under Windows, then by default, your TSM database will be installed on the C: This can be an issue as the C: is usually reserved for system data, and system administrators prefer that your application data be stored on a different drive. It is possible to move the database using the DB2 utility 'db2relocatedb'. However db2relocatedb will not actually move your database, you have to do that yourself. What it does is update the pointers within DB2 so it knows where the database has been moved to.
First, just confirm that the database is allocated on the C:. Run the 'db2cmd' command from a Windows command line to open a DB2 command line, then run 'db2 list database directory' and within the command listing you should see a line
Now, just incase something goes wrong, run a full TSM database backup
Stop the TSM Server with the HALT command. This should stop DB2 as well, but check and make sure it is down.
Copy your data to the new drive with the Windows copy command. Assuming you are going to the G:, this would be¬†
The db2relocatedb utility needs a configuration file to tell it what you are moving. The configuration file would normally be created in the same directory as db2relocateddb runs from and is usually called reloc.cfg. However you can create the file anywhere, in which case you need to specify the absolute path in the command example below.¬†
Create this file then run the db2relocatedb command pointing it to the configuration file location.
Now start your TSM server up again and check that all is well. Rerun that 'db2 list database directory' command and check that the server is actually running from the g: Once you are certain all is well you can deleted the data off the c:
We have 18 guests and no members online
Articles Most Read
Articles by Date