• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

Shared object "libarchive.so.7" not found, required by "pkg"

Scheduled Pinned Locked Moved General pfSense Questions
34 Posts 11 Posters 25.1k Views
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.
  • T
    tkriviradev
    last edited by tkriviradev Feb 21, 2021, 6:18 PM Feb 21, 2021, 6:15 PM

    First restore the repository file:

    /usr/local/share/pfSense/pkg/repos: cp pfSense-repo-245.conf pfSense-repo.conf
    

    Second step is to re-install pkg

    pkg bootstrap -f
    

    Third clean-up and update

    pkg clean all && pkg update
    

    if not error try

    pkg search vim # and then install whatever
    
    I 1 Reply Last reply Sep 19, 2021, 8:17 AM Reply Quote 3
    • C
      caligo-erik @Qinn
      last edited by caligo-erik Mar 31, 2021, 6:02 AM Mar 31, 2021, 5:50 AM

      @qinn said in Shared object "libarchive.so.7" not found, required by "pkg":

      Downgraded pkg

      Bumped into this post; how did you downgrade pkg?

      When I try the same command, I get:
      pkg-static: Newer FreeBSD version for package pfSense-pkg-iperf

      I am unsure whether to use the suggested " IGNORE_OSVERSION=yes " option..

      T 1 Reply Last reply Mar 31, 2021, 11:57 AM Reply Quote 0
      • S
        stephenw10 Netgate Administrator
        last edited by Mar 31, 2021, 11:07 AM

        No don't do that. You are trying to pull a version of pkg from a repo set to a different FreeBSD version. That is not the same as forcing a package downgrade within the same version.

        Steve

        A 1 Reply Last reply Apr 23, 2021, 5:45 PM Reply Quote 1
        • Q
          Qinn @Qinn
          last edited by Qinn Mar 31, 2021, 11:14 AM Mar 31, 2021, 11:10 AM

          @qinn said in Shared object "libarchive.so.7" not found, required by "pkg":

          Think I found it, the pkg package gets updated when in GUI from System/Update/System update you select "Update Latest 2.4.x development version (2.4.5)" in Branch and I did not confirm it, just selected it!

          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
          1.12.0
          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg-static install -f pkg
          Updating pfSense-core repository catalogue...
          pfSense-core repository is up to date.
          Updating pfSense repository catalogue...
          pfSense repository is up to date.
          All repositories are up to date.
          Checking integrity... done (0 conflicting)
          The following 1 package(s) will be affected (of 0 checked):
          
          Installed packages to be DOWNGRADED:
                  pkg: 1.12.0 -> 1.10.5_6 [pfSense]
          
          Number of packages to be downgraded: 1
          
          The operation will free 1 MiB.
          
          Proceed with this action? [y/N]: y
          [1/1] Downgrading pkg from 1.12.0 to 1.10.5_6...
          [1/1] Extracting pkg-1.10.5_6: 100%
          You may need to manually remove /usr/local/etc/pkg.conf if it is no longer needed.
          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
          1.10.5
          

          Selected it and...

          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
          1.12.0
          [2.4.4-RELEASE][root@pfSense.localdomain]/root:
          ``
          

          @caligo-erik but why would you do it? Just like @stephenw10 advises don't change the package manager version.

          Hardeware: Intel(R) Celeron(R) J4125 CPU @ 2.00GHz 102 GB mSATA SSD (ZFS)
          Firmware: Latest-stable-pfSense CE (amd64)
          Packages: pfBlockerNG devel-beta (beta tester) - Avahi - Notes - Ntopng - PIMD/udpbroadcastrelay - Service Watchdog - System Patches

          C 1 Reply Last reply Mar 31, 2021, 1:18 PM Reply Quote 0
          • T
            tkriviradev @caligo-erik
            last edited by Mar 31, 2021, 11:57 AM

            @caligo-erik

            If you want to stay on 2.4.5-RELEASE-p1 for a while before upgrading, make sure you go to System|Update and change your Branch to "Previous stable version". This will keep your System|Package Manager from offering Updates that may not be suitable for 2.4.5

            1 Reply Last reply Reply Quote 1
            • C
              caligo-erik @Qinn
              last edited by Mar 31, 2021, 1:18 PM

              @qinn said in Shared object "libarchive.so.7" not found, required by "pkg":

              @qinn said in Shared object "libarchive.so.7" not found, required by "pkg":

              Think I found it, the pkg package gets updated when in GUI from System/Update/System update you select "Update Latest 2.4.x development version (2.4.5)" in Branch and I did not confirm it, just selected it!

              [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
              1.12.0
              [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg-static install -f pkg
              Updating pfSense-core repository catalogue...
              pfSense-core repository is up to date.
              Updating pfSense repository catalogue...
              pfSense repository is up to date.
              All repositories are up to date.
              Checking integrity... done (0 conflicting)
              The following 1 package(s) will be affected (of 0 checked):
              
              Installed packages to be DOWNGRADED:
                      pkg: 1.12.0 -> 1.10.5_6 [pfSense]
              
              Number of packages to be downgraded: 1
              
              The operation will free 1 MiB.
              
              Proceed with this action? [y/N]: y
              [1/1] Downgrading pkg from 1.12.0 to 1.10.5_6...
              [1/1] Extracting pkg-1.10.5_6: 100%
              You may need to manually remove /usr/local/etc/pkg.conf if it is no longer needed.
              [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
              1.10.5
              

              Selected it and...

              [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
              1.12.0
              [2.4.4-RELEASE][root@pfSense.localdomain]/root:
              ``
              

              @caligo-erik but why would you do it? Just like @stephenw10 advises don't change the package manager version.

              It all started with wanting to install a package using the GUI, and no packages were available. I read on some forums, that it might be a temporary issue, so I waited a couple of days, and retried.

              Then I tried to update to 2.5, but it got stuck.

              Since then I've been reading up on various posts of people with similar problems, ultimately bumping into this one.

              I've already create a backup config.xml file and - unless I can fix this otherwise first - will do a reinstall over the weekend.

              C 1 Reply Last reply May 1, 2021, 3:09 PM Reply Quote 1
              • A
                adamw @stephenw10
                last edited by adamw Apr 23, 2021, 6:11 PM Apr 23, 2021, 5:45 PM

                @stephenw10

                After upgrading SG-3100 to 2.4.5-p1 a while ago my pkg appears completely broken, can't even check its version:

                [2.4.5-RELEASE][root@pfsense]/root: pkg -v
                Shared object "libarchive.so.7" not found, required by "pkg"

                I'm suspecting it resulted from branch switching: https://forum.netgate.com/topic/159349/frozen-package-update

                So solving one problem created another.

                Is there any low risk fix that can be applied remotely?

                S 1 Reply Last reply Apr 25, 2021, 11:05 AM Reply Quote 0
                • S
                  stephenw10 Netgate Administrator @adamw
                  last edited by Apr 25, 2021, 11:05 AM

                  The only thing you can do is try the suggestions here:
                  https://docs.netgate.com/pfsense/en/latest/troubleshooting/upgrades.html#upgrade-not-offered-library-errors
                  Some of those are not without risk though.

                  Steve

                  A 1 Reply Last reply Apr 27, 2021, 1:55 PM Reply Quote 1
                  • A
                    adamw @stephenw10
                    last edited by Apr 27, 2021, 1:55 PM

                    @stephenw10

                    Thank you Steve.

                    I'm rather planning to upgrade from 2.4.5-p1 to 21.02.2.

                    Mainly to mitigate OpenVPN randomly crashing with (fixed in OpenSSL 1.1.1j and later):

                    cipher_ctx_update: EVP_CipherUpdate() failed
                    Exiting due to fatal error
                    

                    Is the upgrade likely to fix pkg? Are there any special steps I should consider?

                    1 Reply Last reply Reply Quote 0
                    • S
                      stephenw10 Netgate Administrator
                      last edited by Apr 27, 2021, 4:05 PM

                      Yes, if the upgrade runs it will all be replaced but getting to run requires pkg to be working....

                      A 1 Reply Last reply Apr 27, 2021, 4:33 PM Reply Quote 0
                      • A
                        adamw @stephenw10
                        last edited by Apr 27, 2021, 4:33 PM

                        @stephenw10

                        So I HAVE to fix pkg manually first before even consider a full upgrade, right?

                        C 1 Reply Last reply May 1, 2021, 3:12 PM Reply Quote 0
                        • C
                          caligo-erik @caligo-erik
                          last edited by May 1, 2021, 3:09 PM

                          @caligo-erik said in Shared object "libarchive.so.7" not found, required by "pkg":

                          @qinn said in Shared object "libarchive.so.7" not found, required by "pkg":

                          @qinn said in Shared object "libarchive.so.7" not found, required by "pkg":

                          Think I found it, the pkg package gets updated when in GUI from System/Update/System update you select "Update Latest 2.4.x development version (2.4.5)" in Branch and I did not confirm it, just selected it!

                          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
                          1.12.0
                          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg-static install -f pkg
                          Updating pfSense-core repository catalogue...
                          pfSense-core repository is up to date.
                          Updating pfSense repository catalogue...
                          pfSense repository is up to date.
                          All repositories are up to date.
                          Checking integrity... done (0 conflicting)
                          The following 1 package(s) will be affected (of 0 checked):
                          
                          Installed packages to be DOWNGRADED:
                                  pkg: 1.12.0 -> 1.10.5_6 [pfSense]
                          
                          Number of packages to be downgraded: 1
                          
                          The operation will free 1 MiB.
                          
                          Proceed with this action? [y/N]: y
                          [1/1] Downgrading pkg from 1.12.0 to 1.10.5_6...
                          [1/1] Extracting pkg-1.10.5_6: 100%
                          You may need to manually remove /usr/local/etc/pkg.conf if it is no longer needed.
                          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
                          1.10.5
                          

                          Selected it and...

                          [2.4.4-RELEASE][root@pfSense.localdomain]/root: pkg -v
                          1.12.0
                          [2.4.4-RELEASE][root@pfSense.localdomain]/root:
                          ``
                          

                          @caligo-erik but why would you do it? Just like @stephenw10 advises don't change the package manager version.

                          It all started with wanting to install a package using the GUI, and no packages were available. I read on some forums, that it might be a temporary issue, so I waited a couple of days, and retried.

                          Then I tried to update to 2.5, but it got stuck.

                          Since then I've been reading up on various posts of people with similar problems, ultimately bumping into this one.

                          I've already create a backup config.xml file and - unless I can fix this otherwise first - will do a reinstall over the weekend.

                          Update:
                          FINALLY I got round to pluck up the courage to reinstall pfSense with the newer version.
                          It was actually very simple, you can copy the config file to the USB installer disk, and it will use it during install.

                          I did, however, make a full clone of the hard-disk before doing so, better safe than sorry 🤠

                          1 Reply Last reply Reply Quote 0
                          • C
                            caligo-erik @adamw
                            last edited by caligo-erik May 1, 2021, 3:13 PM May 1, 2021, 3:12 PM

                            @adamw said in Shared object "libarchive.so.7" not found, required by "pkg":

                            @stephenw10

                            So I HAVE to fix pkg manually first before even consider a full upgrade, right?

                            I didn't manage to fix pkg manually. In fact, I managed to get pkg from "partially working" to "not working at all" 💩

                            In the end, I went for a export config to USB installer -> reinstall.

                            1 Reply Last reply Reply Quote 0
                            • S
                              stephenw10 Netgate Administrator
                              last edited by May 3, 2021, 11:58 AM

                              Yeah pkg/pkg-static is required to run the upgrade so it must be functional.

                              Reinstalling and restoring the config is often faster and easier if you've ever done it before.

                              Steve

                              1 Reply Last reply Reply Quote 0
                              • I
                                ipfftw @tkriviradev
                                last edited by Sep 19, 2021, 8:17 AM

                                This post is deleted!
                                1 Reply Last reply Reply Quote 0
                                • T TheGushi referenced this topic on Nov 26, 2024, 10:43 PM
                                • First post
                                  Last post
                                Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
                                  [[user:consent.lead]]
                                  [[user:consent.not_received]]