About the X server

Hi guys,

I would like to know what "X server' means. i have tried a few books but i still have a vague idea about it. just give me the basics......
also suggest a few websites.

I would like to know how difficult it is to make a xserver for windows.
can you give me a brief explanation of the xprotocol.

does it send me the images bit by bit or just asks me to draw the windows however i like,,,,
also if a mouse is clicked who is supposed to recognose it. does the server find out which window was clicked ans send a event mouse click to that client or do i just send message click..( to whom do i send it?)

please reply.... i am very confused,,,,,,,,,,,

baprebapAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

DVBCommented:
Here's my understanding of wht Xserver is.
This is the program that gives you the GUI on a un*x. The drawing of windows/handling of i/p is done by a separate program called as window manager.
Try www.xfree86.org for some help. These are the guys who write the x server for Linux/BSD/other unices.
I'm sorry to give a partial answer, but I'm not too confident about myself here. (I'm going to do this next, after I learn Linux well enough to admin my machine well (and after I graduate:))).
0
strmtrprCommented:
try man Xserver.
0
spavCommented:
The Xserver allows the hardware to talk to the video card, keyboard and mouse.  Like DVB said above.  The windowmanager takes care of the actual windows and placement and the like.  But without the Xserver translating the mouse and keyboard and pumping those grafix to the video card, you wouls see nothing.
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

baprebapAuthor Commented:
I have learnt a bit more of x by this time.
i wouls like to know the work of the window manager.

the xservers in our labs display a menu of the list of hosts willing to connect. WHO GIVES this list. i read that it is got by a XDMCP request. To whom am i to send the request? Also everybody says the xserver runs at port 6000. what does this actually mean?
After selecting the host from the menu i get a login screen. WHO gives this login screen.

also,
let a screen have many windows. when a mouse is clicked do i have to resolve in which window it was clicked and give it the focus or.....

please help...
i am giving ample points
0
spavCommented:
Logins to X are handled by XDM.  That is your translator for security access.  The port 6000 you are also talking about is a that it is possible to use X like a terminal server.  Using RSH or SSH you can fire up X and then ssh through an xterm to another server, and run an X program from that server.  The output is then piped to port 6000 where the X server translates the program into your windomanager.

As said before the X server handles the mouse keyboard, and video.  Everything else is handled by the window manager.  The window manager handles also handles issues like focus.  Usually this is customizable.  I use WindowMaker, and you can set it to however you want it to work, whether it be for the focus to follow the mouse, or for the window to be clicked on to be focused on.  

The list of hosts, I personally have never run into, but I can tell you that it is most likely handled by an XDM call and is asking which host you wish to authenticate to.  Which in turn brings up XDM's login prompt, that then moves you into your window manager of choice, that run on top of the X server.

best of luck, and I hope that made enough sense :)
0
baprebapAuthor Commented:
Thank you spav...
Just a few more q's and i will give u the pts..

you said that the login is managed by the xdm.usually the xdm starts up the xserver in specified local and freign machines and manages the login. my situation is like this. i am running a xserver in windows. i have to login into the remote client i.e the unix server. the question is how do i contact this xdm process. is it runnning as a daemon in a specific port?
and what is this XDMCP used for? is it for what i have said ? (to contact the xdm process)

0
baprebapAuthor Commented:
Thank you spav...
Just a few more q's and i will give u the pts..

you said that the login is managed by the xdm.usually the xdm starts up the xserver in specified local and freign machines and manages the login. my situation is like this. i am running a xserver in windows. i have to login into the remote client i.e the unix server. the question is how do i contact this xdm process. is it runnning as a daemon in a specific port?
and what is this XDMCP used for? is it for what i have said ? (to contact the xdm process)

0
spavCommented:
According to the man page (which has a wealth of info on this subject)  XDM has the ability to use XDMCP which will make a call to the server you are trying to log into.  If this is a different host than the local machine, then it will probably give you a list that is predefined in a configuration file on that server.  So in essence XDM and XDMCP are one and the same on linux.  In older unices the two may have been seperate, but XDM actually will make the same calls that XDMCP makes to query the proper host for login.

To get far enough to even get a login prompt you have to be already running an X server.  So after you choose your host and log in the only other call you're making is to load the proper windowmanger that your account is associated with, and from there you should be at your familiar interface.  

XDM runs on top of the X server as an intermediary to get an authentication to a server, it is a daemon, but it does not use a port.  That port 6000 mentioned earlier is something that is inherant in the X server to pipe programs and run terminal sessions remotely.

I hope that I'm answering your question, but if you're having a specific problem per say, let me know.

good luck
0
baprebapAuthor Commented:
Dear spav,
I get your answer. i am using a xterminal whose name is not present in the list i.e the Xservers file. i read that the xterminal i.e the server can contact the xdm using XDMCP and set up a login session.

what i want to know is how does the xterminal contact the xdm process . where is the specification on XDMCP?

0
jyu_88Commented:
the list can be fixed list in a file or it can be gathered through XDMCP query on the network. The XDMCP compliant remote server actually can configure to broadcast or not to the network once it is up. /etc/X11/xdm/Xaccess in RedHat.
If you use Xnest under Linux, you can do indirect or direct.

X terminal has a bare-bone (nobody is managing it) server up. It could be set up to gather a list of XDMCP compliant servers on the network and show it as a list for you to choose. Basically, X server on the X terminal is asking the chosen remote server to manage Xserver on X terminal based on XDMCP.
0
xtek121499Commented:
Basically XDMCP is X Display Management Protocol.
XDM is X Display Manager program.

xdm is running in Linux/Unix systems waiting for X server connection.
xdm uses udp 177 port number.
PC X server broadcast xdm query message at broadcast address.
So, every systems on the same network can receive the query message
including Linux/Unix system.

If xdm receives the query message from PC X server,
it send willing message to the X server.
And so, PC X server can display the host list.

If you select a host and connect to it, the xdm prepares
some working environments and displays a greeting window.
The greeting window is just a login window.
And greeting window is normal X client program.
It connects to PC X server at TCP 6000 port number.

Can you understand this story?

In summary,
PC X server is an xdm client,
xdm is server program waiting for connection from PC X server in UDP port number 177.
A greeting window is X client that connects to PC X server at TCP port number 6000.
PC X server is a display server that is waiting for connection
from an X client.
PC X server opens TCP port 6000, and wait for a pretty client.

sorry, I know very well but can't explain nicely.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.