2.3 pkg upgrade error
-
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.
-
Post an output of your 'df' results. What package are you trying to install?
-
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/devI have already checked that I can create files in /usr/local/share/zsh/site-functions/.
What package are you trying to install?
Any. Even updating pkg will not work - see above.
-
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.
-
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 _pkgAnother 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.
-
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.
-
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.