ifcfg: downgrade warning about NM_CONTROLLED=no
NM_CONTROLLED=no is an explicit user configuration. There is no point in issuing a warning that the user doesn't want to manage a device. <warn> [1467722628.7388] ifcfg-rh: Ignoring connection /etc/sysconfig/network-scripts/ifcfg-eth0 (5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03,"System eth0") / device 'eth0' due to NM_CONTROLLED=no. Also, don't truncate the device spec, instead show the full device spec, it may contains a MAC address or a s390 subchannel.
This commit is contained in:
@@ -470,7 +470,7 @@ nm_ifcfg_connection_init (NMIfcfgConnection *connection)
|
||||
|
||||
static void
|
||||
set_property (GObject *object, guint prop_id,
|
||||
const GValue *value, GParamSpec *pspec)
|
||||
const GValue *value, GParamSpec *pspec)
|
||||
{
|
||||
NMIfcfgConnectionPrivate *priv = NM_IFCFG_CONNECTION_GET_PRIVATE (object);
|
||||
|
||||
@@ -489,7 +489,7 @@ set_property (GObject *object, guint prop_id,
|
||||
|
||||
static void
|
||||
get_property (GObject *object, guint prop_id,
|
||||
GValue *value, GParamSpec *pspec)
|
||||
GValue *value, GParamSpec *pspec)
|
||||
{
|
||||
NMIfcfgConnectionPrivate *priv = NM_IFCFG_CONNECTION_GET_PRIVATE (object);
|
||||
|
||||
|
@@ -363,17 +363,9 @@ update_connection (SettingsPluginIfcfg *self,
|
||||
self);
|
||||
|
||||
if (nm_ifcfg_connection_get_unmanaged_spec (connection_new)) {
|
||||
const char *spec;
|
||||
const char *device_id;
|
||||
|
||||
spec = nm_ifcfg_connection_get_unmanaged_spec (connection_new);
|
||||
device_id = strchr (spec, ':');
|
||||
if (device_id)
|
||||
device_id++;
|
||||
else
|
||||
device_id = spec;
|
||||
_LOGW ("Ignoring connection "NM_IFCFG_CONNECTION_LOG_FMT" / device '%s' due to NM_CONTROLLED=no.",
|
||||
NM_IFCFG_CONNECTION_LOG_ARG (connection_new), device_id);
|
||||
_LOGI ("Ignoring connection "NM_IFCFG_CONNECTION_LOG_FMT" due to NM_CONTROLLED=no. Unmanaged: %s.",
|
||||
NM_IFCFG_CONNECTION_LOG_ARG (connection_new),
|
||||
nm_ifcfg_connection_get_unmanaged_spec (connection_new));
|
||||
} else if (nm_ifcfg_connection_get_unrecognized_spec (connection_new))
|
||||
_LOGW ("Ignoring connection "NM_IFCFG_CONNECTION_LOG_FMT" of unrecognized type.", NM_IFCFG_CONNECTION_LOG_ARG (connection_new));
|
||||
|
||||
|
Reference in New Issue
Block a user