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

    2.3 pkg upgrade error

    Scheduled Pinned Locked Moved Problems Installing or Upgrading pfSense Software
    7 Posts 3 Posters 2.6k 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.
    • G Offline
      gglockner
      last edited by

      I just upgraded from 2.2.(6?) to 2.3.2, and now I am unable to install new packages.  When I do, I get an error like:

      pkg: Fail to create temporary file: /usr/local/share/zsh/site-functions/._pkg.OhUwAdt0Oa2t: Input/output error

      I tried following some instructions on the shell, and I get output like:

      [2.3.2-RELEASE][admin@pfsense.glockners.net]/root: pkg update
      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.
      [2.3.2-RELEASE][admin@pfsense.glockners.net]/root: pkg upgrade 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.
      New version of pkg detected; it needs to be installed first.
      Checking integrity... done (0 conflicting)
      The following 1 package(s) will be affected (of 0 checked):

      Installed packages to be UPGRADED:
      pkg: 1.8.7 -> 1.8.7_1 [pfSense]

      Number of packages to be upgraded: 1

      Proceed with this action? [y/N]: y
      [1/1] Upgrading pkg from 1.8.7 to 1.8.7_1…
      [1/1] Extracting pkg-1.8.7_1:  96%
      pkg: Fail to create temporary file: /usr/local/share/zsh/site-functions/._pkg.OhUwAdt0Oa2t: Input/output error
      [1/1] Extracting pkg-1.8.7_1: 100%

      df shows the router has plenty of disk space. Suggestions appreciated.

      1 Reply Last reply Reply Quote 0
      • M Offline
        muswellhillbilly
        last edited by

        Post an output of your 'df' results. What package are you trying to install?

        1 Reply Last reply Reply Quote 0
        • G Offline
          gglockner
          last edited by

          @muswellhillbilly:

          Post an output of your 'df' results.

          Filesystem                  1K-blocks    Used    Avail Capacity  Mounted on
          /dev/ufsid/5670fc8c909e6046  22153292 6542364 13838668    32%    /
          devfs                              1      1        0  100%    /dev
          /dev/md0                        3484    132    3076    4%    /var/run
          devfs                              1      1        0  100%    /var/dhcpd/dev

          I have already checked that I can create files in /usr/local/share/zsh/site-functions/.

          @muswellhillbilly:

          What package are you trying to install?

          Any.  Even updating pkg will not work - see above.

          1 Reply Last reply Reply Quote 0
          • M Offline
            muswellhillbilly
            last edited by

            Looks like either package corruption or folder/file permissions. Have you checked to see if there are any other '._pkg.' files in that location? The leading dot will hide them from an 'ls' command, so you'd have to run 'ls .' to see them. Another thought: The package updater itself may not have correct permissions to that folder even if your admin account does.

            1 Reply Last reply Reply Quote 0
            • G Offline
              gglockner
              last edited by

              @muswellhillbilly:

              Have you checked to see if there are any other '._pkg.*' files in that location?

              Nope:

              [2.3.2-RELEASE][admin@pfsense.glockners.net]/root: ls -al /usr/local/share/zsh/site-functions
              total 52
              drwxr-xr-x  2 root  wheel    512 Aug 18 06:03 .
              drwxr-xr-x  3 root  wheel    512 Jul 20 08:39 ..
              -rw-r–r--  1 root  wheel  11527 Jul 19 09:22 _curl
              -rw-r--r--  1 root  wheel  31155 Jul 19 09:01 _pkg

              @muswellhillbilly:

              Another thought: The package updater itself may not have correct permissions to that folder even if your admin account does.

              This makes no sense, but the permissions seem fine above.  Remember, this fails when I run pkg upgrade pkg even if I first do su.

              1 Reply Last reply Reply Quote 0
              • jimpJ Offline
                jimp Rebel Alliance Developer Netgate
                last edited by

                Run this and then reboot:

                touch /root/force_fsck
                

                Check the system log for errors as well.

                Depending on what you find, it could be a filesystem error, a disk problem, or just a corrupt database.

                If all else fails, grab a config.xml backup, wipe+reload+restore and you'll be back up in minutes.

                Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

                Need help fast? Netgate Global Support!

                Do not Chat/PM for help!

                1 Reply Last reply Reply Quote 0
                • G Offline
                  gglockner
                  last edited by

                  When I connected to the serial terminal, I saw various disk errors. I did a complete reinstall and restored the backup configuration, and everything looks fine now. Thanks for the suggestion. Meantime, I'll watch the disk to see if this was a software or hardware problem.

                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post
                  Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.