If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > how can you config a db using command line or put in bat file?? v8.1

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 03-27-04, 19:09
ElementX ElementX is offline
Registered User
 
Join Date: Mar 2004
Posts: 5
how can you config a db using command line or put in bat file?? v8.1

I've just gone from DB2 6.1 to 8.1 and wow things are much different. I'm trying to figure out how to configure a database quickly and easily without having to talk users through the client configuration assistant.

In v6.1, I would have them run the following command and it would automatically configure the database.

C:\SQLLIB\BIN\DB2CFIMP.exe %SrcDir%\IBM\DB2.ins

Here's an example of what the DB2.ins file contained:

[FILE_DESCRIPTION]
APPLICATION=DB2/Windows 95 6.1.0
FILE_CONTENT=DB2 CCA Exported Data Sources
FILE_TYPE=CommonServer
FILE_FORMAT_VERSION=2.0
Platform=15
DB2SYSTEM=
Instance=DB2

[INST>DB2]
instance_name=DB2
NodeType=2
ServerType=DB2WINDOWS95

[NODE>SIEBEL00]
DB2SYSTEM=sampledb
Instance=db2pacp
ServerType=DB26000
Protocol=TCPIP
Hostname=sample.hostname.com
Portnumber=1000
Security=0

[DB>SIEBEL00:dbsample]
Dir_entry_type=REMOTE
Authentication=NOTSPEC
DBName=dbsample

[CLI_ODBC>dbsample]
DataSourceName=dbsample
DataSourceType=System
ODBCParameters=No

I would like to know how this would be done in v8.1. Whats the equivalent to the DB2CFIMP.exe app in v6.1? Thanks in advance
Reply With Quote
  #2 (permalink)  
Old 03-27-04, 22:13
ElementX ElementX is offline
Registered User
 
Join Date: Mar 2004
Posts: 5
I forgot to mention some details. This is DB2 v.8.1.4 running on windows 2000 and XP.

I work at a helpdesk and I do not work with DB2 much. I just work with users to configure their databases and would like to simplify the task as much as possible.

Instead of relying on the users' abilities to spell and type properly, I'd like to make it a one click process and save me 10 mins on the phone. I generally create a gui interface for these things using Autoplay so the users get a button to click on to do this for them.. I just dont know what the commands are for DB2 v8.1 for configuring databases without going through the configuration assistant. And I'd prefer not use the import option.
Reply With Quote
  #3 (permalink)  
Old 03-27-04, 23:25
Marcus_A Marcus_A is offline
Registered User
 
Join Date: May 2003
Location: USA
Posts: 5,198
Assuming you are using TCP/IP, look at the following 2 commands in the Command Reference manual (which can be downloaded from the IBM site).

CATALOG TCP/IP NODE
CATALOG DATABASE
__________________
M. A. Feldman
IBM Certified DBA on DB2 for Linux, UNIX, and Windows
IBM Certified DBA on DB2 for z/OS and OS/390
Reply With Quote
  #4 (permalink)  
Old 03-28-04, 11:28
ElementX ElementX is offline
Registered User
 
Join Date: Mar 2004
Posts: 5
Thanks for the response Marcus.

I figured it out yesterday. Looks like DB2 v8.1 still has the same command, DB2CFIMP.exe. I just went through the configuration assistant, then exported the database into a file. Then I just ran DB2CFIMP.exe and specified the exported file and it configured the databased! I read through tons of posts here and discovered that the imp in db2cfimp means import. I guess I failed to specify that i didnt want to launch the configuration assistant and use the import option in the menus. Now I can just use the following command to do the configuration:

"c:\program files\sqllib\bin\db2cfimp.exe" "%SrcDir%\whatever folder\database configuration file"
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On