Results 1 to 10 of 10
  1. #1
    Join Date
    Mar 2003
    Location
    germany
    Posts
    17

    Cool Unanswered: db2 V8 client & server

    I want' to install DB2 V.8 Workgroup Server and the Administration
    Client on the same PC. Is this possible ? And if it is how can i
    connect from the client (as a normal user with few rights only)
    to the servers databases and tables (instance is the default instance:
    db2inst1) ? Does db2 have to start as a service at anyones loggin ?

    thanks
    chris

  2. #2
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    Yes, you can install the Administrative Client on the same machine as the DB2 database server.

    DB2 runs as a service on Windows NT, 2000, XP, etc. Normally you would have the DB2 service started automatically when the machine boots up. If you did not want to start DB2 service automatically, then someone would need to do that (either on the server, or remotely). But one of the following authorizations is necessary to issue db2start:

    - sysadm
    - sysctrl
    - sysmaint

    If DB2 is already started, then any user with any rights (like select) on a specific database (within the instance) can connect to that database. The major resources that DB2 uses (primarily system memory) are not allocated until someone connects to a particular database.

  3. #3
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    Actually, I am not sure if you can start DB2 remotely on Windows unless you telnet into the server machine. But most have the DB2 started automatically at boot up time, since it does not use a significant amount of resources until someone connects to a database.

  4. #4
    Join Date
    Mar 2003
    Location
    germany
    Posts
    17

    db2 v8 client&server on the same machine

    I forgot to say: It is not windows but Linux (Suse V.8.1)
    On the server (with the db2inst1 - instance) i have a
    account named equal to my linux-account-name.
    But when I log in Linux no db2 command is known.
    Maybe db2 has to start as a service on Linux too,
    but how ?

    thanks
    chris

  5. #5
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    I am running DB2 Linux on RH8. The db2start command is located in the /home/db2inst1... directories. That is why another user cannot execute the commands unless they specify exactly where they are located or inlcude the directory in the path statement.

    But to start DB2 a user will need one of the authorities to execute the db2start command. The Linux file itself (db2start) also has security as to who can execute it (but this can be modified within Linux). DB2 can be set up to be auto-started in Linux.

    When starting the DB2 Administrative Server (if not auto-started) you need to be (or have same authority as) the DB2 Adminintrative Server User (probably dasusr1). Same issues apply with regard to directory paths as to where the db2admin program is. The command to start the Admin Server is "db2admin start."
    Last edited by Marcus_A; 06-06-03 at 03:37.

  6. #6
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    You can start db2 remotely from control centre ...

    Requisites:
    1) Admin node defined on client
    2) Admin Server running
    3) Attach with privileged uid/password

    Cheers

    Sathyaram

    Originally posted by Marcus_A
    Actually, I am not sure if you can start DB2 remotely on Windows unless you telnet into the server machine. But most have the DB2 started automatically at boot up time, since it does not use a significant amount of resources until someone connects to a database.

  7. #7
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650

    Re: db2 v8 client&server on the same machine

    a script $INSTHOME/sqllib/db2profile sets up the environment to use a db2 instance

    assuming db2inst1 is your instance, in your user's(equal) .profile(or equivalent) add

    . ~db2inst1/sqllib/db2profile

    HTH

    Sathyaram

    Originally posted by chrste
    I forgot to say: It is not windows but Linux (Suse V.8.1)
    On the server (with the db2inst1 - instance) i have a
    account named equal to my linux-account-name.
    But when I log in Linux no db2 command is known.
    Maybe db2 has to start as a service on Linux too,
    but how ?

    thanks
    chris

  8. #8
    Join Date
    Mar 2003
    Location
    germany
    Posts
    17

    Smile Re: db2 v8 client&server on the same machine

    O.K. that seams to work now. When i work with the Command
    Center (starting is very slow now) i can see all tables. Working
    with the CLP its a bit different.
    1) db2
    2) connect to databasename
    3) list tables DOESN'T WORK (??? - I will find out)
    4) Select * from db2inst1.tablename --> works fine
    5) Hope there won't occur further problems

    Many Thanks to all who helped me.
    Chris

    Originally posted by sathyaram_s
    a script $INSTHOME/sqllib/db2profile sets up the environment to use a db2 instance

    assuming db2inst1 is your instance, in your user's(equal) .profile(or equivalent) add

    . ~db2inst1/sqllib/db2profile

    HTH

    Sathyaram

  9. #9
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650

    Re: db2 v8 client&server on the same machine

    3) list tables DOESN'T WORK (??? - I will find out)

    Lists tables using the CURRENT SCHEMA name

    list tables for schema <name>

    will do the trick

    Sathyaram



    Originally posted by chrste
    O.K. that seams to work now. When i work with the Command
    Center (starting is very slow now) i can see all tables. Working
    with the CLP its a bit different.
    1) db2
    2) connect to databasename
    3) list tables DOESN'T WORK (??? - I will find out)
    4) Select * from db2inst1.tablename --> works fine
    5) Hope there won't occur further problems

    Many Thanks to all who helped me.
    Chris

  10. #10
    Join Date
    Mar 2003
    Location
    germany
    Posts
    17

    Re: db2 v8 client&server on the same machine

    Everything works fine now.
    Thank you all.

    Chris

    Originally posted by sathyaram_s
    3) list tables DOESN'T WORK (??? - I will find out)

    Lists tables using the CURRENT SCHEMA name

    list tables for schema <name>

    will do the trick

    Sathyaram

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •