I'm trying to test out Spider, but it doesn't seem to want to connect to the remote server if the remote user doesn't have SUPER privileges. Why is this necessary?
e.g. if I do the following on the remote server:
CREATE DATABASE spider_test;
GRANT ALL PRIVILEGES ON spider_test.* TO spider_test@'%' IDENTIFIED BY 'password';
USE spider_test;
CREATE TABLE local_tab (
id int auto_increment primary key,
str varchar(50)
) ENGINE=InnoDB;
And then the following on the Spider server:
CREATE SERVER srv1
FOREIGN DATA WRAPPER mysql
OPTIONS(
HOST '172.30.0.249',
DATABASE 'spider_test',
USER 'spider_test',
PASSWORD 'password'
);
CREATE DATABASE spider_test;
USE spider_test;
CREATE TABLE spider_tab (
id int auto_increment primary key,
str varchar(50)
) ENGINE=Spider COMMENT='wrapper "mysql", srv "srv1", table "local_tab"';
I am not able to query the spider table:
MariaDB [spider_test]> SELECT * FROM spider_tab;
ERROR 1227 (42000): Access denied; you need (at least one of) the SUPER privilege(s) for this operation
Even though I am able to connect to the remote server and query the table using the regular mysql client:
$ mysql -h 172.30.0.249 -u spider_test -ppassword spider_test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 15
Server version: 10.1.31-MariaDB MariaDB Server
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [spider_test]> SELECT * FROM local_tab;
Empty set (0.00 sec)
The spider table works if I give the user the SUPER privileges.
remote server:
GRANT SUPER ON *.* TO spider_test@'%';
Spider server:
MariaDB [spider_test]> SELECT * FROM spider_tab;
Empty set (0.01 sec)
Why would the remote user need SUPER privileges?
Elena Stepanova
made changes -
2018-03-27 23:11
Field
Original Value
New Value
Fix Version/s
10.2
[ 14601
]
Assignee
Jacob Mathew
[ jacob-mathew
]
Jacob Mathew (Inactive)
made changes -
2018-05-01 22:08
Assignee
Jacob Mathew
[ jacob-mathew
]
Kentoku
[ kentoku
]
Status
In Progress
[ 3
]
In Review
[ 10002
]
Kentoku Shiba (Inactive)
made changes -
2018-05-09 12:12
Assignee
Kentoku
[ kentoku
]
Jacob Mathew
[ jacob-mathew
]
Status
In Review
[ 10002
]
Stalled
[ 10000
]
Jacob Mathew (Inactive)
made changes -
2018-05-09 19:41
Fix Version/s
10.2.15
[ 23006
]
Fix Version/s
10.3.7
[ 23005
]
Fix Version/s
10.2
[ 14601
]
Fix Version/s
10.3
[ 22126
]
Resolution
Fixed
[ 1
]
Status
Stalled
[ 10000
]
Closed
[ 6
]
Sergei Golubchik
made changes -
2021-12-06 21:47
Workflow
MariaDB v3
[ 86257
]
MariaDB v4
[ 154038
]
{"report":{"fcp":1037.8000001907349,"ttfb":436.6000003814697,"pageVisibility":"visible","entityId":66554,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"09369f62-8105-4907-9916-8f2c2bf4d4b1","navigationType":0,"readyForUser":1121.9000005722046,"redirectCount":0,"resourceLoadedEnd":1153.6000003814697,"resourceLoadedStart":442,"resourceTiming":[{"duration":17.300000190734863,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":442,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":442,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":459.30000019073486,"responseStart":0,"secureConnectionStart":0},{"duration":18,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/2bf333562ca6724060a9d5f1535471f6/_/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":442.30000019073486,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":442.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":460.30000019073486,"responseStart":0,"secureConnectionStart":0},{"duration":81.10000038146973,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":442.5,"connectEnd":442.5,"connectStart":442.5,"domainLookupEnd":442.5,"domainLookupStart":442.5,"fetchStart":442.5,"redirectEnd":0,"redirectStart":0,"requestStart":442.5,"responseEnd":523.6000003814697,"responseStart":523.6000003814697,"secureConnectionStart":442.5},{"duration":164.39999961853027,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/2bf333562ca6724060a9d5f1535471f6/_/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":442.6000003814697,"connectEnd":442.6000003814697,"connectStart":442.6000003814697,"domainLookupEnd":442.6000003814697,"domainLookupStart":442.6000003814697,"fetchStart":442.6000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":442.6000003814697,"responseEnd":607,"responseStart":607,"secureConnectionStart":442.6000003814697},{"duration":168,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":442.9000005722046,"connectEnd":442.9000005722046,"connectStart":442.9000005722046,"domainLookupEnd":442.9000005722046,"domainLookupStart":442.9000005722046,"fetchStart":442.9000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":442.9000005722046,"responseEnd":610.9000005722046,"responseStart":610.9000005722046,"secureConnectionStart":442.9000005722046},{"duration":168.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":443,"connectEnd":443,"connectStart":443,"domainLookupEnd":443,"domainLookupStart":443,"fetchStart":443,"redirectEnd":0,"redirectStart":0,"requestStart":443,"responseEnd":611.5,"responseStart":611.5,"secureConnectionStart":443},{"duration":168.60000038146973,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":443.30000019073486,"connectEnd":443.30000019073486,"connectStart":443.30000019073486,"domainLookupEnd":443.30000019073486,"domainLookupStart":443.30000019073486,"fetchStart":443.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":443.30000019073486,"responseEnd":611.9000005722046,"responseStart":611.9000005722046,"secureConnectionStart":443.30000019073486},{"duration":225.30000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":443.4000005722046,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":443.4000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":668.7000007629395,"responseStart":0,"secureConnectionStart":0},{"duration":168.80000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":443.6000003814697,"connectEnd":443.6000003814697,"connectStart":443.6000003814697,"domainLookupEnd":443.6000003814697,"domainLookupStart":443.6000003814697,"fetchStart":443.6000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":443.6000003814697,"responseEnd":612.4000005722046,"responseStart":612.4000005722046,"secureConnectionStart":443.6000003814697},{"duration":225,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/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":443.80000019073486,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":443.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":668.8000001907349,"responseStart":0,"secureConnectionStart":0},{"duration":169.0999994277954,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/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":443.9000005722046,"connectEnd":443.9000005722046,"connectStart":443.9000005722046,"domainLookupEnd":443.9000005722046,"domainLookupStart":443.9000005722046,"fetchStart":443.9000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":443.9000005722046,"responseEnd":613,"responseStart":613,"secureConnectionStart":443.9000005722046},{"duration":495.1000003814697,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":450.80000019073486,"connectEnd":450.80000019073486,"connectStart":450.80000019073486,"domainLookupEnd":450.80000019073486,"domainLookupStart":450.80000019073486,"fetchStart":450.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":450.80000019073486,"responseEnd":945.9000005722046,"responseStart":945.9000005722046,"secureConnectionStart":450.80000019073486},{"duration":673.0999994277954,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":450.9000005722046,"connectEnd":450.9000005722046,"connectStart":450.9000005722046,"domainLookupEnd":450.9000005722046,"domainLookupStart":450.9000005722046,"fetchStart":450.9000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":450.9000005722046,"responseEnd":1124,"responseStart":1124,"secureConnectionStart":450.9000005722046},{"duration":264.30000019073486,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":682,"connectEnd":682,"connectStart":682,"domainLookupEnd":682,"domainLookupStart":682,"fetchStart":682,"redirectEnd":0,"redirectStart":0,"requestStart":682,"responseEnd":946.3000001907349,"responseStart":946.3000001907349,"secureConnectionStart":682},{"duration":193.30000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/css/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true","startTime":960.3000001907349,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":960.3000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1153.6000003814697,"responseStart":0,"secureConnectionStart":0},{"duration":184.10000038146973,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/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":961.3000001907349,"connectEnd":961.3000001907349,"connectStart":961.3000001907349,"domainLookupEnd":961.3000001907349,"domainLookupStart":961.3000001907349,"fetchStart":961.3000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":961.3000001907349,"responseEnd":1145.4000005722046,"responseStart":1145.4000005722046,"secureConnectionStart":961.3000001907349},{"duration":188.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/097ae97cb8fbec7d6ea4bbb1f26955b9-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/js/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true","startTime":961.8000001907349,"connectEnd":961.8000001907349,"connectStart":961.8000001907349,"domainLookupEnd":961.8000001907349,"domainLookupStart":961.8000001907349,"fetchStart":961.8000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":961.8000001907349,"responseEnd":1150.3000001907349,"responseStart":1150.3000001907349,"secureConnectionStart":961.8000001907349},{"duration":276.5,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":1031.4000005722046,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":1031.4000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1307.9000005722046,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":229,"responseStart":437,"responseEnd":442,"domLoading":440,"domInteractive":1237,"domContentLoadedEventStart":1237,"domContentLoadedEventEnd":1294,"domComplete":1545,"loadEventStart":1545,"loadEventEnd":1546,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1211.3000001907349},{"name":"bigPipe.sidebar-id.end","time":1213.7000007629395},{"name":"bigPipe.activity-panel-pipe-id.start","time":1213.8000001907349},{"name":"bigPipe.activity-panel-pipe-id.end","time":1218.3000001907349},{"name":"activityTabFullyLoaded","time":1323}],"measures":[],"correlationId":"35e81018bb13e5","effectiveType":"4g","downlink":9.1,"rtt":0,"serverDuration":139,"dbReadsTimeInMs":26,"dbConnsTimeInMs":35,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
See https://mariadb.com/kb/en/library/spider-server-system-variables/#spider_remote_sql_log_off
Setting this to 1 ('set GLOBAL spider_remote_sql_log_off=0;') results in spider not trying to 'set session sql_log_off = 1;' on the remote databases.
Maybe the default could be changed?