PROD ScadaBridge DB: DBA must create the 104 nonclustered indexes before the central starts #59
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
PROD ScadaBridge config DB
wondersqlpd.zmr.zimmer.com/ScadaBridge(WONDER-SQL-VP03) was pre-built by a DBA with tables, PKs, FKs and partitioning but no nonclustered indexes (0 of 104). The app loginwwpdsbrwhas no DDL.Done 2026-11-20 19:48Z as
wwpdsbrw(DML only): 65__EFMigrationsHistoryrows (= QA, last20261115221558_RemoveAuditLogHashChain),zbauth/zbsecretsschema_versionv1,LdapGroupMappingsseed ids 1–5 and the five_PRODrows (ids 6–10). Record:docs/deploy/2026-11-19-prod-stage/2026-11-20-prod-sql-check.md.Owed by the DBA: run
docs/deploy/2026-11-19-prod-stage/sql/prod-complete-dba-schema.sql(idempotent; only the 104CREATE INDEXstatements do anything now) with db_owner/db_ddladmin.Do not start ScadaBridge Central (plan Phase 5) before this. The EF migration check now passes, but the missing unique indexes mean no uniqueness enforcement, and the zbauth/zbsecrets startup migrators will attempt
CREATE INDEXand be denied.Verify after: nonclustered index count = 104 and the QA-vs-PROD schema diff shows 0 index differences.
Updated:
prod-complete-dba-schema.sqlnow holds only what the DBA must do (sha2563e05e167…, commit9c77b6c): the 104 guardedCREATE INDEX(one transaction, refuses unless EF history is at 2e0ce81e), then a read-only check of the 24 default/computed/check definitions against QA. Expected final row: 104 indexes, 0 mismatches, 65 migrations, 10 mappings. The data half is already applied (65 EF history rows, schema_version v1 x2, LdapGroupMappings 1-10); nothing else can be done withwwpdsbrw.Update 2026-11-20 (first PROD run): ScadaBridge 2e0ce81e is installed on vp03/vp04 and stopped, start type Manual until this closes (records ScadaBridge
facf24b2). The central-store seeds also failed on this gate: the SQL Secrets CLI runs the zbsecrets migrator (Cannot find the object \"zbsecrets.secret\" because it does not exist or you do not have permissions= CREATE INDEX denied). After the DBA script: (1) re-stagenam-ldap-central.txtfrom Keychainbtdb-manager/ldapintoE:\psrem-stage\_values\seed\on vp03 (site-psk.txtis still there); (2)seed-secret-prod.ps1 -Target ScadaBridge-Centralfor nam-ldap-svc-password and-SecretName SB-GRPC-PSK-site-par; (3)sc config ScadaBridge-Central start= auto, start vp03, ready, start vp04; §3A.5; (4) Site entity site-par, mxgw API key, MxGateway data connection. Sites site-par are already running (par-vp03 active, par-vp04 standby).Verified 2026-11-20 21:23Z: 104 nonclustered indexes present (tables changed 15:56Z), 368 index partitions. Schema diff vs QA: every index name, key columns, includes and uniqueness match (30 unique, 8 filtered on both); filter texts are hidden from wwpdsbrw so only has_filter could be compared; PK/check names differ only by auto-generated suffix. Then: central store seeded on vp03 (nam-ldap-svc-password, sb-grpc-psk-site-par, readback-match=True), ScadaBridge-Central set back to Automatic, vp03 started 21:24:15Z (ready 200 in 14 s, Akka leader), vp04 ready 200 in 9 s, 2-member pair, vp03 active. Cluster configuration continues (Site site-par, mxgw key, MxGateway connection).