-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Kdump_Remote_SSH_Support #1714
Kdump_Remote_SSH_Support #1714
Conversation
reviewed in community on 7/9/2024, recording can be found from https://zoom.us/rec/share/vlA3FUiC7lv0UK4edaEciUabfsFzyVRtTvB4-QmEZ33b-JOLcyuZCn8lsAOc9smz.Tqd4HaNLMQJQFHDM |
asked during the review meeting and keep a record here: current design only supports kdump to remote server over IPv4, no IPv6 support. |
doc/kdump/kdump_Remote_SSH_HLD.md
Outdated
leaf remote { | ||
description "SSH Remote Config"; | ||
|
||
type string { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can the type be boolean to represent true/false instead of string?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I will do this.
|
||
- Required for kdump_remote_ssh_dump: Initialize network interfaces and enable DHCP upon kernel crash. | ||
|
||
2. files/scripts/network_setup.sh (New Addition) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add some details for this new change? is this only for eth0 interface?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this script initializes the eth0 interface and enables dhcp on it.
User be prompted to choose a location to save the key pair. By default, it saves the private key to ~/.ssh/id_rsa and the public key to ~/.ssh/id_rsa.pub. | ||
|
||
``` | ||
admin@sonic: ssh-copy-id username@server_address |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this the manual setup apart from configuring kdump CLI commands? can this be abstracted within kdump command?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is a manual setup apart from kdump CLI commands. The manual setup ensures clarity and avoids the complexity and prompts that might arise from using kdump CLI commands.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you handle this as part of the Click command handler?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, we can implement this through the CLI, but it would be more suitable for the user to generate the key and save it to the desired path, which can then be configured in the "kdump-tools" file
doc/kdump/kdump_Remote_SSH_HLD.md
Outdated
} | ||
} | ||
|
||
leaf ssh_connection_string { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to add more than one remote IPs? e.g if one of the server is not reachable, is it possible to choose the alternate server to transfer the kdump data?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No this is not possible according to my understanding. There is variable #SSH in kdump-config file in /etc/default/kdump-tools directory, it allows you to add only one remote IP at a time.
doc/kdump/kdump_Remote_SSH_HLD.md
Outdated
Kdump memory reservation: 512 | ||
Maximum number of Kdump files: 3 | ||
remote: true | ||
Kdump remote server user@ip/hostname: [email protected] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have we tested the remote server reachability via mgmt VRF?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, but I will test it and keep posted.
IPv6 should work without any issues, we just need to validate this. |
@venkatmahalingam We have edited the HLD please help review it and related code PR's. |
This feature works fine with IPv6 as tested. |
@venkatmahalingam Hi Venkat, Can you please help review HLD and its Linked PRs. Target is 202411 |
Sure, will take a look next week. |
doc/kdump/kdump_Remote_SSH_HLD.md
Outdated
type boolean; | ||
} | ||
|
||
leaf ssh_stirng { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo. string
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
type string; | ||
} | ||
|
||
leaf ssh_path { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a description explaining the format for all fields.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Descriptions Added
doc/kdump/kdump_Remote_SSH_HLD.md
Outdated
- CLI support for configuring remote kdump feature enable/disable via ssh. | ||
- CLI support for configuring username and hostname of ssh server (username@server_address). | ||
- CLI support for configuring SSH private key path for ssh server (SSH_private_Key_Path). | ||
- CLI support for displaying crededentials of ssh server. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo. crededentials, please do a spell-checker for this HLD.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
@venkatmahalingam Hi, We have updated daemon as per your suggestion. Please help review updated HLD and linked code PRs. Target is 202411. Thanks in advance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
code PRs are not merged yet, move to backlog |
Hi @zhangyanzhao / @qiluo-msft We have been requesting a merge of Code PRs for days before the release. All code PRs pass checks and have been approved by the reviewers. Every week, we are requesting for review and approval. Kindly help merge these PRs. Thanks |
@zhangyanzhao Code PRs are done since long and approved but still awaiting for merge. We are already pushing hard for repo owner to merge it. @qiluo-msft kindly merged these approved code PRs. |
This HLD outlines the configuration and usage of the kdump remote feature with SSH for the SONiC network operating system. Kdump, a built-in Linux kernel feature, generates and stores a crash dump file in the event of a kernel panic. It extends beyond local storage by enabling remote dumps via SSH or NFS protocols, allowing you to transmit kernel crash data to a designated remote server. This functionality facilitates offline analysis by storing crash dump files remotely.