Permission denied (publickey)
时间: 2023-11-06 09:00:54 浏览: 47
码云出现错误git@gitee.com: Permission denied (publickey). fatal: Could not read from remote repository. P
5星 · 资源好评率100%
This error message usually occurs when attempting to connect to a remote server with SSH and the server is not able to authenticate the user's public key.
There are a few possible reasons why this error message may occur:
1. The public key is not present in the authorized_keys file on the server. Ensure that the correct public key has been added to the authorized_keys file on the server.
2. The permissions on the authorized_keys file are not set correctly. The file should have permissions of 600 or 644, and the .ssh directory should have permissions of 700.
3. The public key is incorrect or has been modified. Check that the public key being used matches the private key that was generated.
4. The SSH agent is not running or the key has not been added to the agent. Ensure that the SSH agent is running and the key has been added to the agent.
To resolve this error message, check the above issues and ensure that the public key is correctly configured and authorized on the server.
阅读全文