title: Oracle 12c docker setup on Apple M1
body: <p>I am trying to run Oracle db in docker on M1 Mac. I have tried images from both <code>store/oracle/database-enterprise:12.2.0.1-slim</code> and <code>container-registry.oracle.com/database/enterprise:12.2.0.1-slim</code> but getting the same error.</p>
  <p><code>docker run -d -it --name oracle -v $(pwd)/db/oradata:/ORCL store/oracle/database-enterprise:12.2.0.1-slim</code></p>
  <p>I also tried non-slim version and by providing the <code>--platform linux/amd64</code> to the docker command. Result is same.</p>
  <p>Here's the result of <code>docker logs -f oracle</code></p>
  <pre class="lang-sh prettyprint-override"><code>Setup Oracle Database
  Oracle Database 12.2.0.1 Setup
  Sat Jul 31 18:44:14 UTC 2021
  
  Check parameters ......
  log file is : /home/oracle/setup/log/paramChk.log
  paramChk.sh is done at 1 sec
  
  untar DB bits ......
  log file is : /home/oracle/setup/log/untarDB.log
  untarDB.sh is done at 29 sec
  
  config DB ......
  log file is : /home/oracle/setup/log/configDB.log
  Sat Jul 31 18:44:42 UTC 2021
  Start Docker DB configuration
  Call configDBora.sh to configure database
  Sat Jul 31 18:44:42 UTC 2021
  Configure DB as oracle user
  Setup Database directories ...
  
  SQL*Plus: Release 12.2.0.1.0 Production on Sat Jul 31 18:44:43 2021
  
  Copyright (c) 1982, 2016, Oracle.  All rights reserved.
  
  ERROR:
  ORA-12547: TNS:lost contact
  
  
  Enter user-name: SP2-0306: Invalid option.
  Usage: CONN[ECT] [{logon|/|proxy} [AS {SYSDBA|SYSOPER|SYSASM|SYSBACKUP|SYSDG|SYSKM|SYSRAC}] [edition=value]]
  where &lt;logon&gt; ::= &lt;username&gt;[/&lt;password&gt;][@&lt;connect_identifier&gt;]
        &lt;proxy&gt; ::= &lt;proxyuser&gt;[&lt;username&gt;][/&lt;password&gt;][@&lt;connect_identifier&gt;]
  Enter user-name: Enter password: 
  ERROR:
  ORA-12547: TNS:lost contact
  
  
  SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
  update password
  
  Enter password for SYS: 
  create pdb : ORCLPDB1
  
  SQL*Plus: Release 12.2.0.1.0 Production on Sat Jul 31 18:44:43 2021
  
  Copyright (c) 1982, 2016, Oracle.  All rights reserved.
  
  ERROR:
  ORA-12547: TNS:lost contact
  
  
  Enter user-name: SP2-0306: Invalid option.
  Usage: CONN[ECT] [{logon|/|proxy} [AS {SYSDBA|SYSOPER|SYSASM|SYSBACKUP|SYSDG|SYSKM|SYSRAC}] [edition=value]]
  where &lt;logon&gt; ::= &lt;username&gt;[/&lt;password&gt;][@&lt;connect_identifier&gt;]
        &lt;proxy&gt; ::= &lt;proxyuser&gt;[&lt;username&gt;][/&lt;password&gt;][@&lt;connect_identifier&gt;]
  Enter user-name: SP2-0306: Invalid option.
  Usage: CONN[ECT] [{logon|/|proxy} [AS {SYSDBA|SYSOPER|SYSASM|SYSBACKUP|SYSDG|SYSKM|SYSRAC}] [edition=value]]
  where &lt;logon&gt; ::= &lt;username&gt;[/&lt;password&gt;][@&lt;connect_identifier&gt;]
        &lt;proxy&gt; ::= &lt;proxyuser&gt;[&lt;username&gt;][/&lt;password&gt;][@&lt;connect_identifier&gt;]
  SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
  Reset Database parameters
  
  SQL*Plus: Release 12.2.0.1.0 Production on Sat Jul 31 18:44:43 2021
  
  Copyright (c) 1982, 2016, Oracle.  All rights reserved.
  
  ERROR:
  ORA-12547: TNS:lost contact
  
  
  Enter user-name: SP2-0306: Invalid option.
  Usage: CONN[ECT] [{logon|/|proxy} [AS {SYSDBA|SYSOPER|SYSASM|SYSBACKUP|SYSDG|SYSKM|SYSRAC}] [edition=value]]
  where &lt;logon&gt; ::= &lt;username&gt;[/&lt;password&gt;][@&lt;connect_identifier&gt;]
        &lt;proxy&gt; ::= &lt;proxyuser&gt;[&lt;username&gt;][/&lt;password&gt;][@&lt;connect_identifier&gt;]
  Enter user-name: Enter password: 
  ERROR:
  ORA-12547: TNS:lost contact
  
  
  SP2-0157: unable to CONNECT to ORACLE after 3 attempts, exiting SQL*Plus
  
  LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 31-JUL-2021 18:44:44
  
  Copyright (c) 1991, 2016, Oracle.  All rights reserved.
  
  Starting /u01/app/oracle/product/12.2.0/dbhome_1/bin/tnslsnr: please wait...
  
  TNSLSNR for Linux: Version 12.2.0.1.0 - Production
  System parameter file is /u01/app/oracle/product/12.2.0/dbhome_1/admin/ORCLCDB/listener.ora
  Log messages written to /u01/app/oracle/diag/tnslsnr/989db909d8df/listener/alert/log.xml
  Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=0.0.0.0)(PORT=1521)))
  Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  
  Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=0.0.0.0)(PORT=1521)))
  STATUS of the LISTENER
  ------------------------
  Alias                     LISTENER
  Version                   TNSLSNR for Linux: Version 12.2.0.1.0 - Production
  Start Date                31-JUL-2021 18:44:44
  Uptime                    0 days 0 hr. 0 min. 0 sec
  Trace Level               off
  Security                  ON: Local OS Authentication
  SNMP                      OFF
  Listener Parameter File   /u01/app/oracle/product/12.2.0/dbhome_1/admin/ORCLCDB/listener.ora
  Listener Log File         /u01/app/oracle/diag/tnslsnr/989db909d8df/listener/alert/log.xml
  Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=0.0.0.0)(PORT=1521)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  The listener supports no services
  The command completed successfully
  
  DONE!
  Remove password info
  Docker DB configuration is complete !
  ERROR : config DB failed, please check log /home/oracle/setup/log/configDB.log for details!
  OS process OFSD (ospid 188) idle for 30 seconds, exiting
  2017-08-09T10:36:20.752530+00:00
  ARCH: Archival disabled due to shutdown: 1090
  Shutting down archive processes
  Archiving is disabled
  JIT: pid 563 requesting stop
  2017-08-09T10:36:20.815635+00:00
  Stopping background process VKTM
  2017-08-09T10:36:26.581058+00:00
  Instance shutdown complete (OS id: 563)
  /usr/bin/tail: inotify cannot be used, reverting to polling: Function not implemented
  </code></pre>
  <p>Is it the issue with M1 or I my configuration</p>