Skip to content

iop: ssh_upgrade: Multiple fixes and enhancements (new versions of SCP, target device model, sysupgrade parameters)

Series of commits, best reviewed one at a time.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit 800282b71aca513f97dc0f4acc2801b24cdf982f ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Sep 14 18:40:32 2022 +0200

    iop: ssh_upgrade: Use mktemp instead of tempfile
    
    The tempfile has been deprecated for a long time and is no longer
    available on RHEL and Fedora, use mktemp instead.
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>


━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit 290344c30705659e2652b7cfa1283a634dcf1842 ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Sep 14 17:21:40 2022 +0200

    iop: ssh_upgrade: Update help text
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit ee3fe2a6cf17ae304186d133fb0afe195d56641c ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Sep 14 17:12:55 2022 +0200

    iop: ssh_upgrade: Fix typos
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit c3e3ff52c5378a549b2d8f0a5a44232dd8eac3a7 ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Sep 14 17:28:01 2022 +0200

    iop: ssh_upgrade: Adapt to new image filenames
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit 58c5a2d2fa2a005afcf3cb8b2c3041ff9ca1e2c4 ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Sep 14 14:35:54 2022 +0200

    iop: ssh_upgrade: Update for new sysupgrade-params
    
    sysupgrade CLI has changed over time. Update ssh_upgrade script to
    accomodate for those changes.
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit e5c9c27186498867aa170f9b0a558b764cfbe1e4 ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Jul 20 18:12:50 2022 +0200

    iop: ssh_upgrade: Use ssh instead of scp
    
    Use SSH with a pipe to transfer the file and invoke sysupgrade in one
    go. Using SSH instead of SCP gives a higher throughput (not very
    noticable for small files like the ones we use for sysupgrade, though),
    but using only one command invocation saves a significant overhead of
    TCP and SSH connection setup.
    
    The main reason for this change is though that OpenSSH 9.0 and later
    use SFTP instead of the scp protocol when using the scp command in an
    effort of deprecating the very clunky legacy SCP protocol. One can use
    scp -O to continue using scp, but switching to ssh only has other
    benefits outlined above.
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit 7dbb1f132ed823dd2ec3034aa98b2dc116489cee ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Wed Jul 20 18:12:14 2022 +0200

    iop: ssh_upgrade: Don't hardcode subtarget to generic
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit 399f8162c6e6b970eb9f3ba405c904021566497b ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Thu Jun 9 16:54:19 2022 +0200

    iop: ssh_upgrade: Remove iopu support
    
    iopu has been removed in IOWRT 6 and has never really been supported.
    Remove any support for it in the ssh_upgrade helper script.
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
commit f0d47d5b92959ccf88db826706f75dac8f914c59 ┃
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Author: Andreas Gnau <andreas.gnau@iopsys.eu>
Date:   Thu Jun 9 17:34:31 2022 +0200

    iop: ssh_upgrade: Fix formatting using shfmt
    
    The file was formatted using a wild mix of tabs and spaces. Run shfmt on
    it to fix the formatting
    
    Signed-off-by: Andreas Gnau <andreas.gnau@iopsys.eu>
Edited by Andreas Gnau

Merge request reports