[Nix-dev] Delays on ssh connection

Carles Pagès page.lists at gmail.com
Mon Feb 16 09:01:30 CET 2015


It was on 14.12 rev139ead2, and I don't think my configuration.nix has
anything special. I later updated to latest 14.12 from channel and had
to reboot with 'alt+sysreq+b', since not even a proper reboot would
work, with such a message:
feb 13 14:36:04 pica systemd[1]: Requested transaction contradicts
existing jobs: Transaction is destructive.

Anyway, I'll report back if it happens again. Thanks!

2015-02-13 12:18 GMT+01:00 Wout Mertens <wout.mertens at gmail.com>:
> Weird - what branch are you on? Anything special in you configuration.nix?
> Sounds like a bug somewhere but could be anything. I have no idea what
> causes that "connection timed out" for the session creation if it's not DNS.
>
> You could try picking a different nixpkgs commit and see if your system is
> stable there.
>
> Wout.
>
> On Wed Feb 11 2015 at 12:43:29 PM Carles Pagès <page.lists at gmail.com> wrote:
>>
>> It also happens if I ssh to localhost, so I don't think it's the same.
>> I forgot to mention that systemd is consuming a lot of cpu (top shows
>> ~15% constantly).
>>
>> 2015-02-11 11:28 GMT+01:00  <emil.rangden at chas.se>:
>> > On 2015-02-11 9:57, Carles Pagès wrote:
>> >> Hi all,
>> >>
>> >> My system (nixos 14.12.231.139ead2) is in a state that, when
>> >> connecting through ssh there is a delay of ~30s. It happened to me a
>> >> while ago and was 'solved' with a reboot.
>> >>
>> >> Looking at the logs, I see:
>> >> feb 10 09:33:03 pica sshd[9346]: pam_unix(sshd:session): session
>> >> opened for user xxx by (uid=0)
>> >> feb 10 09:33:03 pica systemd-logind[1748]: New session 66 of user xxx.
>> >> feb 10 09:33:28 pica sshd[9346]: pam_systemd(sshd:session): Failed to
>> >> create session: Connection timed out
>> >>
>> >> Also, the log is full of:
>> >> feb 10 09:33:04 pica systemd[1]: Looping too fast. Throttling
>> >> execution a little.
>> >>
>> >> Seems like there is something wrong with systemd. Trying to look for
>> >> an explanation, I've found people commenting on similar issues that
>> >> were triggered by systemd crashes, but not exactly what I see.
>> >>
>> >> Going back in the log, the 'throttling' starts to appear after this:
>> >> feb 09 02:15:01 pica
>> >> /nix/store/8xg2yyyj651nik95lqmwza4xn0h7d7na-cron-4.1/bin/cron[24928]:
>> >> (root) CMD (/nix/store/8iq0r1d7na-cron-4.1/bin/cron[24928]: (root) CMD
>> >> (/nix/store/8iq0r1l97dzcsvkv33zg465gxlsx56dl-systemd-217/bin/systemctl
>> >> start ul97dzcsvkv33zg465gxlsx56dl-systemd-217/bin/systemctl start
>> >> update-locatedb.service)
>> >>
>> >> Though there's previous executions of that cron task that didn't
>> >> trigger the issue.
>> >>
>> >> Any clues on what might be wrong and/or how to solve this?
>> >> _______________________________________________
>> >> nix-dev mailing list
>> >> nix-dev at lists.science.uu.nl
>> >> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>> >
>> > Might not at all be what you are looking for, but I had a similar
>> > problem
>> > with nixos-containers. It was 'solved' by telling sshd not to do any dns
>> > lookups with something like
>> >
>> >    services = {
>> >      openssh = {
>> >        enable = true;
>> >        extraConfig =
>> >          ''
>> >            UseDNS no
>> >          '';
>> >    };
>> >
>> > _______________________________________________
>> > nix-dev mailing list
>> > nix-dev at lists.science.uu.nl
>> > http://lists.science.uu.nl/mailman/listinfo/nix-dev
>> _______________________________________________
>> nix-dev mailing list
>> nix-dev at lists.science.uu.nl
>> http://lists.science.uu.nl/mailman/listinfo/nix-dev


More information about the nix-dev mailing list