{"id":17978,"date":"2025-04-20T15:03:33","date_gmt":"2025-04-20T07:03:33","guid":{"rendered":"https:\/\/www.orczhou.com\/?p=17978"},"modified":"2025-04-20T15:05:33","modified_gmt":"2025-04-20T07:05:33","slug":"using-docker-install-oracle-database","status":"publish","type":"post","link":"https:\/\/www.orczhou.com\/index.php\/2025\/04\/using-docker-install-oracle-database\/","title":{"rendered":"\u4f7f\u7528 Docker  \u5de5\u5177\u5b89\u88c5\u4e0d\u540c\u7248\u672c\u7684Oracle\u6570\u636e\u5e93"},"content":{"rendered":"<div id=\"tocer-1\" class=\"tocer tocer-pos-flt-e\"><div class=\"tocer-toc\"><header class=\"tocer-header\"><h2 class=\"tocer-title\">\u76ee\u5f55<\/h2>\n<\/header>\n<ul class=\"tocer-list tocer-adv tocer-sp-os-bf tocer-st-ctrs-dec tocer-lvl1\"><li class=\"tocer-has-sub\"><div><a href=\"#tocer-heading-1\">Oracle \u5b98\u65b9\u63d0\u4f9b\u4e86\u54ea\u4e9b\u955c\u50cf<\/a><\/div>\n<ul class=\"tocer-sublist tocer-lvl2\"><li><div><a href=\"#tocer-heading-2\">Oracle \u955c\u50cf\u5b98\u65b9\u9875\u9762<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-3\">\u627e\u5230\u8f6f\u4ef6\u5bf9\u5e94\u7684\u5b50\u4ed3\u5e93<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-4\">\u9009\u62e9\u7248\u672c\u4e0e\u955c\u50cf\u7ad9\u70b9<\/a><\/div><\/li>\n<\/ul>\n<\/li>\n<li class=\"tocer-has-sub\"><div><a href=\"#tocer-heading-5\">\u5b89\u88c5 Oracle \u6570\u636e\u5e93<\/a><\/div>\n<ul class=\"tocer-sublist tocer-lvl2\"><li><div><a href=\"#tocer-heading-6\">\u62c9\u53d6\u955c\u50cf<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-7\">\u521b\u5efa Oracle \u6570\u636e\u5e93\u7684\u5bb9\u5668<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-8\">\u542f\u52a8\u5bb9\u5668<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-9\">\u89c2\u5bdf\u542f\u52a8\u72b6\u6001<\/a><\/div><\/li>\n<\/ul>\n<\/li>\n<li><div><a href=\"#tocer-heading-10\">\u767b\u5f55\u5bb9\u5668\u4e2d\u7684 Oracle \u6570\u636e\u5e93<\/a><\/div><\/li>\n<li class=\"tocer-has-sub\"><div><a href=\"#tocer-heading-11\">\u6388\u6743\u534f\u8bae\u4e0e\u8ba4\u8bc1<\/a><\/div>\n<ul class=\"tocer-sublist tocer-lvl2\"><li><div><a href=\"#tocer-heading-12\">requested access to the resource is denied<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-13\">\u767b\u5f55Oracle\u4ed3\u5e93\u7ad9\u70b9\u5e76\u540c\u610f\u534f\u8bae<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-14\">docker login<\/a><\/div><\/li>\n<\/ul>\n<\/li>\n<li><div><a href=\"#tocer-heading-15\">Enterprise Edition\u7684Docker\u5b89\u88c5<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-16\">\u521b\u5efa\u5bb9\u5668\u65f6\u7684\u53c2\u6570<\/a><\/div><\/li>\n<li><div><a href=\"#tocer-heading-17\">\u76f8\u5173\u8d44\u6e90<\/a><\/div><\/li>\n<\/ul>\n<\/div><\/div>\n\n\n\n<p>Docker \u5927\u5927\u7b80\u5316\u4e86\u6570\u636e\u5e93\u7684\u5b89\u88c5\uff0c\u7279\u522b\u662f\u5728\u4ea7\u54c1\u6d4b\u8bd5\u9636\u6bb5\u7684\u65f6\u5019\uff0c\u53ef\u4ee5\u8ba9\u5f00\u53d1\u8005\u4ee5\u6700\u5feb\u901f\u7684\u65b9\u5f0f\u4f53\u9a8c\u6280\u672f\u4ea7\u54c1\uff0c\u5c24\u5176\u662f\u5f53\u8fd9\u4e2a\u6280\u672f\u4ea7\u54c1\u5df2\u7ecf\u975e\u5e38\u590d\u6742\u7684\u65f6\u5019\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Oracle \u5b98\u65b9\u63d0\u4f9b\u4e86\u54ea\u4e9b\u955c\u50cf<\/h3>\n\n\n\n<h4 class=\"wp-block-heading\">Oracle \u955c\u50cf\u5b98\u65b9\u9875\u9762<\/h4>\n\n\n\n<p>Oracle \u5728\u5b98\u65b9\u7ad9\u70b9\u4e2d\u5217\u51fa\u4e86\u6240\u6709\u652f\u6301\u7684\u4ea7\u54c1\uff0c\u4ee5\u53ca\u5bf9\u5e94\u7684\u4ed3\u5e93\u5217\u8868\u3002 Oracle \u955c\u50cf\u4ed3\u5e93\u7684\u5b98\u65b9\u9875\u9762\uff1a<\/p>\n\n\n\n<p class=\"has-text-align-center\"><strong>\u4ed3\u5e93\u5b98\u65b9\u9875\uff1a <a href=\"https:\/\/container-registry.oracle.com\/\">https:\/\/container-registry.oracle.com\/<\/a><\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"522\" src=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-2-1024x522.png\" alt=\"\" class=\"wp-image-17979\" style=\"width:726px;height:auto\" srcset=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-2-1024x522.png 1024w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-2-300x153.png 300w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-2-768x391.png 768w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-2.png 1354w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">\u627e\u5230\u8f6f\u4ef6\u5bf9\u5e94\u7684\u5b50\u4ed3\u5e93<\/h4>\n\n\n\n<p>\u8fd9\u91cc\u5173\u6ce8 Oracle Database \u76f8\u5173\u7684\u4ed3\u5e93\uff0c\u6545\u9009\u62e9\u7b2c\u4e00\u4e2a\u4ed3\u5e93\u5217\u8868\u9875\u3002\u5728\u8fd9\u91cc\u53ef\u4ee5\u770b\u5230\u6709\u5f88\u591a\u7684\u5b50\u4ed3\u5e93\uff0c\u53ef\u4ee5\u7528\u4e8e\u5b89\u88c5\u4e0d\u540c\u7684 Oracle \u6570\u636e\u5e93\u7248\u672c\u6216\u7ec4\u4ef6\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"617\" src=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-3-1024x617.png\" alt=\"\" class=\"wp-image-17981\" style=\"width:666px;height:auto\" srcset=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-3-1024x617.png 1024w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-3-300x181.png 300w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-3-768x463.png 768w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-3.png 1506w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">\u9009\u62e9\u7248\u672c\u4e0e\u955c\u50cf\u7ad9\u70b9<\/h4>\n\n\n\n<p>\u8fdb\u5165\u5355\u4e2a\u5b50\u4ed3\u5e93\uff0c\u5728\u9875\u9762\u7684\u6700\u5e95\u4e0b\u53ef\u4ee5\u770b\u5230\uff0c\u8be5\u4ed3\u5e93\u6709\u54ea\u4e9b\u7248\u672c\u7684\u955c\u50cf\u53ef\u4ee5\u4f7f\u7528\uff0c\u4f8b\u5982\uff0c\u8fd9\u91cc\u9009\u62e9\u4e86 <code>express<\/code> \u5b50\u4ed3\u5e93\uff0c\u5728\u9875\u9762\u6700\u5e95\u7aef\u627e\u5230\u652f\u6301\u7684\u7248\u672c\u5217\u8868\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"278\" src=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-4-1024x278.png\" alt=\"\" class=\"wp-image-17983\" style=\"width:685px;height:auto\" srcset=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-4-1024x278.png 1024w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-4-300x81.png 300w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-4-768x209.png 768w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-4.png 1318w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>\u53e6\u5916\uff0c\u8fd9\u91cc\u8fd8\u63d0\u4f9b\u4e86\u4e00\u4e9b\u53ef\u4f9b\u9009\u62e9\u7684\u955c\u50cf\u5217\u8868\uff0c\u5f00\u53d1\u8005\u53ef\u4ee5\u6839\u636e\u81ea\u5df1\u7684\u5730\u7406\u4f4d\u7f6e\u9009\u62e9\u5408\u9002\u7684\u955c\u50cf\u7ad9\u70b9\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u5b89\u88c5 Oracle \u6570\u636e\u5e93<\/h3>\n\n\n\n<h4 class=\"wp-block-heading\">\u62c9\u53d6\u955c\u50cf<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code class=\"\">docker pull container-registry.oracle.com\/database\/express:latest\n  or:  \ndocker pull container-registry.oracle.com\/database\/express:21.3.0-xe\n  or:\ndocker pull container-registry.oracle.com\/database\/express:18.4.0-xe<\/code><\/pre>\n\n\n\n<p>\u8fd9\u91cc\u7684\u6d4b\u8bd5\u9009\u62e9\u4e86<code>express:18.4.0-xe<\/code>\u7248\u672c\u8fdb\u884c\u5b89\u88c5\u3002\u67e5\u770b\u672c\u5730\u7684\u955c\u50cf\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">docker image ls\nEmulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\nREPOSITORY                                            TAG         IMAGE ID      CREATED       SIZE\ncontainer-registry.oracle.com\/mysql\/community-server  9.1         f1f889678a73  6 months ago  606 MB\ncontainer-registry.oracle.com\/database\/express        18.4.0-xe   364598d20118  4 years ago   6.03 GB<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u521b\u5efa Oracle \u6570\u636e\u5e93\u7684\u5bb9\u5668<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">docker container create \\\n   -it \\\n   --name oracle-18ex \\\n   -p 1521:1521 \\\n   -e ORACLE_PWD=oracledocker \\\n   container-registry.oracle.com\/database\/express:18.4.0-xe<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u542f\u52a8\u5bb9\u5668<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">docker start oracle-18ex<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u89c2\u5bdf\u542f\u52a8\u72b6\u6001<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">docker logs -f oracle-18ex\nEmulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\nORACLE PASSWORD FOR SYS AND SYSTEM: oracledocker\nSpecify a password to be used for database accounts. Oracle recommends that the password entered should be at least 8 characters in length, contain at least 1 uppercase character, 1 lower case character and 1 digit [0-9]. Note that the same password will be used for SYS, SYSTEM and PDBADMIN accounts:\nConfirm the password:\nConfiguring Oracle Listener.\nListener configuration succeeded.\nConfiguring Oracle Database XE.\nEnter SYS user password:\n****************\nEnter SYSTEM user password:\n*************\nEnter PDBADMIN User Password:\n*************\nPrepare for db operation\n7% complete\nCopying database files\n29% complete\nCreating and starting Oracle instance\n30% complete\n31% complete\n34% complete\n38% complete\n41% complete\n43% complete\nCompleting Database Creation\n47% complete\n50% complete\nCreating Pluggable Databases\n54% complete\n71% complete\nExecuting Post Configuration Actions\n93% complete\nRunning Custom Scripts\n100% complete\nDatabase creation complete. For details check the logfiles at:\n \/opt\/oracle\/cfgtoollogs\/dbca\/XE.\nDatabase Information:\nGlobal Database Name:XE\nSystem Identifier(SID):XE\nLook at the log file \"\/opt\/oracle\/cfgtoollogs\/dbca\/XE\/XE.log\" for further details.\n\nConnect to Oracle Database using one of the connect strings:\n     Pluggable database: bd127ae4faab\/XEPDB1\n     Multitenant container database: bd127ae4faab\nUse https:\/\/localhost:5500\/em to access Oracle Enterprise Manager for Oracle Database XE\nThe Oracle base remains unchanged with value \/opt\/oracle\n#########################\nDATABASE IS READY TO USE!\n#########################\nThe following output is now a tail of the alert.log:\n2025-04-17T03:40:43.663079+00:00\nXEPDB1(3):Resize operation completed for file# 10, old size 358400K, new size 368640K\n2025-04-17T03:40:44.483587+00:00\nXEPDB1(3):CREATE SMALLFILE TABLESPACE \"USERS\" LOGGING  DATAFILE  '\/opt\/oracle\/oradata\/XE\/XEPDB1\/users01.dbf' SIZE 5M REUSE AUTOEXTEND ON NEXT  1280K MAXSIZE UNLIMITED  EXTENT MANAGEMENT LOCAL  SEGMENT SPACE MANAGEMENT  AUTO\nXEPDB1(3):Completed: CREATE SMALLFILE TABLESPACE \"USERS\" LOGGING  DATAFILE  '\/opt\/oracle\/oradata\/XE\/XEPDB1\/users01.dbf' SIZE 5M REUSE AUTOEXTEND ON NEXT  1280K MAXSIZE UNLIMITED  EXTENT MANAGEMENT LOCAL  SEGMENT SPACE MANAGEMENT  AUTO\nXEPDB1(3):ALTER DATABASE DEFAULT TABLESPACE \"USERS\"\nXEPDB1(3):Completed: ALTER DATABASE DEFAULT TABLESPACE \"USERS\"\n2025-04-17T03:40:44.930766+00:00\nALTER PLUGGABLE DATABASE XEPDB1 SAVE STATE\nCompleted: ALTER PLUGGABLE DATABASE XEPDB1 SAVE STATE<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">\u767b\u5f55\u5bb9\u5668\u4e2d\u7684 Oracle \u6570\u636e\u5e93<\/h3>\n\n\n\n<p>\u5728\u4e0a\u9762\u7684\u8f93\u51fa\u4e2d\u53ef\u4ee5\u770b\u5230\uff0c\u5b89\u88c5\u65f6\u4f1a\u9ed8\u8ba4\u521b\u5efa\u5982\u4e0b\u6570\u636e\u5e93\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">Database Information:\nGlobal Database Name:XE\nSystem Identifier(SID):XE<\/code><\/pre>\n\n\n\n<p>\u6839\u636e\u5728\u4e0a\u8ff0 <code>docker<\/code> \u547d\u4ee4\u4e2d\u6307\u5b9a\u7684\u5bc6\u7801\uff0c\u5219\u53ef\u4ee5\u4f7f\u7528\u5982\u4e0b\u7684\u547d\u4ee4\u767b\u5f55\u6570\u636e\u6570\u636e\u5e93\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">docker exec -it oracle-18ex sqlplus sys\/oracledocker@XE as sysdba\n  or:\ndocker exec -it oracle-18ex sqlplus system\/oracledocker@XE<\/code><\/pre>\n\n\n\n<p>\u767b\u5f55\u540e\uff0c\u4f1a\u6709\u5982\u4e0b\u63d0\u793a\u8f93\u5165\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">Emulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\n\nSQL*Plus: Release 18.0.0.0.0 - Production on Thu Apr 17 03:56:27 2025\nVersion 18.4.0.0.0\n\nCopyright (c) 1982, 2018, Oracle.  All rights reserved.\n\nLast Successful login time: Thu Apr 17 2025 03:49:37 +00:00\n\nConnected to:\nOracle Database 18c Express Edition Release 18.0.0.0.0 - Production\nVersion 18.4.0.0.0\n\nSQL&gt;<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">\u6388\u6743\u534f\u8bae\u4e0e\u8ba4\u8bc1<\/h3>\n\n\n\n<p>\u5982\u679c\u4f60\u8981\u4f7f\u7528 Oracle \u6570\u636e\u5e93\u7684\u4f01\u4e1a\u7248\u7684\u8bdd\uff0c\u5728\u62c9\u53d6\u955c\u50cf\u524d\u5219\u9700\u8981\u5148\u767b\u5f55\u5b98\u7f51\u201c\u540c\u610f\u201d\u76f8\u5173\u7684\u534f\u8bae\uff0c\u5e76\u4f7f\u7528<code>docker login<\/code>\u7684\u65b9\u5f0f\u8fdb\u884c\u8ba4\u8bc1\uff0c\u7136\u540e\u624d\u53ef\u4ee5\u62c9\u53d6\u955c\u50cf\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">requested access to the resource is denied<\/h4>\n\n\n\n<p>\u5982\u679c\u6ca1\u6709\u8ba4\u8bc1\u6216\u63d0\u524d\u5728\u5b98\u7f51\u7edf\u4e00\u534f\u8bae\uff0c\u5219\u53ef\u80fd\u9047\u5230\u5982\u4e0b\u62a5\u9519\uff1a<code>requested access to the resource is denied<\/code>\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code class=\"\">docker pull container-registry.oracle.com\/database\/enterprise:12.2.0.1\nEmulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\nTrying to pull container-registry.oracle.com\/database\/enterprise:12.2.0.1...\nError: initializing source docker:\/\/container-registry.oracle.com\/database\/enterprise:12.2.0.1: reading manifest 12.2.0.1 in container-registry.oracle.com\/database\/enterprise: requested access to the resource is denied<\/code><\/pre>\n\n\n\n<p>\u6216\u8005\uff1a<code>invalid username\/password: authentication required<\/code><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code class=\"\">docker pull container-registry-tokyo.oracle.com\/database\/enterprise:12.2.0.1\nEmulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\nTrying to pull container-registry-tokyo.oracle.com\/database\/enterprise:12.2.0.1...\nError: initializing source docker:\/\/container-registry-tokyo.oracle.com\/database\/enterprise:12.2.0.1: unable to retrieve auth token: invalid username\/password: authentication required<\/code><\/pre>\n\n\n\n<p>\u89e3\u51b3\u4e0a\u8ff0\u95ee\u9898\uff0c\u9996\u5148\u9700\u8981\u767b\u5f55Oracle\u955c\u50cf\u7684\u5b98\u65b9\u7ad9\u70b9\uff0c\u5e76\u540c\u610f\u76f8\u5173\u534f\u8bae\uff0c\u7136\u540e\u4f7f\u7528<code>docker login<\/code>\u5b8c\u6210\u8ba4\u8bc1\uff0c\u540e\u5373\u53ef\u4e0b\u8f7d\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">\u767b\u5f55Oracle\u4ed3\u5e93\u7ad9\u70b9\u5e76\u540c\u610f\u534f\u8bae<\/h4>\n\n\n\n<p>\u4f8b\u5982\uff0c\u5982\u679c\u9700\u8981\u4e0b\u8f7d\u201cOracle Database Enterprise Edition\u201d\uff0c\u5219\u9700\u8981\u5148\u8fdb\u5165\u5bf9\u5e94\u4ed3\u5e93\u7ad9\u70b9\uff1a<a href=\"https:\/\/container-registry.oracle.com\/ords\/ocr\/ba\/database\/enterprise\">\u94fe\u63a5<\/a>\uff0c\u5e76\u5728\u9875\u9762\u7684\u53f3\u4fa7\u680f\u70b9\u51fb\u534f\u8bae\u5e76\u540c\u610f\u534f\u8bae\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"556\" src=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-5-1024x556.png\" alt=\"\" class=\"wp-image-17999\" style=\"width:619px;height:auto\" srcset=\"https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-5-1024x556.png 1024w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-5-300x163.png 300w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-5-768x417.png 768w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-5-1536x834.png 1536w, https:\/\/www.orczhou.com\/wp-content\/uploads\/2025\/04\/image-5.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">docker login<\/h4>\n\n\n\n<p>\u540c\u610f\u534f\u8bae\u540e\uff0c\u5c31\u53ef\u4ee5\u4f7f\u7528<code>docker login<\/code>\u767b\u5f55\u8d26\u53f7\u5e76\u8fdb\u884c\u955c\u50cf\u7684\u4e0b\u8f7d\u4e86\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Enterprise Edition\u7684Docker\u5b89\u88c5<\/h3>\n\n\n\n<p>\u5728\u53c2\u8003 Oracle \u4f01\u4e1a\u7248\u5b98\u65b9\u6587\u6863\uff08<a href=\"https:\/\/container-registry.oracle.com\/ords\/ocr\/ba\/database\/enterprise\">\u53c2\u8003<\/a>\uff09\u8fdb\u884c\u5b89\u88c5\u90e8\u7f72\u7684\u65f6\u5019\uff0c\u5728 AlmaLinux \u90e8\u7f72\u65f6\u4f1a\u9047\u5230\u5982\u4e0b\u7684\u95ee\u9898\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">docker exec -it oracle-1202ee sqlplus \/ as sysdba\nEmulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\nError: crun: executable file `sqlplus` not found in $PATH: No such file or directory: OCI runtime attempted to invoke a command that was not found<\/code><\/pre>\n\n\n\n<p>\u5f53\u524d\u7684\u7ed5\u8fc7\u65b9\u6848\u662f\uff0c\u8fdb\u5165\u5bb9\u5668\u7684<code>bash<\/code>\uff0c\u7136\u540e\u518d\u6267\u884c\u5373\u53ef\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"bash\" class=\"language-bash\">[root@oracle-docker-test ~]# docker exec -it oracle-1202ee bash\nEmulate Docker CLI using podman. Create \/etc\/containers\/nodocker to quiet msg.\n[oracle@8bb1ec09ec5e \/]$ sqlplus \/ as sysdba\n\nSQL*Plus: Release 12.2.0.1.0 Production on Fri Apr 18 02:37:30 2025\n\nCopyright (c) 1982, 2016, Oracle.  All rights reserved.\n\n\nConnected to:\nOracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production\n\nSQL&gt;<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">\u521b\u5efa\u5bb9\u5668\u65f6\u7684\u53c2\u6570<\/h3>\n\n\n\n<p>\u5728\u521b\u5efa\u5bb9\u5668\u7684\u65f6\u5019\uff0c\u53ef\u4ee5\u4f7f\u7528\u547d\u4ee4\u884c\u8fdb\u884c\u90e8\u5206\u542f\u52a8\u53c2\u6570\u7684\u914d\u7f6e\u3002\u4f8b\u5982\uff0c\u9ed8\u8ba4\u542f\u52a8\u65f6\uff0c\u662f\u6ca1\u6709\u5f00\u542f\u5f52\u6863\u65e5\u5fd7\u7684\uff08Archive Logs\uff09\u7684\uff0c\u5219\u53ef\u4ee5\u901a\u8fc7\u6dfb\u52a0\u5982\u4e0b\u5bb9\u5668\u6784\u5efa\u53c2\u6570\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code class=\"\">-e ENABLE_ARCHIVELOG=true<\/code><\/pre>\n\n\n\n<p>\u5b8c\u6574\u7684\u547d\u4ee4\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code class=\"\">docker container create \\\n   -it \\\n   --name oracle-1202ee \\\n   -p 1521:1521 \\\n   -e ENABLE_ARCHIVELOG=true \\\n   -e ORACLE_PWD=oracledocker \\\n   container-registry.oracle.com\/database\/enterprise:12.2.0.1<\/code><\/pre>\n\n\n\n<p><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u76f8\u5173\u8d44\u6e90<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Oracle \u955c\u50cf\u4ed3\u5e93\u5b98\u65b9\u7ad9\u70b9\uff1a<a href=\"https:\/\/container-registry.oracle.com\/ords\/f?p=113:10::::::\">Oracle Container Registry<\/a><\/li>\n\n\n\n<li>Oracle \u5b98\u65b9 GitHub \u955c\u50cf\u5217\u8868\uff1a<a href=\"https:\/\/github.com\/oracle\/docker-images\/tree\/main\/OracleDatabase\/SingleInstance\/dockerfiles\">docker-images\/OracleDatabase@GitHub<\/a><\/li>\n\n\n\n<li>Oracle \u5b98\u65b9\u5bb9\u5668\u955c\u50cf\u4f7f\u7528\u8bf4\u660e\uff1a\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/container-registry.oracle.com\/ords\/f?p=113:4:18403371360730:::4:P4_REPOSITORY,AI_REPOSITORY,AI_REPOSITORY_NAME,P4_REPOSITORY_NAME,P4_EULA_ID,P4_BUSINESS_AREA_ID:803,803,Oracle%20Database%20Express%20Edition,Oracle%20Database%20Express%20Edition,1,0&amp;cs=33EUgEnwcDnbJpXnhA8u3vcepvCvT-2liEUlmVoJdEMznpm4JFD-kj7hYmd5uLCaLJPkV9_E0yBFYTSOMlOqcVw\">Oracle Database XE Release Docker Image Documentation<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/container-registry.oracle.com\/ords\/ocr\/ba\/database\/enterprise\">Oracle Database Enterprise Edition Docker Image Documentation<\/a><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Docker \u5927\u5927\u7b80\u5316\u4e86\u6570\u636e\u5e93\u7684\u5b89\u88c5\uff0c\u7279\u522b\u662f\u5728\u4ea7\u54c1\u6d4b\u8bd5\u9636\u6bb5\u7684\u65f6\u5019\uff0c\u53ef\u4ee5\u8ba9\u5f00\u53d1\u8005\u4ee5\u6700\u5feb\u901f\u7684\u65b9\u5f0f\u4f53\u9a8c\u6280\u672f\u4ea7\u54c1\uff0c\u5c24\u5176\u662f\u5f53\u8fd9\u4e2a\u6280\u672f\u4ea7\u54c1\u5df2\u7ecf\u975e\u5e38\u590d\u6742\u7684\u65f6\u5019\u3002 Oracle \u5b98\u65b9\u63d0\u4f9b\u4e86\u54ea\u4e9b\u955c\u50cf Oracle \u955c\u50cf\u5b98\u65b9\u9875\u9762 Oracle \u5728\u5b98\u65b9\u7ad9\u70b9\u4e2d\u5217\u51fa\u4e86\u6240\u6709\u652f\u6301\u7684\u4ea7\u54c1\uff0c\u4ee5\u53ca\u5bf9\u5e94\u7684\u4ed3\u5e93\u5217\u8868\u3002 Oracle \u955c\u50cf\u4ed3\u5e93\u7684\u5b98\u65b9\u9875\u9762\uff1a \u4ed3\u5e93\u5b98\u65b9\u9875\uff1a https:\/\/container-registry.oracle.com\/ \u627e\u5230\u8f6f\u4ef6\u5bf9\u5e94\u7684\u5b50\u4ed3\u5e93 \u8fd9\u91cc\u5173\u6ce8 Oracle Database \u76f8\u5173\u7684\u4ed3\u5e93\uff0c\u6545\u9009\u62e9\u7b2c\u4e00\u4e2a\u4ed3\u5e93\u5217\u8868\u9875\u3002\u5728\u8fd9\u91cc\u53ef\u4ee5\u770b\u5230\u6709\u5f88\u591a\u7684\u5b50\u4ed3\u5e93\uff0c\u53ef\u4ee5\u7528\u4e8e\u5b89\u88c5\u4e0d\u540c\u7684 Oracle \u6570\u636e\u5e93\u7248\u672c\u6216\u7ec4\u4ef6\uff1a \u9009\u62e9\u7248\u672c\u4e0e\u955c\u50cf\u7ad9\u70b9 \u8fdb\u5165\u5355\u4e2a\u5b50\u4ed3\u5e93\uff0c\u5728\u9875\u9762\u7684\u6700\u5e95\u4e0b\u53ef\u4ee5\u770b\u5230\uff0c\u8be5\u4ed3\u5e93\u6709\u54ea\u4e9b\u7248\u672c\u7684\u955c\u50cf\u53ef\u4ee5\u4f7f\u7528\uff0c\u4f8b\u5982\uff0c\u8fd9\u91cc\u9009\u62e9\u4e86 express \u5b50\u4ed3\u5e93\uff0c\u5728\u9875\u9762\u6700\u5e95\u7aef\u627e\u5230\u652f\u6301\u7684\u7248\u672c\u5217\u8868\uff1a \u53e6\u5916\uff0c\u8fd9\u91cc\u8fd8\u63d0\u4f9b\u4e86\u4e00\u4e9b\u53ef\u4f9b\u9009\u62e9\u7684\u955c\u50cf\u5217\u8868\uff0c\u5f00\u53d1\u8005\u53ef\u4ee5\u6839\u636e\u81ea\u5df1\u7684\u5730\u7406\u4f4d\u7f6e\u9009\u62e9\u5408\u9002\u7684\u955c\u50cf\u7ad9\u70b9\u3002 \u5b89\u88c5 Oracle \u6570\u636e\u5e93 \u62c9\u53d6\u955c\u50cf \u8fd9\u91cc\u7684\u6d4b\u8bd5\u9009\u62e9\u4e86express:18.4.0-xe\u7248\u672c\u8fdb\u884c\u5b89\u88c5\u3002\u67e5\u770b\u672c\u5730\u7684\u955c\u50cf\uff1a \u521b\u5efa Oracle \u6570\u636e\u5e93\u7684\u5bb9\u5668 \u542f\u52a8\u5bb9\u5668 \u89c2\u5bdf\u542f\u52a8\u72b6\u6001 \u767b\u5f55\u5bb9\u5668\u4e2d\u7684 Oracle \u6570\u636e\u5e93 \u5728\u4e0a\u9762\u7684\u8f93\u51fa\u4e2d\u53ef\u4ee5\u770b\u5230\uff0c\u5b89\u88c5\u65f6\u4f1a\u9ed8\u8ba4\u521b\u5efa\u5982\u4e0b\u6570\u636e\u5e93\uff1a \u6839\u636e\u5728\u4e0a\u8ff0 docker \u547d\u4ee4\u4e2d\u6307\u5b9a\u7684\u5bc6\u7801\uff0c\u5219\u53ef\u4ee5\u4f7f\u7528\u5982\u4e0b\u7684\u547d\u4ee4\u767b\u5f55\u6570\u636e\u6570\u636e\u5e93\uff1a \u767b\u5f55\u540e\uff0c\u4f1a\u6709\u5982\u4e0b\u63d0\u793a\u8f93\u5165\uff1a \u6388\u6743\u534f\u8bae\u4e0e\u8ba4\u8bc1 \u5982\u679c\u4f60\u8981\u4f7f\u7528 Oracle \u6570\u636e\u5e93\u7684\u4f01\u4e1a\u7248\u7684\u8bdd\uff0c\u5728\u62c9\u53d6\u955c\u50cf\u524d\u5219\u9700\u8981\u5148\u767b\u5f55\u5b98\u7f51\u201c\u540c\u610f\u201d\u76f8\u5173\u7684\u534f\u8bae\uff0c\u5e76\u4f7f\u7528docker login\u7684\u65b9\u5f0f\u8fdb\u884c\u8ba4\u8bc1\uff0c\u7136\u540e\u624d\u53ef\u4ee5\u62c9\u53d6\u955c\u50cf\u3002 requested access to the resource is denied \u5982\u679c\u6ca1\u6709\u8ba4\u8bc1\u6216\u63d0\u524d\u5728\u5b98\u7f51\u7edf\u4e00\u534f\u8bae\uff0c\u5219\u53ef\u80fd\u9047\u5230\u5982\u4e0b\u62a5\u9519\uff1arequested [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"wp-custom-template-a-1440-px-width-template","format":"standard","meta":{"_eb_attr":"","inline_featured_image":false,"_tocer_settings":[],"footnotes":""},"categories":[126,13,137],"tags":[],"class_list":["post-17978","post","type-post","status-publish","format-standard","hentry","category-database","category-oracle","category-learning-more"],"_links":{"self":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts\/17978","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/comments?post=17978"}],"version-history":[{"count":23,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts\/17978\/revisions"}],"predecessor-version":[{"id":18018,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts\/17978\/revisions\/18018"}],"wp:attachment":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/media?parent=17978"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/categories?post=17978"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/tags?post=17978"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}