<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <p>Hello Matthias,</p>
    <p>Thank you for your quick reply! This will work for me.</p>
    <p>Is there a way to add an "after upgrade script" to run
      automatically? So maybe add a custom step to the upgrade
      procedure?<br>
    </p>
    <p>Regards,</p>
    <p>Henk<br>
    </p>
    <div class="moz-cite-prefix">On 28-Apr-22 17:34, Matthias Hohl
      wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:1142575761.1448965.1651160091142.JavaMail.zimbra@mx">
      
      <meta name="Generator" content="Microsoft Word 15 (filtered
        medium)">
      <style>@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}span.E-MailFormatvorlage19
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}div.WordSection1
        {page:WordSection1;}</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
      <div class="WordSection1">
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US">Hello
            Henk,<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">we had the same topic after migration to 9.5.x
            on PRO version and we solved it with an “after upgrade
            script” and symlinks.<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">The files inside the directory
            /etc/ngcp-config/ will not be removed after upgrade, so we
            placed the config files there and installed the software and
            create the symlinks to the files in our “telematica”
            directory.<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">I hope I could help you with this work-a-round.<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">For an example with fail2ban we did it this
            way:<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">### Fetch latest packages and create
            directories<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">apt-get update<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">mkdir /ngcp-data/telematica<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">### Install Packages<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">apt-get install -y fail2ban<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">echo "fail2ban installed"<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">### Create Fail2Ban Symlinks<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">ln -s
            /etc/ngcp-config/telematica/fail2ban/jail.local
            /etc/fail2ban/jail.local<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">ln -s
            /etc/ngcp-config/telematica/fail2ban/fail2ban.local
            /etc/fail2ban/fail2ban.local<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">ln -s
            /etc/ngcp-config/telematica/fail2ban/filter.d/kamailio-lb.local
            /etc/fail2ban/filter.d/kamailio-lb.local<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">ln -s
            /etc/ngcp-config/telematica/fail2ban/filter.d/kamailio-proxy.local
            /etc/fail2ban/filter.d/kamailio-proxy.local<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">echo "fail2ban configured"<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">systemctl restart fail2ban<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US">#<o:p></o:p></span></p>
        <p class="MsoNormal"><span style="mso-fareast-language:EN-US" lang="EN-US"><o:p> </o:p></span></p>
        <div>
          <div style="border:none;border-top:solid #E1E1E1
            1.0pt;padding:3.0pt 0cm 0cm 0cm">
            <p class="MsoNormal"><b><span lang="DE">Von:</span></b><span lang="DE"> Henk <a class="moz-txt-link-rfc2396E" href="mailto:henkpls@hotmail.com"><henkpls@hotmail.com></a> <br>
                <b>Gesendet:</b> Donnerstag, 28. April 2022 17:28<br>
                <b>An:</b> <a class="moz-txt-link-abbreviated" href="mailto:spce-user@lists.sipwise.com">spce-user@lists.sipwise.com</a><br>
                <b>Betreff:</b> [Spce-user] A/B upgrade schema, how to
                keep custom installed software<o:p></o:p></span></p>
          </div>
        </div>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal">Hi all,<br>
          <br>
          I just upgraded to mr9.5.4 and noticed that the A/B upgrade
          schema takes <br>
          a lot of extra work to reinstall all software that disappears
          when <br>
          upgrading. For example I'm using letsencrypt; fail2ban and
          ipset <br>
          (ipset-blacklist), which is very useful to block unwanted
          scanners.<br>
          <br>
          Is there an easy way to keep those extra programs?<br>
          <br>
          Also it would be nice to have some documentation on how to
          rollback the <br>
          system to a previous version.<br>
          <br>
          Regards,<br>
          <br>
          Henk Plessius<br>
          <br>
          <br>
          -- <br>
          Spce-user mailing list<br>
          <a href="mailto:Spce-user@lists.sipwise.com" moz-do-not-send="true" class="moz-txt-link-freetext">Spce-user@lists.sipwise.com</a><br>
          <a href="http://lists.sipwise.com/mailman/listinfo/spce-user_lists.sipwise.com" moz-do-not-send="true" class="moz-txt-link-freetext">http://lists.sipwise.com/mailman/listinfo/spce-user_lists.sipwise.com</a><o:p></o:p></p>
      </div>
    </blockquote>
  </body>
</html>