{"id":95214,"date":"2024-10-19T23:11:17","date_gmt":"2024-10-19T15:11:17","guid":{"rendered":"https:\/\/server.hk\/cnblog\/95214\/"},"modified":"2024-10-19T23:11:17","modified_gmt":"2024-10-19T15:11:17","slug":"oracle%e7%b0%a1%e5%96%ae%e9%ab%98%e6%95%88%ef%bc%9a%e4%bd%bf%e7%94%a8exp%e5%bf%ab%e9%80%9f%e5%b0%8e%e5%87%ba%e6%95%b8%e6%93%9a%e5%ba%ab-oracle%e5%b0%8e%e5%87%ba%e6%95%b8%e6%93%9a%e5%ba%abexp","status":"publish","type":"post","link":"https:\/\/server.hk\/cnblog\/95214\/","title":{"rendered":"Oracle\u7c21\u55ae\u9ad8\u6548\uff1a\u4f7f\u7528exp\u5feb\u901f\u5c0e\u51fa\u6578\u64da\u5eab (oracle\u5c0e\u51fa\u6578\u64da\u5eabexp)"},"content":{"rendered":"<h1 id=\"oracle%e7%b0%a1%e5%96%ae%e9%ab%98%e6%95%88%ef%bc%9a%e4%bd%bf%e7%94%a8exp%e5%bf%ab%e9%80%9f%e5%b0%8e%e5%87%ba%e6%95%b8%e6%93%9a%e5%ba%ab-nxKHaXRkSc\">Oracle\u7c21\u55ae\u9ad8\u6548\uff1a\u4f7f\u7528exp\u5feb\u901f\u5c0e\u51fa\u6578\u64da\u5eab<\/h1>\n<p>\u5728\u6578\u64da\u5eab\u7ba1\u7406\u4e2d\uff0c\u6578\u64da\u7684\u5c0e\u51fa\u662f\u4e00\u500b\u91cd\u8981\u7684\u64cd\u4f5c\uff0c\u5c24\u5176\u662f\u5728\u9700\u8981\u5099\u4efd\u6216\u9077\u79fb\u6578\u64da\u6642\u3002Oracle\u6578\u64da\u5eab\u63d0\u4f9b\u4e86\u591a\u7a2e\u5de5\u5177\u4f86\u5be6\u73fe\u6578\u64da\u7684\u5c0e\u51fa\uff0c\u5176\u4e2d\u6700\u5e38\u7528\u7684\u5de5\u5177\u4e4b\u4e00\u5c31\u662fexp\uff08Export Utility\uff09\u3002\u672c\u6587\u5c07\u4ecb\u7d39\u5982\u4f55\u4f7f\u7528exp\u5de5\u5177\u5feb\u901f\u5c0e\u51faOracle\u6578\u64da\u5eab\uff0c\u4e26\u63d0\u4f9b\u4e00\u4e9b\u5be6\u7528\u7684\u793a\u4f8b\u548c\u6280\u5de7\u3002<\/p>\n<h2 id=\"%e4%bb%80%e9%ba%bc%e6%98%afexp%e5%b7%a5%e5%85%b7%ef%bc%9f-nxKHaXRkSc\">\u4ec0\u9ebc\u662fexp\u5de5\u5177\uff1f<\/h2>\n<p>exp\u5de5\u5177\u662fOracle\u63d0\u4f9b\u7684\u4e00\u500b\u547d\u4ee4\u884c\u5de5\u5177\uff0c\u7528\u65bc\u5c0e\u51fa\u6578\u64da\u5eab\u4e2d\u7684\u6578\u64da\u3002\u5b83\u53ef\u4ee5\u5c07\u6578\u64da\u5c0e\u51fa\u70ba\u4e8c\u9032\u5236\u683c\u5f0f\uff0c\u4e26\u751f\u6210.dmp\u6587\u4ef6\uff0c\u9019\u4e9b\u6587\u4ef6\u53ef\u4ee5\u5728\u9700\u8981\u6642\u901a\u904eimp\uff08Import Utility\uff09\u5de5\u5177\u9032\u884c\u5c0e\u5165\u3002exp\u5de5\u5177\u7684\u512a\u52e2\u5728\u65bc\u5176\u7c21\u55ae\u9ad8\u6548\uff0c\u9069\u5408\u7528\u65bc\u5feb\u901f\u5099\u4efd\u548c\u6578\u64da\u9077\u79fb\u3002<\/p>\n<h2 id=\"%e4%bd%bf%e7%94%a8exp%e5%b0%8e%e5%87%ba%e6%95%b8%e6%93%9a%e5%ba%ab%e7%9a%84%e5%9f%ba%e6%9c%ac%e6%ad%a5%e9%a9%9f-nxKHaXRkSc\">\u4f7f\u7528exp\u5c0e\u51fa\u6578\u64da\u5eab\u7684\u57fa\u672c\u6b65\u9a5f<\/h2>\n<p>\u4f7f\u7528exp\u5de5\u5177\u5c0e\u51fa\u6578\u64da\u5eab\u7684\u57fa\u672c\u6b65\u9a5f\u5982\u4e0b\uff1a<\/p>\n<ol>\n<li><strong>\u6e96\u5099\u74b0\u5883\uff1a<\/strong>\u78ba\u4fddOracle\u6578\u64da\u5eab\u5df2\u5b89\u88dd\u4e26\u904b\u884c\uff0c\u4e26\u4e14\u7528\u6236\u5177\u6709\u8db3\u5920\u7684\u6b0a\u9650\u4f86\u57f7\u884c\u5c0e\u51fa\u64cd\u4f5c\u3002<\/li>\n<li><strong>\u6253\u958b\u547d\u4ee4\u884c\u754c\u9762\uff1a<\/strong>\u5728Windows\u7cfb\u7d71\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528cmd\u547d\u4ee4\u63d0\u793a\u7b26\uff1b\u5728Linux\u7cfb\u7d71\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528\u7d42\u7aef\u3002<\/li>\n<li><strong>\u57f7\u884cexp\u547d\u4ee4\uff1a<\/strong>\u4f7f\u7528\u4ee5\u4e0b\u57fa\u672c\u8a9e\u6cd5\u4f86\u57f7\u884c\u5c0e\u51fa\u64cd\u4f5c\uff1a<\/li>\n<\/ol>\n<pre><code>exp username\/password@database_name file=export.dmp log=export.log<\/code><\/pre>\n<p>\u5728\u9019\u88e1\uff0c<code>username<\/code>\u548c<code>password<\/code>\u662f\u7528\u6236\u540d\u548c\u5bc6\u78bc\uff0c<code>database_name<\/code>\u662f\u6578\u64da\u5eab\u7684\u540d\u7a31\uff0c<code>file<\/code>\u53c3\u6578\u6307\u5b9a\u4e86\u5c0e\u51fa\u6587\u4ef6\u7684\u540d\u7a31\uff0c<code>log<\/code>\u53c3\u6578\u6307\u5b9a\u4e86\u65e5\u8a8c\u6587\u4ef6\u7684\u540d\u7a31\u3002<\/p>\n<h2 id=\"%e5%b0%8e%e5%87%ba%e7%89%b9%e5%ae%9a%e8%a1%a8%e6%88%96%e7%94%a8%e6%88%b6-nxKHaXRkSc\">\u5c0e\u51fa\u7279\u5b9a\u8868\u6216\u7528\u6236<\/h2>\n<p>\u5982\u679c\u53ea\u9700\u8981\u5c0e\u51fa\u7279\u5b9a\u7684\u8868\u6216\u7528\u6236\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n<pre><code>exp username\/password@database_name tables=(table1, table2) file=export.dmp log=export.log<\/code><\/pre>\n<p>\u5728\u9019\u88e1\uff0c<code>tables<\/code>\u53c3\u6578\u6307\u5b9a\u4e86\u8981\u5c0e\u51fa\u7684\u8868\u540d\uff0c\u4f7f\u7528\u9017\u865f\u5206\u9694\u3002<\/p>\n<h2 id=\"%e5%b0%8e%e5%87%ba%e6%95%b4%e5%80%8b%e6%95%b8%e6%93%9a%e5%ba%ab-nxKHaXRkSc\">\u5c0e\u51fa\u6574\u500b\u6578\u64da\u5eab<\/h2>\n<p>\u8981\u5c0e\u51fa\u6574\u500b\u6578\u64da\u5eab\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n<pre><code>exp username\/password@database_name full=y file=export.dmp log=export.log<\/code><\/pre>\n<p>\u5728\u9019\u88e1\uff0c<code>full=y<\/code>\u8868\u793a\u5c0e\u51fa\u6574\u500b\u6578\u64da\u5eab\u3002<\/p>\n<h2 id=\"%e5%b0%8e%e5%87%ba%e9%81%b8%e9%a0%85-nxKHaXRkSc\">\u5c0e\u51fa\u9078\u9805<\/h2>\n<p>exp\u5de5\u5177\u9084\u63d0\u4f9b\u4e86\u591a\u7a2e\u9078\u9805\u4f86\u81ea\u5b9a\u7fa9\u5c0e\u51fa\u904e\u7a0b\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u7528\u7684\u9078\u9805\uff1a<\/p>\n<ul>\n<li><strong>compress\uff1a<\/strong>\u6307\u5b9a\u662f\u5426\u58d3\u7e2e\u5c0e\u51fa\u7684\u6578\u64da\u3002<\/li>\n<li><strong>owner\uff1a<\/strong>\u6307\u5b9a\u8981\u5c0e\u51fa\u7684\u7528\u6236\u3002<\/li>\n<li><strong>rows\uff1a<\/strong>\u6307\u5b9a\u662f\u5426\u5c0e\u51fa\u6578\u64da\u884c\u3002<\/li>\n<\/ul>\n<p>\u4f8b\u5982\uff0c\u82e5\u8981\u5c0e\u51fa\u7279\u5b9a\u7528\u6236\u7684\u6578\u64da\u4e26\u58d3\u7e2e\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n<pre><code>exp username\/password@database_name owner=user_name compress=y file=export.dmp log=export.log<\/code><\/pre>\n<h2 id=\"%e6%b3%a8%e6%84%8f%e4%ba%8b%e9%a0%85-nxKHaXRkSc\">\u6ce8\u610f\u4e8b\u9805<\/h2>\n<p>\u5728\u4f7f\u7528exp\u5de5\u5177\u6642\uff0c\u6709\u5e7e\u9ede\u9700\u8981\u6ce8\u610f\uff1a<\/p>\n<ul>\n<li>\u78ba\u4fdd\u6709\u8db3\u5920\u7684\u78c1\u789f\u7a7a\u9593\u4f86\u5b58\u5132\u5c0e\u51fa\u7684.dmp\u6587\u4ef6\u3002<\/li>\n<li>\u5b9a\u671f\u6aa2\u67e5\u5c0e\u51fa\u65e5\u8a8c\u6587\u4ef6\uff0c\u4ee5\u78ba\u4fdd\u5c0e\u51fa\u904e\u7a0b\u6c92\u6709\u932f\u8aa4\u3002<\/li>\n<li>\u5728\u5c0e\u51fa\u5927\u578b\u6578\u64da\u5eab\u6642\uff0c\u53ef\u80fd\u9700\u8981\u8003\u616e\u5c0e\u51fa\u6642\u9593\u548c\u7cfb\u7d71\u6027\u80fd\u5f71\u97ff\u3002<\/li>\n<\/ul>\n<h2 id=\"%e7%b8%bd%e7%b5%90-nxKHaXRkSc\">\u7e3d\u7d50<\/h2>\n<p>\u4f7f\u7528exp\u5de5\u5177\u5c0e\u51faOracle\u6578\u64da\u5eab\u662f\u4e00\u500b\u7c21\u55ae\u800c\u9ad8\u6548\u7684\u904e\u7a0b\uff0c\u9069\u5408\u7528\u65bc\u6578\u64da\u5099\u4efd\u548c\u9077\u79fb\u3002\u901a\u904e\u638c\u63e1\u57fa\u672c\u7684\u547d\u4ee4\u548c\u9078\u9805\uff0c\u60a8\u53ef\u4ee5\u9748\u6d3b\u5730\u5c0e\u51fa\u6240\u9700\u7684\u6578\u64da\u3002\u82e5\u60a8\u9700\u8981\u7a69\u5b9a\u7684\u74b0\u5883\u4f86\u904b\u884cOracle\u6578\u64da\u5eab\uff0c\u8003\u616e\u4f7f\u7528<a href=\"https:\/\/server.hk\">\u9999\u6e2fVPS<\/a>\u670d\u52d9\uff0c\u4ee5\u78ba\u4fdd\u60a8\u7684\u6578\u64da\u5b89\u5168\u548c\u9ad8\u6548\u904b\u884c\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5b78\u7fd2\u5982\u4f55\u4f7f\u7528Oracle\u7684exp\u5de5\u5177\u5feb\u901f\u9ad8\u6548\u5730\u5c0e\u51fa\u6578\u64da\u5eab\uff0c\u7c21\u5316\u6578\u64da\u7ba1\u7406\u6d41\u7a0b\uff0c\u63d0\u5347\u5de5\u4f5c\u6548\u7387\u3002<\/p>\n","protected":false},"author":0,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[101],"tags":[],"class_list":["post-95214","post","type-post","status-publish","format-standard","hentry","category-database"],"_links":{"self":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/95214","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/comments?post=95214"}],"version-history":[{"count":1,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/95214\/revisions"}],"predecessor-version":[{"id":95215,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/95214\/revisions\/95215"}],"wp:attachment":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/media?parent=95214"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/categories?post=95214"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/tags?post=95214"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}