Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    Duet Pi Regression - How?

    Scheduled Pinned Locked Moved
    Beta Firmware
    3
    34
    1.3k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Danalundefined
      Danal @A Former User
      last edited by Danal

      @bearer said in Duet Pi Regression - How?:

      and purging duetsd will clear out the whole /opt/dsf/sd folder configs, macros, gcode, everything.

      Agreed. I'm now on the warpath to avoid 'apt purge'.

      'apt remove' only removes things in the package manifest, and deletes empty directories. If non empty, it will leave them. I believe the one time I regressed (by a manual method) that everything stayed intact, EXCEPT config.g had been overlaid with the empty-ish distribution copy. All other files, like tfree and tpost and so forth, and macros, they were all intact.

      1 Reply Last reply Reply Quote 0
      • Danalundefined
        Danal @A Former User
        last edited by

        @bearer said in Duet Pi Regression - How?:

        @Danal said in Duet Pi Regression - How?:

        Why is that 95%? Or what is the 5% edge case?

        oh, and there is something weird with the reprapfirmeware n.n.n.n-1 and n.n.n.n-999 dependenices for otherwise identical versions. so i ignore the 999 in the rexeg

        Me too.

        1 Reply Last reply Reply Quote 0
        • Danalundefined
          Danal
          last edited by

          With regard to "how to recurse" without depending on the exact structure of the package, this seems to work, then parse the "depends" line:

          apt show duetsoftwareframework=1.2.3.0
          Package: duetsoftwareframework
          Version: 1.2.3.0
          Priority: standard
          Section: electronics
          Maintainer: Duet3D Packaging Authority <pkg@duet3d.com>
          Installed-Size: unknown
          Depends: duetcontrolserver (= 1.2.3.0), duetsd (= 1.0.5), duettools (= 1.2.3.0), duetwebserver (= 1.2.1.0), duetwebcontrol (= 2.0.4-1), reprapfirmware (>= 1.2.3.0-1), reprapfirmware (<= 1.2.3.0-999)
          Homepage: https://pkg.duet3d.com
          Vcs-Git: https://github.com/chrishamm/DuetSoftwareFramework.git
          Download-Size: 1,710 B
          APT-Manual-Installed: yes
          APT-Sources: https://pkg.duet3d.com unstable/armv7 armhf Packages
          Description: Meta package for the full Duet software framework
          
          A Former User? 1 Reply Last reply Reply Quote 0
          • A Former User?
            A Former User @Danal
            last edited by A Former User

            @Danal said in Duet Pi Regression - How?:

            this seems to work,

            missing duetruntime which is why i turne to recusion that ultimately failed if left run to to all the leaf nodes.

            1 Reply Last reply Reply Quote 0
            • Danalundefined
              Danal
              last edited by

              Hmmm... I wonder how it gets installed? With no dependency?

              A Former User? 1 Reply Last reply Reply Quote 0
              • A Former User?
                A Former User @Danal
                last edited by A Former User

                @Danal said in Duet Pi Regression - How?:

                I wonder how it gets installed? With no dependency?

                duetcontrolserver has it as a dependency iirc (thus the recursion)

                1 Reply Last reply Reply Quote 0
                • Danalundefined
                  Danal
                  last edited by

                  Ah, light bulb just came on. Thank you.

                  1 Reply Last reply Reply Quote 0
                  • Danalundefined
                    Danal
                    last edited by

                    And, by the way, autopurge (which I am NOT going to use) actually does not purge the recursive stuff after a

                    sudo apt install duetsoftwareframework=1.2.3.0 duetcontrolserver=1.2.3.0 duetruntime=1.2.3.0 duetsd=1.0.5 duettools=1.2.3.0 duetwebserver=1.2.1.0 duetwebcontrol=2.0.4-1 reprapfirmware=1.2.3.0-1

                    style install, and an apt remove duetsoftwareframework.

                    So.... it would not have worked anyway.

                    A Former User? 1 Reply Last reply Reply Quote 0
                    • gtj0undefined
                      gtj0
                      last edited by

                      Just switch to RPM 😂

                      A Former User? Danalundefined 2 Replies Last reply Reply Quote 1
                      • A Former User?
                        A Former User @gtj0
                        last edited by A Former User

                        @gtj0 said in Duet Pi Regression - How?:

                        Just switch to RPM 😂

                        +2

                        was wondering if aptitude* would be better suited, but decided to brush up on regex instead 😇

                        *) not better than RPM..

                        1 Reply Last reply Reply Quote 2
                        • Danalundefined
                          Danal @gtj0
                          last edited by

                          @gtj0 said in Duet Pi Regression - How?:

                          Just switch to RPM 😂

                          How about //STEP1 EXEC PGM=SMPE? It handled prereqs, coreqs, and even postreqs flawlessly. Why, I've heard you could build and entire OS with it!

                          1 Reply Last reply Reply Quote 1
                          • A Former User?
                            A Former User @Danal
                            last edited by

                            @Danal said in Duet Pi Regression - How?:

                            and an apt remove duetsoftwareframework.

                            apt remove duet* reprapfirmware is about the same length and oddly more specific. would work with remove and purge for that matter.

                            Danalundefined 1 Reply Last reply Reply Quote 0
                            • Danalundefined
                              Danal @A Former User
                              last edited by

                              @bearer said in Duet Pi Regression - How?:

                              @Danal said in Duet Pi Regression - How?:

                              and an apt remove duetsoftwareframework.

                              apt remove duet* reprapfirmware is about the same length and oddly more specific. would work with remove and purge for that matter.

                              Yah, I thought about the nicely structured names. As you said though, if the package changes...

                              A Former User? 1 Reply Last reply Reply Quote 0
                              • A Former User?
                                A Former User @Danal
                                last edited by

                                @Danal said in Duet Pi Regression - How?:

                                As you said though, if the package changes...

                                then it has a greater chance of catching it as duetruntime still doesn't depend on duetsoftwareframework.

                                and if apt remove duetcontrolserver duetruntime duetsd duetsoftwareframework duettools duetwebcontrol duetwebserver reprapfirmware is the alternative then it needs to be updated anyways.

                                to be honest I have more faith in a * than apt and dependencies defined for the packages should autoremove fail.

                                1 Reply Last reply Reply Quote 0
                                • Danalundefined
                                  Danal
                                  last edited by Danal

                                  OK, here is a "first draft" that works. Comments welcome:

                                  ./DuetRegress.sh 2.1.0
                                  Currently Installed duetsoftwareframework=
                                  Command line argument is requesting duetsoftwareframework=2.1.0
                                  Which has associated reprapfirmware of 2.1.0-1 also known as 3.01-RC9
                                  
                                  ***********************************************************************************
                                  * Note: The next step will run for a while; the script is (probably) not hung.    *
                                  ***********************************************************************************
                                  
                                  To regress to DSF version 2.1.0 which is RRF version 3.01-RC9:
                                  1) Backup your files via:
                                    mkdir ~/duetback
                                    cp -r /opt/dsf/sd/* ~/duetback
                                  or similar. Verify that the backup worked: 'ls ~/duetback' should show directories: 'filaments firmware gcodes macros sys' or similar.
                                  
                                  2) Run this command: (it is long, be sure you get it all on one line)
                                    sudo apt -y  --allow-downgrades install duetsoftwareframework=2.1.0 duetcontrolserver=2.1.0 duetruntime=2.1.0 duetsd=1.0.6 duettools=2.1.0 duetwebcontrol=2.1.4 duetwebserver=2.1.0 reprapfirmware=2.1.0-1
                                  
                                  3) Verify system is running properly, web interface opens, etc
                                  
                                  4) If Pi runs, but won't connect to Duet Board, bossa the board
                                     with the file found at /opt/dsf/sd/sys/Duet3Firmware_MB6HC.bin
                                     Instructions here:
                                     https://duet3d.dozuki.com/Wiki/Getting_Started_With_Duet_3#Section_Updating_Duet_3_main_board_firmware
                                  
                                  5) Check files like config.g, macros, etc, and restore as required.
                                  

                                  There are no name or other recursion dependencies in the script. Also, I took out the "apt remove" command, I don't believe it is required, apt will just overlay things.

                                  1 Reply Last reply Reply Quote 0
                                  • A Former User?
                                    A Former User
                                    last edited by

                                    i opted for splitting the lines so it can be easy to read and copy, or if piped/backticked its not.

                                    i'd also reconsider the -y bit gives apt a chance to complain if it feels the need.

                                    pi@raspberrypi:~ $ bash rrfdep.sh 3.01-RC9
                                    sudo apt install \
                                      duetcontrolserver=2.1.0 \
                                      duetsd=1.0.6 \
                                      duettools=2.1.0 \
                                      duetwebserver=2.1.0 \
                                      duetwebcontrol=2.1.4 \
                                      reprapfirmware=2.1.0-1 \
                                      duetsoftwareframework=2.1.0
                                    pi@raspberrypi:~ $
                                    

                                    don't think i'll put up the version that resolves it from the reprap firmware version, smells like lots of unnecessary load on servers just to save people looking up a table

                                    1 Reply Last reply Reply Quote 0
                                    • Danalundefined
                                      Danal
                                      last edited by Danal

                                      Excellent idea on the lines! I will do that. In fact, I was a bit concerned about line length... not only that, but I'm flattening a 'list' now, all I have to do is not do that.

                                      I go back and forth on the -y. Given that this is intended to be used by people who literally can't even answer the initial "Do you want me to do what you asked? [Y/n]" prompt... well... I'm inclined to leave it in.

                                      re: servers, yeah, this one is entirely local. In fact, it ought to insist on a recent (whatever that means) sudo apt update.

                                      Danalundefined A Former User? 2 Replies Last reply Reply Quote 0
                                      • Danalundefined
                                        Danal @Danal
                                        last edited by

                                        This post is deleted!
                                        1 Reply Last reply Reply Quote 0
                                        • A Former User?
                                          A Former User @Danal
                                          last edited by A Former User

                                          @Danal said in Duet Pi Regression - How?:

                                          I go back and forth on the -y. Given that this is intended to be used by people who literally can't even answer the initial "Do you want me to do what you asked? [Y/n]" prompt... well... I'm inclined to leave it in.

                                          you don't get any questions if you have all the packages specified; the one you're missing is (likely) libunwind8 (if there are questions) no idea how that snuck into anything, but the rest holds true..

                                          ref the bottom code block; no -Y and no question (also before libunwind8) https://forum.duet3d.com/post/150402

                                          1 Reply Last reply Reply Quote 0
                                          • Danalundefined
                                            Danal
                                            last edited by Danal

                                            Direct copy from your code block; don't know why it is different on your machine and mine.

                                            P.S. Given the name "lib un-wind ate" I was trying to figure out if you were making a bad pun or someting... 😉

                                             sudo apt install \
                                            >   duetcontrolserver=1.2.3.0 \
                                            >   duetruntime=1.2.3.0 \
                                            >   duetsd=1.0.5 \
                                            >   duettools=1.2.3.0 \
                                            >   duetwebserver=1.2.1.0 \
                                            >   duetwebcontrol=2.0.4-1 \
                                            >   reprapfirmware=1.2.3.0-1 \
                                            >   duetsoftwareframework=1.2.3.0
                                            Reading package lists... Done
                                            Building dependency tree
                                            Reading state information... Done
                                            The following packages will be DOWNGRADED:
                                              duetcontrolserver duetruntime duetsd duetsoftwareframework duettools duetwebcontrol duetwebserver
                                              reprapfirmware
                                            0 upgraded, 0 newly installed, 8 downgraded, 0 to remove and 0 not upgraded.
                                            Need to get 32.2 MB/32.2 MB of archives.
                                            After this operation, 0 B of additional disk space will be used.
                                            W: Sources disagree on hashes for supposely identical version '1.2.3.0' of 'duetsoftwareframework:armhf'.
                                            W: Sources disagree on hashes for supposely identical version '1.0.5' of 'duetsd:armhf'.
                                            Do you want to continue? [Y/n]
                                            
                                            A Former User? 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Unless otherwise noted, all forum content is licensed under CC-BY-SA