cockroachdb / cockroachdb/cockroach
cli: debug zip uses invalid cast for show settings
Open
A-cli-client
A-observability-inf
C-bug
T-supportability
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
`debug zip` uses `SELECT *, to_hex(value::bytes) as hex_value FROM system.settings` but `value::bytes` which can return errors:
```
root@localhost:26257/defaultdb> set cluster setting cluster.organization = 'a\nbcd';
SET CLUSTER SETTING
root@localhost:26257/defaultdb> select *, to_hex(value::bytea) from system.settings;
ERROR: invalid bytea escape sequence
SQLSTATE: 22025
```
Observed on a customer cluster in https://github.com/cockroachlabs/support/issues/1918.
Jira issue: CRDB-27739
Contributor guide
Assessment
This issue has not been assessed yet.