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 > access level problem in multiple instance

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-18-07, 10:00
Lxw176 Lxw176 is offline
Registered User
 
Join Date: Feb 2005
Posts: 36
access level problem in multiple instance

Hi,

We have installed DB2 V9.1 Enterprise Server Edition on AIX 5L server side, at client side, we use DB2 V9.1 Client installed on Windows XP machine. So users can use SSH or DB2 GUI tools, such as DB2 Command Editor or DB2 Control Center to connect to the database on the server. Also, we created two separate instances db2inst1 and db2inst2 on the server. However, it seems db2inst1 can access any database exists in db2inst2 and vice versa. Same problem as individual user, each user can connect to both db2inst1 and db2inst2 database using personal account which theoretically suppose to access only one instance. Does anyone can tell me how to restrict user access? Does it a AIX access level thing?

Thanks in advance!
Lan
Reply With Quote
  #2 (permalink)  
Old 07-18-07, 10:54
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
grant connect is done to public
revoke this authority and grant connect to individual users
grant access on tables to individual users
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
Reply With Quote
  #3 (permalink)  
Old 07-18-07, 13:49
Lxw176 Lxw176 is offline
Registered User
 
Join Date: Feb 2005
Posts: 36
access level problem in multiple instance

Hi Guy,

what you mean "grant connect is done to public" ?
and how I can
"revoke this authority and grant connect to individual users"?
and
"grant access on tables to individual users"?

Could you tell me in more detail? since I'm not familiar with DB2.

Thanks!
Lan
Reply With Quote
  #4 (permalink)  
Old 07-18-07, 18:37
gou007 gou007 is offline
Registered User
 
Join Date: Jun 2007
Posts: 12
hi,
by default whenever a database is created CONNECT, CRETETAB, BINDADD, IMPLICIT_SCHEMA privileges are granted to public.
Also USERSPACE1 is granted to public
so all the users can access all the tables and connect to that database.
These are called implicit privileges.

so u need to revoke them explicitly and grant them to u'r choice
To revoke use these commands...

1. revoke connect on database from public

2. revoke use of tablespace userspace1 from public

and now u can decide to whom u want to grant privieges

Last edited by gou007; 07-18-07 at 19:00.
Reply With Quote
  #5 (permalink)  
Old 07-19-07, 02:21
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
and the grant command (see infocenter for detail)
grant connect on database to user xxx
grant select on sqldba.employee to user yyy
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
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