12
12
See the License for the specific language governing permissions and
13
13
limitations under the License. See accompanying LICENSE file.
14
14
-->
15
- <yandex >
16
- <!-- Profiles of settings. -->
17
- <profiles >
18
- <!-- Default settings. -->
19
- <default >
20
- <!-- Maximum memory usage for processing single query, in bytes. -->
21
- <max_memory_usage >10000000000</max_memory_usage >
22
-
23
- <!-- How to choose between replicas during distributed query processing.
24
- random - choose random replica from set of replicas with minimum number of errors
25
- nearest_hostname - from set of replicas with minimum number of errors, choose replica
26
- with minimum number of different symbols between replica's hostname and local hostname
27
- (Hamming distance).
28
- in_order - first live replica is chosen in specified order.
29
- first_or_random - if first replica one has higher number of errors, pick a random one from replicas with minimum number of errors.
30
- -->
31
- <load_balancing >random</load_balancing >
32
- <!-- Enable Map support -->
33
- <allow_experimental_map_type >1</allow_experimental_map_type >
34
- </default >
35
-
36
- <!-- Profile that allows only read queries. -->
37
- <readonly >
38
- <readonly >1</readonly >
39
- </readonly >
40
- </profiles >
41
-
15
+ <clickhouse >
42
16
<!-- Users and ACL. -->
43
17
<users >
44
- <!-- If user name was not specified, 'default' user is used. -->
45
18
<default >
46
- <!-- Password could be specified in plaintext or in SHA256 (in hex format).
47
-
48
- If you want to specify password in plaintext (not recommended), place it in 'password' element.
49
- Example: <password>qwerty</password>.
50
- Password could be empty.
51
-
52
- If you want to specify SHA256, place it in 'password_sha256_hex' element.
53
- Example: <password_sha256_hex>65e84be33532fb784c48129675f9eff3a682b27168c0ea744b2cf58ee02337c5</password_sha256_hex>
54
- Restrictions of SHA256: impossibility to connect to ClickHouse using MySQL JS client (as of July 2019).
55
-
56
- If you want to specify double SHA1, place it in 'password_double_sha1_hex' element.
57
- Example: <password_double_sha1_hex>e395796d6546b1b65db9d665cd43f0e858dd4303</password_double_sha1_hex>
58
-
59
- If you want to specify a previously defined LDAP server (see 'ldap_servers' in main config) for authentication, place its name in 'server' element inside 'ldap' element.
60
- Example: <ldap><server>my_ldap_server</server></ldap>
61
-
62
- How to generate decent password:
63
- Execute: PASSWORD=$(base64 < /dev/urandom | head -c8); echo "$PASSWORD"; echo -n "$PASSWORD" | sha256sum | tr -d '-'
64
- In first line will be password and in second - corresponding SHA256.
65
-
66
- How to generate double SHA1:
67
- Execute: PASSWORD=$(base64 < /dev/urandom | head -c8); echo "$PASSWORD"; echo -n "$PASSWORD" | sha1sum | tr -d '-' | xxd -r -p | sha1sum | tr -d '-'
68
- In first line will be password and in second - corresponding double SHA1.
69
- -->
19
+ <!-- Password could be empty. If so, any password is allowed. -->
70
20
<password ></password >
71
21
72
- <!-- List of networks with open access.
73
-
74
- To open access from everywhere, specify:
75
- <ip>::/0</ip>
76
-
77
- To open access only from localhost, specify:
78
- <ip>::1</ip>
79
- <ip>127.0.0.1</ip>
22
+ <!-- Or you can specify password hash (see authentication methods section). -->
23
+ <!-- <password_sha256_hex></password_sha256_hex> -->
80
24
81
- Each element of list has one of the following forms:
82
- <ip> IP-address or network mask. Examples: 213.180.204.3 or 10.0.0.1/8 or 10.0.0.1/255.255.255.0
83
- 2a02:6b8::3 or 2a02:6b8::3/64 or 2a02:6b8::3/ffff:ffff:ffff:ffff::.
84
- <host> Hostname. Example: server01.yandex.ru.
85
- To check access, DNS query is performed, and all received addresses compared to peer address.
86
- <host_regexp> Regular expression for host names. Example, ^server\d\d-\d\d-\d\.yandex\.ru$
87
- To check access, DNS PTR query is performed for peer address and then regexp is applied.
88
- Then, for result of PTR query, another DNS query is performed and all received addresses compared to peer address.
89
- Strongly recommended that regexp is ends with $
90
- All results of DNS requests are cached till server restart.
91
- -->
25
+ <!-- List of networks with open access. -->
92
26
<networks >
93
27
<ip >::/0</ip >
94
28
</networks >
95
29
96
- <!-- Settings profile for user. -->
30
+ <!-- Settings profile for the user. -->
97
31
<profile >default</profile >
98
32
99
- <!-- Quota for user. -->
33
+ <!-- Quota for the user. -->
100
34
<quota >default</quota >
101
35
102
- <!-- User can create other users and grant rights to them . -->
103
- <!-- < access_management>1</access_management> -- >
36
+ <!-- Access management for the user . -->
37
+ <access_management >1</access_management >
104
38
</default >
105
39
</users >
106
40
41
+ <!-- Profiles of settings. -->
42
+ <profiles >
43
+ <default >
44
+ <max_memory_usage >10000000000</max_memory_usage >
45
+ <use_uncompressed_cache >0</use_uncompressed_cache >
46
+ <load_balancing >random</load_balancing >
47
+ </default >
48
+ </profiles >
49
+
107
50
<!-- Quotas. -->
108
51
<quotas >
109
- <!-- Name of quota. -->
110
52
<default >
111
- <!-- Limits for time interval. You could specify many intervals with different limits. -->
112
53
<interval >
113
- <!-- Length of interval. -->
114
54
<duration >3600</duration >
115
-
116
- <!-- No limits. Just calculate resource usage for time interval. -->
117
55
<queries >0</queries >
118
56
<errors >0</errors >
119
57
<result_rows >0</result_rows >
122
60
</interval >
123
61
</default >
124
62
</quotas >
125
- </yandex >
63
+ </clickhouse >
0 commit comments