After system upgrade: TinyDNS upgrade fails
I had an full installation of 2010.04.15 23:01 snapshot with TinyDNS installed.
Today I did an upgrade from console to 2010.05.06 07:06, which seemed to work OK.
When connecting to GUI, the GUI tried to update TinyDNS.
The update failed. I did not note the exact error messages, as I intended to just reinstall TinyDNS later.
I de-installed TinyDNS, which did not produce any error messages.
However, I could not re-install TinyDNS, as it continues to be listed under "Installed Packages".
I guess this might be a general problem. Somehow packages can be "half installed"; meaning that they are not installed and working, but can neither be de-installed and re-installed.
I found this with TinyDNS, but I suspect it might be a general problem, which needs to be looked into…
Anyway, I removed TinyDNS from /cf/conf/config.xml.
Now TinyDNS shows up as an available package, which I then tried to install again.
However, installation still fails, and the log shows:
cat /tmp/pkg_mgr_dns-server.log Beginning package installation. Downloading package configuration file... ucspi-tcp-0.88_2 Array (  => Requested space: 264K bytes, free space: 910M bytes in /var/tmp/instmp.mwjwhz  => extract: Package name is ucspi-tcp-0.88_2  => extract: CWD to /usr/local [... snip ...]  => extract: /usr/local/bin/who@  => extract: CWD to .  => Running mtree for ucspi-tcp-0.88_2..  => mtree -U -f +MTREE_DIRS -d -e -p /usr/local >/dev/null  => Attempting to record package into /var/db/pkg/ucspi-tcp-0.88_2..  => Package ucspi-tcp-0.88_2 registered in /var/db/pkg/ucspi-tcp-0.88_2 ) pkg_add successfully completed. daemontools-0.76_12 Array (  => Requested space: 948 bytes, free space: 910M bytes in /var/tmp/instmp.QjuxJg  => tar: Unrecognized archive format  => tar: +CONTENTS: Not found in archive  => tar: Error exit delayed from previous errors.  => pkg_add: tar extract of /tmp/apkg_daemontools-0.76_12.tbz failed!  => pkg_add: unable to extract table of contents file from '/tmp/apkg_daemontools-0.76_12.tbz' - not a package?  => pkg_add: 1 package addition(s) failed ) Package WAS NOT installed properly.
And sure enough, /tmp/apkg_daemontools-0.76_12.tbz is actually not a gzipped tar but a HTML 404:
The requested URL /packages/8/All//daemontools-0.76_12.tbz was not found on this server.
Looking at http://files.pfsense.org/packages/8/All/ I see daemontools-0.76_14.tbz but not _12 ??!!
I am certainly not an expert on pfSense infrastructure, but it seems to me that this must be a bug either in the package definition, or in the contents of files.pfsense.org.
So, I rebooted into another partition with a working 2010-04-21 03:15 snapshot, which was working fine some hours before.
However, TinyDNS seems to be failing here as well.
It seems that upon rebooting, pfSense tried to install the latest TinyDNS, and failed.
The messages scrolled off my terminal, but as far as I remember there was something like
Installing TinyDns 0%…50%...100%
And I see the same problem in /tmp/pkg_mgr_dns-server.log and /tmp/apkg_daemontools-0.76_12.tbz, as on the other partition.
Question: Is pfSense supposed to try to install new package versions upon reboot?
If so: I would suggest not to do this.
If a system works before reboot, it should work after reboot as well.
Package upgrade should - in my opinion - be a GUI option.
So, after having "played" with beta 2.0 for a couple of months, I now had to revert to a 1.2.3 partition ))-:
That's why it's still a BETA. :-)
Packages are one area that still need some attention, precisely for the reasons you are seeing. There are a few scenarios where packages can still end up half-installed and wreak havoc.
jimp, I am very sorry if my post came across as a complaint.
My intention was simply to state my experience as precisely as possible; hoping that developers more knowledgeable than myself may be able to solve the problems!
I have been trying to resolve or workaround this issue, but failed )))-:
(1) Does it make sense for me to try to find a workaround, or is this expected to be fixed by the more knowledgeable developers in the near future?
[ This is not a complaint against beta, just a question for my own enlightenment ]
(2) As mentioned above on this thread, tinydns tries to load the dependency /packages/8/All//daemontools-0.76_12.tbz
However only /packages/8/All//daemontools-0.76_14.tbz is provided.
Can anybody enlighten me as to whether _12 is correct (so the http://files.pfsense.org/packages/8/All site is "wrong") or whether _14 is correct (so the package config is "wrong")
(3) It seems that whatever I put in /cf/conf/config.xml is overwritten at boot.
Can enybody enlighten me as to where to specify _14 to work around the problem?
(4) I am at a bit of a loss understanding how and why packages and package configs are updated.
Can anybody point out any documentation towards this - or maybe explain it to stupid me.
See also http://redmine.pfsense.org/issues/605 and http://redmine.pfsense.org/issues/606
That dependency is a compile-time option when the package was made. Whoever compiled the tinydns package probably just needs to recompile it with an up-to-date ports tree and then upload a new set of packages.
In the meantime you can install daemontools first:
pkg_add -r http://files.pfsense.org/packages/8/All/packages/8/All//daemontools-0.76_14.tbz
And then install tinydns. It will still complain that the version doesn't match but should continue.
Jim, thank you for your suggestion!
I tried to deinstall TinyDNS from GUI (seemed to work OK).
Then pkg_add'ed daemontools-0.76_14.tbz as per your suggestion, as well as
pkg_add -r http://files.pfsense.org/packages/8/All/djbdns-1.05_13.tbz
However, when I try to install TinyDNS again from GUI I get:
Downloading package configuration file… done. Saving updated package information... done. Downloading dns-server and its dependencies... done. Checking for successful package installation... of daemontools-0.76_12 failed! Installation aborted.
Then you'll just have to wait until the maintainer of the tinydns package generates a new version that is more compatible with 2.0.
Sure, I will just wait, no problem.
I just hoped to get some comments on "my issues (1) to (5) above" to understand pfSense 2.0 better…
I was hoping that with some guidance and comments I might be able to understand and then resolve the issue and submit a patch...
One more comment, after all:
As I reported before in http://forum.pfsense.org/index.php/topic,24912.msg129125.html#msg129125:
With a perfectly working pfSense 2.0; upon reboot, TinyDNS tries to re-install itself and fails.
This is beta and I have no problem with this at all in this phase, but I would be most unhappy to see this in a 2.0 release…
I have tried to investigate this issue further, but found no culprit or solution.
I am writing my observations here, hoping someone more knowledgeable may be able to enlighten me!
First of all, I have created http://redmine.pfsense.org/issues/618 in the hope that the issue will not be forgotten.
Tiny-DNS worked fine for me on 21-april, but was broken on 6-may.
(I am not sure if the box was rebooted in between, so I cannot get any closer to a specific date).
On 6-may, TinyDNS is trying to upgrade itself and as per pkg_config.8.xml it tries to download daemontools-0.76_12.tbz from http://files.pfsense.org/packages/8/All/
However http://files.pfsense.org/packages/8/All/ only contains daemontools-0.76_14.tbz (i.e _14 instead of _12).
I am a newbee to pfSense, but as far as I can see, the FreeBSD package building would be controlled by either
… not sure which...
The RELENG_8_1-supfile file is being updated every now and again to reflect the current date, whereas RELENG_8-supfile has been stable since october last year.
The timestamp on http://files.pfsense.org/packages/8/All/daemontools-0.76_14.tbz is 21-Jan-2010
And sure enough, according to http://www.freebsd.org/cgi/cvsweb.cgi/ports/sysutils/daemontools/Makefile.diff?r1=1.28;r2=1.29;f=h FreeBSD upgraded from _12 to _13 already on 04-jan, and to _14 on 7-jan.
Around 21-Jan, RELENG_8_1-supfile seems to have contained either
so as far as I can see, this should have picked up the _14 release, consistent with http://files.pfsense.org/packages/8/All/daemontools-0.76_14.tbz
So, from all the info I can find, _14 was introduced back in january, but "my" TinyDNS broke only in may. I wonder why...
I see a few packages in http://files.pfsense.org/packages/8/All/ have the same name but different versions.
Could it be that daemontools-0.76_14.tbz was build already back in jan-2010, but that a daemontools-0.76_12.tbz was also left in place, but somehow deleted between 21-april and 6-may ?
Any hints would be much appreciated...