Permission Error When Starting a Notebook Instance as Root User
Symptom
If the user starts a notebook instance as the root user with a custom image where the root user's UID/GID is not set to 0, the container will adopt that UID at startup, causing permission issues.
Possible Causes
- The UID/GID of the root user is not 0.
- Linux grants root permissions when the UID is 0. Changing this UID can disrupt critical system services like sudo, SSH, and package managers, corrupt file permissions, or permanently damage the system.
- If the root user's UID in the image is not 0, Kubernetes' runAsUser=0 setting will not override it since the image's user configuration takes precedence over runAsUser.
Solution
Ensure that the UID and GID of the root user is 0 (default value). Change the image of the notebook instance to solve this problem. For details, see Updating a Notebook Instance.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot