Permission denied to access public ssh key
up vote
0
down vote
favorite
I can't add my ssh public key to the ssh-agent and my ssh folder is odd I believe.here is a screenshot
18.04 ssh ssh-agent
add a comment |
up vote
0
down vote
favorite
I can't add my ssh public key to the ssh-agent and my ssh folder is odd I believe.here is a screenshot
18.04 ssh ssh-agent
What is the output fromls -lad /home/maydara/.ssh /home/maydata
andid
– mdpc
Dec 5 at 1:09
@mdpc drwxr-xr-x 38 maydara maydara 4096 Dec 5 02:20 /home/maydara drw------- 2 maydara maydara 4096 Dec 5 00:54 /home/maydara/.ssh
– Getsuga
Dec 5 at 1:21
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I can't add my ssh public key to the ssh-agent and my ssh folder is odd I believe.here is a screenshot
18.04 ssh ssh-agent
I can't add my ssh public key to the ssh-agent and my ssh folder is odd I believe.here is a screenshot
18.04 ssh ssh-agent
18.04 ssh ssh-agent
asked Dec 5 at 0:40
Getsuga
3114
3114
What is the output fromls -lad /home/maydara/.ssh /home/maydata
andid
– mdpc
Dec 5 at 1:09
@mdpc drwxr-xr-x 38 maydara maydara 4096 Dec 5 02:20 /home/maydara drw------- 2 maydara maydara 4096 Dec 5 00:54 /home/maydara/.ssh
– Getsuga
Dec 5 at 1:21
add a comment |
What is the output fromls -lad /home/maydara/.ssh /home/maydata
andid
– mdpc
Dec 5 at 1:09
@mdpc drwxr-xr-x 38 maydara maydara 4096 Dec 5 02:20 /home/maydara drw------- 2 maydara maydara 4096 Dec 5 00:54 /home/maydara/.ssh
– Getsuga
Dec 5 at 1:21
What is the output from
ls -lad /home/maydara/.ssh /home/maydata
and id
– mdpc
Dec 5 at 1:09
What is the output from
ls -lad /home/maydara/.ssh /home/maydata
and id
– mdpc
Dec 5 at 1:09
@mdpc drwxr-xr-x 38 maydara maydara 4096 Dec 5 02:20 /home/maydara drw------- 2 maydara maydara 4096 Dec 5 00:54 /home/maydara/.ssh
– Getsuga
Dec 5 at 1:21
@mdpc drwxr-xr-x 38 maydara maydara 4096 Dec 5 02:20 /home/maydara drw------- 2 maydara maydara 4096 Dec 5 00:54 /home/maydara/.ssh
– Getsuga
Dec 5 at 1:21
add a comment |
2 Answers
2
active
oldest
votes
up vote
1
down vote
The fix is chmod 700 /home/maydara/.ssh
Without the 'x' permission, a directory cannot be searched (i.e. files in directory cannot be found).
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
add a comment |
up vote
0
down vote
accepted
To fix my problem I ended up removing my ssh folder and regenarating my keys:
rm -rf ~/.ssh
ssh-keygen -t rsa -b 4096
ssh-add ~/.ssh/[the_name_of_your_private_key]
then I uploaded my public keys again to github, digitalocean, etc.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1098523%2fpermission-denied-to-access-public-ssh-key%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
The fix is chmod 700 /home/maydara/.ssh
Without the 'x' permission, a directory cannot be searched (i.e. files in directory cannot be found).
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
add a comment |
up vote
1
down vote
The fix is chmod 700 /home/maydara/.ssh
Without the 'x' permission, a directory cannot be searched (i.e. files in directory cannot be found).
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
add a comment |
up vote
1
down vote
up vote
1
down vote
The fix is chmod 700 /home/maydara/.ssh
Without the 'x' permission, a directory cannot be searched (i.e. files in directory cannot be found).
The fix is chmod 700 /home/maydara/.ssh
Without the 'x' permission, a directory cannot be searched (i.e. files in directory cannot be found).
edited Dec 5 at 19:07
Kulfy
2,69331034
2,69331034
answered Dec 5 at 19:02
mdpc
8161818
8161818
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
add a comment |
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Mbpc i've tried this before i wrote this post and it didn't work, I ended up deleting the whole folder and the keys then I started from scratch.
– Getsuga
Dec 5 at 20:21
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Getsuga You might like to add that as an answer. :-)
– Kulfy
Dec 8 at 8:39
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Kulfy thx for the suggestion but what i've done is not really a fix, it's a rebuild from scratch and that won't be helpful for people who don't have copies of their ssh keys.
– Getsuga
Dec 8 at 21:42
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
@Getsuga Answer section is meant for posting things which solved the problem. I've seen many a times people do post a re-installation as their answer (since they solved their problem by re-installation). Your solution might help those who have copies. So, please write that as an answer and mark that answer as accepted. :-)
– Kulfy
Dec 9 at 1:05
add a comment |
up vote
0
down vote
accepted
To fix my problem I ended up removing my ssh folder and regenarating my keys:
rm -rf ~/.ssh
ssh-keygen -t rsa -b 4096
ssh-add ~/.ssh/[the_name_of_your_private_key]
then I uploaded my public keys again to github, digitalocean, etc.
add a comment |
up vote
0
down vote
accepted
To fix my problem I ended up removing my ssh folder and regenarating my keys:
rm -rf ~/.ssh
ssh-keygen -t rsa -b 4096
ssh-add ~/.ssh/[the_name_of_your_private_key]
then I uploaded my public keys again to github, digitalocean, etc.
add a comment |
up vote
0
down vote
accepted
up vote
0
down vote
accepted
To fix my problem I ended up removing my ssh folder and regenarating my keys:
rm -rf ~/.ssh
ssh-keygen -t rsa -b 4096
ssh-add ~/.ssh/[the_name_of_your_private_key]
then I uploaded my public keys again to github, digitalocean, etc.
To fix my problem I ended up removing my ssh folder and regenarating my keys:
rm -rf ~/.ssh
ssh-keygen -t rsa -b 4096
ssh-add ~/.ssh/[the_name_of_your_private_key]
then I uploaded my public keys again to github, digitalocean, etc.
answered Dec 11 at 10:58
Getsuga
3114
3114
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1098523%2fpermission-denied-to-access-public-ssh-key%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
What is the output from
ls -lad /home/maydara/.ssh /home/maydata
andid
– mdpc
Dec 5 at 1:09
@mdpc drwxr-xr-x 38 maydara maydara 4096 Dec 5 02:20 /home/maydara drw------- 2 maydara maydara 4096 Dec 5 00:54 /home/maydara/.ssh
– Getsuga
Dec 5 at 1:21