PDA

View Full Version : X server problem


GigiLaTrottola
03-23-2008, 10:14 AM
I don't know if it's the right section to post, but the problem is about my x server video card (I guess), and it seems to me that this is the best way to do. So, let's start. I don't know why but I've noticed that if I run

kate
kate: cannot connect to X server

this is for every application I try to run and in particular when I do the following

winecfg
Application tried to create a window, but no driver could be loaded.
Make sure that your X server is running and that $DISPLAY is set correctly.
Application tried to create a window, but no driver could be loaded.
Make sure that your X server is running and that $DISPLAY is set correctly.
err:ole:apartment_createwindowifneeded CreateWindow failed with error 1114


I think that there's something wrong with x-server. Yesterday I've run the setup display and then everything went fine but this morning it's not. My monitor is a

LG Flatron L1915S

and my graphic card is

none1@pci1:0:0: class=0x030000 card=0x40601043 chip=0x015110de rev=0xa4 hdr=0x00
vendor = 'NVIDIA Corporation'
device = 'GeForce2 Ti (DDR) [NV15DDR]'
class = display
subclass = VGA


How can I fix the problem? Give me your knowledge I'm like a sponge (bath sponge) :-D

Bye, Daniele.

GigiLaTrottola
03-23-2008, 10:41 AM
I have to specify that I've this problem only when I try to perform commands with root user. In fact when I use my user everything is fine.

Bye, Daniele.

pheet
03-23-2008, 04:17 PM
I have to specify that I've this problem only when I try to perform commands with root user.

Hmm, I suspected that when I read your inital post :)

The default configuration (at least on PCBSD) for the X-server is that other users (even root) cannot connect to your display while you're logged in.

You can change the configuration, maybe start here for info (http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/x11.html), but this may make the setup less secure.

Easier to run through kdesu. E.g, from a console (as your normal user, not root):

% kdesu kate &

Also, if you right-click an item in the Kmenu, there's an option for "Put into run dialog". This dialog will also allow you to run the application as root - tick "run as another user" and enter the necessary details.

HTH

GigiLaTrottola
03-23-2008, 05:13 PM
Well, sometimes I'm still noob :-D. Thanks for explanation, I've increased my knowledge. In these days I will read something about kdesu. I've always thought that it was another shell like bash or C-shell.

Bye,
Daniele.

TerryP
03-23-2008, 05:44 PM
kdesu's just a wrapper around the su program.

rayden5
06-20-2008, 06:28 AM
well that's not a problem at all, KDE by default doesn't let root to connect to the xserver... you can change that in the kdmrc file... You can give temporary root window lautch right's to the root by simply run the following command as the user who have launtched the KDE -> xhost +

keep cool

regards rayden

TerryP
06-21-2008, 05:28 PM
IF memory serves, you would want xhost +root when doing something like that

because xhost +

should mean, let the whole freaking user base connect to my $DISPLAY and fool around.

rayden5
06-26-2008, 08:07 AM
basically yes, but only temporarly...

GigiLaTrottola
09-30-2008, 08:46 AM
Hi guys,
yesterday I've installed pcbsd 7. Everything about the installation process went fine, but when I reboot the PC I get the following problem.

X server start the auto-detection process to determine the right configuration, but then, what I get is a screen with green pixels and with missing windows to set the right value of frequencies and resolution. After that the screen goes down and I can't see anything.

Hence, I' ve tried the following solutions but nothing worked. The first thing I did is to unplug the screen since the boot process is started to "jump" the configuration... but nothing to do. So I've selected #7 from menu to restart configuration...but nothing to do. The only thing I can do is to select #4 from menu and start the "console" mode. In this way I can see my xorg.conf file and the content is the following


# XFree86 configuration file for RoFreeSBIE

Section "ServerLayout"
Identifier "XFree86 Configured"
Screen 0 "Screen0" 0 0
InputDevice "Mouse0" "CorePointer"
InputDevice "Keyboard0" "CoreKeyboard"
EndSection

Section "ServerFlags"
Option "DisableVidModeExtension" "True"
#Option "NoTrapSignals" "True"
#Option "DisableModInDev" "True"
EndSection

