⚠ Special Note for Updating FreePBX 17 Installations Following the Release of Debian 13 trixie!

There are many VMs hosted on cloud services whose images are released by various vendors. The command recommended above just messed up the Google package update for a VM ISO on Google Cloud Platform.

apt-get update
Get:1 file:/etc/apt/mirrors/debian.list Mirrorlist [30 B]
Get:2 file:/etc/apt/mirrors/debian-security.list Mirrorlist [39 B]
Hit:7 Index of /debian bookworm InRelease
Hit:3 Index of /debian bookworm InRelease
Hit:4 Index of /debian bookworm-updates InRelease
Hit:5 Index of /debian bookworm-backports InRelease
Hit:8 https://packages.cloud.google.com/apt gcsfuse-bookworm InRelease
Ign:9 https://packages.cloud.google.com/apt google-compute-engine-bookworm-bookworm InRelease
Hit:6 https://deb.debian.org/debian-security bookworm-security InRelease
Hit:10 https://packages.cloud.google.com/apt cloud-sdk-bookworm InRelease
Hit:11 https://packages.cloud.google.com/apt google-cloud-ops-agent-bookworm-2 InRelease
Err:12 https://packages.cloud.google.com/apt google-compute-engine-bookworm-bookworm Release
404 Not Found [IP: 142.250.178.238 443]
Hit:13 http://deb.freepbx.org/freepbx17-prod bookworm InRelease
Reading package lists… Done
E: The repository ‘https://packages.cloud.google.com/apt google-compute-engine-bookworm-bookworm Release’ does not have a Release file.
N: Updating from such a repository can’t be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

Those have nothing to do with the install script. AWS and Google highly modify their ISO releases. So Google added repos of their own and one isn’t responding.

I’m not so sure after running the command

$ sudo fwconsole ma downloadinstall sysadmin --tag=17.0.2.35
$ sudo fwconsole sa disable-deb-update-v13
$ apt-add-repository -L | grep stable

on 3 different freepbx machines the problem appears which was not present before

In /etc/apt/sources.list.d file google-cloud.list has changed from

deb https://packages.cloud.google.com/apt google-compute-engine-bookworm-stable main
deb https://packages.cloud.google.com/apt cloud-sdk-bookworm main

to

deb https://packages.cloud.google.com/apt google-compute-engine-bookworm-bookworm main
deb https://packages.cloud.google.com/apt cloud-sdk-bookworm main

I had to restore google-cloud.list from bookworm to Stable and now it works again

@kgupta @penguinpbx this whole issue is only because you want to load the libfdk-aac2 package which is in the non-free repo. If it weren’t for that then there would be no need at all to modify standard OS repos.

What if you brought this package into the freepbx repo instead?

Or by default don’t load it and if someone wants to use that then they modify the repo definition and add it themselves.

edit: alternatively, it can be cloned from GitHub - mstorsjo/fdk-aac: A standalone library of the Fraunhofer FDK AAC code from Android. and built (no dependencies required outside of standard library) in a couple minutes. This is the same source as used to build the non-free package.

1 Like

They can’t, it’s a licensing issue. Even with Asterisk, it will only detect if libfdk-aac2 is installed and if it is, it will compile against it. You need to install it on your own for Asterisk to use it. I think you can do ./configure --with-fdk-aac with Asterisk which will trigger it to install but I’ve never tested it with that.

But the licensing of libfdk-aac2 prevents it from be re-distributed with GPL software.

Isn’t much the point of the freepbx repo (I mean the apt repo of course) so that SNG can distribute their non-free stuff like sysadmin module binaries?

Given what I wrote above, I think the script is a bit intrusive.

It changes from stable to bookworm even where it shouldn’t, for example in /etc/apt/sources.list.d file/google-cloud.list

1 Like

It needs a minor tweak to fix this problem. There was a reason I said it needed to be fully tested against various use case scenarios before merging it with the main branch. I can cancel the current PR and push a new update with the needed tweaks but won’t be able to do it until way later tonight.

However, since this change hasn’t been merged unless you’re using that PR commit explicitly it had no impact on the install. If you did use it, you should have noted the whole “Needs to be tested” disclaimer but you did find a bug that testing should have shown. So there is that silver lining.

