<br><tt><font size=2>freenx-knx-bounces@kde.org wrote on 02/05/2013 08:27:03:<br>
[SNIP]</font></tt>
<br><tt><font size=2><br>
> >You can best test your ssh from the FreeNX server <br>
> > using the line of NX code ( with "your-user-name-here
added" ) <br>
>> <br>
> ><br>
>> ssh -2 -x -l "your-user-name-here" 127.0.0.1 -o
"NumberOfPasswordPrompts 1" -p 22 <br>
</font></tt>
<br><tt><font size=2>> <br>
> This proved to be helpful. I could SSH into the server, but
I <br>
> couldn't SSH locally on the server. I checked my logs and found
this:<br>
[SNIP]</font></tt>
<br><tt><font size=2>> opened for user nx by (uid=0)<br>
> May 2 01:01:54 chi nxserver[10860]: (nx) Failed login for <br>
> user=[username] from IP=[myip]<br>
> May 2 01:01:54 chi sshd[10619]: pam_unix(sshd:session): session
<br>
> closed for user nx<br>
> <br>
> SSH would instantly close when I tried it locally with the following
errors:<br>
> <br>
> Connection closed by ::1<br>
> Connection closed by 127.0.0.1<br>
> <br>
> So, to fix it, I commented all the IPv6 lines from the hosts file,
<br>
> and removed some huge long lines that spanned forever that were <br>
> added for all of the websites I host so that I can access them <br>
> locally by using the hosts file. This is done automatically
by the <br>
> software I use. I guess the length was so long, it corrupted
<br>
> things. I have since turned this feature off.<br>
> <br>
> Thanks for the help!<br>
</font></tt>
<br><tt><font size=2>This is caused by localhost becoming ::1
i.e. IPv6</font></tt>
<br>
<br><tt><font size=2>If you aren't IPv6-ing to ssh you can try</font></tt>
<br><tt><font size=2> </font></tt>
<br><tt><font size=2> AddressFamily
inet</font></tt>
<br><tt><font size=2> </font></tt>
<br><tt><font size=2>in sshd_config</font></tt>
<br><tt><font size=2>to</font></tt>
<br><tt><font size=2>pin sshd to IPv4</font></tt>
<br><tt><font size=2>else</font></tt>
<br><tt><font size=2>disable IPv6 in </font></tt>
<br>
<br><tt><font size=2> /etc/sysctl.conf</font></tt>
<br>
<br><tt><font size=2>net.ipv6.conf.all.disable_ipv6 = 1</font></tt>
<br><tt><font size=2>net.ipv6.conf.default.disable_ipv6 = 1</font></tt>
<br>
<br>
<br>
<br>
<br>