Bug 5780 - rp3 segfault if DEVICE= line missing in ifcfg-XXX
rp3 segfault if DEVICE= line missing in ifcfg-XXX
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: rp3 (Show other bugs)
6.1
All Linux
medium Severity high
: ---
: ---
Assigned To: Michael K. Johnson
:
: 5984 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-10-09 13:32 EDT by tzs
Modified: 2007-04-18 12:23 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-11-22 15:28:33 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description tzs 1999-10-09 13:32:40 EDT
If the ifcfg-XXX file in /etc/sysconfig/network-scripts for
device XXX does not have a DEVICE= entry, rp3 will segfault.
At line 314 of interface.c, i->logicalName will be set to
NULL.  At line 417, that null pointer is passed to strncmp
to compare it to "PPP".  *BOOM*
Comment 1 Michael K. Johnson 1999-10-27 12:06:59 EDT
Nothing that uses the ifcfg files works if the DEVICE= line is
missing.  It is a critical data element in that file.  None of
the tools that modifies that file should leave that line out.
How did it get left out in the first place?
Comment 2 Michael K. Johnson 1999-10-29 16:31:59 EDT
I suppose I should be clearer: how did you create that network
configuration, what tools (if any) did you use to edit it, and
did you ever try to edit it by hand?

Sorry for the less-than-clear question before.

------- Additional Comments From   10/29/99 17:05 -------
I'm not sure how I created it.  The one perhaps unusual thing I'm
doing is running two networks on one card, so I've got "ifconfig
eth0:0 192.168.0.1" in my rc.local, and a couple lines to enable IP
masquerading between that network and the other network.  I don't know
what made the device entry in network-scripts.  Looking at my notes of
what I've changed since installing RH 6.1, I don't see anything that
would have changed that file.  I'm pretty sure the only hand editing I
did was to add in the DEVICE= entry after determining that its lack
was causing the crash.
Comment 3 Michael K. Johnson 1999-11-01 12:22:59 EST
Do you know if you used netcfg or linuxconf to set up the
ethernet device in the first place, or to modify it later,
or did you just set it up as part of the install process?

Thanks,
Comment 4 Michael K. Johnson 1999-11-04 16:49:59 EST
Hmm, it appears that enough people have this problem that we should
work around it in rp3 as well as try to resolve it at its source, so
the next version of rp3 should fix this.  I would still appreciate a
list of any programs you used to modify the network configuration so
that I can try to search for the source of this problem and fix it
at its root.
Comment 5 Michael K. Johnson 1999-11-04 16:56:59 EST
*** Bug 5984 has been marked as a duplicate of this bug. ***

Upon updating a Redhat 6.0 i386 system to Redhat 6.1,
usernet (replaced with rp3) crashes when run (segmentation
error).

All packages required by rp3 (according to rp3.spec provided
in the source distribution) are installed.

A sample stack trace follows:

stat("/etc/gnome/config//rp3", 0xbffff8a0) = -1 ENOENT (No
such file or directory)
stat("./gnome/config//rp3", 0xbffff894) = -1 ENOENT (No such
file or directory)
time(NULL)                              = 939987808
time(NULL)                              = 939987808
socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 6
--- SIGSEGV (Segmentation fault) ---


------- Additional Comments From   10/18/99 23:26 -------
Upon upgrading a different i386 machine from RedHat 6.0 to RedHat 6.1,
I found the same results, rp3 (usernet) crashes.

I was able to fix this problem on both machines by running netcfg, and
removing an un-named interface from the Interfaces section of the
Network Configurator. As far as I can tell, the 'un-named' interface
did not exist before performing the upgrade from 6.0 to 6.1.

In result, rp3 runs fine.

------- Additional Comments From johnsonm@redhat.com  10/27/99 12:22 -------
Could the original reporter of this bug check bug 5780 and see
if it's the same problem?

------- Additional Comments From kprox@wwnet.net  10/27/99 22:52 -------
It seems very similar. Beyond the stack trace, I did run rp3 under
xgdb, and the xgdb stack trace displayed an error similar to the one
listed in bug #5780. Unfortunately, I can not recall the exact xgdb
stack trace error display, but it should be easy enough to re-create.

------- Additional Comments From johnsonm@redhat.com  11/01/99 12:23 -------
Well, do any of the /etc/sysconfig/network-scripts/ifcfg-*
file not contain a line starting with "DEVICE="?
Comment 6 Michael K. Johnson 1999-11-18 18:28:59 EST
Please try
ftp://people.redhat.com/johnsonm/rp3/rp3-1.0.2-i386.rpm
and see if it fixes the problem for you.
Comment 7 Michael K. Johnson 1999-11-22 15:28:59 EST
I'm going to assume that 1.0.2 fixes the bug, since I haven't heard back.
If that's not the case, please reopen the bug and let me know.  Thanks!
I've marked it fixed in RawHide, but we have an upcoming errata release
as well once a few more bugs are fixed.

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