Skip to content

OpenSSH kicks me out just after connecting

I'm trying to connect to Arch Linux as a Virtualbox guest on a OS X host.

I've installed OpenSSH on Arch, and I think that I've configured it correctly, and I've redirected port 3022 to 22 in the virtualbox guest's network settings (using NAT connection mode), Host Port 3022 and Guest Port 22.

But I get kicked out just after I've logged in.

This is the output of ssh -vvv ran@localhost -p 3022 that is run on my host computer: http://pastebin.com/raw/ptmH3vJs

Less verbose (just one -v): http://pastebin.com/raw/mHGv770u

This is my /etc/ssh/sshd_config: http://termbin.com/dxpf

The host's hostname is ran-mpb14, the arch guest hostname is ran-arch-vb. I'm using the user ran on both machines.

Edited 6 Jun 2016. We only hold this version.

4 points6 comments
Open on Reddit
About this post
Posted
Archived
Edited
Score
4 · 100% up
Kind
Text
ID
4mtk65

Author

49
posts
253
comments
2
media
View profile

7 comments

Shot in the dark, what does

grep "ran" /etc/passwd

give you on the VM?

Sometimes a bad shell config will kick you right out of the session.

4 points
Ran4OP1 hidden

ran:x:1000:1000::/home/ran:/usr/bin/zsh

Should it be something else?

1 points

Nah looks good. I guess you should check if zsh is actually installed... but it sounds like you were using it...

2 points

What do the logs look like on the arch box in /var/log?

1 points
Ran4OP1 hidden

Is there any specific log file I should look for/in?

1 points

Arch barely uses /var/log any more.

# journalctl -u sshd -b

should give you the ssh daemon's output for the current boot.

2 points
unknown author

Deleted before we saved it.

1 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.