Bug 1032941

Summary: hwcert-backend Error: could not determine selinux parameters
Product: [Retired] Red Hat Hardware Certification Program Reporter: Dong Zhu <dZhu>
Component: Test Suite (harness)Assignee: Greg Nichols <gnichols>
Status: CLOSED CURRENTRELEASE QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 1.7.0CC: gnichols, qcai, rlandry, wgomerin
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: hwcert-client 1.7.0-20131203 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-07-05 17:50:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 1016295    
Attachments:
Description Flags
Fix the error "could not determine selinux parameters" when selinux is disabled gnichols: review+

Description Dong Zhu 2013-11-21 09:38:40 UTC
Description of problem:
when executing "hwcert-backend run" I got the following errors on rhel-7 :
# hwcert-backend run

Running the following tests:
USB2                  pci0000:00/0000:00:1a.7/usb1        
1GigEthernet enp11s0    pci0000:00/0000:00:01.0/0000:0b:00.0/net/enp11s0
Ethernet   enp0s29f0u2 usb5/5-2/5-2:1.0/net/enp0s29f0u2    
memory                                                    
fv_core                                                   
fv_memory                                                 
fv_network                                                
fv_storage                                                
video                 pci0000:00/0000:00:1c.4/0000:06:00.0/0000:07:00.0
storage    host4      host4/target4:1:3/4:1:3:0/block/sda 
core                                                      
cpuscaling                                                
profiler                                                  
info                                                      
kdump      nfs                                            
kdump      local                                          

Network test for enp11s0 failed verification:
Error: No test server was set.

Network test for enp0s29f0u2 failed verification:
Error: Could not determine IP Address.
Error: No test server was set.
System Memory: 15907 MB
Free Memory: 15475 MB
Swap Memory: 8071 MB
Error: could not determine selinux parameters
"/usr/sbin/sestatus" no match for regular expression Current mode:[     ]+(?P<selinuxMode>[a-zA-Z]+)
kdump test for nfs failed verification: No test server was set.

4 Tests Failed Verification

selinux enabled:
# sestatus
SELinux status:                 enabled
SELinuxfs mount:                /sys/fs/selinux
SELinux root directory:         /etc/selinux
Loaded policy name:             targeted
Current mode:                   enforcing
Mode from config file:          enforcing
Policy MLS status:              enabled
Policy deny_unknown status:     allowed
Max kernel policy version:      28


selinux disabled:
# sestatus
SELinux status:                 disabled

If the the selinux is disabled currently it will not match the regex anymore so we will get this error.

Version-Release number of selected component (if applicable):
hwcert-client-1.7.0-20131120.el7

Comment 1 Dong Zhu 2013-11-28 05:37:44 UTC
Created attachment 829992 [details]
Fix the error "could not determine selinux parameters" when selinux is disabled