Skip to content

Instantly share code, notes, and snippets.

@dasl-
Created January 18, 2019 22:05
Show Gist options
  • Save dasl-/27dd5eadafa03834f9f614652fac606d to your computer and use it in GitHub Desktop.
Save dasl-/27dd5eadafa03834f9f614652fac606d to your computer and use it in GitHub Desktop.
vitess@localhost:/vt/src/vitess.io/vitess$ /vitess-scripts/setup.sh
enter zk2 env
Starting zk servers...
Waiting for zk servers to be ready...
Started zk servers.
ERROR: logging before flag.Parse: E0118 21:37:04.540226 146 syslogger.go:122] can't connect to syslog
W0118 21:37:04.563246 146 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
Configured zk servers.
enter zk2 env
Starting vtctld...
Access vtctld web UI at http://localhost:15000
Send commands with: vtctlclient -server localhost:15999 ...
enter zk2 env
Starting MySQL for tablet test-0000000100...
Starting MySQL for tablet test-0000000101...
Starting vttablet for test-0000000100...
Access tablet test-0000000100 at http://localhost:15100/debug/status
Starting vttablet for test-0000000101...
Access tablet test-0000000101 at http://localhost:15101/debug/status
W0118 21:37:46.656959 3336 main.go:60] W0118 21:37:46.651137 reparent.go:181] master-elect tablet test-0000000100 is not the shard master, proceeding anyway as -force was used
W0118 21:37:46.658510 3336 main.go:60] W0118 21:37:46.651577 reparent.go:187] master-elect tablet test-0000000100 is not a master in the shard, proceeding anyway as -force was used
enter zk2 env
Starting MySQL for tablet test-0000000200...
Starting MySQL for tablet test-0000000201...
Starting vttablet for test-0000000200...
Access tablet test-0000000200 at http://localhost:15200/debug/status
Starting vttablet for test-0000000201...
Access tablet test-0000000201 at http://localhost:15201/debug/status
W0118 21:38:39.393290 6567 main.go:60] W0118 21:38:39.385919 reparent.go:181] master-elect tablet test-0000000200 is not the shard master, proceeding anyway as -force was used
W0118 21:38:39.395817 6567 main.go:60] W0118 21:38:39.386603 reparent.go:187] master-elect tablet test-0000000200 is not a master in the shard, proceeding anyway as -force was used
enter zk2 env
Starting MySQL for tablet test-0000000300...
Starting MySQL for tablet test-0000000301...
Starting vttablet for test-0000000300...
Access tablet test-0000000300 at http://localhost:15300/debug/status
Starting vttablet for test-0000000301...
Access tablet test-0000000301 at http://localhost:15301/debug/status
W0118 21:39:24.843553 9795 main.go:60] W0118 21:39:24.836632 reparent.go:181] master-elect tablet test-0000000300 is not the shard master, proceeding anyway as -force was used
W0118 21:39:24.852036 9795 main.go:60] W0118 21:39:24.836940 reparent.go:187] master-elect tablet test-0000000300 is not a master in the shard, proceeding anyway as -force was used
New VSchema object:
{
"tables": {
"shops_index": {
}
}
}
If this is not what you expected, check the input data (as JSON parsing will skip unexpected fields).
New VSchema object:
{
"sharded": true,
"vindexes": {
"shop_id_shop_shard_idx": {
"type": "lookup_hash_unique",
"params": {
"from": "shop_id",
"table": "shops_index",
"to": "shop_shard"
}
}
},
"tables": {
"shop_data": {
"columnVindexes": [
{
"column": "shop_id",
"name": "shop_id_shop_shard_idx"
}
]
}
}
}
If this is not what you expected, check the input data (as JSON parsing will skip unexpected fields).
enter zk2 env
Access vtgate at http://localhost:15001/debug/status
.cat: /vt/vtdataroot/tmp/vtgate.pid: No such file or directory
.9877
ERROR: logging before flag.Parse: E0118 21:39:27.386389 9895 syslogger.go:122] can't connect to syslog
----------------------------------------------------------------------
INSERT INTO shops_index (shop_id, shop_shard) VALUES(123, 100)
1 index_test/-: begin
1 index_test/-: insert into shops_index(shop_id, shop_shard) values (123, 100)
1 index_test/-: commit
----------------------------------------------------------------------
ERROR: logging before flag.Parse: E0118 21:39:27.560814 9907 syslogger.go:122] can't connect to syslog
----------------------------------------------------------------------
INSERT INTO shop_data (shop_id, name) VALUES(123, 'my_shop')
1 index_test/-: begin
1 index_test/-: select shop_shard from shops_index where shop_id = 123 limit 10001
2 shard_test/-80: begin
2 shard_test/-80: insert into shop_data(shop_id, name) values (123, 'my_shop') /* vtgate:: keyspace_id:166b40b44aba4bd6 */
3 index_test/-: commit
4 shard_test/-80: commit
----------------------------------------------------------------------
ERROR: logging before flag.Parse: E0118 21:39:27.740021 9918 syslogger.go:122] can't connect to syslog
W0118 21:39:27.755882 9918 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.328318 9940 syslogger.go:122] can't connect to syslog
W0118 21:39:30.340228 9940 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.409818 9950 syslogger.go:122] can't connect to syslog
W0118 21:39:30.421759 9950 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.471350 9961 syslogger.go:122] can't connect to syslog
W0118 21:39:30.480879 9961 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.588986 9972 syslogger.go:122] can't connect to syslog
W0118 21:39:30.604798 9972 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.662270 9983 syslogger.go:122] can't connect to syslog
W0118 21:39:30.674524 9983 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.740088 9994 syslogger.go:122] can't connect to syslog
W0118 21:39:30.746591 9994 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.806601 10006 syslogger.go:122] can't connect to syslog
W0118 21:39:30.817950 10006 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.878452 10017 syslogger.go:122] can't connect to syslog
W0118 21:39:30.888239 10017 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:30.955720 10028 syslogger.go:122] can't connect to syslog
W0118 21:39:30.967809 10028 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:31.007486 10041 syslogger.go:122] can't connect to syslog
W0118 21:39:31.017215 10041 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:31.076176 10054 syslogger.go:122] can't connect to syslog
W0118 21:39:31.089608 10054 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:31.149121 10066 syslogger.go:122] can't connect to syslog
W0118 21:39:31.165555 10066 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:31.233761 10078 syslogger.go:122] can't connect to syslog
W0118 21:39:31.245283 10078 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:31.316263 10091 syslogger.go:122] can't connect to syslog
W0118 21:39:31.332047 10091 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
ERROR: logging before flag.Parse: E0118 21:39:31.400625 10104 syslogger.go:122] can't connect to syslog
W0118 21:39:31.412243 10104 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+
+
shops_index data:
ERROR: logging before flag.Parse: E0118 21:39:31.491005 10117 syslogger.go:122] can't connect to syslog
W0118 21:39:31.511830 10117 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+---------+------------+
| shop_id | shop_shard |
+---------+------------+
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
| 4 | 4 |
| 5 | 5 |
| 6 | 6 |
| 7 | 7 |
| 8 | 8 |
+---------+------------+
shop_data data:
ERROR: logging before flag.Parse: E0118 21:39:31.580410 10131 syslogger.go:122] can't connect to syslog
W0118 21:39:31.600905 10131 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+---------+---------+
| shop_id | name |
+---------+---------+
| 1 | my_shop |
| 2 | my_shop |
| 3 | my_shop |
| 5 | my_shop |
| 4 | my_shop |
| 6 | my_shop |
| 7 | my_shop |
| 8 | my_shop |
+---------+---------+
shop_data shard -80 data:
ERROR: logging before flag.Parse: E0118 21:39:31.670581 10145 syslogger.go:122] can't connect to syslog
W0118 21:39:31.693194 10145 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+---------+---------+
| shop_id | name |
+---------+---------+
| 1 | my_shop |
| 2 | my_shop |
| 3 | my_shop |
| 5 | my_shop |
+---------+---------+
shop_data shard 80- data:
ERROR: logging before flag.Parse: E0118 21:39:31.749950 10156 syslogger.go:122] can't connect to syslog
W0118 21:39:31.756226 10156 vtctl.go:80] cannot connect to syslog: Unix syslog delivery error
+---------+---------+
| shop_id | name |
+---------+---------+
| 4 | my_shop |
| 6 | my_shop |
| 7 | my_shop |
| 8 | my_shop |
+---------+---------+
API server listening at: [::]:40000
INFO[0000] attaching to pid 9877 layer=debugger
Could not attach to pid 9877: this could be caused by a kernel security setting, try writing "0" to /proc/sys/kernel/yama/ptrace_scope
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment