Docker Community Forums

Share and learn in the Docker community.

Unable to su to oracle user for Oracle Database Server Enterprise Edition


(Mvgian) #1

Expected behavior

Able to switch user to oracle successfully

Actual behavior

Error shown:
su: cannot open session: Permission denied


I’m trying to run Oracle container in my Docker and I’m unable to su to oracle user in bash with error permission denied. Currently I’m using the latest Docker Version 18.06.1-ce-win73 (19507) under Windows 10 Pro Version 1803 build 17134.407. My Docker is set to Windows container with Experimental features enabled so that I can run Linux containers in LCOW setup.

When I was using Linux container without experimental features in the past, I was able to configure Oracle and su oracle in bash successfully. However after I switch to Windows container and enable experimental features, I was not able to su oracle in bash.

Steps to reproduce the behavior

1 Execute docker run image
docker run --platform=linux -d -it --name OracleDB --shm-size=4G -p 1521:1521
2 Execute bash to Oracle DB container
docker exec -it OracleDB bash
3 su oracle

(Pkrause79) #2

I have a similar behaviour with the same settings: running the container itself works well, but when I want to first login to the database with the Oracle “sys” user and the given credentials from the Oracle readme (start sqlplus on bash, connect sys as sysdba, password Oradoc_db1) I am getting “Permission denied” error after enter the user password. Same for the user “system” (normal login) and for “/” - none of them are working. So I cannot manage the database and therefor I cannot use this container at all (on Windows, in a mixed mode together with Linux containers by using LCOW experimental feature). Any idea’s?