Bug 474528 - system-config-network - profiles problem
system-config-network - profiles problem
Product: Fedora
Classification: Fedora
Component: system-config-network (Show other bugs)
i686 Linux
low Severity urgent
: ---
: ---
Assigned To: Harald Hoyer
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2008-12-04 05:10 EST by Michalux
Modified: 2010-07-21 02:37 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2009-12-18 02:08:41 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Michalux 2008-12-04 05:10:15 EST
Description of problem:
Three profiles: Office, Home and default. Four interfaces: eth0, eth1, eth0_Home (alias of eth0), eth0_Office (alias of eth0). Initially interfaces added to the profiles as followes:
Profile      Interface
default      none
Home         eth0_Home
Office       eth0_Office

I save the above config, active the profile Office and live the s-c-n. Then I open it again and the situation looks like this:
Profile     Interface
default     eth0_Office
Home        eth0_Home, eth0_Office
Office      eth0_Office

As a result running the system then with Home profile, during reboot the system tries to ifup both the eth0_Home and eth0_Office.
Looking to the /etc/syscofnig/network-scripts I can find the hard links to both eth0_Home and eth0_Office, so even service network restart again stars to ifdown/ifup both interfaces. After removing eth0_Office - service network restart ifdows/ifups only the eth0_Home (as required).
The additionl problem is, that due to this problem, the system messes up with the hosts configuration (either doesn't link the hosts file form the choosen profiel, or leaves it empty at all).

Version-Release number of selected component (if applicable):

How reproducible:
Every time - just like described above.

Steps to Reproduce:
1. Make 2 or more aliases to eth0.
2. Prepare 2 or more profiles (additional to default)
3. Assign one interface to each profile (leave default empty)
4. Save configuration. Active one profile (other then default).
5. Try to change the profiles in s-c-n, or close the s-c-n and open it again. Than look at the profiles and assigned interfaces. 
Actual results:
Totaly messed up the network configuration after a few reboots with changed profiles. The links to interfaces (eth0_....) from the not currently used profiles seem not to be removed from /etc/sysconfig/network-scripts/

Expected results:
Interfaces assignment to paricular profiles should remain as configured. Choosen profile should provide the system with the only configured interfaces.

Additional info:
Comment 1 Michalux 2008-12-05 05:12:51 EST
After additional checking I've noticed that, when there is one profile active, there is no way to switch to another. System-control-network or s-c-n-cmd show the following error:
# system-config-network-cmd -p OFFICE -a
Network device deactivating...
Deactivating network device eth0, please wait...
An unhandled exception has occured.  This is most likely a bug.
Please file a detailed bug report against the component system-config-network at 
using the text below.
Component: system-config-network
Version: 1.5.94
Summary: TB /usr/share/system-config-network/netconfpkg/NC_functions.py:582:generic_run_dialog:AttributeError: 'list' object has no attribute 'join'
Traceback (most recent call last):
  File "/usr/sbin/system-config-network-cmd", line 364, in main
    (ret, msg) = device.deactivate()
  File "/usr/share/system-config-network/netconfpkg/NCDevice.py", line 534, in deactivate
    dialog = dialog )
  File "/usr/share/system-config-network/netconfpkg/NC_functions.py", line 582, in generic_run_dialog
    log.log(1, "Running %s %s" % (command, argv.join()))
AttributeError: 'list' object has no attribute 'join'

Local variables in innermost frame:
searchPath: 0
errlabel: Cannot deactivate network device eth0!

title: Network device deactivating...
stdin: 0
argv: ['/sbin/ifdown', 'eth0', 'down']
label: Deactivating network device eth0, please wait...
catchfd: (1, 2)
command: /sbin/ifdown
closefd: -1
dialog: None
root: /
select: <module 'select' from '/usr/lib/python2.5/lib-dynload/selectmodule.so'>

It looks like this one can be the root of the whole problem.
Comment 2 Michalux 2008-12-05 06:06:15 EST
Additional info.
I've commented out the line in NC_functions.py that had a problem with join attribute. The error stoped to show itself, but still the problem with the profiles exists. It looks like when one profile has been activated, than when I try to activate another one, then the interface assigned to currently active profile is not removed from network-scripts, and the interface assigned to the profile I want to switch to is additionally hard-linked in network-scripts. So network scripts try to up both of the interfaces.
Another thing is that when I try to switch form current profile to the Common profile (that has no interfaces assigned), s-c-n hard-links the interface assigned to current profile in /etc/sysconfig/networking/profiles/default directory, and s-c-n shows that interface as assigned to other configured profiles (although in profiles directory it shows only in its profile and default).

I'll be gratefull for some help in this problem, because now the network profiles are totaly unusable in Fedora10.
Comment 3 mkpyc9 2008-12-06 04:32:22 EST
I'm not sure if my problem is related to the above: in short, system-control-network fails if run by a non-root user.

Laptop with wireless card (eth0) and network card (eth1).

Since I do not require wireless networking, I set up a profile containing just the ethernet card.

As root, I can activate and deactivate the network card using system-control-network. The correct profile is loaded and just the ethernet connection is displayed.

When I try to run system-network-control under my regular account, the Python scripts try to open the wireless configuration, which isn't even in the current profile, in write mode:

Traceback (most recent call last):
  File "/usr/bin/system-control-network", line 536, in <module>
    window = mainDialog()
  File "/usr/bin/system-control-network", line 130, in __init__
    self.devicelist = self.getProfDeviceList()
  File "/usr/bin/system-control-network", line 453, in getProfDeviceList
    profilelist = getProfileList(refresh)
  File "/usr/share/system-config-network/netconfpkg/NCProfileList.py", line 669, in getProfileList
  File "/usr/share/system-config-network/netconfpkg/NCProfileList.py", line 90, in load
    self.loadprof(pr, profdir)                
  File "/usr/share/system-config-network/netconfpkg/NCProfileList.py", line 104, in loadprof
    devicelist = NCDeviceList.getDeviceList()
  File "/usr/share/system-config-network/netconfpkg/NCDeviceList.py", line 327, in getDeviceList
  File "/usr/share/system-config-network/netconfpkg/NCDeviceList.py", line 87, in load
  File "/usr/share/system-config-network/netconfpkg/plugins/NCPluginDevWireless.py", line 44, in load
  File "/usr/share/system-config-network/netconfpkg/NCDevice.py", line 128, in write
  File "/usr/share/system-config-network/netconfpkg/conf/Conf.py", line 329, in write
    mfile = open(self.filename, 'w', -1)
IOError: [Errno 13] Permission denied: '//etc/sysconfig/networking/devices/ifcfg-eth0'


Versions Affected
Occurs with both system-config-network 1.5.93 and 1.5.94
Comment 4 Jiri Moskovcak 2008-12-08 08:20:12 EST
comment #3:
no, this is another problem, I think it's the same like: rhbz#470203
Comment 5 Michalux 2009-01-07 07:30:54 EST
Any news regarding the problem ?
Comment 6 Bug Zapper 2009-11-18 04:26:46 EST
This message is a reminder that Fedora 10 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 10.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '10'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 10's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 10 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
Comment 7 Bug Zapper 2009-12-18 02:08:41 EST
Fedora 10 changed to end-of-life (EOL) status on 2009-12-17. Fedora 10 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.
Comment 8 Walter Neumann 2010-07-20 21:22:18 EDT
I have exactly the problem described above (first message) with Fedora 12.

Why is this "closed, wontfix"?   Could it be re-opened? For anyone who, like me, has dhcp at home and a fixed ip in the office this is a serious nuisance.
Comment 9 Harald Hoyer 2010-07-21 02:37:00 EDT
Please file a bug against NetworkManager to add profiles. system-config-network is not being developed actively anymore.

Note You need to log in before you can comment on or make changes to this bug.