RH_SATELLITE = "satellite" RH_SATELLITE_DESC = "Red Hat Satellite" SAT_OPTS = SoSOptions(verify=True, plugopts=['apache.log=on']) CB = "cantboot" CB_DESC = "For use when normal system startup fails" CB_OPTS = SoSOptions(verify=True, all_logs=True, onlyplugins=_cb_plugs) CB_NOTE = ("Data collection will be limited to a boot-affecting scope") NOTE_SIZE = "This preset may increase report size" NOTE_TIME = "This preset may increase report run time" NOTE_SIZE_TIME = "This preset may increase report size and run time" rhel_presets = { RHV: PresetDefaults(name=RHV, desc=RHV_DESC, note=NOTE_TIME, opts=_opts_verify), RHEL: PresetDefaults(name=RHEL, desc=RHEL_DESC), RHOSP: PresetDefaults(name=RHOSP, desc=RHOSP_DESC, note=NOTE_SIZE, opts=_opts_all_logs_no_lsof), RHOCP: PresetDefaults(name=RHOCP, desc=RHOCP_DESC, note=NOTE_SIZE_TIME, opts=_opts_all_logs_verify), RH_SATELLITE: PresetDefaults(name=RH_SATELLITE, desc=RH_SATELLITE_DESC,
RHOSP = "rhosp" RHOSP_DESC = "Red Hat OpenStack Platform" RHOCP = "ocp" RHOCP_DESC = "OpenShift Container Platform by Red Hat" RH_SATELLITE = "satellite" RH_SATELLITE_DESC = "Red Hat Satellite" NOTE_SIZE = "This preset may increase report size" NOTE_TIME = "This preset may increase report run time" NOTE_SIZE_TIME = "This preset may increase report size and run time" rhel_presets = { RHV: PresetDefaults(name=RHV, desc=RHV_DESC, note=NOTE_TIME, opts=_opts_verify), RHEL: PresetDefaults(name=RHEL, desc=RHEL_DESC), RHOSP: PresetDefaults(name=RHOSP, desc=RHOSP_DESC, note=NOTE_SIZE, opts=_opts_all_logs_no_lsof), RHOCP: PresetDefaults(name=RHOCP, desc=RHOCP_DESC, note=NOTE_SIZE_TIME, opts=_opts_all_logs_verify), RH_SATELLITE: PresetDefaults(name=RH_SATELLITE, desc=RH_SATELLITE_DESC,
from sos.plugins import RedHatPlugin from sos.policies import LinuxPolicy, PackageManager, PresetDefaults from sos import _sos as _ from sos import SoSOptions sys.path.insert(0, "/usr/share/rhn/") try: from up2date_client import up2dateAuth from up2date_client import config from rhn import rpclib except ImportError: # might fail if non-RHEL pass rh_presets = { "": PresetDefaults(name="rhel"), "rhel7": PresetDefaults(name="rhel7"), "rhosp": PresetDefaults(name="rhosp", opts=SoSOptions(all_logs=True)), "ocp": PresetDefaults(name="ocp", opts=SoSOptions(all_logs=True, verify=True)), "rhv": PresetDefaults(name="rhv", opts=SoSOptions(verify=True)) } OS_RELEASE = "/etc/os-release" class RedHatPolicy(LinuxPolicy): distro = "Red Hat" vendor = "Red Hat" vendor_url = "http://www.redhat.com/" _redhat_release = '/etc/redhat-release'
SAT_OPTS = SoSOptions(verify=True, plugopts=['apache.log=on']) CB = "cantboot" CB_DESC = "For use when normal system startup fails" CB_OPTS = SoSOptions( verify=True, all_logs=True, profiles=_cb_profiles, plugopts=_cb_plugopts ) CB_NOTE = ("Data collection will be limited to a boot-affecting scope") NOTE_SIZE = "This preset may increase report size" NOTE_TIME = "This preset may increase report run time" NOTE_SIZE_TIME = "This preset may increase report size and run time" rhel_presets = { RHV: PresetDefaults(name=RHV, desc=RHV_DESC, note=NOTE_TIME, opts=_opts_verify), RHEL: PresetDefaults(name=RHEL, desc=RHEL_DESC), RHOSP: PresetDefaults(name=RHOSP, desc=RHOSP_DESC, opts=RHOSP_OPTS), RHOCP: PresetDefaults(name=RHOCP, desc=RHOCP_DESC, note=NOTE_SIZE_TIME, opts=_opts_all_logs_verify), RH_CFME: PresetDefaults(name=RH_CFME, desc=RH_CFME_DESC, note=NOTE_TIME, opts=_opts_verify), RH_SATELLITE: PresetDefaults(name=RH_SATELLITE, desc=RH_SATELLITE_DESC, note=NOTE_TIME, opts=SAT_OPTS), CB: PresetDefaults(name=CB, desc=CB_DESC, note=CB_NOTE, opts=CB_OPTS) } # Legal disclaimer text for Red Hat products disclaimer_text = """ Any information provided to %(vendor)s will be treated in \ accordance with the published support policies at:\n