{"id":1228,"date":"2019-06-21T08:55:08","date_gmt":"2019-06-21T00:55:08","guid":{"rendered":"http:\/\/www.hefeiyu.com\/?p=1228"},"modified":"2019-06-21T08:59:54","modified_gmt":"2019-06-21T00:59:54","slug":"oracle-11g%e9%80%8f%e6%98%8e%e7%bd%91%e5%85%b3%e8%bf%9e%e6%8e%a5sqlserver","status":"publish","type":"post","link":"https:\/\/www.hefeiyu.com\/?p=1228","title":{"rendered":"Oracle 11g\u900f\u660e\u7f51\u5173\u8fde\u63a5Sqlserver"},"content":{"rendered":"<p>oracle \u900f\u660e\u7f51\u5173\u662foracle\u8fde\u63a5\u5f02\u6784\u6570\u636e\u5e93\u63d0\u4f9b\u7684\u4e00\u79cd\u6280\u672f\u3002\u901a\u8fc7Gateway\uff0c\u53ef\u4ee5\u5728Oracle\u91cc\u900f\u660e\u7684\u8bbf\u95ee\u5176\u4ed6\u4e0d\u540c\u7684\u6570\u636e\u5e93\uff0c\u5982SQL Server, DB2, Sybase\u7b49\u7b49\uff0c\u5c31\u50cf\u8fdc\u7a0bOracle\u6570\u636e\u5e93\u4e00\u6837\u3002\u914d\u7f6e\u540e\u7684sql\u67e5\u8be2\u7684\u5904\u7406\u6d41\u7a0b<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"931\" height=\"104\" class=\"wp-image-1229\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-11.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-11.png 931w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-11-768x86.png 768w\" sizes=\"auto, (max-width: 931px) 100vw, 931px\" \/><\/p>\n<p><strong>\u4e00\u3001\u73af\u5883\u4fe1\u606f<\/strong><\/p>\n<p><strong>Oracle11g \uff08<\/strong>linux.x64\u7cfb\u7edf<strong>\uff09<\/strong><\/p>\n<table>\n<tbody>\n<tr>\n<td>IP\u5730\u5740<\/td>\n<td>192.168.1.9<\/td>\n<\/tr>\n<tr>\n<td>Oracle\u6839\u76ee\u5f55<\/td>\n<td>\/u2\/oracle\/product\/11.2.0\/dbhome_1<\/td>\n<\/tr>\n<tr>\n<td>Oracle\u7aef\u53e3<\/td>\n<td>1521<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>Oracle gateway \uff08Window server 2008 R2\uff09<\/strong><\/p>\n<p><strong>(\u53ef\u4ee5\u72ec\u7acb\u4e00\u53f0\u670d\u52a1\u3002\u672c\u4f8b\u5b50\u8ddfSqlserver2008 R2 \u7684\u670d\u52a1\u5668\u88c5\u5728\u4e00\u8d77\u4e86\u3002\u539f\u56e0\u662f\u61d2\u5f97\u518d\u88c5\u4e00\u53f0\u670d\u52a1\u5668\uff0c\u672c\u4f8b\u5b50Sqlserver2008 R2\u662fWindow server 2008 R2\u7cfb\u7edf\uff0c\u53ef\u89c6\u5316\u64cd\u4f5c\u65b9\u4fbf\u70b9\uff0c\u6240\u4ee5\u5e72\u8106\u88c5\u4e00\u8d77\u4e86\u3002\u9664\u4e86\u76d1\u542c\u7aef\u53e3\u8981\u4ece1521\u6539\u62101522\u5916\uff0c\u65b0\u88c5\u4e00\u53f0\u670d\u52a1\u5668\u4e0a\u6240\u6709\u914d\u7f6e\u4e00\u6837\u7684)<\/strong><\/p>\n<table>\n<tbody>\n<tr>\n<td>IP\u5730\u5740<\/td>\n<td>192.168.1.50<\/td>\n<\/tr>\n<tr>\n<td>gateway11\u6839\u76ee\u5f55<\/td>\n<td>D:\\Oracle\\product\\11.2.0\\tg_1<\/td>\n<\/tr>\n<tr>\n<td>gateway\u7aef\u53e3<\/td>\n<td><strong><span style=\"color: #ff0000;\">1522 (\u9ed8\u8ba4\u662f1521\uff0c\u56e0\u4e3a\u6b64\u8ba1\u7b97\u673a\u4e0a\u5df2\u7ecf\u5b89\u88c5\u4e86\u6570\u636e\u5e93\u4f7f\u7528\u6b64\u7aef\u53e3\uff0c\u6240\u4ee5\u7aef\u53e3\u51b2\u7a81\u4e86\uff0c\u9700\u8981\u6539\u4e00\u4e0b)<\/span><\/strong><\/td>\n<\/tr>\n<tr>\n<td>SID<\/td>\n<td>C6<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>\u91d1\u548cOA\u7684C6 (Sqlserver2008 R2) Window server 2008 R2<\/strong><\/p>\n<table>\n<tbody>\n<tr>\n<td>IP\u5730\u5740<\/td>\n<td>192.168.1.50<\/td>\n<\/tr>\n<tr>\n<td>\u6570\u636e\u5e93\u540d<\/td>\n<td>C6<\/td>\n<\/tr>\n<tr>\n<td>\u7528\u6237\u540d<\/td>\n<td>sa<\/td>\n<\/tr>\n<tr>\n<td>\u5bc6\u7801<\/td>\n<td>admin_123<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Oracle\u900f\u660e\u7f51\u5173linux\u7cfb\u7edf\u4e0b\u8f7d\u5730\u5740\uff0c\u4e5f\u53ef\u4ee5\u81ea\u52a8\u641c\u7d22\u4e0b\u8f7d:<\/p>\n<p>http:\/\/download.oracle.com\/otn\/linux\/oracle11g\/R2\/linux.x64_11gR2_gateways.zip<\/p>\n<p>\u9002\u7528\u4e8e Microsoft Windows (x64) \u7684 Oracle Database Gateways 11g \u7b2c 2 \u7248 (11.2.0.1.0)<\/p>\n<p>http:\/\/download.oracle.com\/otn\/nt\/oracle11g\/112010\/win64_11gR2_gateways.zip<\/p>\n<p><strong>\u4e8c\u3001Oracle\u900f\u660e\u7f51\u5173\u914d\u7f6e<\/strong><\/p>\n<p><strong>2.1. gateway\u5b89\u88c5<\/strong><\/p>\n<p>\u4e0b\u8f7d\u548c\u89e3\u538bwin64_11gR2_gateways.zip\u5230Oracle gateway\u670d\u52a1\u5668\u4e2d\uff08\u672c\u4f8b\u662f\u91d1\u548cOA\u7684C6\u670d\u52a1\u5668192.168.1.50\uff09\uff0c\u8fd0\u884csetup\u5b89\u88c5\u5373\u53ef<\/p>\n<p>\u3010<strong><span style=\"color: #ff0000;\">\u6ce8\u610f\uff1a\u672c\u4f8b\u6211\u4eec\u5c06\u900f\u660e\u7f51\u5173\u548cSQLServer\u6570\u636e\u5e93\u5b89\u5728\u4e86\u4e00\u53f0\u670d\u52a1\u5668\u4e0a\u3002<\/span><\/strong>\u3011<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"656\" height=\"520\" class=\"wp-image-1230\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-12.png\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"659\" height=\"523\" class=\"wp-image-1231\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-13.png\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"659\" height=\"524\" class=\"wp-image-1232\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-14.png\" \/><\/p>\n<p>\u4e0b\u4e00\u6b65\uff0c\u586b\u5199\u00a0<strong><span style=\"color: #ff0000;\">SQLServer\u6570\u636e\u5e93<\/span>\u00a0<\/strong>\u670d\u52a1\u5668\u4e3b\u673a\u540d\uff0c\u5982\uff1a192.168.1.50\uff1b\u6570\u636e\u5e93\u540d\u79f0\uff1aC6<\/p>\n<p>\u3010\u8bf4\u660e\u4e00\u4e0b\uff0c\u4e4b\u6240\u4ee5\u662fC6\uff0c\u662f\u56e0\u4e3a192.168.1.50\u4e2dsqlserver2008\u7684\u6570\u636e\u5e93\u547d\u540d\u4e3aC6\u3011<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"401\" height=\"342\" class=\"wp-image-1233\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-15.png\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"489\" height=\"385\" class=\"wp-image-1234\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-16.png\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"661\" height=\"522\" class=\"wp-image-1235\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-17.png\" \/><\/p>\n<p>\u5b89\u88c5\u5b8c\u540e\uff0c\u4f1a\u5f39\u51fa\u914d\u7f6e\u76d1\u542c\u754c\u9762\uff0c\u56e0\u4e3a\u6211\u4eec\u8981\u624b\u5de5\u914d\u7f6e\uff0c\u70b9\u51fb\u53d6\u6d88\u5373\u53ef\u3002<\/p>\n<p>\u5b89\u88c5\u5b8cGateway\u8f6f\u4ef6\u540e\uff0c\u5728ORACLE_HOME\u76ee\u5f55(D:\\product\\11.2.0\\tg_1)\u4e0b\u6709\u4e00\u4e0bdg4msql\u7684\u76ee\u5f55\uff0c\u8fd9\u5c31\u662fGateway\u8f6f\u4ef6\u7684\u76ee\u5f55\u4e86\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"277\" height=\"464\" class=\"wp-image-1236\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-18.png\" \/> <img loading=\"lazy\" decoding=\"async\" width=\"263\" height=\"177\" class=\"wp-image-1237\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-19.png\" \/><\/p>\n<p><strong>2.2. \u900f\u660e\u7f51\u5173\u5c42\u914d\u7f6e\u7684SID\u4fe1\u606f\uff0c\u6307\u660e\u8981\u8bbf\u95ee\u7684MSSQL\u6570\u636e\u5e93<\/strong><\/p>\n<p>\u5728<strong>D:\\Oracle\\product\\11.2.0\\tg_1\\dg4msql\\admin\\initdg4msql.ora<\/strong>\u76ee\u5f55\u4e0b\u6709\u4e00\u4e2ainitdg4msql.ora\u7684\u6587\u4ef6\u3002\u8be5\u6587\u4ef6\u662fGateway\u7684\u521d\u59cb\u53c2\u6570\u6587\u4ef6\uff0c\u63cf\u8ff0\u8fde\u63a5\u7684\u662f\u54ea\u4e2aSQL Server\u6570\u636e\u5e93\u3002\u8be5\u6587\u4ef6\u7684\u683c\u5f0f\u662finitSID.ora\uff0c\u8fd9\u91cc\u7684SID\u5728\u540e\u9762\u9700\u8981\u7528\u5230\uff0c\u7cfb\u7edf\u9ed8\u8ba4\u7684\u662fdg4msql\uff0c\u4e00\u822c\u60c5\u51b5\u8fd9\u6837\u5c31\u53ef\u4ee5\u4e86\u3002\u5982\u679c\u6539\u540d\uff0c\u5982\u4f7f\u7528C6\u4f5c\u4e3aSID\uff0c\u5219\u6587\u4ef6\u540d\u53d8\u6210\u00a0<span style=\"color: #ff0000;\"><strong>initC6.ora<\/strong><\/span>\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"645\" height=\"213\" class=\"wp-image-1238\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-20.png\" \/><\/p>\n<p><strong>initC6.ora<\/strong>\u6587\u4ef6\u5185\u5bb9\u5982\u4fee\u6539\u5982\u4e0b \u683c\u5f0f\uff1a\u3010HS_FDS_CONNECT_INFO=[IP]\/\u6570\u636e\u5b9e\u4f8b\u540d\/\u6570\u636e\u5e93\u540d\u3011<\/p>\n<p># This is a customized agent init file that contains the HS parameters<\/p>\n<p># that are needed for the Database Gateway for Microsoft SQL Server<\/p>\n<p>#<\/p>\n<p># HS init parameters<\/p>\n<p># HS_FDS_CONNECT_INFO=[192.168.1.50]\/\/C6 \u7531\u4e8e\u662f\u5b89\u88c5\u5728\u540c\u4e00\u670d\u52a1\u5668\u5185\uff0c\u6240\u4ee5IP\u53ef\u4ee5\u7528.\u6765\u66ff\u4ee3<\/p>\n<p># \u6ce8\u610f\uff1a\u6700\u597d\u522b\u7528localhost\uff0c\u6709\u7684\u6570\u636e\u5e93\u53ef\u80fd\u4e0d\u8bc6\u522blocalhost\uff0c\u53ea\u80fd\u7528.\u4ee3\u66ff\uff0c\u4e0d\u7136\u4f1a\u62a5\uff1aORA-28500\u9519\u8bef<\/p>\n<p>HS_FDS_CONNECT_INFO=[.]\/\/C6<\/p>\n<p>HS_FDS_TRACE_LEVEL=OFF<\/p>\n<p>HS_FDS_RECOVERY_ACCOUNT=RECOVER<\/p>\n<p>HS_FDS_RECOVERY_PWD=RECOVER<\/p>\n<p>\u518d\u6b21\u8bf4\u660e\uff1a\u53ea\u8981\u4fee\u6539HS_FDS_CONNECT_INFO\u53c2\u6570\u5c31\u53ef\u4ee5\u4e86\u3002\u683c\u5f0f\u662f\uff1a[hostname:port]\/serverinstance\/databasename\uff0c\u5176\u4e2dhostname\u662f\u673a\u5668\u540d\u79f0\u6216IP\uff0cPORT\u662fSQL Server\u7684\u7aef\u53e3\u53f7\uff0cSQL Server2005\u9ed8\u8ba4\u4e3a1433.serverinstance\u662fSQL Server\u7684\u5b9e\u4f8b\u540d\uff0c\u4e00\u822c\u7a7a\u7740\u5c31\u884c\u3002Databasename\u662fSQL Server\u7684\u6570\u636e\u5e93\u540d\u3002\u56e0\u4e3a\u6211\u4eec\u5728\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u6307\u5b9a\u4e86\u4e3b\u673a\u540d\u548c\u6570\u636e\u5e93\u540d\uff0c\u8fd9\u91cc\u5df2\u7ecf\u6709\u4fe1\u606f\u4e86\u3002<\/p>\n<p><strong>2.3.\u00a0\u900f\u660e\u7f51\u5173\u5c42\u914d\u7f6e\u76d1\u542c\u5668\uff0c\u5904\u7406oracle\u7684\u67e5\u8be2\u8bf7\u6c42<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"281\" height=\"167\" class=\"wp-image-1239\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-21.png\" \/> \u5728NETWORK\\admin\u76ee\u5f55\u91cc\u9762\uff1a<\/p>\n<p>\u900f\u660e\u7f51\u5173\u5c42\u7684\u76d1\u542c\u914d\u7f6e\u6587\u4ef6: D:\\Oracle\\product\\11.2.0\\tg_1\\NETWORK\\ADMIN\\listener.ora ,\u5982\u679c\u8be5\u76ee\u5f55\u4e0b\u6ca1\u6709\u6b64\u6587\u4ef6\uff0c<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"660\" height=\"209\" class=\"wp-image-1240\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-22.png\" \/><\/p>\n<p>\u6ce8\u610f\uff1a\u8fd9\u91ccPROGRAM\u6307\u5b9a\u5e94\u7528\u7a0b\u5e8f\u540d\u79f0\uff0c\u56e0\u4e3a\u5b9e\u4f8b\u914d\u7f6e\u6587\u4ef6\u5728D:\\Oracle\\product\\11.2.0\\tg_1\\<strong><span style=\"color: #ff0000;\">dg4msql<\/span><\/strong>\\admin\\initdg4msql.ora\uff0c\u6240\u4ee5PROGRAM\u4e0d\u80fd\u6539\u53d8, SID_NAME\u5c31\u662f\u524d\u9762init.ora\u6587\u4ef6\u540d\u91cc\u6307\u5b9a\u7684SID<\/p>\n<p># listener.ora Network Configuration File: D:\\product\\11.2.0\\tg_1\\network\\admin\\listener.ora<\/p>\n<p># Generated by Oracle configuration tools.<\/p>\n<p>&nbsp;<\/p>\n<p>SID_LIST_LISTENER =<\/p>\n<p>(SID_LIST =<\/p>\n<p>(SID_DESC =<\/p>\n<p>(GLOBAL_DBNAME = <strong><span style=\"color: #ff0000;\">C6<\/span><\/strong>)<\/p>\n<p>(PROGRAM = <strong><span style=\"color: #ff0000;\">dg4msql<\/span><\/strong>)<\/p>\n<p>(SID_NAME = <strong><span style=\"color: #ff0000;\">C6<\/span><\/strong>)<\/p>\n<p>(ORACLE_HOME = <span style=\"color: #ff0000;\">D:\\product\\11.2.0\\tg_1<\/span>)<\/p>\n<p>)<\/p>\n<p>)<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>LISTENER =<\/p>\n<p>(DESCRIPTION_LIST =<\/p>\n<p>(DESCRIPTION =<\/p>\n<p>(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.50)(PORT = 1522))<\/p>\n<p>(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))<\/p>\n<p>)<\/p>\n<p>)<\/p>\n<p>&nbsp;<\/p>\n<p>ADR_BASE_LISTENER = D:\\product\\11.2.0\\tg_1<\/p>\n<p><span style=\"color: #ff0000;\"><strong>\u6ce8\u610f\uff1aLISTENER \u6bb5\uff0c192.168.1.50)(PORT = 1522)) \uff0c\u672c\u6765\u662f1521\u7684\u7aef\u53e3\uff0c\u6539\u6210\u4e861522<\/strong><\/span><\/p>\n<p>\u542f\u52a8\u76d1\u542c<\/p>\n<p>\u5f00\u59cb\u83dc\u5355&gt;\u8fd0\u884c&gt;cmd,\u8f93\u5165<\/p>\n<p>C:\\Users\\Administrator&gt;<strong>lsnrctl start<\/strong><\/p>\n<p>&nbsp;<\/p>\n<p>LSNRCTL for 64-bit Windows: Version 11.2.0.1.0 &#8211; Production on 28-4\u6708 -2018 15:0<\/p>\n<p>8:31<\/p>\n<p>&nbsp;<\/p>\n<p>Copyright (c) 1991, 2010, Oracle. All rights reserved.<\/p>\n<p>&nbsp;<\/p>\n<p>\u542f\u52a8tnslsnr: \u8bf7\u7a0d\u5019&#8230;<\/p>\n<p>&nbsp;<\/p>\n<p>TNSLSNR for 64-bit Windows: Version 11.2.0.1.0 &#8211; Production<\/p>\n<p>\u7cfb\u7edf\u53c2\u6570\u6587\u4ef6\u4e3aD:\\product\\11.2.0\\tg_1\\network\\admin\\listener.ora<\/p>\n<p>\u5199\u5165d:\\product\\11.2.0\\tg_1\\diag\\tnslsnr\\WIN-158KFV5FSBR\\listener\\alert\\log.xml\u7684<\/p>\n<p>\u65e5\u5fd7\u4fe1\u606f<\/p>\n<p>\u76d1\u542c: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.1.50)(PORT=1522)))<\/p>\n<p>\u76d1\u542c: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\\\.\\pipe\\EXTPROC1521ipc)))<\/p>\n<p>&nbsp;<\/p>\n<p>\u6b63\u5728\u8fde\u63a5\u5230 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.1.50)(PORT=1522)))<\/p>\n<p>&nbsp;<\/p>\n<p>LISTENER \u7684 STATUS<\/p>\n<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<\/p>\n<p>\u522b\u540d LISTENER<\/p>\n<p>\u7248\u672c TNSLSNR for 64-bit Windows: Version 11.2.0.1.0 &#8211; Produ<\/p>\n<p>ction<\/p>\n<p>\u542f\u52a8\u65e5\u671f 28-4\u6708 -2018 15:08:47<\/p>\n<p>\u6b63\u5e38\u8fd0\u884c\u65f6\u95f4 0 \u5929 0 \u5c0f\u65f6 0 \u5206 3 \u79d2<\/p>\n<p>\u8ddf\u8e2a\u7ea7\u522b off<\/p>\n<p>\u5b89\u5168\u6027 ON: Local OS Authentication<\/p>\n<p>SNMP OFF<\/p>\n<p>\u76d1\u542c\u7a0b\u5e8f\u53c2\u6570\u6587\u4ef6 D:\\product\\11.2.0\\tg_1\\network\\admin\\listener.ora<\/p>\n<p>\u76d1\u542c\u7a0b\u5e8f\u65e5\u5fd7\u6587\u4ef6 d:\\product\\11.2.0\\tg_1\\diag\\tnslsnr\\WIN-158KFV5FSBR\\li<\/p>\n<p>stener\\alert\\log.xml<\/p>\n<p>\u76d1\u542c\u7aef\u70b9\u6982\u8981&#8230;<\/p>\n<p>(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.1.50)(PORT=1522)))<\/p>\n<p>(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\\\.\\pipe\\EXTPROC1521ipc)))<\/p>\n<p>\u670d\u52a1\u6458\u8981..<\/p>\n<p>\u670d\u52a1 &#8220;C6&#8221; \u5305\u542b 1 \u4e2a\u5b9e\u4f8b\u3002<\/p>\n<p>\u5b9e\u4f8b &#8220;C6&#8221;, \u72b6\u6001 UNKNOWN, \u5305\u542b\u6b64\u670d\u52a1\u7684 1 \u4e2a\u5904\u7406\u7a0b\u5e8f&#8230;<\/p>\n<p>\u547d\u4ee4\u6267\u884c\u6210\u529f<\/p>\n<p>&nbsp;<\/p>\n<p>C:\\Users\\Administrator&gt;<\/p>\n<p>\u4e5f\u53ef\u4ee5\u53bbwindows\u7684\u670d\u52a1\u4e2d\u67e5\u770bOracleOraGtw11g_home1TNSListener\u662f\u5426\u5df2\u7ecf\u542f\u52a8<\/p>\n<p>====\u300b\u53e6\u4e00\u79cd\u542f\u52a8\u6216\u8005\u91cd\u542f\u65b9\u6cd5\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"316\" height=\"195\" class=\"wp-image-1241\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-23.png\" \/><\/p>\n<p>\u70b9\u51fb LSNRCTL.exe\u6587\u4ef6\uff0c\u8fdb\u5165\u4e0b\u9762\u754c\u9762\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"636\" height=\"672\" class=\"wp-image-1242\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-24.png\" \/><\/p>\n<p><strong>2.4 Oracle\u670d\u52a1\u5668\u914d\u7f6etns<\/strong><\/p>\n<p><strong>\u5728\u9700\u8981\u5efa\u7acbdblink\u7684Oracle\u6570\u636e\u5e93\u6240\u5728\u670d\u52a1\u5668\uff0c<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"917\" height=\"98\" class=\"wp-image-1243\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-25.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-25.png 917w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-25-768x82.png 768w\" sizes=\"auto, (max-width: 917px) 100vw, 917px\" \/><\/p>\n<p><strong>\u914d\u7f6e<\/strong>\/u2\/oracle\/app\/product\/11.2.0\/dbhome_1\/network\/admin\/<strong>tnsnames.ora \uff0c\u63a8\u8350\u5148\u5907\u4efd\u4e00\u4e0b\u6b64\u6587\u4ef6\u3002<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"874\" height=\"282\" class=\"wp-image-1244\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-26.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-26.png 874w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-26-768x248.png 768w\" sizes=\"auto, (max-width: 874px) 100vw, 874px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"781\" height=\"409\" class=\"wp-image-1245\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-27.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-27.png 781w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-27-768x402.png 768w\" sizes=\"auto, (max-width: 781px) 100vw, 781px\" \/><\/p>\n<p>\u4ee5\u4e0b\u662f\u53ef\u590d\u5236\u5185\u5bb9<\/p>\n<p>C6 =<\/p>\n<p>(DESCRIPTION =<\/p>\n<p>(ADDRESS = (PROTOCOL = TCP)(HOST =192.168.1.50)(PORT = 1522))<\/p>\n<p>(CONNECT_DATA=(SID=C6))<\/p>\n<p>(HS=OK)<\/p>\n<p>)<\/p>\n<p>\u6d4b\u8bd5tns\u662f\u5426\u6210\u529f\u3002<\/p>\n<p>[oracle@elearningtest admin]$ tnsping C6<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"934\" height=\"184\" class=\"wp-image-1246\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-28.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-28.png 934w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-28-768x151.png 768w\" sizes=\"auto, (max-width: 934px) 100vw, 934px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p>TNS Ping Utility for Linux: Version 11.2.0.4.0 &#8211; Production on 20-JUL-2016 15:14:22<\/p>\n<p>&nbsp;<\/p>\n<p>Copyright (c) 1997, 2011, Oracle. All rights reserved.<\/p>\n<p>&nbsp;<\/p>\n<p>Used parameter files:<\/p>\n<p>\/u01\/oracle\/app\/product\/11.2.0\/dbhome_1\/network\/admin\/sqlnet.ora<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Used TNSNAMES adapter to resolve the alias<\/p>\n<p>Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST =192.168.1.50)(PORT = 1522)) (CONNECT_DATA=(SID=HR)) (HS=OK))<\/p>\n<p>OK (10 msec)<\/p>\n<p>\u5efa\u7acbDB link<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"937\" height=\"221\" class=\"wp-image-1247\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-29.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-29.png 937w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-29-768x181.png 768w\" sizes=\"auto, (max-width: 937px) 100vw, 937px\" \/><\/p>\n<p>\u4e0b\u9762\u662f\u53ef\u590d\u5236\u5185\u5bb9\uff1a<\/p>\n<p><strong>2.5.\u5efa\u7acbDB link<\/strong><\/p>\n<p>create public database link JHOADB connect to sa identified by &#8220;sa\u5bc6\u7801&#8221; using &#8216;C6&#8217;;<\/p>\n<p><strong>2.6 \u6d4b\u8bd5<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"249\" height=\"114\" class=\"wp-image-1248\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-30.png\" \/><\/p>\n<p>SQL&gt; select <strong>1<\/strong> from dual@JHOADB;<\/p>\n<p><strong>1<\/strong><\/p>\n<p>&#8212;&#8212;&#8212;-<\/p>\n<p><strong>1<\/strong><\/p>\n<p>select * from USERS@JHOADB<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"963\" height=\"129\" class=\"wp-image-1249\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-31.png\" srcset=\"https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-31.png 963w, https:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-31-768x103.png 768w\" sizes=\"auto, (max-width: 963px) 100vw, 963px\" \/><\/p>\n<p><strong>\u6ce8\u610f\u4e8b\u9879\uff1aoracle\u67e5\u8be2sqlserver\u7684\u65f6\u5019\uff0c\u5b57\u6bb5\u8981\u533a\u5206\u5927\u5c0f\u5199\uff0c\u5e76\u4e14\u8981\u7528&#8221;&#8221;\u62ec\u8d77\u6765\u3002\u5426\u5219\u4f1a\u63d0\u793a<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"460\" height=\"206\" class=\"wp-image-1250\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-32.png\" \/><\/p>\n<p><strong>\u6b63\u786e\u8bed\u53e5\uff1a<\/strong><\/p>\n<p>select * from USERS@JHOADB WHERE &#8220;UserID&#8221;=&#8217;00300&#8242;;<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"689\" height=\"177\" class=\"wp-image-1251\" src=\"http:\/\/www.hefeiyu.com\/wp-content\/uploads\/2019\/06\/word-image-33.png\" \/><\/p>\n<p><strong>\u4e09\u3001\u9047\u5230\u7684\u9519\u8bef<\/strong><\/p>\n<p><strong>\u9519\u8bef1:initdg4msql.ora\u9519\u8bef<\/strong><\/p>\n<p>[SQL]Select 1 from USERS@JHOADB<\/p>\n<p>[Err] ORA-28545: \u8fde\u63a5\u4ee3\u7406\u65f6 Net8 \u8bca\u65ad\u5230\u9519\u8bef<\/p>\n<p>Unable to retrieve text of NETWORK\/NCR message 65535<\/p>\n<p>ORA-02063: \u7d27\u63a5\u7740 2 lines (\u8d77\u81ea HRDBLINK)<\/p>\n<p>\u539f\u56e0:<\/p>\n<p><strong>$OracleHOME\\dg4msql\\admin\\initdg4msql.ora\u7684HS_FDS_CONNECT_INFO\u503c\u914d\u7f6e\u9519\u8bef<\/strong><\/p>\n<p><strong>\u9519\u8bef2.\u900f\u660e\u7f51\u5173\u7684\u76d1\u542c\u5361\u4f4f\uff0c\u65e0\u6cd5\u91cd\u542f<\/strong><\/p>\n<p>\u76f8\u5173\u8fdb\u7a0b\u6ca1\u6709\u5f7b\u5e95\u5173\u95ed\uff0c\u6740\u6389\u76f8\u5173\u8fdb\u7a0b \u5982dg4msql.exe<\/p>\n<p>\u8f6c\u8f7d\u8bf7\u6ce8\u660e\uff1a<a href=\"https:\/\/www.hefeiyu.com\">\u8d6b\u975e\u57df<\/a> &raquo; <a href=\"https:\/\/www.hefeiyu.com\/?p=1228\">Oracle 11g\u900f\u660e\u7f51\u5173\u8fde\u63a5Sqlserver<\/a><\/p>","protected":false},"excerpt":{"rendered":"<p>oracle \u900f\u660e\u7f51\u5173\u662foracle\u8fde\u63a5\u5f02\u6784\u6570\u636e\u5e93\u63d0\u4f9b\u7684\u4e00\u79cd\u6280\u672f\u3002\u901a\u8fc7Gateway\uff0c\u53ef\u4ee5\u5728Oracle\u91cc\u900f\u660e\u7684\u8bbf\u95ee\u5176\u4ed6\u4e0d\u540c\u7684\u6570\u636e\u5e93\uff0c\u5982SQL Server, DB2, Sybase\u7b49\u7b49\uff0c\u5c31\u50cf\u8fdc\u7a0bOracle\u6570\u636e\u5e93\u4e00\u6837\u3002\u914d\u7f6e\u540e\u7684sql\u67e5\u8be2\u7684\u5904\u7406\u6d41\u7a0b  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[28],"tags":[51,54,440],"class_list":["post-1228","post","type-post","status-publish","format-standard","hentry","category-unix","tag-oracle","tag-54","tag-440"],"_links":{"self":[{"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=\/wp\/v2\/posts\/1228","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1228"}],"version-history":[{"count":3,"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=\/wp\/v2\/posts\/1228\/revisions"}],"predecessor-version":[{"id":1254,"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=\/wp\/v2\/posts\/1228\/revisions\/1254"}],"wp:attachment":[{"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1228"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1228"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hefeiyu.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1228"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}