1 Answers
A:
Here are some methods you can try to resolve the 'Permission denied (publickey)' or 'Authentication failed, permission denied' errors
authorized_keys file.ssh-agent to load the key automatically.authorized_keys file.If you copied your SSH keys from another source, you might encounter a permission denied error. This can happen if the file permissions on the SSH keys are too open. It’s simply not allowed to have 777 permissions on the public or private keys. You can set the following permissions on the ssh directory and its files:
.ssh directory: 700 (drwx------)
public keys: 644 (-rw-r--r--)
private keys: 600 (-rw-------)
authorized_keys: 600 (-rw-------)
known_hosts: 600 (-rw-------)
config: 600 (-rw-------)
 
You can change these permissions using chmod command.
If these methods don’t work, you might need to check your SSH configuration file or restart your SSH service.
 
                                Amazon EC2
AmazonDisclaimer
Techjockey’s software industry experts offer advice for educational and informational purposes only. A category or product query or issue posted, created, or compiled by Techjockey is not meant to replace your independent judgment.
                        20,000+ Software Listed
                    
 Best
                            Price Guaranteed
                    
                        Free Expert
                            Consultation
                    
 2M+
                            Happy Customers