Section "Files"
RgbPath "/usr/local/lib/X11/rgb"
ModulePath "/usr/local/lib/modules"
ModulePath "/usr/local/lib/xorg/modules"
FontPath "/usr/local/lib/X11/fonts/cyrillic/"
FontPath "/usr/local/lib/X11/fonts/TrueType/"
FontPath "/usr/local/lib/X11/fonts/illinoy/"
FontPath "/usr/local/lib/X11/fonts/webfonts/"
FontPath "/usr/local/lib/X11/fonts/misc/"
FontPath "/usr/local/lib/X11/fonts/TTF/"
FontPath "/usr/local/lib/X11/fonts/Speedo/"
FontPath "/usr/local/lib/X11/fonts/Type1/"
FontPath "/usr/local/lib/X11/fonts/CID/"
FontPath "/usr/local/lib/X11/fonts/75dpi/"
FontPath "/usr/local/lib/X11/fonts/100dpi/"
FontPath "/usr/local/lib/X11/fonts/dejavu/"
FontPath "/usr/local/lib/X11/fonts/cyrillic/"
FontPath "/usr/local/lib/X11/fonts/hebrew/"
FontPath "/usr/local/lib/X11/fonts/vietnamese/"
FontPath "/usr/local/lib/X11/fonts/indic/"
FontPath "/usr/local/lib/X11/fonts/ae_fonts1/AAHS"
FontPath "/usr/local/lib/X11/fonts/ae_fonts1/AGA"
FontPath "/usr/local/lib/X11/fonts/ae_fonts1/FS"
FontPath "/usr/local/lib/X11/fonts/ae_fonts1/Kasr"
FontPath "/usr/local/lib/X11/fonts/ae_fonts1/MCS"
FontPath "/usr/local/lib/X11/fonts/ae_fonts1/Shmookh"
FontPath "/usr/local/lib/X11/fonts/local/"
EndSection

Section "Module"
# Load "record"
# Load "ddc"
# Load "dri"
# Load "dbe"
# Load "extmod"
# Load "glx"
# Load "xtrap"
# Load "freetype"
EndSection

Section "InputDevice"
Identifier "Keyboard0"
Driver "keyboard"
Option "XkbModel" "pc105"
Option "XkbLayout" "us"
Option "XkbVariant" ""
EndSection

Section "InputDevice"
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "auto"
Option "Device" "/dev/sysmouse"
Option "Buttons" "6"
Option "ZAxisMapping" "4 5"
Option "Emulate3Buttons"
EndSection

Section "Screen"
Identifier "Screen0"
Device "Card0"
Monitor "Monitor0"
DefaultDepth 16
SubSection "Display"
Depth 4
Modes "1024x768"
EndSubSection
SubSection "Display"
Depth 8
Modes "1024x768"
EndSubSection
SubSection "Display"
Depth 15
Modes "1024x768"
EndSubSection
SubSection "Display"
Depth 16
Modes "1024x768"
EndSubSection
SubSection "Display"
Depth 24
Modes "1024x768"
EndSubSection
EndSection
Section "Monitor"
#DisplaySize 380 300 # mm
Identifier "Monitor0"
VendorName "GSM"
ModelName ""
### Comment all HorizSync and VertRefresh values to use DDC:
HorizSync 30.0 - 83.0
VertRefresh 56.0 - 75.0
Option "DPMS"
EndSection

Section "Device"
### Available Driver options are:-
### Values: [i]: integer, <f>: float, <bool>: "True"/"False",
### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
### [arg]: arg optional
#Option "NoAccel" # [<bool>]
#Option "SWcursor" # [<bool>]
#Option "Dac6Bit" # [<bool>]
#Option "Dac8Bit" # [<bool>]
#Option "BusType" # [<str>]
#Option "CPPIOMode" # [<bool>]
#Option "CPusecTimeout" # [i]
#Option "AGPMode" # [i]
#Option "AGPFastWrite" # [<bool>]
#Option "AGPSize" # [i]
#Option "GARTSize" # [i]
#Option "RingSize" # [i]
#Option "BufferSize" # [i]
#Option "EnableDepthMoves" # [<bool>]
#Option "EnablePageFlip" # [<bool>]
#Option "NoBackBuffer" # [<bool>]
#Option "DMAForXv" # [<bool>]
#Option "FBTexPercent" # [i]
#Option "DepthBits" # [i]
#Option "PCIAPERSize" # [i]
#Option "AccelDFS" # [<bool>]
#Option "DDCMode" # [<bool>]
#Option "IgnoreEDID" # [<bool>]
#Option "DisplayPriority" # [<str>]
#Option "PanelSize" # [<str>]
#Option "ForceMinDotClock" # <freq>
#Option "ColorTiling" # [<bool>]
#Option "VideoKey" # [i]
#Option "RageTheatreCrystal" # [i]
#Option "RageTheatreTunerPort" # [i]
#Option "RageTheatreCompositePort" # [i]
#Option "RageTheatreSVideoPort" # [i]
#Option "TunerType" # [i]
#Option "RageTheatreMicrocPath" # <str>
#Option "RageTheatreMicrocType" # <str>
#Option "ScalerWidth" # [i]
#Option "RenderAccel" # [<bool>]
#Option "SubPixelOrder" # [<str>]
#Option "ShowCache" # [<bool>]
#Option "DynamicClocks" # [<bool>]
#Option "VGAAccess" # [<bool>]
#Option "ReverseDDC" # [<bool>]
#Option "LVDSProbePLL" # [<bool>]
#Option "AccelMethod" # <str>
#Option "DRI" # [<bool>]
#Option "ConnectorTable" # <str>
#Option "DefaultConnectorTable" # [<bool>]
#Option "DefaultTMDSPLL" # [<bool>]
#Option "TVDACLoadDetect" # [<bool>]
#Option "ForceTVOut" # [<bool>]
#Option "TVStandard" # <str>
#Option "IgnoreLidStatus" # [<bool>]
#Option "DefaultTVDACAdj" # [<bool>]
#Option "Int10" # [<bool>]
Identifier "Card0"
Driver "radeon"
VendorName "ATI Technologies Inc"
BoardName "RV410 [Radeon X700 (PCIE)]"
BusID "PCI:1:0:0"
EndSection


Something in the section monitor is missing, but the frequencies rate is correct because I've an LG Flatron L1915S (technical report is here http://www.lge.com/products/model/detail/l1915s.jhtml) and an Nvidia GeForce 2 video card.
I've tried to change xorg.conf entering with #4 but the file system is read only so I can't write anything. The only thing I did was to copy xorg.conf on a USB stick.
What else?... ah... I've run into the same problem the last time I' ve installed pc bsd 1.5 but the unplug method (i.e unplugging the video during X server configuration) worked fine for me.

Bye guys.

TerryP
10-01-2008, 04:10 AM
you can remount / rewrite:


# mount -u -w /

GigiLaTrottola
10-02-2008, 08:21 AM
Hi,
let me ask this question. Why I can display correctly the graphic installer but don't the X server after reboot? What differences between before and after?
I thought... why I can't brutally copy the configuration file for X created during installation in /etc/X11/xorg.conf?
So, I started and pressed #4 then mounted / using your suggestion. I did a backup of xorg.conf and then I've replaced it with /PCBSD/xorg-gui/conf/xorg.conf.basic (which I guess it's the setup configuration for X during installation).

Now, it doesn't work the same as before. Is it possible that /PCBSD/xorg-gui/conf/xorg.conf.basic it's not the file created during installation? The fixed point is that before it works and then it doesn't. So there must be a way to make it working correctly. I'm sure!

I also think that, the auto configuring procedure overwrite every change I do to /etc/X11/xorg.conf in some way. If I change for example video card driver from "radeon" to "vesa" and restart my PC, then when I edit xorg.conf, I can see "radeon" again.

I would like to know if someone of you guys, have some suggestions. More brains is better than zero! :D

Bye,
Daniele

TerryP
10-02-2008, 07:13 PM
Why I can display correctly the graphic installer but don't the X server after reboot? What differences between before and after?


I have no idea how PC-BSD7 handles the initial config, but I would expect it either generates one or uses a stored "generic of the generic" setup.

GigiLaTrottola
10-03-2008, 08:14 AM
Hi,
Do you know someone I could ask for this problem? I mean a developer of the pcbsd team, able to explain me how the initial setup is done.
I would try to understand the procedure to try to find a solution by myself.

Now, this is only a match between me and xorg the brutus :D.

Bye,
Daniele.

TerryP
10-03-2008, 07:36 PM
Best man to ask would probably be Kris Moore, you can find his E-Mail on the team members (http://www.pcbsd.org/content/view/23/30/) page

GigiLaTrottola
10-04-2008, 04:22 PM
Hi, :D
it's still me. I've sent a mail to Kris and now I'm still waiting for his answer. In this whie I'm still going on with my experiments. I'm always booting with #4. From this shell I' ve changed xorg.conf to use a vesa card intead of a radeon... and surprise...something works but... if I tipe


startx


xauth: creating new authority file /root/.serverauth.865
xauth: (stdin):1: bad display name ":0" in "add" command
xauth: (argv):1: bad display name ":0" in "list" command
xauth: (stdin):1: bad display name ":0" in "add" command
xauth: (argv):1: bad display name ":0" in "list" command
xauth: (stdin):1: bad display name ":0" in "add" command

_XSERVTransSocketCreateListener: failed to bind listener
_XSERVTransSocketINETCreateListener: ...SocketCreateListener() failed
_XSERVTransMakeAllCOTSServerListeners: failed to create listener for inet6
waiting for X server to begin accepting connections .
_XSERVTransSocketCreateListener: failed to bind listener
_XSERVTransSocketINETCreateListener: ...SocketCreateListener() failed
_XSERVTransMakeAllCOTSServerListeners: failed to create listener for inet
.
X.Org X Server 1.4.2
Release Date: 11 June 2008
X Protocol Version 11, Revision 0
Build Operating System: FreeBSD 7.0-RELEASE i386
Current Operating System: FreeBSD 7.1-PRERELEASE FreeBSD 7.1-PRERELEASE #42: Thu Sep 11 09:07:25 EDT 2008 root@pcbsd:/usr/obj/usr/src/sys/PCBSD i386
Build Date: 07 September 2008 12:11:13AM

Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
Module Loader present
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Sat Oct 4 14:21:03 2008
(==) Using config file: "/etc/X11/xorg.conf"
(II) Module "ddc" already built-in
.expected keysym, got XF86KbdLightOnOff: line 70 of pc
expected keysym, got XF86KbdBrightnessDown: line 71 of pc
expected keysym, got XF86KbdBrightnessUp: line 72 of pc
expected keysym, got XF86KbdLightOnOff: line 70 of pc
expected keysym, got XF86KbdBrightnessDown: line 71 of pc
expected keysym, got XF86KbdBrightnessUp: line 72 of pc

Failed to read: session.screen0.maxIgnoreIncrement
Setting default value
Failed to read: session.screen0.maxDisableMove
Setting default value
Failed to read: session.screen0.maxDisableResize
Setting default value
Failed to read: session.screen0.noFocusWhileTypingDelay
Setting default value
Failed to read: session.screen0.tooltipDelay
Setting default value
Failed to read: session.screen0.allowRemoteActions
Setting default value
Failed to read: session.screen0.clientMenu.usePixmap
Setting default value
Failed to read: session.screen0.maxIgnoreIncrement
Setting default value
Failed to read: session.screen0.maxDisableMove
Setting default value
Failed to read: session.screen0.maxDisableResize
Setting default value
Failed to read: session.screen0.noFocusWhileTypingDelay
Setting default value
Failed to read: session.screen0.tooltipDelay
Setting default value
Failed to read: session.screen0.allowRemoteActions
Setting default value
Failed to read: session.screen0.clientMenu.usePixmap
Setting default value
Failed to read: session.screen0.maxIgnoreIncrement
Setting default value
Failed to read: session.screen0.maxDisableMove
Setting default value
Failed to read: session.screen0.maxDisableResize
Setting default value
Failed to read: session.screen0.noFocusWhileTypingDelay
Setting default value
Failed to read: session.screen0.tooltipDelay
Setting default value
Failed to read: session.screen0.allowRemoteActions
Setting default value
Failed to read: session.screen0.clientMenu.usePixmap
Setting default value
Failed to read: session.screen0.slit.acceptKdeDockapps
Setting default value
XGUI(892) KLocalePrivate::initEncoding: Cannot resolve system encoding, defaulting to ISO 8859-1.

waiting for X server to shut down

xauth: (argv):1: bad display name ":0" in "remove" command
xauth: (argv):1: bad display name ":0" in "remove" command
xauth: creating new authority file /root/.serverauth.936
xauth: (stdin):1: bad display name ":0" in "add" command
xauth: (argv):1: bad display name ":0" in "list" command
xauth: (stdin):1: bad display name ":0" in "add" command
xauth: (argv):1: bad display name ":0" in "list" command
xauth: (stdin):1: bad display name ":0" in "add" command


now I can see the graphical box that tell me to configure screen resolution and other things but when I push the button X server shut down and I come back to the shell. So I don't mind but if I type


startkde
$DISPLAY is not set or cannot connect to the X server.


I think that something is missing. So I've tried to set up the $DISPLAY variable (that was really empty) typing


setenv $DISPLAY ":0.0"


but the message I get is the same.
In conclusion, I suspect that the problem is due to graphical card and not to screen and some uninitialized variable. Suggestions?

Bye,
Daniele.

TerryP
10-04-2008, 07:06 PM
What is the contents of your /etc/hosts file?

If you've any .Xauthority .ICEauthority files in roots home directory or related files in /var/tmp, I would delete them.

GigiLaTrottola
10-04-2008, 07:37 PM
Thank you Terry. Now I'm not at home but tomorrow afternoon I will post what you are asking for.

One day, I'll offer you a beer (or a bottle of good italian wine)! :D

Bye,
Daniele

GigiLaTrottola
10-05-2008, 05:42 PM
Hi, :mrgreen:
I have some good and bad news. First of all here you can see the content of my /etc/hosts


# : src/etc/hosts,v 1.16 2003/01/28 21:29:23 dbaker Exp $
#
# Host Database
#
# This file should contain the addresses and aliases for local hosts that
# share this file. Replace 'my.domain' below with the domainname of your
# machine.
#
# In the presence of the domain name service or NIS, this file may
# not be consulted at all; see /etc/nsswitch.conf for the resolution order.
#
#
::1 localhost localhost.localdomain pcbsd.localhost pcbsd
127.0.0.1 localhost localhost.localdomain pcbsd.localhost pcbsd

#
# Imaginary network.
#10.0.0.2 myname.my.domain myname
#10.0.0.3 myfriend.my.domain myfriend
#
# According to RFC 1918, you can use the following IP networks for
# private nets which will never be connected to the Internet:
#
# 10.0.0.0 - 10.255.255.255
# 172.16.0.0 - 172.31.255.255
# 192.168.0.0 - 192.168.255.255
#
# In case you want to be able to connect to the Internet, you need
# real official assigned numbers. Do not try to invent your own network
# numbers but instead get one from your network provider (if any) or
# from your regional registry (ARIN, APNIC, LACNIC, RIPE NCC, or AfriNIC.)


After this, I've throwed away /root/.ICEAuthority and /root/.XAuthority then modified xorg.conf with vesa mode (sometimes is restored to the old version wiyh radeon driver enabled...bah :?:) launched startx again and now X start and I get an xterm sessione. From here I can start kde launching startkde (startfluxbox doesn't work... bah :?:) the desktop is created (empty because /root/Desktop doesn't exist) and I can't do anything.

The first time I've launched startx after erasing .ICEAuthority and .XAuthority a new copy of .ICEAuthority was creadted. You can see this here, I made a backup of the older files


ls -al /root/
total 62
drwxr-xr-x 14 root wheel 1024 Oct 5 20:16 .
drwxr-xr-x 21 root wheel 512 Oct 4 11:12 ..
-rw------- 1 root wheel 0 Oct 5 20:00 .ICEauthority
-rw------- 1 root wheel 145 Oct 5 19:25 .ICEauthority.bak
-rw------- 1 root wheel 160 Oct 5 19:25 .Xauthority.bak
drwxr-xr-x 2 root wheel 512 Sep 13 17:13 .config
-rw-r--r-- 1 master master 820 Jun 20 16:18 .cshrc
drwx------ 3 root wheel 512 Oct 2 18:48 .dbus
drwxr-xr-x 5 root wheel 512 Oct 5 20:13 .fluxbox
drwxr-xr-x 5 root wheel 512 Oct 5 19:49 .fluxbox.xbak
-rw------- 1 root wheel 2877 Oct 5 20:16 .history
drwxr----- 2 root wheel 512 Oct 5 19:47 .hplip
-rw-r--r-- 1 root wheel 143 Sep 6 22:48 .k5login
drwx------ 3 root wheel 512 Oct 4 13:00 .kde
drwx------ 4 root wheel 512 Oct 4 13:00 .kde4
drwx------ 3 root wheel 512 Oct 5 19:47 .local
-rw-r--r-- 1 root wheel 293 Sep 6 22:48 .login
drwxr-xr-x 2 root wheel 512 Oct 5 19:47 .mplayer
-rw-r--r-- 1 master master 287 Jun 20 16:18 .profile
drwxr-xr-x 2 root wheel 512 Sep 13 16:31 .qt
-rw------- 1 root wheel 100 Oct 2 18:56 .serverauth.3817
-rw------- 1 root wheel 100 Oct 2 18:40 .serverauth.3820
-rw------- 1 root wheel 50 Oct 1 23:01 .serverauth.3831
-rw------- 1 root wheel 100 Oct 2 07:42 .serverauth.3846
-rw------- 1 root wheel 100 Oct 1 23:05 .serverauth.3850
-rw------- 1 root wheel 100 Oct 4 10:48 .serverauth.3940
-rw------- 1 root wheel 100 Oct 4 12:25 .serverauth.4792
drwxr-xr-x 2 root wheel 512 Oct 5 20:00 .xine
-rwxr-xr-x 1 root wheel 816 Oct 4 12:25 .xinitrc.xbak
-rw------- 1 root wheel 529 Oct 4 13:36 .xsession-errors
-rw------- 1 root wheel 189 Oct 4 13:36 .xsm19YB0D


and here you can see my /var/tmp folder


ls -al /var/tmp/
total 8
drwxrwxrwt 4 root wheel 512 Oct 5 20:16 .
drwxr-xr-x 25 root wheel 512 Oct 5 20:04 ..
srwxrwxrwx 1 root wheel 0 Oct 4 12:25 dbus-cHOAzLuGAf
drwx------ 4 root wheel 512 Oct 5 20:15 kdecache-root
drwxrwxrwt 2 root wheel 512 Sep 7 17:24 vi.recover


An interesting thing is the following. I don't know why, but inside /root/ there was a file named xorg.conf.new. I don't know when this file was created. Another interesting thing is that sometimes xorg.conf disappear from /etc/X11 folder and I have to copy another xorg.conf file from a backup. This time I've pasted /root/xorg.conf.new in /etc/X11/ and this is what happened.

Other suggestions?
Bye,
Daniele

TerryP
10-05-2008, 07:28 PM
I have not seen it happen in a *long* time, but when I originally set up my laptop (PC-BSD 1.1~1.11a), the boot system would replace my /etc/X11/xorg.conf with a generic vesa one somewhere in /PCBSD/.


My solution was to find the file, and replace it with my xorg.conf file.

GigiLaTrottola
10-05-2008, 08:53 PM
Hi,
the problem is that I've already copied /PCBSD/xorg-gui/conf/xorg.conf.basic the first time I booted the system and xorg.conf.basic is the same as the xorg.conf that I'm actually using.
I've only three things in my mind:

1) reinstall pcbsd 1.5.1 praying god that this problem won't came again;
2) install free bsd 7;
3) try to change my hardware card or monitor to understand where is the real problem.

Changing or not... this is the problem!

Bye,
Daniele.