Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - bfoss

#1
After looking into this some more, I'm realizing that OPNsense version 22.1.6 seems to use the base/kernel versions 22.1.5 and the packages version 22.1.6. Is there a convenient place to find these relationships between OPNsense version and the specific versions that make up a release without using the GUI since I am not connected to WIFI?
#2
I've been downloading upgrade files from the mirror and using those to upgrade my device through the provided CLI tool. This has been working great for my use case, but now I'm running into a weird edge case issue where some releases don't provide upgrade files for that specific version. For instance, the newest release of 22.1.6 does not show up in the upgrade sets within the official mirror:
https://pkg.opnsense.org/FreeBSD:13:amd64/22.1/sets/

However, it does have the files for the packages portion of the upgrade as seen here:
https://pkg.opnsense.org/FreeBSD:13:amd64/22.1/MINT/22.1.6/OpenSSL/

I also see a similar situation with version 22.1.3. Is there a reason why some files are missing after being released? If so, is there a way I could still get them somewhere else? My process doesn't let me use the internet to get packages so I rely on retrieving them on an external device through these mirrors before transferring them and performing the upgrade.

Thanks in advance for any clarification!
#3
I'm going to move forward assuming that these errors are expected during upgrade reboots and that I shouldn't be worried since the upgrade seems to work fine on the final boot. If anyone sees this down the road and feels differently, please chime in. Thanks!
#4
Hi there, I've been working on a method to upgrade OPNsense offline through the provided `opnsense-update` CLI tool using local update files. I've gotten it to work successfully, but it does throw some exceptions and failures during the process that leave me wondering if I should be concerned or not.

Note: These errors only occur during subsequent reboots during the upgrade process and I don't see them again following the final reboot.

I'll list the issues I'm seeing during initial reboots below and I'm hoping someone can chime in on whether or not these are expected or should be addressed.

- `pkg` is upgraded and then fails to execute the lua script:


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.12.0_1 -> 1.16.3_1

Number of packages to be upgraded: 1
[1/1] Upgrading pkg from 1.12.0_1 to 1.16.3.1...
[1/1] Extracting pkg-1.16.3_1: .......... done
pkg-static: Failed to execute lua script: [string "-- args: etc/pkg.conf.sample..."]:12: attempt to call a nil value (field 'stat')


- While checking package integrity, there are conflicting packages between the new version and previous version:

One example:

- php74-sockets-7.4.28 conflicts with php73-sockets-7.3.20 on /usr/local/etc/php/ext-20-sockets.ini


- There are missing packages during package extraction:

One example:

[100.177] Extracting brotli-1.0.9,1: .........brotli-1.0.7_2,1: missing file /usr/local/lib/libbrotlicommon.so.1.0.7
done
brotli-1.0.7_2,1: missing file /usr/local/lib/libbrotlidec.so.1.0.7
brotli-1.0.7_2,1: missing file /usr/local/lib/libbrotlienc.so.1.0.7
brotli-1.0.7_2,1: missing file /usr/local/share/licenses/brotli-1.0.7_2,1/LICENSE
brotli-1.0.7_2,1: missing file /usr/local/share/licenses/brotli-1.0.7_2,1/brotli-1.0.7_2,1/MIT
brotli-1.0.7_2,1: missing file /usr/local/share/licenses/brotli-1.0.7_2,1/catalog.mk


- There are uncaught errors while extracting packages of plugins I already have installed:


[175/177] Upgrading os-nginx from 1.19 to 1.26...
[175/177] Extracting os-nginx-1.26: .......... done
Starting configd.

Fatal error: Uncaught Error: Class 'Phalcon\Validation\Validator' not found in /                                                                                                                                                                             usr/local/opnsense/mvc/app/models/OPNsense/Base/Validators/NetworkValidator.php:                                                                                                                                                                             41
Stack trace:
#0 [internal function]: unknown()
#1 [internal function]: Phalcon\Loader->autoLoad('OPNsense\\Base\\V...')
#2 [internal function]: spl_autoload_call('OPNsense\\Base\\V...')
#3 /usr/local/opnsense/mvc/script/run_migrations.php(52): ReflectionClass->__con                                                                                                                                                                             struct('OPNsense\\Base\\V...')
#4 {main}
  thrown in /usr/local/opnsense/mvc/app/models/OPNsense/Base/Validators/NetworkV                                                                                                                                                                             alidator.php on line 41

Notice: Undefined variable: field_rfcls in /usr/local/opnsense/mvc/app/models/OP                                                                                                                                                                             Nsense/Base/BaseModel.php on line 150

Notice: Trying to get property 'name' of non-object in /usr/local/opnsense/mvc/a                                                                                                                                                                             pp/models/OPNsense/Base/BaseModel.php on line 150

