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 do you open db2 command line in Linux v8.1 db2

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-15-07, 16:52
mr_coffee mr_coffee is offline
Registered User
 
Join Date: Aug 2007
Posts: 28
Talking how do you open db2 command line in Linux v8.1 db2

Hello everyone.

Someone just installed DB2 on a RHEL4 Linux box and I need to test to see if its collecting data or not...

The problem is I have no idea how to get to the db2 command line.

I'm reading this tutorial and it tells me to type in db2start but this doesn't work.

I'm checking in the following directory:
DB2V8.1/bin

Any idea how I can get to the screen so I can try to log in and run some queries?

Thanks any help would be great!
__________________
IBM: Tivoli zSeries Co-op
Reply With Quote
  #2 (permalink)  
Old 10-15-07, 18:07
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
The executable name for DB2 command line processor is "db2"
Reply With Quote
  #3 (permalink)  
Old 10-15-07, 19:00
mr_coffee mr_coffee is offline
Registered User
 
Join Date: Aug 2007
Posts: 28
I also tried that in the bin directory of db2 v8.1


I tried both db2 and also running it as a shell script ./db2 and there is no db2 to run, so does this mean db2 was installed improperly or am I missing something?

This is on linux by the way (RHEL 4)

EDIT:
I get the following error when ./db2

root@opie~] ./db2
SQL10007N Message "-1390" could not be retrieved. Reason code: "6".



Google told me the problem is I need to set the DB2INSTANCE environment variable...but what do I set it to exactly?

Sorry I'm a n00b to db2/linux.
__________________
IBM: Tivoli zSeries Co-op

Last edited by mr_coffee; 10-15-07 at 19:13.
Reply With Quote
  #4 (permalink)  
Old 10-16-07, 02:58
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
create a client instance for this user, and sqllib and bin and other will be created profile will be changed and sqllib/bin will be in the path and db2 can be executed.. (see db2icrt command to be executed from root)
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
Reply With Quote
  #5 (permalink)  
Old 10-17-07, 04:52
grofaty grofaty is offline
Registered User
 
Join Date: Jan 2003
Posts: 1,570
Hi,
it look like you haven't installed/configured as it should.
Try looking into how-to for db2-linux:
http://tldp.org/HOWTO/DB2-HOWTO/
Regards,
Grofaty
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