On 12/14/18 00:27, ???????????????????????? wrote: > Hello, > I've got a PC running OpenBSD current. > After the latest upgrade I cannot ssh to it. > > When I run "ssh 10.26.5.70" > I get this: > "Connection to 10.26.5.70 closed by remote host. > Connection to 10.26.5.70 closed." > As an SSH client I use another OpenBSD box and a Linux machine > with the same result. > When I run "ssh -vvv 10.26.5.70" > the last messages are: > > "debug3: receive packet: type 52 > debug1: Authentication succeeded (publickey). > Authenticated to 10.26.5.70 ([10.26.5.70]:22). > debug1: channel 0: new [client-session] > debug3: ssh_session2_open: channel_new: 0 > debug2: channel 0: send open > debug3: send packet: type 90 > debug1: Requesting no-more-sessi...@openssh.com > debug3: send packet: type 80 > debug1: Entering interactive session. > debug1: pledge: network > debug3: send packet: type 1 > debug1: channel 0: free: client-session, nchannels 1 > debug3: channel 0: status: The following connections are open: > #0 client-session (t3 nr0 i0/0 o0/0 e[write]/0 fd 4/5/6 sock -1 cc -1) > > debug3: fd 1 is not O_NONBLOCK > Connection to 10.26.5.70 closed by remote host. > Connection to 10.26.5.70 closed. > Transferred: sent 2644, received 1932 bytes, in 0.0 seconds > Bytes per second: sent 1085498.2, received 793185.5 > debug1: Exit status -1" > > > No errors in /var/log/daemon > No errors in /var/log/authlog > > The result doesn't depend on the user which I use to login.
I have seen SSH server immediately closing connection in the following setting: I run Alpine Linux as a XEN dom0 host in production on several moderately large physical machines (256 GB of RAM, 44 cores, and a dozen or so DomU guests on the dedicated block devices). By default Dom0 instance of Alpine is provision with 256 MB of RAM regardless of the RAM size of the physical host. That amount of RAM is typically sufficient for hypervisor itself + one or two micro instances. Once you try to spin a larger DomU instance SSH server running on Dom0 host will reproducibly close connection when you try to ssh to it due to the insufficient RAM. First time I got bitten by this behavior it took me a long time to understand what was happening. Namely, I typically provision at least 4GB of RAM for Dom0 host in /boot/extlinux.conf. However that file gets overwritten with the default options every time one runs apk update apk upgrade As soon as one reboots the box after the update (new /boot/extlinux.conf unedited is used with 256MB of RAM for Dom0) SSH server on Dom0 starts to close connection. I have no idea about your set up (if your SSH server runs on the physical or virtual host) and my experience might seems completely unrelated to your question at first. However it would be worth looking at the RAM consumption of your SSH server when it starts misbehaving. It sounded like the set up you currently have worked before you upgraded to current. That might have been the case and the current misbehavior might have been trigger by new higher RAM requirement of the OpenBSD 6.4 current. It also occurred to me that you might be using non amd64 image like the one needed for EdgeRouter Lite (which I like to use for our remote offices). The EdgeRouters I have come with 512MB of RAM. It is very plausible that if you run something like IPsec (site-to-site) tunnel or non-caching web proxy from such box you are running out of RAM and that manifests in SSH server closing on you. In my experience 6.4 runs like a champ on EdgeRouters in the role of pure firewall. Most Kind Regards, Predrag