I understand, but the problem is upstream, meaning that any updates to the Bookworm branch should have been blocked.

In any case, could you kindly confirm that the proposed patch only affects the files in the /etc/apt/sources.list.d folder?

I would be grateful.

No since that wouldn’t cover all the areas that these changes needed to be in. I can confirm the update will be more targeted and not match against <version>-stable which is what happened in this case.

Thanks, but maybe I explained myself badly, I meant, can you confirm that the current commands

$ sudo fwconsole ma downloadinstall sysadmin --tag=17.0.2.35
$ sudo fwconsole sa disable-deb-update-v13
$ apt-add-repository -L | grep stable

currently only work in the /etc/apt/sources.list.d folder?

Those fwconsole and apt-add-repository commands are independent of the working directory.

It looks like the issue is that Google is using both the words “bookworm” and “stable” in their repo names :face_with_spiral_eyes:. In this situation, it does not appear that there is anything actually for you to do, at least not in that file. The adjustments offered previously are targeted towards standard Debian repositories.

No clue, that’s a commercial module we can’t see the source to. Can’t speak to what if fully does with the update.

@BlazeStudios I offered an alternate approach at fixing this in the installer: Avoid updating OS repos; install libfdk-aac from source instead by billsimon · Pull Request #196 · FreePBX/sng_freepbx_debian_install · GitHub

The fact is this whole mess is only because the installer wants to load non-free repo for a single library, which builds and installs from source without any fuss.

Whether they choose your solution or mine I do not care, both will work.

But here’s the really stupid part, the ffmpeg that is installed from the Sangoma repo doesn’t even work right :frowning: [bug]: ffmpeg from Sangoma Debian repo does not actually use libfdk-aac for which it is compiled · Issue #834 · FreePBX/issue-tracker · GitHub

Once ffmpeg is rebuilt for Debian, either the compiled option (my proposal), or the packaged version of libfdk_aac from the non-free repo, will be used. Not even sure how much value there is, since ffmpeg has a reasonable AAC encoder built in (apparently libfdk_aac is slightly better in some circumstances).

Asterisk doesn’t use ffmpeg for MoH streaming. So only focusing on ffmpeg ignores other places that might want this. Asterisk does have a built in aac so you can use res_aac but you need libfdk-aac for res_fdk_aac to be used. Based on what I’ve read, even with ffmpeg, using the built-in options are lower quality and have limitations vs using libfdk-aac.

As to the licensing mentioned earlier, Sangoma would have to put libfdk-aac in the commercial repos to avoid license violations. Not sure how that would impact non-commercial install options.

I focused on ffmpeg because the only place in the FreePBX source that references the aac codec is a PHP library that calls out to ffmpeg. This appears to be used by the call recordings report module.

For what it’s worth, Sangoma had no issue distributing fdk-aac from their SNG7 repo. It’s installed in the FreePBX 16 distro.

I’m going to guess it is because the 16 ISO was considered a commercial product and licensed as such. That, based on what I’ve read, does not violate the license for fdk-aac. They could do the same for v17 but it has to be served up from the commercial repo, not a repo that has GPL based software in it.

The work around for years (think mp3) was to have a folder somewhere called “contrib” with a script the user would run to add what was needed. So it was not being included, distributed, or installed by the dev but by the user. the following may be a bad example as it looks like it was on their svn to be added but there was a manual process to do it which apparently is ok with the lawyers.

Does I need this if I’m already running FreePBX 17 on Debian 12?

It is advised to be careful when running apt update and apt upgrade because if you mistakenly manually accept the offer to upgrade to 13 – despite the warnings listed – then you are likely to run into a lot of problems running FreePBX. Whether these problems are apparent immediately, or not, or if you are able to fix them yourself, is an open question.

Should you @unlikely choose the road less taken by assertively pressing ‘Y’ during those upgrades :pray: please know that any patches you uncover along your academic journey towards improved PHP v8.4 language support, linting, unit testing, documentation, and the like would be warmly received for review in the GitHub repositorieshopefully with one eye on the early FreePBX v18 milestone possibilities! :hugs: