In a Galera Cluster, a very old and long running stored procedure creates a temporary file.
CREATE TEMPORARY TABLE IF NOT EXISTS Stats_Action_Temp ...
Then proceeds to work the temp file.
The connected database works correctly.
However the connected (slave) server does not see or execute the temporary file creation and fails in the sync. The galera sync stops and can only be restart with a server restart and a full rsync
Error I now get:
2024-07-11 12:30:01 2 [ERROR] Slave SQL: Error 'Table 'Playback_Stats.Stats_Content_Temp' doesn't exist' on query. Default database:
'Playback_Stats'. Query: 'INSERT INTO Content_Stats
Followed by error:
2024-07-11 12:30:01 2 [ERROR] Slave SQL: Could not execute Write_rows_v1 event on table Playback_Stats.Artist_Stats; Duplicate entry
'365-ENG-64' for key 'PRIMARY', Error_code: 1062; handler error HA_ERR_FOUND_DUPP_KEY; the event's master log FIRST, end_log_pos 0,
Internal MariaDB error code: 1062
2024-07-11 12:30:01 2 [Warning] WSREP: Event 3 Write_rows_v1 apply failed: 121, seqno 2132
2024-07-11 12:30:01 0 [Note] WSREP: Member 1(kvmub.hq.amar.com) initiates vote on bfc9aad9-3fa7-11ef-aced-ae734f946aa8:2132,e969322a244c5e36: Duplicate entry '365-ENG-64' for key 'PRIMARY', Error_code: 1062;
2024-07-11 12:30:01 0 [Note] WSREP: Votes over bfc9aad9-3fa7-11ef-aced-ae734f946aa8:2132:
e969322a244c5e36: 1/2
Waiting for more votes.
2024-07-11 12:30:01 0 [Note] WSREP: Member 0(dbu.hq.amar.com) responds to vote on bfc9aad9-3fa7-11ef-aced-ae734f946aa8:2132,0000000000000000: Success
2024-07-11 12:30:01 0 [Note] WSREP: Votes over bfc9aad9-3fa7-11ef-aced-ae734f946aa8:2132:
0000000000000000: 1/2
e969322a244c5e36: 1/2
Winner: 0000000000000000
2024-07-11 12:30:01 2 [ERROR] WSREP: Inconsistency detected: Inconsistent by consensus on bfc9aad9-3fa7-11ef-aced-ae734f946aa8:2132
at ./galera/src/replicator_smm.cpp:process_apply_error():1370
2024-07-11 12:30:01 2 [Note] WSREP: Closing send monitor...
2024-07-11 12:30:01 2 [Note] WSREP: Closed send monitor.
2024-07-11 12:30:01 2 [Note] WSREP: gcomm: terminating thread
2024-07-11 12:30:01 2 [Note] WSREP: gcomm: joining thread
2024-07-11 12:30:01 2 [Note] WSREP: gcomm: closing backend
2024-07-11 12:30:02 2 [Note] WSREP: view(view_id(NON_PRIM,161ede6b-9789,2) memb
{
3cf93891-8be8,0
}
joined {
} left {
} partitioned
{
161ede6b-9789,0
}
)
2024-07-11 12:30:02 2 [Note] WSREP: PC protocol downgrade 1 -> 0
2024-07-11 12:30:02 2 [Note] WSREP: view((empty))
2024-07-11 12:30:02 2 [Note] WSREP: gcomm: closed
2024-07-11 12:30:02 0 [Note] WSREP: New COMPONENT: primary = no, bootstrap = no, my_idx = 0, memb_num = 1
2024-07-11 12:30:02 0 [Note] WSREP: Flow-control interval: [16, 16]
2024-07-11 12:30:02 0 [Note] WSREP: Received NON-PRIMARY.
2024-07-11 12:30:02 0 [Note] WSREP: Shifting SYNCED -> OPEN (TO: 2132)
2024-07-11 12:30:02 0 [Note] WSREP: New SELF-LEAVE.
2024-07-11 12:30:02 0 [Note] WSREP: Flow-control interval: [0, 0]
2024-07-11 12:30:02 0 [Note] WSREP: Received SELF-LEAVE. Closing connection.
2024-07-11 12:30:02 0 [Note] WSREP: Shifting OPEN -> CLOSED (TO: 2132)
2024-07-11 12:30:02 0 [Note] WSREP: RECV thread exiting 0: Success
2024-07-11 12:30:02 2 [Note] WSREP: recv_thread() joined.
2024-07-11 12:30:02 2 [Note] WSREP: Closing send queue.
2024-07-11 12:30:02 2 [Note] WSREP: Closing receive queue.
Transition |
Time In Source Status |
Execution Times |
Open |
|
Needs Feedback |
|
10d 9h 49m
|
1
|
Needs Feedback |
|
Open |
|
35d 8h 24m
|
1
|
{"report":{"fcp":671.9000000953674,"ttfb":171.40000009536743,"pageVisibility":"visible","entityId":130051,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":1,"journeyId":"92d3709f-512d-4813-aba0-71245cfb9867","navigationType":0,"readyForUser":749.8000001907349,"redirectCount":0,"resourceLoadedEnd":823.8000001907349,"resourceLoadedStart":176.5,"resourceTiming":[{"duration":8.800000190734863,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2bsh/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":176.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":176.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":185.30000019073486,"responseStart":0,"secureConnectionStart":0},{"duration":8.699999809265137,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2bsh/820016/12ta74/eb142f92e4bd16bd1ef8b08c1b9d5d56/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":176.80000019073486,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":176.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":185.5,"responseStart":0,"secureConnectionStart":0},{"duration":66.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/b09d0d077992e4331b5f9ec0d3ec448c-CDN/lu2bsh/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":176.90000009536743,"connectEnd":176.90000009536743,"connectStart":176.90000009536743,"domainLookupEnd":176.90000009536743,"domainLookupStart":176.90000009536743,"fetchStart":176.90000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":176.90000009536743,"responseEnd":243,"responseStart":243,"secureConnectionStart":176.90000009536743},{"duration":183.59999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/b47ab3df14096803b180217eb8482517-CDN/lu2bsh/820016/12ta74/eb142f92e4bd16bd1ef8b08c1b9d5d56/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true","startTime":177,"connectEnd":177,"connectStart":177,"domainLookupEnd":177,"domainLookupStart":177,"fetchStart":177,"redirectEnd":0,"redirectStart":0,"requestStart":177,"responseEnd":360.59999990463257,"responseStart":360.59999990463257,"secureConnectionStart":177},{"duration":187.2000002861023,"initiatorType":"script","name":"https://jira.mariadb.org/s/6c569cbf8087ab04e40d0bef98627457-CDN/lu2bsh/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":177.09999990463257,"connectEnd":177.09999990463257,"connectStart":177.09999990463257,"domainLookupEnd":177.09999990463257,"domainLookupStart":177.09999990463257,"fetchStart":177.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":177.09999990463257,"responseEnd":364.30000019073486,"responseStart":364.30000019073486,"secureConnectionStart":177.09999990463257},{"duration":187.90000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bsh/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":177.19999980926514,"connectEnd":177.19999980926514,"connectStart":177.19999980926514,"domainLookupEnd":177.19999980926514,"domainLookupStart":177.19999980926514,"fetchStart":177.19999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":177.19999980926514,"responseEnd":365.09999990463257,"responseStart":365.09999990463257,"secureConnectionStart":177.19999980926514},{"duration":187.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bsh/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":177.19999980926514,"connectEnd":177.19999980926514,"connectStart":177.19999980926514,"domainLookupEnd":177.19999980926514,"domainLookupStart":177.19999980926514,"fetchStart":177.19999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":177.19999980926514,"responseEnd":364.69999980926514,"responseStart":364.69999980926514,"secureConnectionStart":177.19999980926514},{"duration":188.19999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2bsh/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":177.40000009536743,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":177.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":365.59999990463257,"responseStart":0,"secureConnectionStart":0},{"duration":188.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":177.5,"connectEnd":177.5,"connectStart":177.5,"domainLookupEnd":177.5,"domainLookupStart":177.5,"fetchStart":177.5,"redirectEnd":0,"redirectStart":0,"requestStart":177.5,"responseEnd":365.59999990463257,"responseStart":365.59999990463257,"secureConnectionStart":177.5},{"duration":188.30000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2bsh/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":177.69999980926514,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":177.69999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":366,"responseStart":0,"secureConnectionStart":0},{"duration":188.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/81b5d7c27af3ebc078cc4a36383678ba-CDN/lu2bsh/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":177.69999980926514,"connectEnd":177.69999980926514,"connectStart":177.69999980926514,"domainLookupEnd":177.69999980926514,"domainLookupStart":177.69999980926514,"fetchStart":177.69999980926514,"redirectEnd":0,"redirectStart":0,"requestStart":177.69999980926514,"responseEnd":366.19999980926514,"responseStart":366.19999980926514,"secureConnectionStart":177.69999980926514},{"duration":503.59999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bsh/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":178.40000009536743,"connectEnd":178.40000009536743,"connectStart":178.40000009536743,"domainLookupEnd":178.40000009536743,"domainLookupStart":178.40000009536743,"fetchStart":178.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":178.40000009536743,"responseEnd":682,"responseStart":682,"secureConnectionStart":178.40000009536743},{"duration":504.59999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bsh/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":178.40000009536743,"connectEnd":178.40000009536743,"connectStart":178.40000009536743,"domainLookupEnd":178.40000009536743,"domainLookupStart":178.40000009536743,"fetchStart":178.40000009536743,"redirectEnd":0,"redirectStart":0,"requestStart":178.40000009536743,"responseEnd":683,"responseStart":683,"secureConnectionStart":178.40000009536743},{"duration":276.69999980926514,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":396,"connectEnd":396,"connectStart":396,"domainLookupEnd":396,"domainLookupStart":396,"fetchStart":396,"redirectEnd":0,"redirectStart":0,"requestStart":396,"responseEnd":672.6999998092651,"responseStart":672.6999998092651,"secureConnectionStart":396},{"duration":19.899999618530273,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":664.8000001907349,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":664.8000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":684.6999998092651,"responseStart":0,"secureConnectionStart":0},{"duration":34.40000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2bsh/820016/12ta74/e65b778d185daf5aee24936755b43da6/_/download/contextbatch/js/browser-metrics-plugin.contrib,-_super,-project.issue.navigator,-jira.view.issue,-atl.general/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":789.4000000953674,"connectEnd":789.4000000953674,"connectStart":789.4000000953674,"domainLookupEnd":789.4000000953674,"domainLookupStart":789.4000000953674,"fetchStart":789.4000000953674,"redirectEnd":0,"redirectStart":0,"requestStart":789.4000000953674,"responseEnd":823.8000001907349,"responseStart":823.8000001907349,"secureConnectionStart":789.4000000953674}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":6,"responseStart":171,"responseEnd":173,"domLoading":175,"domInteractive":870,"domContentLoadedEventStart":870,"domContentLoadedEventEnd":916,"domComplete":1080,"loadEventStart":1080,"loadEventEnd":1081,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":844.5},{"name":"bigPipe.sidebar-id.end","time":845.3000001907349},{"name":"bigPipe.activity-panel-pipe-id.start","time":845.4000000953674},{"name":"bigPipe.activity-panel-pipe-id.end","time":846.5999999046326},{"name":"activityTabFullyLoaded","time":934.8000001907349}],"measures":[],"correlationId":"4317f372ec56a8","effectiveType":"4g","downlink":9,"rtt":0,"serverDuration":98,"dbReadsTimeInMs":16,"dbConnsTimeInMs":25,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}