Skip to content
Federico Stagni edited this page Oct 30, 2026 · 20 revisions

DIRAC v9.1

DIRAC v9.1 main features include:

  • complete removal support for python2 pilot
  • possibility to specify a global index prefix for OpenSearch indices
  • added DiracTime utility
  • RSS simplifications
  • removed TornadoREST and AuthHandler (#8816), followed by the removal of the unused legacy AuthServer, its OAuth2 grants and AuthDB (#8854): this OAuth functionality is provided by DiracX and never found a usage in DIRAC
  • security and performance improvements

Time management within allocations has been fixed (a83fa25). Please double check your CPUTime values in your JDLs (expressed in DB12.seconds) as well as in your CEs configuration (expressed in minutes) as you might get payloads running out of time if they are not correct.

Migration from v9.0 to v9.1

Note Always upgrade from the last release of v9.0.X to the last release of v9.1.X

Database changes

from #8473:

USE ResourceManagementDB;
DROP TABLE AccountingCache;
ALTER TABLE SpaceTokenOccupancyCache DROP COLUMN endpoint;

If the last command fails follow this manual fix:

  1. Check what's duplicated:
SELECT Token, COUNT(*) AS n, GROUP_CONCAT(Endpoint)
FROM SpaceTokenOccupancyCache
GROUP BY Token
HAVING n > 1;
  1. Stop the CacheFeederAgent (and any ResourceManagement service) to avoid writes during the migration — the table is small, so this takes seconds.
  2. Deduplicate — keep only the most recent row per Token:
DELETE t1 FROM SpaceTokenOccupancyCache AS t1
JOIN SpaceTokenOccupancyCache AS t2
  ON t1.Token = t2.Token
 AND (t1.LastCheckTime, t1.Endpoint) < (t2.LastCheckTime, t2.Endpoint);
  1. Now drop the column:
ALTER TABLE SpaceTokenOccupancyCache DROP COLUMN Endpoint;
  1. Restart the agent/service.

from #8642 and #8643, #8446:

USE JobDB;
ALTER TABLE `Jobs` ADD INDEX `JobName` (`JobName`), ALGORITHM=INPLACE, LOCK=NONE;

USE PilotAgentsDB;
ALTER Table `PilotAgents` ADD INDEX `idx_dest_queue_status` (`DestinationSite`,`Queue`,`Status`), ALGORITHM=INPLACE, LOCK=NONE;

USE TaskQueueDB;
ALTER TABLE tq_TQToBannedSites ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;
ALTER TABLE tq_TQToGridCEs ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;
ALTER TABLE tq_TQToGridMiddlewares ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;
ALTER TABLE tq_TQToJobTypes ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;
ALTER TABLE tq_TQToPlatforms ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;
ALTER TABLE tq_TQToSites ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;
ALTER TABLE tq_TQToTags ADD PRIMARY KEY (TQId, Value), DROP INDEX TaskIndex;

USE ResourceStatusDB;
DROP TABLE `NodeHistory`;
DROP TABLE `NodeLog`;
DROP TABLE `NodeStatus`;

from #8714:

USE ReqDB;
CREATE INDEX idx_request_status_notbefore_lastupdate ON Request (Status, NotBefore, LastUpdate) ALGORITHM=INPLACE LOCK=NONE;

from #8842:

USE FileCatalogDB;
ALTER TABLE FC_Replicas MODIFY COLUMN RepID BIGINT NOT NULL AUTO_INCREMENT, ALGORITHM=COPY;
ALTER TABLE FC_ReplicaInfo MODIFY COLUMN RepID BIGINT NOT NULL AUTO_INCREMENT, ALGORITHM=COPY;

Note that data-type changes are not eligible for INPLACE/INSTANT, so ALGORITHM=COPY rebuilds the table and blocks concurrent DML for its duration. On very large FC_Replicas tables consider using pt-online-schema-change or gh-ost instead.

from #8854 (following the removal of TornadoREST and AuthHandler in #8816):

DROP DATABASE AuthDB;

Sites that ran the old AuthHandler (or AuthServer) can drop the AuthDB database. If you never ran these services, there is nothing to do.

CS changes

  • Remove CS entry /Operations/<>/ResourceStatus/StatusTypes
  • from #8520
    • for users of advanced RSS policies: the configuration is only partially backward compatible. The incompatibility is that the old policy type names (DTOngoing, DTScheduled*, FreeDiskSpaceTB/GB/MB, PropagationPolicy) were consolidated into Downtime, FreeDiskSpace and Propagation. Existing CS sections referencing the old names are silently skipped, so affected deployments must rename those sections/types and move hours/unit into the new args. Additionally, two default behaviors change with no CS change: the FreeDiskSpace policy now also applies fraction thresholds (1% Banned / 5% Degraded), so large SEs may flip to Degraded.

Skeleton document for migration

What follows is a skeleton of migration. We suggest to copy/paste/edit what is below, adapting it to your installation. It contains few sections, starting from "PRE".

PRE

Things that have to be done in v9.0, before you even start considering a migration

  • Update to the latest v9.0.X release

the day before the update

  • Partial drain

deep downtime

  • stop services
  • update the databases (instructions above)
  • update the version
  • restart everything

Clone this wiki locally