Sorry we lost some posts because of database errors!

*New 12.1 series Release:
2020-09-01: XigmaNAS 12.1.0.4.7728 - released

*New 11.4 series Release:
2020-08-27: XigmaNAS 11.4.0.4.7718 - released!


We really need "Your" help on XigmaNAS https://translations.launchpad.net/xigmanas translations. Please help today!

Producing and hosting XigmaNAS costs money. Please consider donating for our project so that we can continue to offer you the best.
We need your support! eg: PAYPAL

How to upgrade from Shell if something fail

For "upgrading" from FreeNAS/NAS4Free Legacy to XigmaNAS and upgrading XigmaNAS to newer builds.
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
Thorin
NewUser
NewUser
Posts: 2
Joined: 29 Jan 2020 05:16
Status: Offline

How to upgrade from Shell if something fail

#1

Post by Thorin »

Hello,

sorry if this is a newbie question, I am not yet super familiar with Xigmanas.

I have a RootOnZFS install running 12.1.0.4 7091 (That's the first version I installed). I tried upgrading to 7743 using the System/Firmware Update menu. After a couple hours nothing was happening. If I tried going to the web console I would just get "A Firmware update is in progress" message. I ssh to the machine, tried a reboot, now the console is working but showing 7091 as the version, as if nothing happened.

I read somewhere that RootOnZFS is highly dependant on the rc.firmware file for upgrades, is it possible something in the file is messed up?

Any input would be greatly appreciated.

Regards
Francis

User avatar
JoseMR
Hardware & Software Guru
Hardware & Software Guru
Posts: 1075
Joined: 16 Apr 2014 04:15
Location: PR
Contact:
Status: Offline

Re: Problem upgrading from 12.1.0.4 7091 to 7743

#2

Post by JoseMR »

Thorin wrote:
15 Nov 2020 00:08
Hello,

sorry if this is a newbie question, I am not yet super familiar with Xigmanas.

I have a RootOnZFS install running 12.1.0.4 7091 (That's the first version I installed). I tried upgrading to 7743 using the System/Firmware Update menu. After a couple hours nothing was happening. If I tried going to the web console I would just get "A Firmware update is in progress" message. I ssh to the machine, tried a reboot, now the console is working but showing 7091 as the version, as if nothing happened.

I read somewhere that RootOnZFS is highly dependant on the rc.firmware file for upgrades, is it possible something in the file is messed up?

Any input would be greatly appreciated.

Regards
Francis

Hello, while there is a few post around this RootOnZFS issues, one of the problem you could be facing can be either, the change from .GZ to .TXZ firmware file compression format, or the drop from the old and very well tested `beadm` to the `bectl` utility commands to manage the Boot Environments, since command fallback was not added for the later, it eventually broke this functionality for the RootOnZFS earlier versions.

If this is the case and a Full system reinstall(recommended) is not an option, then the easiest way is that user should update the `rc.firmware` and `system_firmware.php` files manually in order to be able to upgrade their system.

According yo your post and specified version, you need to execute the following commands one-by-one to update from latest firmware file.txz(internet required):

Code: Select all

fetch --no-verify-peer -o /etc/rc.firmware "https://sourceforge.net/p/xigmanas/code/HEAD/tree/trunk/etc/rc.firmware?format=raw"
fetch --no-verify-peer -o /usr/local/www/system_firmware.php "https://sourceforge.net/p/xigmanas/code/HEAD/tree/trunk/www/system_firmware.php?format=raw"
After update success, then you can download the latest firmware upgrade file and re-try, enabling console debug is useful to spot where the firmware upgrade is hanging, though it is disabled by default and required for the user to manually enable it on the WebGUI, good luck

Regards
System: FreeBSD 12 RootOnZFS Mirror, MB: Supermicro X8SI6-F, Xeon X3450, 16GB DDR3 ECC RDIMMs.
XigmaNAS RootOnZFS
Addons at GitHub
BastilleBSD
Boot Environments Intro
Resources Home Page

Thorin
NewUser
NewUser
Posts: 2
Joined: 29 Jan 2020 05:16
Status: Offline

Re: Problem upgrading from 12.1.0.4 7091 to 7743

#3

Post by Thorin »

Thanks a lot for the reply, it's much appreciated.

Since I posted my question I dig around a little more and already tried fetching rc.firmware and system_firmware.php as you suggested and it did not fix my issue. But I will try to enable debug login as you suggested and see if I can find the source of the problem.
In any case a full system re-install is not a problem for, I was just trying to find the source of the bug first.

I find solving problems (or at least finding the source fo the issue) is always the best way to learn.

Regards.

User avatar
JoseMR
Hardware & Software Guru
Hardware & Software Guru
Posts: 1075
Joined: 16 Apr 2014 04:15
Location: PR
Contact:
Status: Offline

Re: Problem upgrading from 12.1.0.4 7091 to 7743

#4

Post by JoseMR »

Thorin wrote:
18 Nov 2020 03:31
Thanks a lot for the reply, it's much appreciated.

Since I posted my question I dig around a little more and already tried fetching rc.firmware and system_firmware.php as you suggested and it did not fix my issue. But I will try to enable debug login as you suggested and see if I can find the source of the problem.
In any case a full system re-install is not a problem for, I was just trying to find the source of the bug first.

I find solving problems (or at least finding the source fo the issue) is always the best way to learn.

Regards.

Hi, it could be that your version is lacking the `bectl` command which is what replaced the previous `beadm` command, unfortunately since there is no fallback to address this issue you may try creating an alias like shown below(recommended):

Code: Select all

alias bectl /usr/local/sbin/beadm
The above is a temporary workaround to upgrade in case the system has the `beadm` command but lacks the `bectl` one, also another way is to create a `bectl` symlink like shown below, though the alias should be enough:

Code: Select all

ln -s /usr/local/sbin/beadm /sbin/bectl
After the upgrade then system will start using the `bectl` command by default to manage the Boot Environments.

Regards
System: FreeBSD 12 RootOnZFS Mirror, MB: Supermicro X8SI6-F, Xeon X3450, 16GB DDR3 ECC RDIMMs.
XigmaNAS RootOnZFS
Addons at GitHub
BastilleBSD
Boot Environments Intro
Resources Home Page

jespejo
NewUser
NewUser
Posts: 2
Joined: 13 Jul 2018 00:25
Status: Offline

Re: Problem upgrading from 12.1.0.4 7091 to 7743

#5

Post by jespejo »

the first fetch command provides a error: Size of the remote file is not known.

User avatar
JoseMR
Hardware & Software Guru
Hardware & Software Guru
Posts: 1075
Joined: 16 Apr 2014 04:15
Location: PR
Contact:
Status: Offline

Re: Problem upgrading from 12.1.0.4 7091 to 7743

#6

Post by JoseMR »

jespejo wrote:
19 Nov 2020 00:36
the first fetch command provides a error: Size of the remote file is not known.
Hello welcome, don't worry about that `fetch` command common error(is a warning actually), it happens to me as well, however the file will be fetched regardless:

Code: Select all

root@server: ~# ls /etc/rc.firmware 
ls: /etc/rc.firmware: No such file or directory
root@server: ~# fetch --no-verify-peer -o /etc/rc.firmware "https://sourceforge.net/p/xigmanas/code/HEAD/tree/trunk/etc/rc.firmware?format=raw"
fetch: https://sourceforge.net/p/xigmanas/code/HEAD/tree/trunk/etc/rc.firmware?format=raw: size of remote file is not known
/etc/rc.firmware                                        23 kB 5061 kBps    00s
root@server: ~# ls /etc/rc.firmware
/etc/rc.firmware
Regards
System: FreeBSD 12 RootOnZFS Mirror, MB: Supermicro X8SI6-F, Xeon X3450, 16GB DDR3 ECC RDIMMs.
XigmaNAS RootOnZFS
Addons at GitHub
BastilleBSD
Boot Environments Intro
Resources Home Page

jespejo
NewUser
NewUser
Posts: 2
Joined: 13 Jul 2018 00:25
Status: Offline

Re: Problem upgrading from 12.1.0.4 7091 to 7743

#7

Post by jespejo »

Well finally got it to work. Using Tools > Command. I was on 7091 and moved to 7743. Which I should be able to do this right from the GUI. I will post for others.

1) ON System>Firmware Update
Enable Firmware button
2) ln -s /usr/local/sbin/beadm /sbin/bectl
3) fetch --no-verify-peer -o /etc/rc.firmware "https://sourceforge.net/p/xigmanas/code ... format=raw"
4) fetch --no-verify-peer -o /usr/local/www/system_firmware.php "https://sourceforge.net/p/xigmanas/code ... format=raw"
5) /etc/rc.firmware fullupgrade /var/tmp/ftmp/XigmaNAS-x64-full-12.1.0.4.7743.txz

Post Reply

Return to “Upgrade XigmaNAS”