Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #243542

Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG

From Andy Smith <andy@strugglers.net>
Newsgroups linux.debian.user
Subject Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG
Date 2021-12-30 18:10 +0100
Message-ID <DA769-7gz-9@gated-at.bofh.it> (permalink)
References <DA48h-5fq-1@gated-at.bofh.it> <DA5nH-69A-1@gated-at.bofh.it> <DA5QK-6jw-15@gated-at.bofh.it> <DA6Wu-6Y4-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Marco,

On Thu, Dec 30, 2021 at 05:49:38PM +0100, Marco Möller wrote:
> As my aim is to interactively run the same commands on several machines, in
> order to observe if they everywhere behave the same or what different
> results they would produce, does each SSH session report back to Ansible the
> console output of the command, or allow interactivity with the session like
> answering questions at the console if the command would produce a question,
> as tmux allows such interactivity? Or is Ansible thought to send
> non-interactive commands which are supposed to not write output back to a
> visible console?

While dsh or Ansible ad-hoc commands would report back the output,
Ansible won't work for / isn't designed for interactive use and it
would be quite awkward in dsh too. Wouldn't work for full terminal
applications and the like. So config management, ssh multilaunchers
and shell loops aren't the right topol for this.

If all you want to do is launch the same command everywhere, it's
pretty simple in tmux. Get all your logins in different panels and
then synchronize them so the same command is launched in all. Then
unsync to go through and interact individually again.

    https://stackoverflow.com/questions/16325449/how-to-send-a-command-to-all-panes-in-tmux

Basically you are wanting a scriptable full terminal, so tmux fits
the bill I think. You can remote control it from outside in many
ways to get it to do what you want.

Cheers,
Andy

-- 
https://bitfolk.com/ -- No-nonsense VPS hosting

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[OT] sending command to multiple SSH sessions, like in mRemoteNG Marco Möller <talby@debianlists.mobilxpress.net> - 2021-12-30 15:00 +0100
  Re: [OT] sending command to multiple SSH sessions, like in  mRemoteNG Celejar <celejar@gmail.com> - 2021-12-30 15:20 +0100
    [SOLVED]: [OT] sending command to multiple SSH sessions, like in  mRemoteNG Marco Möller <talby@debianlists.mobilxpress.net> - 2021-12-30 22:20 +0100
  Re: [OT] sending command to multiple SSH sessions, like in  mRemoteNG Charles Curley <charlescurley@charlescurley.com> - 2021-12-30 15:40 +0100
    [SOLVED]: [OT] sending command to multiple SSH sessions, like in  mRemoteNG Marco Möller <talby@debianlists.mobilxpress.net> - 2021-12-30 22:40 +0100
  Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG Anssi Saari <as@sci.fi> - 2021-12-30 16:20 +0100
    Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG Andy Smith <andy@strugglers.net> - 2021-12-30 16:50 +0100
      Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG Nicholas Geovanis <nickgeovanis@gmail.com> - 2021-12-30 17:40 +0100
        [SOLVED]: [OT] sending command to multiple SSH sessions, like in  mRemoteNG Marco Möller <talby@debianlists.mobilxpress.net> - 2021-12-30 22:40 +0100
      Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG Marco Möller <talby@debianlists.mobilxpress.net> - 2021-12-30 18:00 +0100
        Re: [OT] sending command to multiple SSH sessions, like in mRemoteNG Andy Smith <andy@strugglers.net> - 2021-12-30 18:10 +0100
          [SOLVED]: [OT] sending command to multiple SSH sessions, like in  mRemoteNG Marco Möller <talby@debianlists.mobilxpress.net> - 2021-12-30 21:30 +0100

csiph-web