X

System-config-network crashed on CentOS 5.3

Only today..
with one network card being inactive.. and another one is active..
tried..
via root user..
run ..

“system-config-network”

something like this spitted out. instead of the Network GUI..




Component: system-config-network
Version: 1.3.99.12
Summary: TB0a0f70ae maindialog.py:602:hydrateProfiles:TypeError: sequence item not a string or unicode object



Traceback (most recent call last):
File "/usr/sbin/system-config-network-gui", line 167, in main
window = mainDialog()
File "/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 248, in __init__
self.hydrate()
File "/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 392, in hydrate
self.hydrateProfiles()
File "/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 602, in hydrateProfiles
hclist.append([host.IP, host.Hostname,
TypeError: sequence item not a string or unicode object
Local variables in innermost frame:
profilelist: ProfileList.default.ActiveDevices.1=home
ProfileList.default.ActiveDevices.2=eth1
ProfileList.default.ActiveDevices.3=eth0
ProfileList.default.HostsList.1.Comment=# Do not remove the following line, or various programs
ProfileList.default.HostsList.1.isComment=true
ProfileList.default.HostsList.2.Comment=# that require network ality will fail.
ProfileList.default.HostsList.2.isComment=true
ProfileList.default.HostsList.3.Comment=# Do not remove the following line, or various programs
ProfileList.default.HostsList.3.isComment=true
ProfileList.default.HostsList.4.Comment=# that require network ality will fail.
ProfileList.default.HostsList.4.isComment=true
ProfileList.default.HostsList.5.Comment=
ProfileList.default.HostsList.5.isComment=true
..
Profile.DNS.Domainname=
Profile.DNS.Hostname=nb-namran.techsense.com.my
Profile.DNS.TertiaryDNS=
Profile.DNS.PrimaryDNS=202.188.0.132
Profile.Active=true
Profile.ProfileName=default
row: 49

few google search lead to this..

https://bugzilla.redhat.com/show_bug.cgi?id=474515

Grr…I just want to get my network config back as need to test something on client site WIFI setting..

heck..

Only do this if you’re so tempted to fix it quickly..
suggestion wait for real fix.. soon..


vi /usr/share/system-config-network/netconfpkg/gui/maindialog.py

go to line 602
add comment to both problematic line..


# hclist.append([host.IP, host.Hostname,
# string.join(host.AliasList, ' ')])


examine the /etc/hosts later and fix could be ideal way..

this would be a help if you only want to spend a less 1minute time to fix this .. in order to get it up again ..

and continue the work..

p/s : .. the linksys WIFI setting just went mad.. no idea why..

Updates 2 ::: Fixed it..refer to comment.

Namran Hussin:

View Comments (3)

  • I got better one after a few minute..
    by adding this two line before line 602 (/usr/share/system-config-network/netconfpkg/gui/maindialog.py)


    if (not isinstance (host.Hostname, str)):
    continue

    now it works like charms again.. hehe.. 8-)

  • This was helpful. Summary: if the /etc/hosts file is not well-formed, the python script doesn't handle it well. In my case, somehow a long entry that was commented out got "line wrapped", leaving some uncommented garbage on the next line. Fixing the hosts file or adding the above patch "worked". It seems that some complaint to the user should be generated in such a case, though.

Related Post
Leave a Comment