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

serial console setting does not work with --extra-agent-kernel-args #251

Closed
abckey opened this issue Dec 13, 2020 · 10 comments · Fixed by #252
Closed

serial console setting does not work with --extra-agent-kernel-args #251

abckey opened this issue Dec 13, 2020 · 10 comments · Fixed by #252
Assignees

Comments

@abckey
Copy link

abckey commented Dec 13, 2020

By default, agent environment kernel parameters has console=ttyS0.
With newly added --extra-agent-kernel-args, enabled the ability to add console=ttyS1. (the config working in my servers)
The implemenation ended up with both parameters present, I'm not sure how kernel handles this, but in real test, I still could not get serial console output during agent running.

From from https://www.kernel.org/doc/html/v5.9/admin-guide/serial-console.html, below is mentioned:

Note that you can only define one console per device type (serial, video).
@smira
Copy link
Member

smira commented Dec 14, 2020

I will look into overriding defaults

@smira smira self-assigned this Dec 14, 2020
smira added a commit to smira/sidero that referenced this issue Dec 14, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args=console=ttyS1`.

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
@smira
Copy link
Member

smira commented Dec 14, 2020

@abckey you can try updated version from #252 by updating image reference for sidero-controller-manager to ghcr.io/smira/metal-controller-manager:v0.1.0-alpha.12-13-g51f488f

@abckey
Copy link
Author

abckey commented Dec 14, 2020

with the test image, --extra-agent-kernel-args=console=ttyS1,115200 ended up in kernel cmdline as console=ttyS1 console=tty0 console=ttyS0, did I set it in right format or still a bit fix to do?

@andrewrynhard
Copy link
Member

andrewrynhard commented Dec 14, 2020

with the test image, --extra-agent-kernel-args=console=ttyS1,115200 ended up in kernel cmdline as console=ttyS1 console=tty0 console=ttyS0, did I set it in right format or still a bit fix to do?

Wrap it in quotes: --extra-agent-kernel-args=console="ttyS1,115200"

@smira
Copy link
Member

smira commented Dec 14, 2020

I believe 115200 should be default, so you can skip it. @abckey does it fix the console for you?

@abckey
Copy link
Author

abckey commented Dec 15, 2020

It seems 9600 is the default,it works only with my old HP servers, my newer servers need 115200 to work.
tested --extra-agent-kernel-args=console="ttyS1,115200", it generates console="ttyS1 console=tty0 console=ttyS0 , so still something needs to be done to get it properly set ?

@smira
Copy link
Member

smira commented Dec 15, 2020

@abckey I'll do more testing today and I will get back to you

smira added a commit to smira/sidero that referenced this issue Dec 15, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
@smira
Copy link
Member

smira commented Dec 15, 2020

@abckey I have a new image ghcr.io/smira/metal-controller-manager:v0.1.0-alpha.12-13-g4dba68a

This changes format for --extra-agent-kernel-args to better handle kernel args, it now accepts args in the format of kernel command line:

      - args:
        ...
        - --extra-agent-kernel-args
        - panic=5 console=ttyS0

(just use spaces to separate different options)

@abckey
Copy link
Author

abckey commented Dec 16, 2020

@smira it works now as expected.
from:

- --extra-agent-kernel-args
- console=tty0 console=ttyS1,115200

I got in kernal cmdline:

console=tty0 console=ttyS1,115200

@smira
Copy link
Member

smira commented Dec 16, 2020

Thanks, we'll get into the next release

smira added a commit to smira/sidero that referenced this issue Dec 16, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
smira added a commit to smira/sidero that referenced this issue Dec 16, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
smira added a commit to smira/sidero that referenced this issue Dec 16, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
smira added a commit to smira/sidero that referenced this issue Dec 16, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
smira added a commit to smira/sidero that referenced this issue Dec 16, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes siderolabs#251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
talos-bot pushed a commit that referenced this issue Dec 17, 2020
This allows to override default options (e.g. `console=ttyS0`) with
provided values. Make sure that full value is given for each option, as
any default values for the option are dropped if specified in
`--extra-agent-kernel-args`, e.g.
`--extra-agent-kernel-args "console=tty0 console=ttyS1 panic=5"`.

See also siderolabs/go-procfs#5

Fixes #251

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants