Topic(s):   DB2 Certification

December 17, 2007

DB2 9 DBA Exam Sample Questions: Terminating applications and adding storage containers
Posted by Roger Sanders @ 09:50 AM ET | Dec 17, 2007

Here's a quick way to stay on track with your preparation for the DB2 9 DBA certification exam, even at this busy time of year: Try these sample questions from the book DB2 9 for Linux, UNIX, and Windows Database Administration: Certification Study Guide, published by MC Press. The questions are reprinted here with permission. Check back each week for more, and try past questions here.

QUESTION 7
A LIST APPLICATIONS command returned the following output:




























Auth Id App.Name App.Handle Application Id
DB Name # of Agents
RSANDERS db2taskd 148 *LOCAL.DB2.070601164915 SAMPLE 1
RSANDERS db2stmm 147 *LOCAL.DB2.070601164914 SAMPLE 1
RSANDERS db2bp.exe 146 *LOCAL.DB2.070601164913 SAMPLE 1


Which two of the following commands will terminate all of the applications that are currently running?

A. FORCE APPLICATION (146, 147, 148)
B. FORCE APPLICATION (LOCAL.DB2.070601164915,
LOCAL.DB2.070601164914, LOCAL.DB2.070601164913)
C. FORCE APPLICATION (db2taskd, db2stmm, db2bp.exe)
D. FORCE ALLPICATION ALL
E. FORCE ALL APPLICATIONS

QUESTION 8
If the following CREATE DATABASE command is executed:

CREATE DATABASE payroll ON C:

Which of the following commands will add new storage containers to the PAYROLL database?

A. ALTER TABLESPACE ADD STORAGE D:\data1, D:\data2
B. ALTER DATABASE ADD STORAGE D:\data1, D:\data2
C. ALTER TABLESPACE ADD CONTAINERS D:\data1, D:\data2
D. ALTER DATABASE ADD CONTAINERS D:\data1, D:\data2

Answers
QUESTION 7
The correct answers are A and D. You can terminate one or more running applications pre-maturely by executing the FORCE APPLICATION command (assuming you have SYSADMN or SYSCTRL authority). The basic syntax for this command is:

FORCE APPLICATION ALL

or

FORCE APPLICATION ( [ApplicationHandle] ,... )

where:

ApplicationHandle Identifies the handle associated with one or more applications whose instance attachments and/or database connections are to be terminated.

Thus, if you wanted to force all users and applications connected to databases stored on a server named DB_SERVER to terminate their database connections, you could do so by executing a FORCE APPLICATION command that looks something like this:

FORCE APPLICATION ALL

On the other hand, if you wanted to force a specific application whose handle is 148 to terminate its processing, you could do so by executing a FORCE APPLICATION command that looks like this:

FORCE APPLICATION (148)

QUESTION 8
The correct answer is B. If a database is enabled for automatic storage (which is the default behavior in DB2 9), container and space management characteristics of its table spaces are determined by the DB2 Database Manager. And, although the ALTER TABLESPACE command can be used to add new containers to existing DMS table spaces, it cannot be used to add new containers to automatic storage stable spaces. To perform this type of operation, you must use the ALTER DATABASE statement instead. The basic syntax for this statement is:

ALTER DATABASE [DatabaseName]
ADD STORAGE ON ‘[Container]’ ,... )

where:

DatabaseName Identifies the database, by name that is to have new containers added to its pool of containers that are used for automatic storage.
Container Identifies one or more new storage locations (containers) that are to be added to the collection of storage locations that are used for automatic storage table spaces.

Thus, if you wanted to add the storage locations D:\data1 and D:\data2 to a database named SAMPLE that is configured for automatic storage and resides on a Windows system, you could do so by executing an ALTER DATABASE SQL statement that looks like this:

ALTER DATABASE sample ADD STORAGE ON 'D:\data1', 'D:\data2'

Trackback Pings

TrackBack URL for this entry:
http://www.ibmdatabasemag.com/blog/main/archives/2007/12/post_8.html

« DB2 9 DBA Exam Sample Questions: Recovering a database and LBAC | Main | Most read 2007 articles: DB2 and Informix »





This is a public forum. CMP Media and its affiliates are not responsible for and do not control what is posted herein. CMP Media makes no warranties or guarantees concerning any advice dispensed by its staff members or readers.

Community standards in this comment area do not permit hate language, excessive profanity, or other patently offensive language. Please be aware that all information posted to this comment area becomes the property of CMP Media LLC and may be edited and republished in print or electronic format as outlined in CMP Media's Terms of Service.

Important Note: This comment area is NOT intended for commercial messages or solicitations of business.



CAREER CENTER
Ready to take that job and shove it?
SEARCH JOBS
RECENT JOB POSTINGS
CAREER NEWS
10 Search Engines You Don't Know About
Go beyond Google and get vertical. These specialized search sites will help you find the business information you need -- fast.

Subscribe to the new digital version of IBM Database Magazine
New Digital Version

Sponsored links:



Subscribe to the IBM Database Magazine Newsletter

Email Address *
First Name
Last Name
HTML Preference
HTML Text
 

Fields with * are required.

 




Visit these other IBM and TechWeb Partner Sites: :
Maximizing ROI Through Business Process Management (BPM) and Service-Oriented Architecture (SOA)
Internet Evolution – The Macrosite for News, Analysis, & Opinion About the Future of the Internet
Business Innovation – Technology Strategies and Solutions for Driving Business Success