Auto update - always looses config and changes boot partition?
-
Hello!
Running pfsense 2.0 embedded on ALIX. I am very pleased to see the feature list and the huge step forward pfsense is going to do when 2.0 final is released.
I have one problem with auto upgrade and I do not know if this works as designed:
As first time setup I copied an image to compactflash medium. After setting up the interfaces I copied partition 1 to partition 2 (duplicate slice).
Than I discover the auto upgrade feature and gave it a try. I was impressed but every time I auto upgrade and reboot pfsense boots from a different partition with no configuration.
For example: currently running from partition 1 -> running auto upgrade -> system reboots -> starts up from partition 2 with no interface setup. Then I have to setup the interfaces via serial console. I copied partition 2 to partition 1, setup boot partition to 1, reboot and I am back at partition 1 (no setup needed).Is this the expected process? Did I miss something?
I expected after upgrade to start up with the current partition running the latest version and have a fall back at the other partition.Bye,
eweriP.S. Just wanted to update from release Jan 6 to current release Jan 10 04:34:36 EST 2011 - but it does not reboot automatically after the upgrade has finished. And now it shows at the status page that it will boot the other partition at next boot. I can not even reboot via web-GUI have to reboot via serial console.
P.P.S. I can not even reboot via serial console running release Jan 6 03:49:29 EST 2011. Tried to reboot via shell command :
[2.0-BETA5][root@pfSense.localdomain]/root(2):
System shutdown time has arrived
Cannot reboot at this moment, a config write operation is in progress.
exit: Illegal number: -1and then it reboots.
-
The config is held on a third slice (cf) that has nothing to do with the independent OS slices (pfsense0 and pfsense1). The alternate OS slice (whichever you are not booting from) is used for the upgrade process, or to fall back to if an upgrade goes awry.
I upgrade my ALIX regularly and the config keeps fine. Not sure why your config isn't staying, but there must be something else going on. What you're seeing isn't normal.
-
Okay - so something is wrong with my pfsense installation.
This is what df shows me:
Filesystem 1K-blocks Used Avail Capacity Mounted on /dev/ufs/pfsense1 1898582 138370 1608325 8% / devfs 1 1 0 100% /dev /dev/md0 39406 222 36032 1% /tmp /dev/md1 59246 6406 48102 12% /var devfs 1 1 0 100% /var/dhcpd/dev
Maybe I start from the beginning and copy an image to my cf once again.
And this is what I get from fdisk:
******* Working on device /dev/ufs/pfsense1 ******* parameters extracted from in-core disklabel are: cylinders=3830 heads=16 sectors/track=63 (1008 blks/cyl) Figures below won't work with BIOS for partitions not in cyl 1 parameters to be used for BIOS calculations are: cylinders=3830 heads=16 sectors/track=63 (1008 blks/cyl) fdisk: invalid fdisk partition table found Media sector size is 512 Warning: BIOS sector numbering starts with sector 1 Information from DOS bootblock is: The data for partition 1 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 63, size 3860577 (1885 Meg), flag 80 (active) beg: cyl 0/ head 1/ sector 1; end: cyl 757/ head 15/ sector 63 The data for partition 2 is: <unused>The data for partition 3 is: <unused>The data for partition 4 is:</unused></unused>
Any idea what is happening here?
Bye,
eweri -
None of that looks out of the ordinary.
-
None of that looks out of the ordinary.
Except that you wrote earlier that there should be three slices on the hard drive but fdisk shows only one. Did I miss something?
-
fdisk doesn't list them when it's run alone. He didn't run it with any parameters, so it only listed the pfsense1 slice as it showed in its banner.
[2.0-BETA5][root@pfSense.localdomain]/root(1): fdisk ******* Working on device /dev/ufs/pfsense1 ******* parameters extracted from in-core disklabel are: cylinders=914 heads=16 sectors/track=63 (1008 blks/cyl) parameters to be used for BIOS calculations are: cylinders=914 heads=16 sectors/track=63 (1008 blks/cyl) fdisk: invalid fdisk partition table found Media sector size is 512 Warning: BIOS sector numbering starts with sector 1 Information from DOS bootblock is: The data for partition 1 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 63, size 921249 (449 Meg), flag 80 (active) beg: cyl 0/ head 1/ sector 1; end: cyl 913/ head 15/ sector 63 The data for partition 2 is: <unused>The data for partition 3 is: <unused>The data for partition 4 is:</unused></unused>
If you run it on the whole disk/cf it shows the full proper output:
[2.0-BETA5][root@pfSense.localdomain]/root(2): fdisk /dev/ad0 ******* Working on device /dev/ad0 ******* parameters extracted from in-core disklabel are: cylinders=7964 heads=16 sectors/track=63 (1008 blks/cyl) Figures below won't work with BIOS for partitions not in cyl 1 parameters to be used for BIOS calculations are: cylinders=7964 heads=16 sectors/track=63 (1008 blks/cyl) Media sector size is 512 Warning: BIOS sector numbering starts with sector 1 Information from DOS bootblock is: The data for partition 1 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 63, size 922257 (450 Meg), flag 0 beg: cyl 0/ head 1/ sector 1; end: cyl 914/ head 15/ sector 63 The data for partition 2 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 922383, size 922257 (450 Meg), flag 80 (active) beg: cyl 915/ head 1/ sector 1; end: cyl 805/ head 15/ sector 63 The data for partition 3 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 1844640, size 102816 (50 Meg), flag 0 beg: cyl 806/ head 0/ sector 1; end: cyl 907/ head 15/ sector 63 The data for partition 4 is:
-
Thanks for the explanation.
-
Okay guys!
I started with a fresh image of pfsense 2.0 beta 5 from yesterday and today the configuration survived the update ;-)
BTW. It still does not reboot automatically - still has to do it by hand.
Thanks, bye
eweri -
Hello!
Just want to let the list know that the last update worked without a problem. Reboot worked also.
Bye,
eweri -
According to your df output before, you had no /cf mounted. Maybe that slice was corrupt and couldn't be mounted?