免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3038 | 回复: 1
打印 上一主题 下一主题

紧急求助!!! [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2007-06-27 23:45 |只看该作者 |倒序浏览
在AIX,db2环境上,想建议一个用户B,操作用户A所拥有的数据库,但是不给B数据库的DBM权限,而是通过grant给部分表格的权限;但是B在连接数据库的时候,报如下错误:
SQL0969N There is no message text corresponding to SQL error "-2079391743" inthe message file on this workstation. The error was returned from module"SQLEUCCM" with original tokens "".

把数据库的ADM权限grant过去都不行,但是把db2iadm组加入到B用户的组列表中就可以了,但是这样B和A就拥有同样的dbm权限了.

不知是何原因,请高手赐教!!

另附一篇文章,说是tablespace建立时的用户不对,我检查了我的环境,tablespace没有问题。

SQLEUCCM error message for DB2
Hopefully this proves useful to someone else in the same position in the future... I have been working on a simple PHP application that connects to DB2 using the ibm_db2 extension. Recently I decided to try scaling it up to test the application with a more realistic (10GB) database.

I created a new test database on a partition that had enough room, but then encountered a very strange error message just trying to connect to the database:

[IBM][CLI Driver] SQL0969N There is no message text corresponding to SQL error "-2079391743" in the message file on this workstation. The error was returned from module "SQLEUCCM" with original tokens "". SQLCODE=-2079391743
Needless to say, this message really didn't help me much. Googling and Yahooing for the terms also gave me no useful results (there was a thread on the International DB2 User Group mailing list, but the site requires a user ID and login and I just wanted to get on with my day). The DB2 support site didn't provide any hits, and neither did the DB2 Information Center.

It took me a while to figure this out, but apparently the ownership and permissions on the directory that contains your tablespaces (if you're using filesystem-based, or "system managed" tablespaces) have to be "just so". DB2, for the uninitiated, uses operating system accounts and groups for database authentication and privileges. My DB2 instance user was "db2inst1", belonging to the "db2iadm1" group -- default values -- however, the directory in which I created the tablespaces belonged to user "dan" and group "db2iadm1".

localhost php4 # ls -l /opt/photos/db2base -d
drwxrwxrwx 3 dan db2iadm1 72 Oct 18 10:35 /opt/photos/db2baseOkay, so even though the db2inst1 user is a member of the db2iadm1 group, DB2 apparently also wants it to own the directory in which the tablespaces live. By issuing a "chown db2inst1 /opt/photos/db2base" command, DB2 was satisfied and my PHP scripts started working again. And maybe, just maybe, the next user that runs into this problem will find this post in a search engine and save themselves an hour or two of befuddlement...

感觉是还是用户的权限相关,或者db2某些文件的权限设置有关,但是一时找不到解决办法,各位是否遇到类似问题,是如何解决的??还请不吝赐教!!

论坛徽章:
0
2 [报告]
发表于 2007-06-28 13:34 |只看该作者
用db2diag -rc 0x840F0001可以查看错误代码的含意。如下:
Input ZRC string '0x840F0001' parsed as 0x840F0001 (-2079391743).

ZRC value to map: 0x840F0001 (-2079391743)
        V7 Equivalent ZRC value: 0xFFFFC601 (-14847)

ZRC class :
        Non-Critical Media Error (Class Index: 4)
Component:
        SQLO ; oper system services (Component Index: 15)
Reason Code:
        1 (0x0001)

Identifer:
        SQLO_ACCD
Identifer (without component):
        SQLZ_RC_ACCD

Description:
        Access Denied

Associated information:
        Sqlcode -970
SQL0970N  The system attempted to write to a read-only file.

        Number of sqlca tokens : 0
        Diaglog message number: 8701




是不是用户B在OS层面上有读写权限的问题,虽然数据库权限已经有了?
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP