Bug 66492 - Xconfigurator causes segmentation fault
Summary: Xconfigurator causes segmentation fault
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: Xconfigurator (Show other bugs)
(Show other bugs)
Version: 7.3
Hardware: i386 Linux
Target Milestone: ---
Assignee: Mike A. Harris
QA Contact: David Lawrence
Depends On:
TreeView+ depends on / blocked
Reported: 2002-06-11 12:43 UTC by Henry Tieding
Modified: 2007-04-18 16:43 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-08-05 14:14:06 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
lspci -n output (225 bytes, text/plain)
2002-06-13 01:30 UTC, Henry Tieding
no flags Details
strace of Xconfigurator (41.76 KB, text/plain)
2002-06-13 01:31 UTC, Henry Tieding
no flags Details
XFree86.0.log (1.31 KB, text/plain)
2002-06-13 01:32 UTC, Henry Tieding
no flags Details
/etc/X11/XF86Config (15.99 KB, text/plain)
2002-06-13 01:34 UTC, Henry Tieding
no flags Details
install log (15.12 KB, text/plain)
2002-06-13 01:34 UTC, Henry Tieding
no flags Details
last upgrade log (39.57 KB, text/plain)
2002-06-13 01:35 UTC, Henry Tieding
no flags Details

Description Henry Tieding 2002-06-11 12:43:51 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows 98)

Description of problem:
After installing 7.3 as a server, the "X" server returns errors and will not 
start. Any attemp to run Xconfigurator results in a segmentation fault.

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

How reproducible:

Steps to Reproduce:
1. run startx results in failure
2. run Xconfigurator to configure "X"

Actual Results:  segmentation fault

Additional info:

See help ticket 207146 for full details.
includes strace Xconfigurator output and install log messages.
Technical support has not been able to resolve this.

Comment 1 Mike A. Harris 2002-06-12 00:07:55 UTC
All bug reports in bugzilla must directly contain all of the details
pertaining to the bug.  Engineers do not have access to view help ticket
details, RHN registration details, nor other customer information.

I'll need to know what specific video hardware you've got, as well as a
complete step by step description of how you are able to reproduce the
problem.  "lspci -n" output will provide the video hardware details.

Also, if you've got config files spit out by Xconfigurator, please attach
them, and an X server log if possible to the bug report by using the
link below.


Comment 2 Henry Tieding 2002-06-13 01:28:54 UTC
Starting from a fully operational 7.2 workstation, I did a server install of 
7.3. The install appeared to work correctly, including the "X" configuration(at 
least the display test, etc appeared to work). Upon booting the system, GRUB 
executed in full graphics mode, however "X" would not start automaticaly. 
Manually issuing a startx command causes the message
"INIT: Id "x" respawning too fast: disabled for 5 minutes" to be displayed 
every 5 minutes. After working with tech support for several days trying to 
correct the problem a manual exec of Xconfigurator was tried with a 
segmentation fault, always the result of the command. I am attaching the "X" 
log, the lspci requested, and messages file from install, upgrade, etc

Comment 3 Henry Tieding 2002-06-13 01:30:33 UTC
Created attachment 60744 [details]
lspci -n output

Comment 4 Henry Tieding 2002-06-13 01:31:40 UTC
Created attachment 60745 [details]
strace of Xconfigurator

Comment 5 Henry Tieding 2002-06-13 01:32:52 UTC
Created attachment 60746 [details]

Comment 6 Henry Tieding 2002-06-13 01:34:04 UTC
Created attachment 60747 [details]

Comment 7 Henry Tieding 2002-06-13 01:34:59 UTC
Created attachment 60748 [details]
install log

Comment 8 Henry Tieding 2002-06-13 01:35:56 UTC
Created attachment 60749 [details]
last upgrade log

Comment 9 Henry Tieding 2002-06-13 01:37:30 UTC
have not located any files spit out by Xconfigurator.

Comment 10 Alexei Podtelezhnikov 2002-06-13 17:25:11 UTC
Just one more.... /etc/X11/XF86Config-4 ... anaconda and Xconfigurator write 
that one.

Comment 11 Henry Tieding 2002-06-13 18:08:22 UTC
Do not believe /etc/X11/XF86Config-4 exists, will confirm later this pm.

Comment 12 Henry Tieding 2002-06-13 23:06:25 UTC
/etc/X11/XF86Config-4 does not exist.

Comment 13 Olivier Baudron 2002-06-15 18:12:33 UTC
At what moment does Xconfigurator segfaults? At the beginning?
Would you mind running it through gdb?

Comment 14 Henry Tieding 2002-06-18 12:29:10 UTC
1. Failure of Xconfigurator occurs 15-20 seconds after selecting "OK" on the 
initial screen. No information is displayed except for the 
message "Segmentation fault".
2. I have never used gdb before, can you give me some direction?

Comment 15 Olivier Baudron 2002-06-18 12:54:05 UTC
$ gdb Xconfigurator
(gdb) r
After it crashes...
(gdb) bt

Don't type $ and (gdb), these are prompts.
'r' means 'run'
'bt' means 'backtrace'

Comment 16 Henry Tieding 2002-06-18 23:12:39 UTC
(gdb) r
  Program received signal SIGSEGV, Segmentation fault.
  0x400ddd07 in strlen () from /lib/libc.so.6ce
(gdb) bt
  #0 0x400ddd07 in strlen() from /lib/libc/so.6
  #1 0x0804e3fa in carddb_configuration ()
  #2 0x08053c50 in main ()
  #3 0x4007b0c4 in __libc_start_main from /lib/libc.so.6

Comment 17 Mike A. Harris 2002-06-18 23:22:06 UTC
Hmm.  SEGV in strlen() seems to suggest it is being passed NULL or
some garbage.

Comment 18 Olivier Baudron 2002-06-18 23:57:46 UTC
Now that you masterize gdb, can you start it again with:
$ export LD_PRELOAD=/usr/lib/libefence.so.0
$ gdb Xconfigurator
and etc...

You may have to install ElectricFence, for this.
It will help for telling us where the segfault really occurs.

Comment 19 Henry Tieding 2002-06-19 02:32:54 UTC

Comment 20 Olivier Baudron 2002-06-19 02:37:58 UTC
Yes, a debugging tool in the RedHat distribution.

Comment 21 Henry Tieding 2002-06-20 02:20:07 UTC
results using ElectricFence are identical with previous, except for address.

Comment 22 Henry Tieding 2002-06-28 22:14:15 UTC
Any thing I should do?

Comment 23 Olivier Baudron 2002-06-29 19:07:41 UTC
Could you recompile Xconfigurator with the debbuging flag -g ?
It would be useful to know at where it segfaults.

Comment 24 Need Real Name 2002-07-13 17:36:08 UTC
Have identical bug....... platform HP Vectra 166mHx 64mbt install from scratch

Comment 25 Need Real Name 2002-08-04 18:56:45 UTC
same problem, please notify when corrected

RH 7.3 - new install, S3 775 2mb EDO, S3 Trio 64v2/dx

Open Service Request 210904

Comment 26 Olivier Baudron 2002-08-05 13:48:50 UTC
The problem is when DRIVER is not given in the database /usr/X11R6/lib/X11/Cards
(or /usr/share/hwdata/Cards, I don't know which one is actually used).

Example: for dweeks the relevant part is:

# S3 Trio64V2

# Commented out the DRIVER line since it is not valid as of 4.2.0
NAME S3 Trio64V2 (generic)

Note that hwdata should certainly be updated because officially, this chipset
_is_ supported by XFree86: http://www.xfree86.org/4.2.0/Status28.html#28
"4.2.0: Support (accelerated) for ..., Trio64V2, ..."

Dweeks, can you uncomment #DRIVER s3 in
/usr/X11R6/lib/X11/Cards and /usr/share/hwdata/Cards and tell us if it works?

Other participants can also play if they find their hardware in the list.

And now, the bug in Xconfigurator-4.10.7-3:


        driver_name = strdup(card[i].driver);
            if((card[i].flags & UNSUPPORTED) && !preferxf4 ){
    card_selected = i;

If no driver is defined in the database, then driver_name remains to NULL.
And later:

driver = alloca (strlen(driver_name) + strlen(_(" (Not used by default)")) + 1);

which segfaults at the first strlen().

Btw: Xconfigurator has disappeared from rawhide (??)

Comment 27 Olivier Baudron 2002-08-05 14:14:01 UTC
I checked XFree86 official sources and for the S3 Trio64V2 it is:

# S3 Trio64V2

NAME S3 Trio64V2 (generic)

Comment 28 Mike A. Harris 2002-08-05 23:07:31 UTC
The XFree86 official sources contains an out of date and completely
unmaintained Cards database.

Our Cards file should have had the "SERVER" line commented out instead
of the DRIVER line.  Oops.  Fixed in CVS, and will be in rawhide soon.

It is set to the "s3" driver.  If that driver does not work, try
the "vesa" driver, and report back here, reopening the bug.  If "vesa" does
not work, try "vga".  Let me know your results and I will change the
default accordingly.

Also, for the record..

>Note that hwdata should certainly be updated because officially, this chipset
>_is_ supported by XFree86: http://www.xfree86.org/4.2.0/Status28.html#28
>"4.2.0: Support (accelerated) for ..., Trio64V2, ..."

That would be all fine and dandy if there was ONE card called Trio64V2,
and only one card. There isn't however.  There are a plethora of cards
called that, all of which are slightly different, use different RAMDACs
etc.  Only SOME of them are supported, not all of them.

If you use the s3 driver and it works, then your card is supported by
the driver.  Submit the output of "lspci -vvn" and also "lspci -vv"
and a special entry for your specific card will be added to override
the default.

If "s3" driver does not work, then use "vesa" then "vga" as described
above.  Finally, if no XFree86 4.2.0 driver works - the card is not
supported and will not be fixed, because we do not have 5000 S3 cards
lying around, nor the documentation for them.

Closing bug as fixed in RAWHIDE hwdata package, which will appear sometime
this week.

Comment 29 Mike A. Harris 2002-08-06 00:30:53 UTC
dweeks@frognet.net: I have no idea what "Open Service Request 210904"
is refering to, however if it is some Red Hat tech support ticket number
or somesuch it is useless to me.

Red Hat engineers do not have access to tech support ticket issues.  All
bug report details are tracked solely in bugzilla and must not refer
to outside alternate ticket systems, etc..

Comment 30 Olivier Baudron 2002-08-06 07:38:49 UTC
I had a closer look at how data from 'Cards' were processed and I may be wrong
in my analisis. Line 2007 from Xconfigurator.c is in fact never reached since no
flags 'UNSUPPORTED' are set.

So there is a segfault that remains mysterious to me...

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