Coral EdgeTPU m.2 (for Frigate) not able to install on 24.10 (Electric Eel)

check how many lanes that slot has, you need two lanes to use a dual TPU, an adapter won’t help, even with lane splitting/bifurcation AFAIK

in my case the mobo m.2’s are all single lane so I had to get the single tpu

EDIT: based on cursory research, if you use the slot that’s meant for the SSD you may be able to make it work, but the one that had the WLAN card is single lane so at absolute best you will get 1 TPU (and most likely neither)

FWIW using the 4x slot for the dual TPU is a waste because it will only consume 2 lanes, I’d recommend just getting a single and putting it in the WLAN slot

anyone tested Coral EdgeTPU on FANGTOOTH (25.04)?

EDIT:
Tested now and was successfull.

my steps were:

sudo visudo

#Defaults log_subcmds

then used the steps from @campagnolo - BUT: be sure you call the debuild with sudo:

systemd-sysext unmerge
install-dev-tools
apt install dkms devscripts debhelper dh-dkms -y
git clone https://github.com/heitbaum/gasket-driver
cd gasket-driver
sudo debuild -us -uc -tc -b -d                        <-- must use sudo here
cd ..
dpkg -i gasket-dkms_1.0-18_all.deb
systemd-sysext merge

# if everything was successful
reboot
3 Likes

I followed this completely on a fresh Fangtooth install and it consistently fails at the sudo debuild step. Error I receive is:

sudo: process 1717401 unexpected status 0x57f
dpkg-buildpackage: error: debian/rules clean subprocess was killed by signal 9
debuild: fatal error at line 1182:
dpkg-buildpackage -us -uc -ui -tc -b -d failed

Looking inside debian/rules:

include /usr/share/dpkg/pkg-info.mk

%:
dh $@ --with dkms

