Upgrade 2.1.5 to 2.2 fails on an Alix with NanoBSD



  • Hi there

    I’m having trouble getting from 2.15. to 2.2 on an Alix 2D3 with NanoBSD. It fails with a message „Something went wrong when trying to update the fstab entry. Aborting upgrade.“

    I’m currently running from slice ad0s1, the other slice is broken after the failed upgrade.

    From the output of the upgrade (/cf/conf/upgrade_log.txt):

    SLICE         2
    OLDSLICE      1
    TOFLASH       ad0s2
    COMPLETE_PATH ad0s2a
    GLABEL_SLICE  pfsense1
    

    I was told to run /usr/local/sbin/ufslabels.sh before the upgrade. Is this required on an embedded installation?

    My fstab:

    /dev/ufs/pfsense1 / ufs ro,sync,noatime 1 1
    /dev/ufs/cf /cf ufs ro,sync,noatime 1 1
    

    The above mentioned script breaks on this because the fstab contains no device Ids.

    The script /etc/rc.firmware fails at this command:

    sed -i "" "s/pfsense${OLD_UFS_ID}/pfsense${UFS_ID}/g" /tmp/$GLABEL_SLICE/etc/fstab
    

    where OLD_UFS_ID is 0 and UFS_ID is 1. This seems to be the wrong way round, see my fstab above. :-/

    Any idea?


  • Banned

    @-flo-:

    I was told to run /usr/local/sbin/ufslabels.sh before the upgrade. Is this required on an embedded installation?

    Absolutely not. Reimage the CF card and restore config backup. Everything else is a pure waste of time.



  • Okay … so you're saying that the update mechanism is actually broken beyond repair?

    So I would flash a new card with the full image (don't want to lose a working configuration). Never did that before, how do I get my backupped config in there the easiest way? Do I just run the configuration wizard and after that restore the config? Or can I somehow put the config into the memory card before the first boot?

    -flo-


  • Banned

    The upgrade works just fine for tons of people. No idea what broke for you on your box, plus debugging this and attempting to fix screwed partitions or whatnot is a complete waste of time when you can reimage the card and restore the config in minutes.



  • Could be the drive…  The commands you typed in today.  Commands you typed in previously long before today?

    Who knows.  I would simply backup/wipe/reinstall/restore.

    I'm no expert on those boxes, but my observation has been that seems like people running imbedded devices LOVE a challenge.

    Seems like they LOVE getting to the bottom of the "why didn't my update work" mystery more than just getting the box working.

    I regularly see people spend days investigating such mysteries rather than just simply reinstalling.

    I still have no idea why, unless they are devs.


  • Banned

    You can do the upgrade again and see if it breaks again in the same place. (I really am not into debugging this, there's a 1+ year running threads about screwed partitions with no solution.)



  • You can also try Diagnostics->NanoBSD "Duplicate bootup slice". Let it duplicate the current slice to the other slice. If that succeeds then you have a good other slice that you know can now be written OK. That might be a way to "cleanup/reset" the target slice.


  • Netgate Administrator

    @kejianshi:

    I'm no expert on those boxes, but my observation has been that seems like people running embedded devices LOVE a challenge.

    I run Nano. Whilst I do love a challenge I have had very few problems over years of upgrades. I had an issue where I ran out of RAM on a box with 512MB and had to increase the size of /var slightly. The Alix can easy run out of RAM during an upgrade since it has only 256MB. It's obvious when it happens though you get plenty of error messages. Going to 2.2 my home box failed to reboot after the update due to an issue with my specific hardware. However because I'm running Nano I just switched back to the old slice and carried on.
    As the good Doktor mentioned there is an ongoing issue specific to the Alix related to the drive partitions. There appears to be no way out of it. If there's a chance your box is in this state then reimaging the CF card and restoring the config.xml file is by far the quickest way out of it. Better still use a new CF card and hold the old one as a fall-back. Unless you want to help solve the issue by contributing drive data etc.  ;)

    On-going Alix thread:
    https://forum.pfsense.org/index.php?topic=75069.0

    Same error as you:
    https://forum.pfsense.org/index.php?topic=71760.0

    Steve



  • Well, everybody seeks his or her challenges somewhere. Some (many?) accept a challenge when they see a problem with a pfSense installation even if it is not their own. Thank God, this would be a very empty forum otherwise.

    I tend to accept a challenge with my pfSense also and I'm even having fun most of the time. I decided to run pfSense on an Alix based on cost and power consumption, not fun. I'm taking good advice (I keep with Aristotle and the virtue of prudence), I ordered a new card yesterday. I'll keep the other one as a fall-back. Thank's to all of you for your input!

    Steve, thank you for the links. I checked this out but it seems I have a different problem. That's probably why I did not find these threads myself.

    -flo-



  • We have a similar problem:
    pfsense 2.1.5 nanobsd on ALIX

    We have approx. 50 boxes out in the wild, so we like to test updates in our lab before rolling it out.

    We tried to update 2 testboxes with the out of the box update from the gui.
    Booth boxes are broken after.

    We haven't time to investigate thr error.
    we will try some other scenarios, but we think, theres something wrong with that upgrade. (espec. with nanobsd - 1G on ALIX)


  • Netgate Administrator

    Not much to go on there. Are you going straight to 2.2.1? How broken?

    Steve



  • Just for reference, I have upgraded 8 Alix 2D13 from 2.2 to 2.2.1 "in some wild places" in the last <24 hours, all without a problem. They had all previously been upgraded from 2.1.5 to 2.2.

    As Steve asks, post info on what goes wrong - does not boot at all? what boot messages? what system log messages?…


Log in to reply