Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: ssh permission denied

  1. #1
    Join Date
    Apr 2009
    Location
    Annapolis, MD
    Posts
    204

    Default ssh permission denied

    I am trying to connect to my web host via ssh. I can do this on Windows using Putty without issue. However, if I run this on Linux, I receive a "permission denied" when I am prompted for my login and password. It's obviously making some type of connection, otherwise it wouldn't be prompting me for authentication.

    I initially thought this was a firewall issue. I opened up port 22 and I even tried disabling the firewall altogether. However, I still received this error.

    Online I have seen all kinds of resolutions, but not sure where to start first.

    I have openSuse 11.3 64-bit.

    Any other information I will be happy to provide.

    Thanks.

  2. #2
    Join Date
    Mar 2009
    Location
    sri mayapur, west bengal, india
    Posts
    958

    Default Re: ssh permission denied

    On Mon, 15 Aug 2011 20:36:02 +0530, imterpsfan2
    <imterpsfan2@no-mx.forums.opensuse.org> wrote:

    >
    > I am trying to connect to my web host via ssh. I can do this on Windows
    > using Putty without issue. However, if I run this on Linux, I receive a
    > "permission denied" when I am prompted for my login and password. It's
    > obviously making some type of connection, otherwise it wouldn't be
    > prompting me for authentication.
    >
    > I initially thought this was a firewall issue. I opened up port 22 and
    > I even tried disabling the firewall altogether. However, I still
    > received this error.
    >
    > Online I have seen all kinds of resolutions, but not sure where to
    > start first.
    >
    > I have openSuse 11.3 64-bit.
    >
    > Any other information I will be happy to provide.
    >


    are you sure you are asked for name and password when trying to login? if
    you don't specify a username for your SSH session, it will try to connect
    using your user name of the present openSUSE session; and most likely that
    isn't the same user name you have at your webhost.

    to login via SSH using a different user name, you have to type

    "SSH <webhost username>@<webhost address>"

    then it will ask you for the password that _that_ username uses. otherwise
    it'll try to connect as your user name on your linux machine, which is
    likely wrong.

    --
    phani.

  3. #3
    Join Date
    Mar 2009
    Location
    sri mayapur, west bengal, india
    Posts
    958

    Default Re: ssh permission denied

    On Mon, 15 Aug 2011 20:42:06 +0530, phanisvara <listmail@phanisvara.com>
    wrote:

    > On Mon, 15 Aug 2011 20:36:02 +0530, imterpsfan2
    > <imterpsfan2@no-mx.forums.opensuse.org> wrote:
    >
    >>
    >> I am trying to connect to my web host via ssh. I can do this on Windows
    >> using Putty without issue. However, if I run this on Linux, I receive a
    >> "permission denied" when I am prompted for my login and password. It's
    >> obviously making some type of connection, otherwise it wouldn't be
    >> prompting me for authentication.
    >>
    >> I initially thought this was a firewall issue. I opened up port 22 and
    >> I even tried disabling the firewall altogether. However, I still
    >> received this error.
    >>
    >> Online I have seen all kinds of resolutions, but not sure where to
    >> start first.
    >>
    >> I have openSuse 11.3 64-bit.
    >>
    >> Any other information I will be happy to provide.
    >>

    >
    > are you sure you are asked for name and password when trying to login?
    > if you don't specify a username for your SSH session, it will try to
    > connect using your user name of the present openSUSE session; and most
    > likely that isn't the same user name you have at your webhost.
    >
    > to login via SSH using a different user name, you have to type
    >
    > "SSH <webhost username>@<webhost address>"
    >
    > then it will ask you for the password that _that_ username uses.
    > otherwise it'll try to connect as your user name on your linux machine,
    > which is likely wrong.
    >


    sorry, that's "ssh <webhost username>@<webhost address>" without capitals,
    of course.

    --
    phani.

  4. #4
    Join Date
    Apr 2009
    Location
    Annapolis, MD
    Posts
    204

    Default Re: ssh permission denied

    The way I was using ssh was this way:

    ssh <domain name>

    like

    ssh somebody.somecompany.com

    Then it prompts me for user name: I type the <username>.

    Then it prompts me for password: I type <password>.

    On Windows, it authenticates me and sends me to the command prompt of the target server. On Linux, I get the message "permission denied."

    I'll try this method to see if it works....SSH <webhost username>@<webhost address>"

  5. #5
    Join Date
    Mar 2009
    Location
    sri mayapur, west bengal, india
    Posts
    958

    Default Re: ssh permission denied

    On Mon, 15 Aug 2011 21:56:02 +0530, imterpsfan2
    <imterpsfan2@no-mx.forums.opensuse.org> wrote:

    > ssh somebody.somecompany.com
    > Then it prompts me for user name: I type the <username>.


    strange, on openSUSE, when i type just "ssh whatever.com", it never asks
    me for a user name, but tries to log in with the name i have in the
    openSUSE session. don't remember how that used to work on windows.

    --
    phani.

  6. #6

    Default Re: ssh permission denied

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1

    > strange, on openSUSE, when i type just "ssh whatever.com", it never
    > asks me for a user name, but tries to log in with the name i have in
    > the openSUSE session. don't remember how that used to work on windows.


    It doesn't work on windows; putty always prompts you.

    Good luck.




    - --
    Want to yell at me in person?
    Come to BrainShare 2011 in October: http://tinyurl.com/brainshare2011
    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v2.0.15 (GNU/Linux)
    Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

    iQIcBAEBAgAGBQJOSVQ/AAoJEF+XTK08PnB5ZUwQALWEr9J3MzSepeJh+9e7g9ap
    TSxW2PbGGqny/CkcRTCNWVuPCZh4LMKvrs+ZzLfXJndAdIFQVwRZyeii4lWD+H6z
    +Th86oDSAxKCCTZLy5yfI7Q6qS/n5lqg6CUxa7ueqwbi7yYOJjcUvcb6bhDtgNUV
    YmRbEUc0D7FbFCPHt3czOcq5t9g8gKlrzvbBSkDB8sblqMYRhQqiu3nM4vW+67LA
    X5DHXqZoi+5V735ynW10PGF1iz9mdrNBro82jyx3g51+YasqVkrnrHz5UxxOlKSJ
    WT0mz1033FPoMVSqSngri8E8ob9T3quWnDaPt18rQDrMbF1NiyYX2Vmz9nW1bLVL
    Gyqk23Cw/2wRfbcq88FPrv/ehR2tZq3KbPoxPxEEQXfabrSDktUWu1K6Cyn3EzQP
    0Y9C8zQTqUIMzA1eWprLIIQC6HplfQ8VruixrhTY/8m8ReG3+3Jrb1I3aqZf1KxR
    wNkbI7iW32Bmj4wnp9ZUQ1NbMainx4Q2yot9dwCXaOErRUoIgracHDtH1OqbVseH
    aHgqPN9qzaeCPyvd0fMgQvOSM92ZthwspT7+kBlPOCkv3wMHjzQl5Xfwx9QQlqF2
    37hy1g487Yf28LIiQ6PFCSvvDIM8/iTV40/rv9kukOYge4cWQCC8sTCQ2QppUHD2
    R5ZHJuL+v2/BlCxCmm+d
    =DIaU
    -----END PGP SIGNATURE-----

  7. #7
    Join Date
    Jun 2008
    Location
    Groningen, Netherlands
    Posts
    19,763
    Blog Entries
    14

    Default Re: ssh permission denied

    Code:
    ssh -l `REMOTE_USER_NAME` `REMOTE_HOST_OR_REMOTE_IP` [ -p `REMOTE_SSH_PORT]`
    is the syntax I use most of the time.
    ° Appreciate my reply? Click the star and let me know why.

    ° Perfection is not gonna happen. No way.

    https://en.opensuse.org/openSUSE:Board#Members
    http://en.opensuse.org/User:Knurpht
    http://nl.opensuse.org/Gebruiker:Knurpht

  8. #8

    Default Re: ssh permission denied

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1

    Yeah, and that works, but I personally find it easier (and easier for
    others to read) to do the format with the '@' in the middle:

    ssh ab@mybox0.tld

    Good luck.




    On 08/15/2011 03:16 PM, Knurpht wrote:
    >
    > Code: --------------------
    >
    > ssh -l `REMOTE_USER_NAME` `REMOTE_HOST_OR_REMOTE_IP` [ -p
    > `REMOTE_SSH_PORT]`
    >
    > --------------------
    >
    > is the syntax I use most of the time.
    >
    >


    - --
    Want to yell at me in person?
    Come to BrainShare 2011 in October: http://tinyurl.com/brainshare2011
    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v2.0.15 (GNU/Linux)
    Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

    iQIcBAEBAgAGBQJOSZCFAAoJEF+XTK08PnB5/lMQAMThNEvbIdQtjpIF9lEOFf/X
    DeNAZcmiyHkIYb51j+fyUdjPgYZ11+aajygGjD9ffLZf2qkVtEADaGeSJL55DmDa
    Wl0KOKICbyF7/iFWswgkSJERj51zwKgcbrKigsiWfl96fEIgYcCaD0hADeG3Xzq9
    Jzo4lF9WriOMheHAJ+dkrlKEttPoiEfGPaZAu8R4lUBHCAQ9aRyoavsOHeoTkzo+
    vCY6EGtRWwxDt9847bexxi9g+Ggz5XkPwLcca9D+fdxY4hO4xnCXxi9Ey8RuPmJh
    xnW8oaotr0hfJ8X8uxsGBmVCqXtLKv9SGpLe8TPZx0Mma3ylRWWYABW1p8pBXquO
    7j9zGj/IpVEMEvf6acNEqxURUV9E60STZAVdvZyN+i5SkZp4a4msKbEt80TIxLtl
    0SfQjpza/zCEDVTCDBIX1LCJk8rCsECvZliVMh3wkvnQqschqX9vlfxZvlWMT7XH
    1FBm14Kzlyxz8/xP1CVhulOKIgHPc+1PSP6ZjAPh+xNI0HEs44B7G1JeMwVX47ps
    BBcK7DDI9KYlGBLj7jjYNtO1OssdEmWw22/ykXxA0s52MQNHUTW3+N7CG9/OOZ8F
    gYvvT3RoMba+2vYJvkBtQ/GEywU4wdgLaVcG4RWQzuLRjpBp+1Ves4NNHUHm8bim
    xX+S3yrEgbL6RW4rUwgS
    =S8UZ
    -----END PGP SIGNATURE-----

  9. #9
    Join Date
    Jul 2008
    Location
    Seattle, WA
    Posts
    17,048

    Default Re: ssh permission denied

    On Mon, 15 Aug 2011 21:33:09 +0000, ab wrote:

    > Yeah, and that works, but I personally find it easier (and easier for
    > others to read) to do the format with the '@' in the middle:
    >
    > ssh ab@mybox0.tld


    I find it easier to put the user info in the ~/.ssh/config file - then I
    can assign a name to it so I can just do:

    ssh configname

    And it connects with the user (and options) I want to default to for that
    name.

    But back to the OP's question....

    imterpsfan2: If you enter:

    nslookup hostname.of.your.host

    or

    ping hostname.of.your.host

    Do you get the expected IP address? What I'm wondering is if you're
    somehow connecting to a different host inadvertently.

    Jim
    --
    Jim Henderson
    openSUSE Forums Administrator
    Forum Use Terms & Conditions at http://tinyurl.com/openSUSE-T-C

  10. #10
    Join Date
    Apr 2009
    Location
    Annapolis, MD
    Posts
    204

    Default Re: ssh permission denied

    I was able to connect using the username@webaddress syntax. The mistake I made was trying to use the ssh command the same way I had used Putty on Windows.

    Thanks for your replies.

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •