Trouble upgrading to 25.10.1

I am running TrueNAS 25.04.2.6 and trying to upgrade to 25.10.1 and am getting a barrage of errors as follows hereupon. Can anyone suggest what steps I might need to take to remediate my server such that it can be upgraded?

[EFAULT] Error: Command [‘chroot’, ‘/tmp/tmpv4kdi2zw’, ‘migrate’] failed with exit code 1: + DATABASE=/data/freenas-v1.db + PWENC_SECRET=/data/pwenc_secret + python3 -c import os; import sys; sys.path.remove(“”) if “” in sys.path else None; import middlewared; print(os.path.dirname(middlewared._spec_.origin)) + cd /usr/lib/python3/dist-packages/middlewared + FREENAS_DATABASE=/data/freenas-v1.db FREENAS_PWENC_SECRET=/data/pwenc_secret alembic upgrade head INFO [alembic.runtime.migration] Context impl SQLiteImpl. INFO [alembic.runtime.migration] Will assume non-transactional DDL. INFO [alembic.runtime.migration] Running upgrade 9ada77affbb9 → 5fda0931889d, Drop vm tables INFO [alembic.runtime.migration] Running upgrade 5fda0931889d → ed9a781ec0c6, Remove disk_smartoptions INFO [alembic.runtime.migration] Running upgrade ed9a781ec0c6, 0257529fa6d5 → 616c19f82016, Merge migration for adding uid/gid 568 idmap INFO [alembic.runtime.migration] Running upgrade 616c19f82016 → a156968d5cbb, Remove syslog_tls_certificate_authority INFO [alembic.runtime.migration] Running upgrade a156968d5cbb → 940b79ac591f, API key revoked reason INFO [alembic.runtime.migration] Running upgrade 940b79ac591f → 801eb4df44ce, Rename uq_truenas_enclosurelabel_encid to uq_enclosure_label_encid INFO [alembic.runtime.migration] Running upgrade 801eb4df44ce, df0bffcf1595 → a34e4c124c25, Merge migration for incus storage pools INFO [alembic.runtime.migration] Running upgrade a34e4c124c25 → cf1f98f4c3b1, Remove system.general language column. INFO [alembic.runtime.migration] Running upgrade cf1f98f4c3b1 → 9a5b103ec2e4, Remove CA plugin INFO [alembic.runtime.migration] Running upgrade 9a5b103ec2e4 → f15312414057, Remove SMART support INFO [alembic.runtime.migration] Running upgrade f15312414057, 249b95f63f76 → d7e3a916db65, Merge migration after adding account policy columns INFO [alembic.runtime.migration] Running upgrade d7e3a916db65 → 595b38b52541, Disable password when empty string is used. INFO [alembic.runtime.migration] Running upgrade 595b38b52541 → cafccdf50053, Cloud backup cache path INFO [alembic.runtime.migration] Running upgrade cafccdf50053 → 08febd74cdf9, Add nvmet INFO [alembic.runtime.migration] Running upgrade 08febd74cdf9 → aeae837fb2d5, Periodic snapshot task state INFO [alembic.runtime.migration] Running upgrade aeae837fb2d5, 30c9619bf9e7 → c227e49be4d8, Merge INFO [alembic.runtime.migration] Running upgrade c227e49be4d8 → dae46dda9606, NVMe target does not require trsvcid for FC INFO [alembic.runtime.migration] Running upgrade dae46dda9606 → f8b0ab7c2275, Migrate directory services to new schema Traceback (most recent call last): File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1900, in _execute_context self.dialect.do_execute( File “/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py”, line 736, in do_execute cursor.execute(statement, parameters) sqlite3.OperationalError: no such index: ix_directoryservice_ldap_ldap_certificate_id The above exception was the direct cause of the following exception: Traceback (most recent call last): File “/usr/bin/alembic”, line 33, in sys.exit(load_entry_point(‘alembic==1.8.1.dev0’, ‘console_scripts’, ‘alembic’)()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/usr/lib/python3/dist-packages/alembic/config.py”, line 590, in main CommandLine(prog=prog).main(argv=argv) File “/usr/lib/python3/dist-packages/alembic/config.py”, line 584, in main self.run_cmd(cfg, options) File “/usr/lib/python3/dist-packages/alembic/config.py”, line 561, in run_cmd fn( File “/usr/lib/python3/dist-packages/alembic/command.py”, line 322, in upgrade script.run_env() File “/usr/lib/python3/dist-packages/alembic/script/base.py”, line 569, in run_env util.load_python_file(self.dir, “env.py”) File “/usr/lib/python3/dist-packages/alembic/util/pyfiles.py”, line 94, in load_python_file module = load_module_py(module_id, path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/usr/lib/python3/dist-packages/alembic/util/pyfiles.py”, line 110, in load_module_py spec.loader.exec_module(module) # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “”, line 940, in exec_module File “”, line 241, in _call_with_frames_removed File “/usr/lib/python3/dist-packages/middlewared/alembic/env.py”, line 167, in run_migrations_online() File “/usr/lib/python3/dist-packages/middlewared/alembic/env.py”, line 161, in run_migrations_online context.run_migrations() File “”, line 8, in run_migrations File “/usr/lib/python3/dist-packages/alembic/runtime/environment.py”, line 853, in run_migrations self.get_context().run_migrations(**kw) File “/usr/lib/python3/dist-packages/alembic/runtime/migration.py”, line 623, in run_migrations step.migration_fn(**kw) File “/usr/lib/python3/dist-packages/middlewared/alembic/versions/25.10/2025-05-17_12-57_migrate-ds.py”, line 434, in upgrade with op.batch_alter_table(‘directoryservice_ldap’, schema=None) as batch_op: File “/usr/lib/python3.11/contextlib.py”, line 144, in _exit_ next(self.gen) File “/usr/lib/python3/dist-packages/middlewared/alembic/env.py”, line 45, in batch_alter_table_impl with original_batch_alter_table(self, *args, **kwargs) as result: File “/usr/lib/python3.11/contextlib.py”, line 144, in _exit_ next(self.gen) File “/usr/lib/python3/dist-packages/alembic/operations/base.py”, line 381, in batch_alter_table impl.flush() File “/usr/lib/python3/dist-packages/alembic/operations/batch.py”, line 111, in flush fn(*arg, **kw) File “/usr/lib/python3/dist-packages/alembic/ddl/impl.py”, line 395, in drop_index self._exec(schema.DropIndex(index)) File “/usr/lib/python3/dist-packages/alembic/ddl/impl.py”, line 195, in _exec return conn.execute(construct, multiparams) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1380, in execute return meth(self, multiparams, params, _EMPTY_EXECUTION_OPTS) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/usr/lib/python3/dist-packages/sqlalchemy/sql/ddl.py”, line 80, in _execute_on_connection return connection._execute_ddl( ^^^^^^^^^^^^^^^^^^^^^^^^ File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1472, in _execute_ddl ret = self._execute_context( ^^^^^^^^^^^^^^^^^^^^^^ File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1943, in _execute_context self._handle_dbapi_exception( File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 2124, in _handle_dbapi_exception util.raise_( File “/usr/lib/python3/dist-packages/sqlalchemy/util/compat.py”, line 211, in raise_ raise exception File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1900, in _execute_context self.dialect.do_execute( File “/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py”, line 736, in do_execute cursor.execute(statement, parameters) sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such index: ix_directoryservice_ldap_ldap_certificate_id [SQL: DROP INDEX ix_directoryservice_ldap_ldap_certificate_id] (Background on this error at: https://sqlalche.me/e/14/e3q8)

upon clicking “More info” I saw this:

Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/middlewared/job.py”, line 515, in run
await self.future
File “/usr/lib/python3/dist-packages/middlewared/job.py”, line 560, in __run_body
rv = await self.method(*args)
^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/schema/processor.py”, line 174, in nf
return await func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/plugins/update.py”, line 287, in update
await self.middleware.call(‘update.install’, job, os.path.join(location, ‘update.sqsh’), options)
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1005, in call
return await self.call(
^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 731, in call
return await self.run_in_executor(prepared_call.executor, methodobj, *prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 624, in run_in_executor
return await loop.run_in_executor(pool, functools.partial(method, *args, **kwargs))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3.11/concurrent/futures/thread.py”, line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/middlewared/plugins/update
/install_linux.py", line 50, in install
self.middleware.call_sync(“update.install_scale”, mounted, progress_callback, options)
File “/usr/lib/python3/dist-packages/middlewared/main.py”, line 1041, in call_sync
return methodobj(*prepared_call.args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/middlewared/plugins/update/install.py”, line 61, in install_scale
self.execute_truenas_install(mounted, command, progress_callback)
File "/usr/lib/python3/dist-packages/middlewared/plugins/update
/install.py", line 92, in _execute_truenas_install
raise CallError(result or f"Abnormal installer process termination with code {p.returncode}")
middlewared.service_exception.CallError: [EFAULT] Error: Command [‘chroot’, ‘/tmp/tmpv4kdi2zw’, ‘migrate’] failed with exit code 1: + DATABASE=/data/freenas-v1.db

  • PWENC_SECRET=/data/pwenc_secret
  • python3 -c import os; import sys; sys.path.remove(“”) if “” in sys.path else None; import middlewared; print(os.path.dirname(middlewared.spec.origin))
  • cd /usr/lib/python3/dist-packages/middlewared
  • FREENAS_DATABASE=/data/freenas-v1.db FREENAS_PWENC_SECRET=/data/pwenc_secret alembic upgrade head
    INFO [alembic.runtime.migration] Context impl SQLiteImpl.
    INFO [alembic.runtime.migration] Will assume non-transactional DDL.
    INFO [alembic.runtime.migration] Running upgrade 9ada77affbb9 → 5fda0931889d, Drop vm tables
    INFO [alembic.runtime.migration] Running upgrade 5fda0931889d → ed9a781ec0c6, Remove disk_smartoptions
    INFO [alembic.runtime.migration] Running upgrade ed9a781ec0c6, 0257529fa6d5 → 616c19f82016, Merge migration for adding uid/gid 568 idmap
    INFO [alembic.runtime.migration] Running upgrade 616c19f82016 → a156968d5cbb, Remove syslog_tls_certificate_authority
    INFO [alembic.runtime.migration] Running upgrade a156968d5cbb → 940b79ac591f, API key revoked reason
    INFO [alembic.runtime.migration] Running upgrade 940b79ac591f → 801eb4df44ce, Rename uq_truenas_enclosurelabel_encid to uq_enclosure_label_encid
    INFO [alembic.runtime.migration] Running upgrade 801eb4df44ce, df0bffcf1595 → a34e4c124c25, Merge migration for incus storage pools
    INFO [alembic.runtime.migration] Running upgrade a34e4c124c25 → cf1f98f4c3b1, Remove system.general language column.
    INFO [alembic.runtime.migration] Running upgrade cf1f98f4c3b1 → 9a5b103ec2e4, Remove CA plugin
    INFO [alembic.runtime.migration] Running upgrade 9a5b103ec2e4 → f15312414057, Remove SMART support
    INFO [alembic.runtime.migration] Running upgrade f15312414057, 249b95f63f76 → d7e3a916db65, Merge migration after adding account policy columns
    INFO [alembic.runtime.migration] Running upgrade d7e3a916db65 → 595b38b52541, Disable password when empty string is used.
    INFO [alembic.runtime.migration] Running upgrade 595b38b52541 → cafccdf50053, Cloud backup cache path
    INFO [alembic.runtime.migration] Running upgrade cafccdf50053 → 08febd74cdf9, Add nvmet
    INFO [alembic.runtime.migration] Running upgrade 08febd74cdf9 → aeae837fb2d5, Periodic snapshot task state
    INFO [alembic.runtime.migration] Running upgrade aeae837fb2d5, 30c9619bf9e7 → c227e49be4d8, Merge
    INFO [alembic.runtime.migration] Running upgrade c227e49be4d8 → dae46dda9606, NVMe target does not require trsvcid for FC
    INFO [alembic.runtime.migration] Running upgrade dae46dda9606 → f8b0ab7c2275, Migrate directory services to new schema
    Traceback (most recent call last):
    File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1900, in _execute_context
    self.dialect.do_execute(
    File “/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py”, line 736, in do_execute
    cursor.execute(statement, parameters)
    sqlite3.OperationalError: no such index: ix_directoryservice_ldap_ldap_certificate_id

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File “/usr/bin/alembic”, line 33, in
sys.exit(load_entry_point(‘alembic==1.8.1.dev0’, ‘console_scripts’, ‘alembic’)())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/alembic/config.py”, line 590, in main
CommandLine(prog=prog).main(argv=argv)
File “/usr/lib/python3/dist-packages/alembic/config.py”, line 584, in main
self.run_cmd(cfg, options)
File “/usr/lib/python3/dist-packages/alembic/config.py”, line 561, in run_cmd
fn(
File “/usr/lib/python3/dist-packages/alembic/command.py”, line 322, in upgrade
script.run_env()
File “/usr/lib/python3/dist-packages/alembic/script/base.py”, line 569, in run_env
util.load_python_file(self.dir, “env.py”)
File “/usr/lib/python3/dist-packages/alembic/util/pyfiles.py”, line 94, in load_python_file
module = load_module_py(module_id, path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/alembic/util/pyfiles.py”, line 110, in load_module_py
spec.loader.exec_module(module) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “”, line 940, in exec_module
File “”, line 241, in _call_with_frames_removed
File “/usr/lib/python3/dist-packages/middlewared/alembic/env.py”, line 167, in
run_migrations_online()
File “/usr/lib/python3/dist-packages/middlewared/alembic/env.py”, line 161, in run_migrations_online
context.run_migrations()
File “”, line 8, in run_migrations
File “/usr/lib/python3/dist-packages/alembic/runtime/environment.py”, line 853, in run_migrations
self.get_context().run_migrations(**kw)
File “/usr/lib/python3/dist-packages/alembic/runtime/migration.py”, line 623, in run_migrations
step.migration_fn(**kw)
File “/usr/lib/python3/dist-packages/middlewared/alembic/versions/25.10/2025-05-17_12-57_migrate-ds.py”, line 434, in upgrade
with op.batch_alter_table(‘directoryservice_ldap’, schema=None) as batch_op:
File “/usr/lib/python3.11/contextlib.py”, line 144, in exit
next(self.gen)
File “/usr/lib/python3/dist-packages/middlewared/alembic/env.py”, line 45, in batch_alter_table_impl
with original_batch_alter_table(self, *args, **kwargs) as result:
File “/usr/lib/python3.11/contextlib.py”, line 144, in exit
next(self.gen)
File “/usr/lib/python3/dist-packages/alembic/operations/base.py”, line 381, in batch_alter_table
impl.flush()
File “/usr/lib/python3/dist-packages/alembic/operations/batch.py”, line 111, in flush
fn(*arg, **kw)
File “/usr/lib/python3/dist-packages/alembic/ddl/impl.py”, line 395, in drop_index
self._exec(schema.DropIndex(index))
File “/usr/lib/python3/dist-packages/alembic/ddl/impl.py”, line 195, in _exec
return conn.execute(construct, multiparams)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1380, in execute
return meth(self, multiparams, params, _EMPTY_EXECUTION_OPTS)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/sqlalchemy/sql/ddl.py”, line 80, in _execute_on_connection
return connection._execute_ddl(
^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1472, in _execute_ddl
ret = self._execute_context(
^^^^^^^^^^^^^^^^^^^^^^
File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1943, in _execute_context
self.handle_dbapi_exception(
File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 2124, in handle_dbapi_exception
util.raise
(
File “/usr/lib/python3/dist-packages/sqlalchemy/util/compat.py”, line 211, in raise
raise exception
File “/usr/lib/python3/dist-packages/sqlalchemy/engine/base.py”, line 1900, in _execute_context
self.dialect.do_execute(
File “/usr/lib/python3/dist-packages/sqlalchemy/engine/default.py”, line 736, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such index: ix_directoryservice_ldap_ldap_certificate_id
[SQL:
DROP INDEX ix_directoryservice_ldap_ldap_certificate_id]
(Background on this error at: https://sqlalche.me/e/14/e3q8)

One additional note is that LDAP seems to no longer be able to connect to my FreeIPA servers (wherein it used to be able to do so). However, I am interested to troubleshoot the upgrade first prior to anything else.

Thanks to anyone that can help.

Have you tried booting to TrueNAS 25.04.2.6 and removing the 25.10.1 boot environment and attempting the upgrade again?

Enough free space on boot and data pools? Downloaded a current system configuration or a few of the last ones, if you keep them? Review release notes to see if LDAP disappeared?

SmallBarky,

Can I ask what in the errors I posted made you come to the conclusions you mentioned? I am just curious, as I wish to understand how you decoded them and understood what was wrong from them.

I do not have a “25.10.1” boot environment and you can see my boot pool has plenty of room. I am a bit curious what my data pools have to do with upgrading my server’s OS?

I am surprised by what you are saying that LDAP support was removed as that would seem to me to be a core functionality for any commercial entity using the supported version of TrueNAS SCALE. WOW… I had not heard that TrueNAS SCALE was removing LDAP support. But, since you seem to be asserting that it was removed I will look at the release notes. It is absolutely stunning, flabbergasting, and appalling TrueNAS would do such a thing. It will absolutely degrade my faith in continuing to use TrueNAS or recommend it to the consulting customers I have.

root@truenas1[~]# zfs list -r boot-pool
NAME USED AVAIL REFER MOUNTPOINT
boot-pool 5.87G 51.3G 96K none
boot-pool/ROOT 5.80G 51.3G 96K none
boot-pool/ROOT/25.04.2.6 3.18G 51.3G 176M legacy
boot-pool/ROOT/25.04.2.6/audit 260M 51.3G 245M /audit
boot-pool/ROOT/25.04.2.6/conf 7.15M 51.3G 7.15M /conf
boot-pool/ROOT/25.04.2.6/data 1.75M 51.3G 308K /data
boot-pool/ROOT/25.04.2.6/etc 7.60M 51.3G 6.60M /etc
boot-pool/ROOT/25.04.2.6/home 2.30M 51.3G 1.03M /home
boot-pool/ROOT/25.04.2.6/mnt 104K 51.3G 104K /mnt
boot-pool/ROOT/25.04.2.6/opt 96K 51.3G 96K /opt
boot-pool/ROOT/25.04.2.6/root 2.14M 51.3G 800K /root
boot-pool/ROOT/25.04.2.6/usr 2.56G 51.3G 2.56G /usr
boot-pool/ROOT/25.04.2.6/var 171M 51.3G 5.23M /var
boot-pool/ROOT/25.04.2.6/var/ca-certificates 108K 51.3G 108K /var/local/ca-certificates
boot-pool/ROOT/25.04.2.6/var/lib 30.7M 51.3G 27.8M /var/lib
boot-pool/ROOT/25.04.2.6/var/lib/incus 2.50M 51.3G 2.50M /var/lib/incus
boot-pool/ROOT/25.04.2.6/var/log 134M 51.3G 37.3M /var/log
boot-pool/ROOT/25.04.2.6/var/log/journal 49.9M 51.3G 49.9M /var/log/journal
boot-pool/ROOT/Initial-Install 2.62G 51.3G 2.62G /
boot-pool/grub 8.20M 51.3G 8.20M legacy
root@truenas1[~]#

root@truenas1[~]# zfs list truenas_1tb_pool
NAME USED AVAIL REFER MOUNTPOINT
truenas_1tb_pool 2.28T 1.94T 204K /mnt/truenas_1tb_pool
root@truenas1[~]#

Thanks for your reply.

LDAP may be fine, it may have been depreciated. I was just saying check through the release notes. There is a lot where users upgrade and don’t check those prior.

You didn’t post any specifics on your system, what it runs and it was just a bunch of errors posted. Erasing a boot environment of a failed upgrade and attempting again was something that has been done in the past where users come across problems.

SmallBarky,

Well, I am willing to put the LDAP issue aside for now as I’d prefer to troubleshoot it once I have instantiated a proper upgrade to the latest code train. That said, I am running TrueNAS SCALE on an IBM x3650. What other information would be helpful in debugging this issue?

I had thought that the errors would be enough to try to figure out what was wrong. What did you understand from any of those errors?

Thank you.

A full hardware and setup listing may have clues for others. I don’t run any Apps or VMs on my TrueNAS.

Trying to diag an upgrade is usually easier to try to do the upgrade again. I don’t know if it make a difference to go from 25.04.2.6 directly to 25.10.1 or you need to do the first upgrade to 25.10 then 25.10.1. The usual advice is last upgrade on previous version to next release then the latest in that series.

Another option is to have the backup system configuration and do a fresh install of 25.10.1 and restore the configuration.

You can await other responses also. If you aren’t in a hurry to get the upgrade done, that may be good and get more opinions.

Hello,

I have the exact same issue.
I configured my instance with freeIPA, not only LDAP.

I tried to backup and restore in version 25.10, but i got the same error.

Keep looking arround for a solution.

@stuartbh @EtienneBarbier As has been posted many times, it is difficult to troubleshoot system problems without knowing the details of your system. It’s like saying My car is making a knocking noise - how do I fix it? The error messages tell you something about what is not working, but they don’t tell you why. Other than some general comments, it is not possible to offer specific help.

What are the full details of your systems? Are they bare metal installations or running in a VM? Both of you mentioned using FreeIPA. I have no experience with FreeIPA so I can’t help you, but others might have some insight.

Good luck,

I got it.
After comparing the contents of my database with those of a brand new 25.04 installation, I noticed that some indexes were missing from the database.

We just need to add them to allow an update to 25.10.
The following commands will create theses indexes into the truenas DB.

sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_activedirectory_ad_kerberos_realm_id ON directoryservice_activedirectory (ad_kerberos_realm_id)”
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_idmap_domain_idmap_domain_certificate_id ON directoryservice_idmap_domain (idmap_domain_certificate_id)”
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_ldap_ldap_certificate_id ON directoryservice_ldap (ldap_certificate_id)”
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_ldap_ldap_kerberos_realm_id ON directoryservice_ldap (ldap_kerberos_realm_id)”

Then, just run the upgrade. It succeed on my side.

I don’t know why theses indexes were not present on my instance, maybe because i migrated from CORE in the first place… (maybe not)

EtienneBarbier,

I attempted your fix and this was what I got back:

root@truenas1[~]# cat fixindexes
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_activedirectory_ad_kerberos_realm_id ON directoryservice_activedirectory (ad_kerberos_realm_id)”
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_idmap_domain_idmap_domain_certificate_id ON directoryservice_idmap_domain (idmap_domain_certificate_id)”
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_ldap_ldap_certificate_id ON directoryservice_ldap (ldap_ldap_certificate_id)”
sqlite3 /data/freenas-v1.db “CREATE INDEX ix_directoryservice_ldap_ldap_kerberos_realm_id ON directoryservice_ldap (ldap_kerberos_realm_id)”

root@truenas1[~]# source fixindexes
fixindexes:1: no matches found: (ad_kerberos_realm_id)”
fixindexes:2: no matches found: (idmap_domain_certificate_id)”
fixindexes:3: no matches found: (ldap_ldap_certificate_id)”
fixindexes:4: no matches found: (ldap_kerberos_realm_id)”
root@truenas1[~]#

I realized that this may be the result of a bug (not using IF EXIST and IF NOT EXIST) In the sqlite3 code and filed a bug report on that. If those sub parameters were used, I suspect this issue would not be occurring at all.

I am a bit nervous about continuing to use TrueNAS (and recommending it to customers) as it seems that these sort of code protection methodologies should be obvious to those that wrote the sqlite3 code. But we shall see what changes are forthcoming.

Thank you though and I am still open to attempting to resolve this, though my patience with TrueNAS is growing thinner.