[MDEV-15697] Remote user used by Spider needs SUPER privilege Created: 2018-03-27 Updated: 2018-05-11 Resolved: 2018-05-09 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - Spider |
| Affects Version/s: | 10.2.14 |
| Fix Version/s: | 10.2.15, 10.3.7 |
| Type: | Bug | Priority: | Major |
| Reporter: | Geoff Montee (Inactive) | Assignee: | Jacob Mathew (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | privileges, spider | ||
| Issue Links: |
|
||||
| Description |
|
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:
And then the following on the Spider server:
I am not able to query the spider table:
Even though I am able to connect to the remote server and query the table using the regular mysql client:
The spider table works if I give the user the SUPER privileges. remote server:
Spider server:
Why would the remote user need SUPER privileges? |
| Comments |
| Comment by Buchan [ 2018-04-17 ] |
|
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? |
| Comment by Buchan [ 2018-04-17 ] |
|
Also documented in https://mariadb.com/kb/en/library/spider-use-cases/#enable-use-of-non-root-connections , but I have seen it before and was looking for it again, but 'Use cases' seems to be a weird place to put this; it probably belongs in the FAQ? |
| Comment by Jacob Mathew (Inactive) [ 2018-05-01 ] |
|
To fix the problem, I have changed the spider_internal_sql_log_off configuration setting so that if it is NOT SET, which is the most likely case, the Spider node DOES NOT SEND the 'SET SQL_LOG_OFF' statement to the data nodes. However if the spider_internal_sql_log_off setting IS EXPLICITLY SET to either 0 or 1, then the Spider node DOES SEND the 'SET SQL_LOG_OFF' statement, requiring a remote user with the SUPER privilege. The Spider documentation will be updated to reflect this change. |
| Comment by Jacob Mathew (Inactive) [ 2018-05-01 ] |
|
Kentoku, please review my fix for this problem in commit 72f0efa on my branch. |
| Comment by Kentoku Shiba (Inactive) [ 2018-05-09 ] |
|
It's ok to push. |
| Comment by Jacob Mathew (Inactive) [ 2018-05-09 ] |
|
Fix is pushed to 10.3 and 10.2. |