[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Why does my ssh session terminate immediately?



Guido Martínez <mtzguido@gmail.com> writes:

> Hi,
>
> On Mon, Apr 22, 2013 at 5:49 PM, Andreas Leha
> <andreas.leha@med.uni-goettingen.de> wrote:
>> thanks for that.  Here is what I get:
>> ,----
>> | + '[' -z '' ']'
>> | + return
>> | Connection to 192.168.2.109 closed.
>> `----
>> I guess that means, that "PS1" is unset in this case?
>
> Looks like it, but I think that it shouldn't terminate bash anyway.
> The 'return' you see is local to .bashrc or whatever file was being
> loaded.
>
> Try running 'ssh root@192.168.2.109 bash --norc --noprofile -i' and
> see if you get a shell. If you do, it would suggest some
> misconfiguration of bash but from what I can see your configs are OK..

Here is what I get:
,----
| > ssh root@192.168.2.109 bash --norc --noprofile -i
| bash: cannot set terminal process group (-1): Invalid argument
| bash: no job control in this shell
`----
or:
,----
| > ssh -t root@192.168.2.109 bash --norc --noprofile -i
| Connection to 192.168.2.109 closed.
`----


Regards,
Andreas


Reply to: