Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unknown or unsupported field - consul and tcp #15331

Closed
jhrcz-ls opened this issue May 9, 2022 · 3 comments · Fixed by #15383
Closed

unknown or unsupported field - consul and tcp #15331

jhrcz-ls opened this issue May 9, 2022 · 3 comments · Fixed by #15383
Assignees
Labels
bug Used to indicate a potential bug core Issues and Pull-Requests specific to Vault Core ticketed

Comments

@jhrcz-ls
Copy link

jhrcz-ls commented May 9, 2022

Describe the bug
After upgrade from 1.10.0 to 1.10.2, new warning is shown on every restart or reload, using the same json configuration.

May  6 10:38:41 vault2 vault[xxx]: 2022-05-06T10:38:41.233+0200 [WARN]  unknown or unsupported field consul found in configuration at /etc/vaultserver/config.json
May  6 10:38:41 vault2 vault[xxx]: 2022-05-06T10:38:41.233+0200 [WARN]  unknown or unsupported field tcp found in configuration at /etc/vaultserver/config.json

it may be connected with this change... #14752

confirmed it happens with the same after minor version change to 1.10.1 a 1.9.5

To Reproduce
Steps to reproduce the behavior:

  1. Run docker run --rm -ti -v "$(pwd)/config.json:/config.json:ro" hashicorp/vault:1.10.1 vault server -log-level=trace -config /config.json
  2. See error
2022-05-09T12:30:35.891Z [WARN]  unknown or unsupported field consul found in configuration at /config.json
2022-05-09T12:30:35.891Z [WARN]  unknown or unsupported field tcp found in configuration at /config.json

Expected behavior

error not reported the same way as with older version:
docker run --rm -ti -v "$(pwd)/config.json:/config.json:ro" hashicorp/vault:1.10.0 vault server -log-level=trace -config /config.json

Environment:

  • Vault Server Version (retrieve with vault status): 1.10.1 or 1.9.5
  • Vault CLI Version (retrieve with vault version): x
  • Server Operating System/Architecture: linux (downloaded binary or container hashicorp/vault:1.10.1 / hashicorp/vault:1.9.5

Vault server configuration file(s):

{
    "api_addr": "https://localhost:8200",
    "default_lease_ttl": "6h",
    "disable_mlock": true,
    "listener": {
        "tcp": {
            "address": "0.0.0.0:8200"
        }
    },
    "log_level": "info",
    "storage": {
        "consul": {
            "address": "127.0.0.1:8500"
        }
    },
    "ui": true
}

Additional context

looks like just warning report, function is not affected (error reports storage and tcp field, and tcp endpoints and storage works ok)

@hsimon-hashicorp hsimon-hashicorp added bug Used to indicate a potential bug core Issues and Pull-Requests specific to Vault Core labels May 9, 2022
@lenaing
Copy link

lenaing commented May 10, 2022

Hello,

I have the same issue with the following JSON config (Vault v1.10.2), hopefully everything works as expected :

2022-05-09T12:24:22.118+0200 [WARN]  unknown or unsupported field postgresql found in configuration at /path/to/config/config.json
2022-05-09T12:24:22.118+0200 [WARN]  unknown or unsupported field tcp found in configuration at /path/to/config/config.json
{
  "storage": {
    "postgresql": {
      "connection_url": "postgresql://user:pass@host:5432/database?sslmode=verify-ca&connect_timeout=5",
      "max_idle_connections": -1,
      "table": "vault_kv_store",
      "ha_enabled": "true",
      "ha_table": "vault_ha_locks"
    }
  },
  "listener": [
    {
      "tcp": {
        "address": "0.0.0.0:8200",
        "tls_cert_file": "/path/to/config/vault.crt",
        "tls_key_file": "/path/to/config/vault.key",
        "proxy_protocol_behavior": "use_always",
        "tls_disable_client_certs": "true"
      }
    }
  ],
  "telemetry": {
    "prometheus_retention_time": "12h",
    "disable_hostname": true
  },
  "ui": true,
  "api_addr": "https://vault-host:8200",
  "pid_file": "/path/to/run/vault.pid"
}

It seems to have been introduced with v1.8.0 (or at least backported to it)

@jhrcz-ls
Copy link
Author

jhrcz-ls commented May 10, 2022

@lenaing i would bet that it is the #14752 ... as i looked into git, it was backported to 3 release branches. 1.8.x, 1.9.x, 1.10.x

@HridoyRoy
Copy link
Contributor

Hi folks,
Thanks so much for raising this bug. I'll take a look at this asap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Used to indicate a potential bug core Issues and Pull-Requests specific to Vault Core ticketed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants