usermod: Permission denied. usermod: cannot lock /etc/passwd; try again later.
时间: 2024-05-19 20:01:49 浏览: 443
Ubuntu 非root用户使用Docker命令提示:connect: permission denied
5星 · 资源好评率100%
This error message indicates that the usermod command does not have the necessary permissions to modify the user account information in the /etc/passwd file. The file is locked and cannot be accessed at the moment.
To fix this error, you may need to run the usermod command with root privileges using the sudo command. For example, you can try running the following command instead:
sudo usermod [options] username
If the issue persists, you may need to wait for a while and try again later when the /etc/passwd file is no longer locked.
阅读全文