{"id":700,"date":"2012-03-29T23:48:37","date_gmt":"2012-03-29T15:48:37","guid":{"rendered":"https:\/\/yangtingkun.net\/?p=700"},"modified":"2012-04-01T16:53:16","modified_gmt":"2012-04-01T08:53:16","slug":"linux%e4%b8%8aoracle%e5%90%af%e7%94%a8%e5%bc%82%e6%ad%a5io","status":"publish","type":"post","link":"https:\/\/yangtingkun.net\/?p=700","title":{"rendered":"Linux\u4e0aOracle\u542f\u7528\u5f02\u6b65IO"},"content":{"rendered":"<p>\u521a\u89e3\u51b3\u4e86\u4e00\u4e2a\u5f02\u6b65io\u7684\u95ee\u9898\uff0c\u8fd8\u662f\u4e13\u95e8\u63cf\u8ff0\u4e00\u4e0bOracle\u4e2d\u8bbe\u7f6e\u5f02\u6b65IO\u7684\u65b9\u5f0f\u3002<br \/>\n\u9996\u5148\u8981\u68c0\u67e5\u64cd\u4f5c\u7cfb\u7edf\u4e0a\uff0c\u5f02\u6b65io\u7684\u76f8\u5173\u5305\u662f\u5426\u5df2\u7ecf\u5b89\u88c5\uff0c\u5982\u679c\u6ca1\u6709\u7684\u8bdd\uff0c\u901a\u8fc7rpm\u8fdb\u884c\u5b89\u88c5\uff0c\u5e76\u68c0\u67e5\u7cfb\u7edf\u4e0a\u5f02\u6b65io\u7684\u53c2\u6570\u8bbe\u7f6e\uff1a<\/p>\n<pre lang='SQL'>[oracle@localhost ~]$ rpm -qa|grep aio\r\nlibaio-0.3.107-10.el6.x86_64\r\nlibaio-devel-0.3.107-10.el6.x86_64\r\n[oracle@localhost ~]$ more \/proc\/sys\/fs\/aio-max-nr \r\n1048576<\/pre>\n<p>\u7136\u540e\u68c0\u67e5\u6570\u636e\u5e93\u5728\u94fe\u63a5\u65f6\u662f\u5426\u5df2\u7ecf\u52a0\u8f7d\u4e86aio\u7684\u5305\uff1a<\/p>\n<pre lang='SQL'>[oracle@localhost ~]$ \/usr\/bin\/ldd $ORACLE_HOME\/bin\/oracle | grep libaio\r\nlibaio.so.1 => \/lib64\/libaio.so.1 (0x0000003e13000000)<\/pre>\n<p>\u5982\u679c\u6ca1\u6709\u770b\u5230libaio\u7684\u5305\uff0c\u8bf4\u660eOracle\u6ca1\u6709\u94fe\u63a5aio\uff0c\u90a3\u4e48\u8fd9\u65f6\u5c31\u9700\u8981\u91cd\u65b0make oracle\u7684\u53ef\u6267\u884c\u6587\u4ef6\uff0c9i\u7684\u65b9\u6cd5\u4e3a\uff1a<\/p>\n<pre lang='SQL'>make -f ins_rdbms.mk async_on\r\nmake -f ins_rdbms.mk ioracle<\/pre>\n<p>10g\u4ee5\u540e\u7684\u65b9\u6cd5\u4e3a\uff1a<\/p>\n<pre lang='SQL'>make PL_ORALIBS=-laio -f ins_rdbms.mk async_on<\/pre>\n<p>\u7f16\u8bd1\u5b8c\u6210\u540e\uff0c\u64cd\u4f5c\u7cfb\u7edf\u7684\u8bbe\u7f6e\u5b8c\u6210\uff0c\u8fd8\u9700\u8981\u8bbe\u7f6e\u6570\u636e\u5e93\u7684\u521d\u59cb\u5316\u53c2\u6570\uff1a<\/p>\n<pre lang='SQL'>SQL> show parameter disk_asynch_io\r\nNAME                                 TYPE                             VALUE\r\n------------------------------------ -------------------------------- --------------------\r\ndisk_asynch_io                       boolean                          TRUE\r\nSQL> show parameter filesystemio_options\r\nNAME                                 TYPE                             VALUE\r\n------------------------------------ -------------------------------- ------------------\r\nfilesystemio_options                 string                           none<\/pre>\n<p>\u5bf9\u4e8e\u88f8\u8bbe\u5907\u800c\u8a00\uff0c\u8fd9\u6837\u7684\u8bbe\u7f6e\u5c31\u8db3\u591f\u4e86\uff0c\u4f46\u662f\u5bf9\u4e8e\u6587\u4ef6\u7cfb\u7edf\u800c\u8a00\uff0c\u8fd8\u9700\u8981\u8bb2filesystemio_options\u8bbe\u7f6e\u4e3aASYNCH\u5e76\u91cd\u542f\u6570\u636e\u5e93\uff1a<\/p>\n<pre lang='SQL'>SQL> ALTER SYSTEM SET FILESYSTEMIO_OPTIONS = ASYNCH SCOPE = SPFILE;\r\nSystem altered.<\/pre>\n<p>\u7531\u4e8e\u7f16\u8bd1oracle\u53ef\u6267\u884c\u6587\u4ef6\u7684\u65f6\u5019\u4e5f\u8981\u5173\u95ed\u6570\u636e\u5e93\uff0c\u5408\u7406\u7684\u5b89\u6392\u8bbe\u7f6e\u53c2\u6570\u7684\u987a\u5e8f\uff0c\u53ef\u51cf\u5c11\u6570\u636e\u5e93\u7684\u91cd\u542f\u6b21\u6570\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u521a\u89e3\u51b3\u4e86\u4e00\u4e2a\u5f02\u6b65io\u7684\u95ee\u9898\uff0c\u8fd8\u662f\u4e13\u95e8\u63cf\u8ff0\u4e00\u4e0bOracle\u4e2d\u8bbe\u7f6e\u5f02\u6b65IO\u7684\u65b9\u5f0f\u3002 \u9996\u5148\u8981\u68c0\u67e5\u64cd\u4f5c\u7cfb\u7edf\u4e0a\uff0c\u5f02\u6b65io\u7684\u76f8\u5173\u5305\u662f\u5426\u5df2\u7ecf\u5b89\u88c5\uff0c\u5982\u679c\u6ca1\u6709\u7684\u8bdd\uff0c\u901a\u8fc7rpm\u8fdb\u884c\u5b89\u88c5\uff0c\u5e76\u68c0\u67e5\u7cfb\u7edf\u4e0a\u5f02\u6b65io\u7684\u53c2\u6570\u8bbe\u7f6e\uff1a [oracle@localhost ~]$ rpm -qa|grep aio libaio-0.3.107-10.el6.x86_64 libaio-devel-0.3.107-10.el6.x86_64 [oracle@localhost ~]$ more \/proc\/sys\/fs\/aio-max-nr 1048576 \u7136\u540e\u68c0\u67e5\u6570\u636e\u5e93\u5728\u94fe\u63a5\u65f6\u662f\u5426\u5df2\u7ecf\u52a0\u8f7d\u4e86aio\u7684\u5305\uff1a [oracle@localhost ~]$ \/usr\/bin\/ldd $ORACLE_HOME\/bin\/oracle | grep libaio libaio.so.1 => \/lib64\/libaio.so.1 (0x0000003e13000000) \u5982\u679c\u6ca1\u6709\u770b\u5230libaio\u7684\u5305\uff0c\u8bf4\u660eOracle\u6ca1\u6709\u94fe\u63a5aio\uff0c\u90a3\u4e48\u8fd9\u65f6\u5c31\u9700\u8981\u91cd\u65b0make oracle\u7684\u53ef\u6267\u884c\u6587\u4ef6\uff0c9i\u7684\u65b9\u6cd5\u4e3a\uff1a make -f ins_rdbms.mk async_on make -f ins_rdbms.mk ioracle 10g\u4ee5\u540e\u7684\u65b9\u6cd5\u4e3a\uff1a make PL_ORALIBS=-laio -f &hellip; <a href=\"https:\/\/yangtingkun.net\/?p=700\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[3],"tags":[580,585,584,586,578,579,587,581],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p2yiY3-bi","_links":{"self":[{"href":"https:\/\/yangtingkun.net\/index.php?rest_route=\/wp\/v2\/posts\/700"}],"collection":[{"href":"https:\/\/yangtingkun.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/yangtingkun.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/yangtingkun.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/yangtingkun.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=700"}],"version-history":[{"count":1,"href":"https:\/\/yangtingkun.net\/index.php?rest_route=\/wp\/v2\/posts\/700\/revisions"}],"predecessor-version":[{"id":701,"href":"https:\/\/yangtingkun.net\/index.php?rest_route=\/wp\/v2\/posts\/700\/revisions\/701"}],"wp:attachment":[{"href":"https:\/\/yangtingkun.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=700"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/yangtingkun.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=700"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/yangtingkun.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=700"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}