WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: xsetup  (Read 4000 times)

Offline mbertrand

  • Full Member
  • ***
  • Posts: 225
xsetup
« on: January 27, 2015, 01:30:36 PM »
Apart from boot code, what could invoke xsetup?
We have the same scripts running on systems that have slightly different video.
In .xsession when we specify resolution arg with xvesa would a resolution not supported cause xsetup to run and if so where would I find this code?
Thanks.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11049
Re: xsetup
« Reply #1 on: January 27, 2015, 02:51:10 PM »
Besides the bootcode, it is run by startx if the X server differs. For example, if your current X server is Xorg, but the line in .xsession references Xfbdev, xsetup would be run.

There is no code to handle other conditions like the X server failing to start.
The only barriers that can stop you are the ones you create yourself.

Offline mbertrand

  • Full Member
  • ***
  • Posts: 225
Re: xsetup
« Reply #2 on: January 27, 2015, 03:13:47 PM »
Ok thanks

Offline mbertrand

  • Full Member
  • ***
  • Posts: 225
Re: xsetup
« Reply #3 on: January 27, 2015, 03:21:59 PM »
How does it know what the current X server is?
It's odd because I never explicitly changed server . Always been xvesa. The only difference is the resolution may not support what is set in the .xsession.
« Last Edit: January 27, 2015, 03:28:59 PM by mbertrand »

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11049
Re: xsetup
« Reply #4 on: January 27, 2015, 03:49:07 PM »
Each X server extension writes its name into a file in /etc/sysconfig, letting the system know that way.
The only barriers that can stop you are the ones you create yourself.

Offline mbertrand

  • Full Member
  • ***
  • Posts: 225
Re: xsetup
« Reply #5 on: January 27, 2015, 03:50:37 PM »
Great, thanks.

Offline mbertrand

  • Full Member
  • ***
  • Posts: 225
Re: xsetup
« Reply #6 on: January 27, 2015, 03:57:55 PM »
Is it possible that I had to different xserver packages. If so then I guess the last one would be in sysconfig/Xserver and I'm trying to load the other one?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11049
Re: xsetup
« Reply #7 on: January 28, 2015, 04:40:04 AM »
Sorry?
The only barriers that can stop you are the ones you create yourself.

Offline CentralWare

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 776
Re: xsetup
« Reply #8 on: January 28, 2015, 05:34:46 AM »
If you tce-loaded Xvesa and Xorg (in that order) it would be my impression the launch script of Xorg (the last one to run) in /usr/local/tce.installed/Xorg-x.x would be the last one to update sysconfig and thus be the one that gets executed.  HAVING both should not cause an issue other than possibly Xorg wanting more drivers for graphics (ie: ATI/AMD Radeon generally fails in Xorg without the radeon driver, while it'll still run under Xvesa.)

An easy way to find out:
On a machine which DOES boot into the engine, open a terminal and run ps -a | grep X and either Xorg or Xvesa will be listed.  (I don't think they can both live from boot (as is, if you tried to do so purposefully) at the same time as I'd assume they'd both try to launch display :0 so you should find one or the other.)
« Last Edit: January 28, 2015, 05:36:59 AM by centralware »

Offline CentralWare

  • Retired Admins
  • Hero Member
  • *****
  • Posts: 776
Re: xsetup
« Reply #9 on: January 28, 2015, 05:45:15 AM »
@Curaga: Can you think of any way to poll the system for a monitor's "preferred" resolution?  (I don't recall which distro - I'm thinking it might have been CentOS/Fedora quite some time ago which seemed to know this, along with WinXP/7 which also seems to know this, so I "know" there just "has" to be a way...  I just can't think of it unless it would be specific to monitor drivers, which goes well past the TC scope.)  In class/graphics I don't think there's going to be much of anything as I doubt the GPU "calls" the monitor to ask for these details and I don't remember there being class/monitor.  Any ideas?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11049
Re: xsetup
« Reply #10 on: January 28, 2015, 07:14:54 AM »
Yes, Xorg does EDID probing, but there are standalone applications as well. ddcprobe and readedid are two.
The only barriers that can stop you are the ones you create yourself.