服务名和域名之间的关系???

[复制链接]
查看11 | 回复7 | 2005-10-30 17:05:33 | 显示全部楼层 |阅读模式
一开始我建库的时候用的全局数据库名是APP.COM实例名是APP。当库建好后,我有更改了参数SERVICE_NAME=‘APP.COM,ORA9’,
问题:
1。但是当我在客户端配服务名是还要配Ora9.com才能连上数据库,为什么用Ora9不能连上去???
2。怎样设置才能不用附加域名就可以连上数据库。
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
怎么没人知道吗,Help................................Help...................................
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
客户端配服务名+domain-name(sqlnet.ora)要匹配数据库的服务名,在建好数据库后domain name就以确定,如果改变数据库的服务名,而不改变sqlnet.ora或客户端配服务名当然就没法匹配了
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
参考:
http://blog.itpub.net/post/11/3085
http://blog.itpub.net/post/11/3115
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
最初由 husthxd 发布
[B]参考:
http://blog.itpub.net/post/11/3085
http://blog.itpub.net/post/11/3115 [/B]

我的情况是:
SQL> show parameter service_name
NAME
TYPEVALUE
------------------------------------ ----------- ------------------------------
service_names
stringapp.com,ora9

app.com,ora9[/COLOR]
然后在客户端的设置如下:
APP =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 172.18.150.250)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME =ora9.com[/COLOR]
)
)
)
只有写成 ora9.com[/COLOR] 才能连接上数据库,如果写上 ora9[/COLOR] 是不行的,为什么????????
有没有办法用 ora9[/COLOR] 就能连接上呢?????
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
或者是怎样在数据库中把Domain取消掉????????????
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
你的sqlnet.ora怎么配置的?
加上NAMES.DEFAULT_DOMAIN=com试试

Purpose
Use the parameter NAMES.DEFAULT_DOMAIN to set the domain from which the client most often looks up names resolution requests. When this parameter is set, the default domain name is automatically appended to any unqualified net service name or service name.
For example, if the default domain is set to us.acme.com, the connect string CONNECT scott/tiger@sales gets searched as sales.us.acme.com. If the connect string includes the domain extension, such as CONNECT scott/[email protected], the domain is not appended.
Default
None
Example
NAMES.DEFAULT_DOMAIN=acme.com
回复

使用道具 举报

千问 | 2005-10-30 17:05:33 | 显示全部楼层
谢谢,等回去再试了,快过年了,先祝大家新年快乐。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行