-
Notifications
You must be signed in to change notification settings - Fork 4k
/
Copy pathconnection_multi_bind_address_win.test
142 lines (110 loc) · 6.14 KB
/
connection_multi_bind_address_win.test
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
## This is test file for verification binding on multiple addresses
##
--source include/windows.inc
--let $xplugin_disable_ssl_for_x_at_client_side=1
--source include/xplugin_preamble.inc
## Tests starting here
--echo
--echo
--echo ## Table of testing
--echo #
--echo # 1. localhost bindings
--echo # 2. "not existing hosts" bindings
--echo # 3. skipped "*" binding
--echo # 4. skipped "0.0.0.0" binding
--echo # 5. skipped "empty address" binding
--echo # 6. skipped "empty network namespace" binding
--echo # 7. skipped "wildcard with namespace" binding
--echo # 8. skipped "wrong network namespace" binding
--echo # 9. skipped "distanthost" binding
--echo # 10. default bindings
--echo #
--echo
--echo #
--echo # 1. localhost bindings
--let $expect_bind_address=localhost,127.0.0.1
--let $expect_address=127.0.0.1,127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Value '127.0.0.1' set to `Mysqlx_bind_address`, X Plugin can't bind to it. Skipping this value.'");
call mtr.add_suppression("Plugin mysqlx reported: 'Setup of bind-address: '127.0.0.1' port: [0-9]* failed, `bind\\(\\)` failed with error: Address already in use \\([0-9]+\\). Do you already have another mysqld server running with Mysqlx \\?'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 2. "not existing hosts" bindings
--let $expect_bind_address=otherhost,anotherhost
--let $expect_address=UNDEFINED
--let $wait_for_tcpsocket_status = undefined_value
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Value 'otherhost' set to `Mysqlx_bind_address`, X Plugin can't bind to it. Skipping this value.'");
call mtr.add_suppression("Plugin mysqlx reported: 'Setup of bind-address: 'otherhost' port: [0-9]* failed, can't resolve `hostname`'");
call mtr.add_suppression("Plugin mysqlx reported: 'Value 'anotherhost' set to `Mysqlx_bind_address`, X Plugin can't bind to it. Skipping this value.'");
call mtr.add_suppression("Plugin mysqlx reported: 'Setup of bind-address: 'anotherhost' port: [0-9]* failed, can't resolve `hostname`'");
call mtr.add_suppression("Plugin mysqlx reported: 'Preparation of I/O interfaces failed, X Protocol won't be accessible'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 3. skipped "*" binding
--let $expect_bind_address=*,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Validation of value '\\*' set to `Mysqlx_bind_address` failed: wildcards are not allowed when there are more than one address. Skipping this value.'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 4. skipped "0.0.0.0" binding
--let $expect_bind_address=0.0.0.0,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Validation of value '0.0.0.0' set to `Mysqlx_bind_address` failed: wildcards are not allowed when there are more than one address. Skipping this value.'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 5. skipped "empty address" binding
--let $expect_bind_address=,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Validation of value '' set to `Mysqlx_bind_address` failed: wildcards are not allowed when there are more than one address. Skipping this value.'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 6. skipped "empty network namespace" binding
--let $expect_bind_address=localhost/,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Validation of value 'localhost/' set to `Mysqlx_bind_address` failed: can't be parsed as an address. Skipping this value.'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 7. skipped "wildcard with namespace" binding
--let $expect_bind_address=*/wrong,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Validation of value '\\*/wrong' set to `Mysqlx_bind_address` failed: network namespace are not allowed for wildcards. Skipping this value.'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 8. skipped "wrong network namespace" binding
--let $expect_bind_address=localhost/wrong,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Value 'localhost/wrong' set to `Mysqlx_bind_address`, X Plugin can't bind to it. Skipping this value.'");
call mtr.add_suppression("Plugin mysqlx reported: 'Network Namespaces is not supported on this platform'");
call mtr.add_suppression("Plugin mysqlx reported: 'Setup of bind-address: 'localhost/wrong' port: [0-9]* failed, '");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 9. skipped "distanthost" binding
--let $expect_bind_address=distanthost,localhost
--let $expect_address=127.0.0.1
--let $restart_parameters = restart: --mysqlx_bind_address=$expect_bind_address
call mtr.add_suppression("Plugin mysqlx reported: 'Value 'distanthost' set to `Mysqlx_bind_address`, X Plugin can't bind to it. Skipping this value.'");
call mtr.add_suppression("Plugin mysqlx reported: 'Setup of bind-address: 'distanthost' port: [0-9]* failed, can't resolve `hostname`'");
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
--echo
--echo #
--echo # 10. default bindings
--let $expect_bind_address=*
--let $expect_address=::
--let $restart_parameters = restart:
--source ../include/restart_mysqld_and_verify_bind_addresses.inc
## Cleanup