• thorhop@sopuli.xyz
    link
    fedilink
    arrow-up
    0
    ·
    edit-2
    11 days ago

    Op is a bit confused, but here’s a primer first:

    SSH stands for Secure SHell and is a protocol to logon to a terminal shell via network.

    You need to have an SSHd (or Secure SHell Daemon i.e a background service) running to accept and facilitate connections.

    Systemd is a suite of services and tools that manage a Linux system, like a init system, service management, handing run levels, socket management, logging etc and gives the user tools like systemctl, journalctl, bootctl, basically anything ending with ctl is conventionally a systemd tool for users to manage their systems with.

    Get it? Got it? Good.

    systemd.autossh is an embedded ssh client in systemd that tries to help in reestablishing dropping connections. It does not actually start an SSHd (the actual service that facilitates connections) and is embedded for convenience to minimize frustrations with dropping connections.

    You can read about it here.

    • chuso@fedia.io
      link
      fedilink
      arrow-up
      1
      ·
      10 days ago

      No, it seems you are a bit confused.

      You are talking about autossh, which is a completely different third-party SSH client tool that you have to install separately (as the link you shared describes) to have persistent SSH client connections and has nothing to do with systemd other than that you can start it as a systemd service (like any other third-party service).

      OP is talking about systemd-ssh-generator, which is described here by Lennart Poettering (author of systemd) as working exactly as OP described it.

    • MyBrainHurts@piefed.ca
      link
      fedilink
      English
      arrow-up
      1
      ·
      11 days ago

      Heya thanks so much for that explanation, took a couple read throughs and some thinking but I think I get it!

      The time ans thought you put into that are much appreciated and so emblematic of the awesome nature of the linux world.

      Thanks again!

      • JollyG@lemmy.world
        link
        fedilink
        arrow-up
        1
        ·
        11 days ago

        Every day I wake up and think to myself “today is the day I will form a strong opinion about systemd” but it never happens.

      • toothpaste_sandwich@thebrainbin.org
        link
        fedilink
        arrow-up
        1
        ·
        11 days ago

        Given that it helps with ssh client connections and sshd is, basically, a server—yes. And even then, I imagine it doesn’t actually do anything if there’s no ssh connection.