Hide Forgot
Description of problem: The clean option fails to obfuscate fqdns in /var/log/dnf* & sos_commands/yum/yum_-C_repolist_--verbose (in the URLS for repositories), e.g. 2021-04-18T10:52:27Z INFO Downloading: https://yum-master-lab1.elab.EXAMPLE.com:443/mirrorlist/mirrorlist.pl?repo=rhel-8-for-x86_64-appstream-e4s-rpms&environment=lab&release=8&patchlevel=sap Version-Release number of selected component (if applicable): sos 4.0 Additional info: Should be resolved by https://github.com/sosreport/sos/commit/b27140a9126ea82efb517d60bf1b8455aaf4f5a6 already in the Master branch.
That upstream commit / PR does not fix this issue, in fact even current master branch is affected the same: rm -rf master.zip sos-master curl -L -O https://github.com/sosreport/sos/archive/master.zip unzip master.zip cd sos-master python3 bin/sos report -o yum,dnf --batch --build --clean .. Your sosreport build tree has been generated in: /var/tmp/sosreport-host0-2021-05-25-euojkga .. grep -e EXAMPLE -e avocado-project ${d}/sos_commands/yum/yum_-C_repolist_--verbose ${d}/var/log/dnf.log /var/tmp/sosreport-host0-2021-05-25-euojkga/sos_commands/yum/yum_-C_repolist_--verbose:Repo-baseurl : https://avocado-project.org/data/repos/epel-8-noarch/ /var/tmp/sosreport-host0-2021-05-25-euojkga/var/log/dnf.log:2021-04-18T10:52:27Z INFO Downloading: https://yum-master-lab1.elab.EXAMPLE.com:443/mirrorlist/mirrorlist.pl?repo=rhel-8-for-x86_64-appstream-e4s-rpms&environment=lab&release=8&patchlevel=sap And verbose log shows both the files were obfuscated.. As there is no known fix now, preliminary accepting to 8.6 "only".
@pavel - isn't that FQDN not being scrubbed because it doesn't match the host's domain and nothing is being passed via --domains?
From current master: $ sudo yum -C repolist --verbose Loaded plugins: builddep, changelog, config-manager, copr, debug, debuginfo-install, download, generate_completion_cache, groups-manager, needs-restarting, playground, repoclosure, repodiff, repograph, repomanage, reposync, system-upgrade [...] Repo-id : fedora Repo-name : Fedora 34 - x86_64 Repo-metalink : https://mirrors.fedoraproject.org/metalink?repo=fedora-34&arch=x86_64 $ sudo ./bin/sos report -o yum --clean --domains fedoraproject.org --batch [...] Your sosreport has been generated and saved in: /var/tmp/sosreport-host0-2021-05-25-iyvrkcc-obfuscated.tar.xz $ less sos_commands/yum/yum_-C_repolist_--verbose [...] Repo-id : fedora Repo-name : Fedora 34 - x86_64 Repo-metalink : https://host3.obfuscateddomain1.org/metalink?repo=fedora-34&arch=x86_64 Updated : Tue May 25 20:15:32 2021
I should think twice before writing the next time :) Indeed, I forgot we (by purpose) do not clean all domains. And I can confirm the commit/PR does fix the reported problem. Reproducer for QE: echo "2021-04-18T10:52:27Z INFO Downloading: https://yum-master-lab1.elab.example.com:443/mirrorlist/mirrorlist.pl?repo=rhel-8-for-x86_64-appstream-e4s-rpms&environment=lab&release=8&patchlevel=sap" >> /var/log/dnf.log echo "2021-04-18T10:52:27Z INFO Downloading: https://$(hostname -f):443/mirrorlist/mirrorlist.pl?repo=rhel-8-for-x86_64-appstream-e4s-rpms&environment=lab&release=8&patchlevel=sap" >> /var/log/dnf.log dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm -y sos report -o yum,dnf --batch --build --clean --domains fedoraproject.org,example.com d=/var/tmp/$(ls -tr /var/tmp | grep -v private_map | grep sos | tail -n1) # to point to the latest /var/tmp/sosreport* dir, the built one grep -e fedoraproject.org -e example.com -e $(hostname -f) ${d}/sos_commands/yum/yum_-C_repolist_--verbose ${d}/var/log/dnf.log The grep now returns: /var/tmp/sosreport-host0-2021-05-26-booajgp/sos_commands/yum/yum_-C_repolist_--verbose:Repo-metalink : https://mirrors.fedoraproject.org/metalink?repo=epel-8&arch=x86_64&infra=$infra&content=$contentdir /var/tmp/sosreport-host0-2021-05-26-booajgp/sos_commands/yum/yum_-C_repolist_--verbose:Repo-metalink : https://mirrors.fedoraproject.org/metalink?repo=epel-modular-8&arch=x86_64&infra=$infra&content=$contentdir /var/tmp/sosreport-host0-2021-05-26-booajgp/var/log/dnf.log:2021-04-18T10:52:27Z INFO Downloading: https://yum-master-lab1.elab.example.com:443/mirrorlist/mirrorlist.pl?repo=rhel-8-for-x86_64-appstream-e4s-rpms&environment=lab&release=8&patchlevel=sap /var/tmp/sosreport-host0-2021-05-26-booajgp/var/log/dnf.log:2021-05-26T07:04:25Z DDEBUG Command: dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm -y /var/tmp/sosreport-host0-2021-05-26-booajgp/var/log/dnf.log:2021-05-26T07:04:25Z DDEBUG Extra commands: ['install', 'https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm', '-y'] Gladly not the hostname itself. Applying the commit/PR, grep is empty. We might add it to 8.5, esp. if the reporter can test the fix on provided candidate build/package - would that be possible to verify the fix once RPM ready?
Hello, Yes, I can get the customer to test any build candidates. Please let me know when the RPMs are available. Thank you for working on this so quickly.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (sos bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHEA-2021:4388