Fatal error: Uncaught OPNsense\Base\ModelException: class  of wrong type in mode                                                                                                                                                                             l definition in /usr/local/opnsense/mvc/app/models/OPNsense/Base/BaseModel.php:1                                                                                                                                                                             50
Stack trace:
#0 /usr/local/opnsense/mvc/app/models/OPNsense/Base/BaseModel.php(196): OPNsense                                                                                                                                                                             \Base\BaseModel->getNewField('OPNsense\\Base\\F...')
#1 /usr/local/opnsense/mvc/app/models/OPNsense/Base/BaseModel.php(267): OPNsense                                                                                                                                                                             \Base\BaseModel->parseXml(Object(SimpleXMLElement), NULL, Object(OPNsense\Base\F                                                                                                                                                                             ieldTypes\ContainerField))
#2 /usr/local/opnsense/mvc/app/models/OPNsense/Base/BaseModel.php(328): OPNsense                                                                                                                                                                             \Base\BaseModel->parseXml(Object(SimpleXMLElement), Object(SimpleXMLElement), Ob                                                                                                                                                                             ject(OPNsense\Base\FieldTypes\ContainerField))
#3 [internal function]: OPNsense\Base\BaseModel->__construct()
#4 /usr/local/opnsense/mvc/script/run_migrations.php(55): ReflectionClass->newIn                                                                                                                                                                             stance()
#5 {main}
  thrown in /usr/local/opnsense/mvc/app/models/OPNsense/Base/BaseModel.php on li                                                                                                                                                                             ne 150
Reloading plugin configuration
Configuring system logging...
Fatal error: Uncaught Error: Call to undefined method Phalcon\Logger\Adapter\Sys                                                                                                                                                                             log::error() in /usr/local/opnsense/mvc/app/library/OPNsense/Core/Backend.php:95
Stack trace:
#0 /usr/local/etc/inc/legacy_bindings.inc(41): OPNsense\Core\Backend->configdRun                                                                                                                                                                             ('template reload...', false)
#1 /usr/local/etc/inc/system.inc(605): configd_run('template reload...')
#2 /usr/local/etc/rc.configure_plugins(45): system_syslogd_start(true)
#3 {main}
  thrown in /usr/local/opnsense/mvc/app/library/OPNsense/Core/Backend.php on lin                                                                                                                                                                             e 95
Reloading template OPNsense/Nginx: configd not running!


And


[176/177] Upgrading os-dyndns from 1.22 to 1.27_3...
[176/177] Extracting os-dyndns-1.27_3: .......... done
Starting configd.
Reloading plugin configuration
Configuring system logging...
Fatal error: Uncaught Error: Call to undefined method Phalcon\Logger\Adapter\Syslog::error() in /usr/local/opnsense/mvc/app/library/OPNsense/Core/Backend.php:95
Stack trace:
#0 /usr/local/etc/inc/legacy_bindings.inc(41): OPNsense\Core\Backend->configdRun('template reload...', false)
#1 /usr/local/etc/inc/system.inc(605): configd_run('template reload...')
#2 /usr/local/etc/rc.configure_plugins(45): system_syslogd_start(true)
#3 {main}
  thrown in /usr/local/opnsense/mvc/app/library/OPNsense/Core/Backend.php on line 95
[177/177] Upgrading opnsense from 20.7 to 22.1.2...
[177/177] Extracting opnsense-22.1.2: .......... done


My gut tells me that version mismatches during reboots is causing the majority of these errors since they seem to go away after the final reboot and the upgrade completes, but a sanity check would be greatly appreciated.

Thanks in advance! Also, let me know if you want any more details from my end.
#5
Thanks for the quick and helpful answer! I was able to tar up those files and it seems to be letting me upgrade now.
#6
Hi there, I'm currently working on an easy solution to perform offline upgrades of OPNsense by downloading the files I need directly from an available mirror, SCPing them onto my computer running OPNsense, and then using the CLI update tool to perform an update. This works greats until I try and do this process with a patch version of OPNsense. The CLI tool provided by OPNsense doesn't perform the upgrade because it can't find the specific patch version of the `packages` OpenSSl file.


Fetching packages-22.1.2-OpenSSL-amd64.tar: .
failed, no update found


The mirror only provides a `packages` OpenSSL file for the major and minor version but does not provide a Tar file for the patch versions https://pkg.opnsense.org/FreeBSD:13:amd64/22.1/sets/. Do I need to Tar these `packages` myself from the nested mirror location https://pkg.opnsense.org/FreeBSD:13:amd64/22.1/MINT/22.1.2/OpenSSL/All/?

I feel like I'm misunderstanding something since it seems like the `packages` tar file for each patch version would be included in the mirror by default.

Any advice or clarification would be greatly appreciated!