[TACACS] Fix TACACS accounting UT issue caused by auditd log rotate.#11710
Merged
qiluo-msft merged 1 commit intosonic-net:masterfrom Feb 27, 2024
Merged
[TACACS] Fix TACACS accounting UT issue caused by auditd log rotate.#11710qiluo-msft merged 1 commit intosonic-net:masterfrom
qiluo-msft merged 1 commit intosonic-net:masterfrom
Conversation
qiluo-msft
approved these changes
Feb 26, 2024
mssonicbld
pushed a commit
to mssonicbld/sonic-mgmt
that referenced
this pull request
May 10, 2024
…#11710) Fix TACACS accounting UT issue caused by auditd log rotate ### Description of PR Fix TACACS accounting UT issue caused by auditd log rotate ##### Work item tracking - Microsoft ADO: 26710599 ### Type of change - [x] Bug fix - [ ] Testbed and Framework(new/improvement) - [] Test case(new/improvement) ## Approach #### What is the motivation for this PR? Fix TACACS accounting UT issue caused by auditd log rotate. There are 2 code issue: 1. when auditd log rotate, some auditd log will missing from output of 'service auditd status' 1. duthost.command() can only run 1 command, so can't handle piping output to grep #### How did you do it? show auditd log with 'sudo journalctl -u auditd --boot' and run command with duthost.shell() to support grep. #### How did you verify/test it? Pass all UT
Collaborator
|
Cherry-pick PR to 202305: #12801 |
Closed
5 tasks
mssonicbld
pushed a commit
to mssonicbld/sonic-mgmt
that referenced
this pull request
May 10, 2024
…#11710) Fix TACACS accounting UT issue caused by auditd log rotate ### Description of PR Fix TACACS accounting UT issue caused by auditd log rotate ##### Work item tracking - Microsoft ADO: 26710599 ### Type of change - [x] Bug fix - [ ] Testbed and Framework(new/improvement) - [] Test case(new/improvement) ## Approach #### What is the motivation for this PR? Fix TACACS accounting UT issue caused by auditd log rotate. There are 2 code issue: 1. when auditd log rotate, some auditd log will missing from output of 'service auditd status' 1. duthost.command() can only run 1 command, so can't handle piping output to grep #### How did you do it? show auditd log with 'sudo journalctl -u auditd --boot' and run command with duthost.shell() to support grep. #### How did you verify/test it? Pass all UT
Collaborator
|
Cherry-pick PR to 202311: #12802 |
Merged
5 tasks
mssonicbld
pushed a commit
that referenced
this pull request
May 11, 2024
Fix TACACS accounting UT issue caused by auditd log rotate ### Description of PR Fix TACACS accounting UT issue caused by auditd log rotate ##### Work item tracking - Microsoft ADO: 26710599 ### Type of change - [x] Bug fix - [ ] Testbed and Framework(new/improvement) - [] Test case(new/improvement) ## Approach #### What is the motivation for this PR? Fix TACACS accounting UT issue caused by auditd log rotate. There are 2 code issue: 1. when auditd log rotate, some auditd log will missing from output of 'service auditd status' 1. duthost.command() can only run 1 command, so can't handle piping output to grep #### How did you do it? show auditd log with 'sudo journalctl -u auditd --boot' and run command with duthost.shell() to support grep. #### How did you verify/test it? Pass all UT
Contributor
Author
|
202305 PR not auto merge, remove and add back again |
mssonicbld
pushed a commit
to mssonicbld/sonic-mgmt
that referenced
this pull request
May 11, 2024
…#11710) Fix TACACS accounting UT issue caused by auditd log rotate ### Description of PR Fix TACACS accounting UT issue caused by auditd log rotate ##### Work item tracking - Microsoft ADO: 26710599 ### Type of change - [x] Bug fix - [ ] Testbed and Framework(new/improvement) - [] Test case(new/improvement) ## Approach #### What is the motivation for this PR? Fix TACACS accounting UT issue caused by auditd log rotate. There are 2 code issue: 1. when auditd log rotate, some auditd log will missing from output of 'service auditd status' 1. duthost.command() can only run 1 command, so can't handle piping output to grep #### How did you do it? show auditd log with 'sudo journalctl -u auditd --boot' and run command with duthost.shell() to support grep. #### How did you verify/test it? Pass all UT
Collaborator
|
Cherry-pick PR to 202305: #12823 |
Merged
5 tasks
mssonicbld
pushed a commit
that referenced
this pull request
May 11, 2024
Fix TACACS accounting UT issue caused by auditd log rotate ### Description of PR Fix TACACS accounting UT issue caused by auditd log rotate ##### Work item tracking - Microsoft ADO: 26710599 ### Type of change - [x] Bug fix - [ ] Testbed and Framework(new/improvement) - [] Test case(new/improvement) ## Approach #### What is the motivation for this PR? Fix TACACS accounting UT issue caused by auditd log rotate. There are 2 code issue: 1. when auditd log rotate, some auditd log will missing from output of 'service auditd status' 1. duthost.command() can only run 1 command, so can't handle piping output to grep #### How did you do it? show auditd log with 'sudo journalctl -u auditd --boot' and run command with duthost.shell() to support grep. #### How did you verify/test it? Pass all UT
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix TACACS accounting UT issue caused by auditd log rotate
Description of PR
Fix TACACS accounting UT issue caused by auditd log rotate
Work item tracking
Type of change
Back port request
Approach
What is the motivation for this PR?
Fix TACACS accounting UT issue caused by auditd log rotate.
There are 2 code issue:
How did you do it?
show auditd log with 'sudo journalctl -u auditd --boot' and run command with duthost.shell() to support grep.
How did you verify/test it?
Pass all UT
Any platform specific information?
Supported testbed topology if it's a new test case?
Documentation