override_dh_install:
dh_install src/* usr/src/gasket-$(DEB_VERSION_UPSTREAM)/

override_dh_dkms:
dh_dkms -V $(DEB_VERSION_UPSTREAM)

override_dh_auto_configure:
override_dh_auto_build:
override_dh_auto_test:
override_dh_auto_install:
override_dh_auto_clean:

Something in the rules is getting killed.

Not having luck on Fangtooth either (an upgrade install, things worked fine on Electric Eel).

So far I’m trying to just do the same steps again and the following happens when doing install_dev_tools:

[...]
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up gasket-dkms (1.0-18) ...
Removing old gasket-1.0 DKMS files...
Deleting module gasket-1.0 completely from the DKMS tree.
Loading new gasket-1.0 DKMS files...
Deprecated feature: REMAKE_INITRD (/usr/src/gasket-1.0/dkms.conf)
Building for 6.12.15-production+truenas
Building initial module for 6.12.15-production+truenas
Deprecated feature: REMAKE_INITRD (/var/lib/dkms/gasket/1.0/source/dkms.conf)
Error! Bad return status for module build on kernel: 6.12.15-production+truenas 
(x86_64)
Consult /var/lib/dkms/gasket/1.0/build/make.log for more information.
dpkg: error processing package gasket-dkms (--configure):
 installed gasket-dkms package post-installation script subprocess returned erro
r exit status 10
Errors were encountered while processing:
 gasket-dkms
E: Sub-process /usr/bin/dpkg returned an error code (1)

and the logfile /var/lib/dkms/gasket/1.0/build/make.log says:

Thu May  8 21:21:29 PDT 2025
make: Entering directory '/usr/src/linux-headers-truenas-production-amd64'
  CC [M]  /var/lib/dkms/gasket/1.0/build/gasket_core.o
  CC [M]  /var/lib/dkms/gasket/1.0/build/gasket_ioctl.o
  CC [M]  /var/lib/dkms/gasket/1.0/build/gasket_interrupt.o
  CC [M]  /var/lib/dkms/gasket/1.0/build/gasket_page_table.o
  CC [M]  /var/lib/dkms/gasket/1.0/build/gasket_sysfs.o
  CC [M]  /var/lib/dkms/gasket/1.0/build/apex_driver.o
/var/lib/dkms/gasket/1.0/build/gasket_core.c:1376:19: error: 'no_llseek' undeclared here (not in a function); did you mean 'noop_llseek'?
 1376 |         .llseek = no_llseek,
      |                   ^~~~~~~~~
      |                   noop_llseek
make[2]: *** [scripts/Makefile.build:229: /var/lib/dkms/gasket/1.0/build/gasket_core.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [/usr/src/linux-headers-truenas-production-amd64/Makefile:1940: /var/lib/dkms/gasket/1.0/build] Error 2
make: *** [Makefile:227: __sub-make] Error 2
make: Leaving directory '/usr/src/linux-headers-truenas-production-amd64'

sudo: process 1717401 unexpected status 0x57f

I discovered this error is due to trying to run the script from the boot pool.

Create a folder on the storage pool for doing this compilation. For some reason, Fangtooth doesn’t let you run scripts that are stored on the boot pool.

I’m now at the point where I’ve got the .deb package to build, but can’t get it installed!

1 Like

Success! Coral M.2 pci TPU working in Frigate App on TrueNAS Fangtooth
What a hassle though.
After editing the Frigate app config to passthrough the device:
host device:
/dev/apex_0
container device:
/dev/apex_0

it’s working

Follow-up, working on Truenas Fangtooth (25.04.0). Brief notes:

3 Likes

has anybody looked at creatinga sysext for these drivers?
(for example cloning a boot partion with no dev tools installed, rebooting to the new part, creating the sysext and saving it to one of the non-boot pools) then rebooting to the unmodified boot image and applying the sysext?

that’s a great Idea - although I am not very experienced with this. But maybe a idea to follow!

btw. workaround tested for 25.04.1
for building I had to logout to unprivileged user and start building with
sudo debuild -us -uc -tc -b -d

1 Like

given coral support is dying overall, i chose to use a hailo8 card passed through to a VM.

Hi there,

I am trying to install drivers on TrueNAS scale 25.04.2.3.

However, after running the command: sudo debuild -us -uc -tc -b -d
I get the following error:

 dpkg-buildpackage -us -uc -ui -tc -b -d
dpkg-buildpackage: info: source package gasket-dkms
dpkg-buildpackage: info: source version 1.0-18
dpkg-buildpackage: info: source distribution unstable
dpkg-buildpackage: info: source changed by Coral <coral-support@google.com>
 dpkg-source --before-build .
dpkg-buildpackage: info: host architecture amd64
 debian/rules clean
sudo: process 3299565 unexpected status 0x57f
dpkg-buildpackage: error: debian/rules clean subprocess was killed by signal 9
debuild: fatal error at line 1182:
dpkg-buildpackage -us -uc -ui -tc -b -d failed

Does anyone know what to do and how to fix it?

Thanks

you checked this?

I think yes. I did it this way (correct me if I’m wrong):

  • connect by SSH with admin user (UID 950)
  • then following commands
sudo -i
systemd-sysext unmerge
install-dev-tools
apt install dkms devscripts debhelper dh-dkms -y
git clone https://github.com/heitbaum/gasket-driver
cd gasket-driver
nano src/gasket_core.c
<
go to line  line 1376
delete .llseek = no_llseek,
>
exit // exit from root privileges
sudo debuild -us -uc -tc -b -d

at this point I get my error.

If I run it as a non privileged user, I get this error:

tee: ../gasket-dkms_1.0-18_amd64.build: Permission denied
 dpkg-buildpackage -us -uc -ui -tc -b -d
dpkg-buildpackage: info: source package gasket-dkms
dpkg-buildpackage: info: source version 1.0-18
dpkg-buildpackage: info: source distribution unstable
dpkg-buildpackage: info: source changed by Coral <coral-support@google.com>
 dpkg-source --before-build .
dpkg-buildpackage: info: host architecture amd64
 fakeroot debian/rules clean
/usr/bin/fakeroot: 175: debian/rules: Permission denied
dpkg-buildpackage: error: fakeroot debian/rules clean subprocess returned exit status 126
debuild: fatal error at line 1182:
dpkg-buildpackage -us -uc -ui -tc -b -d failed

Use root, I’d share a link to the .deb package otherwise

1 Like

Just updated to 25.04.2.4 to test this again.
the steps I shared before are still working fine:

why are you editing the gasket_core file?

see attached compiled file, I am not sure if this will work, but you can give it a try.
Just remove the extension .txt
gasket-dkms_1.0-18_all.deb.txt (46.8 KB)

Thanks! With root user I successfully install drivers.

1 Like

Anyone know if this works on goldeye?

Can confirm it works for me, runninh 25.10 Beta1

Thank you so much for these instructions. I am also running TrueNAS 25.04 using the single TPU m.2 device, and I finally was able to get the drivers loading. depmod wasn’t able to write to the cache, thus, I used insmod with as a post init command, and they are loaded after a reboot. Now I should be able to get Frigate to use the device.

1 Like

has anyone made a update for goldeneye ? i keep getting errors trying to install the driver for single edge m.2