blob: 80cd146f061cce2faf89bf6235bf427ed9d6984f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
|
% on the following slides, include icon in the left sidebar
\def\lximg{/usr/share/lx/icons/fueller.png}
\input{configpres}
\section{X Windows}
\title{The X Window System}
\maketitle
% stop displaying 'fueller.png' on the following slides
\def\lximg{none}
\begin{frame}
\frametitle{X / X11 / XFree / Xorg ???}
\begin{itemize}
\item X11 is a graphical environment for UNIX systems (and windows systems...)
\item XFree86 is an open source X11 implementation
\item Xorg is the XServer release by the X.org foundation
\item Xorg was forked from XFree86 4.4 RC2 (due to a license change in XFree)
\item Most of the XFree developers moved to X.org
\end{itemize}
\end{frame}
\begin{frame}
\frametitle{Client / Server}
\begin{figure}[h]
\centering
\includegraphics[width=10cm]{images/x_server_client.png}
\end{figure}
The X protocol is standardized!!!
\end{frame}
\begin{frame}
\frametitle{The X protocol}
The X-Server understands four different types of packets:
\begin{itemize}
\item Event
\item Request
\item Reply
\item Error
\end{itemize}
\end{frame}
\begin{frame}[fragile]
\frametitle{X protocol: Example}
\tiny
1)
\begin{verbatim}
$ xtrace -D:9 -d:0 -k
\end{verbatim}
2)
\begin{verbatim}
$ xclock -display :9
\end{verbatim}
Then xtrace will show the communication:
\begin{verbatim}
...
000:<:0001: 20: Request(98): QueryExtension name='BIG-REQUESTS'
000:>:0001:32: Reply to QueryExtension: present=true(0x01) major-opcode=145
first-event=0 first-error=0
000:<:0002: 4: BIG-REQUESTS-Request(145,0): Enable
....
\end{verbatim}
\end{frame}
\begin{frame}[fragile]
\frametitle{X protocol: Forward to a remote machine}
Assuming you DIDN'T start your Xserver using ''-nolisten tcp'':
\begin{verbatim}
# On the host which should display the app
$ xhost +192.168.0.104
\end{verbatim}
\begin{verbatim}
$ On the machine which starts the app
$ xlock -display 192.168.0.182:0
\end{verbatim}
\end{frame}
\begin{frame}[fragile]
\frametitle{X via SSH}
\begin{enumerate}
\item Enable X11 forwarding on the server side:
\begin{verbatim}
# /etc/ssh/sshd_config
X11Forwarding yes
\end{verbatim}
\item Connect from the client side using:
\begin{verbatim}
$ ssh -Y my_server
# In the SSH session
$ xclock
\end{verbatim}
Xclock will be displayed on the client's X server
\end{enumerate}
\end{frame}
\begin{frame}
\frametitle{What is a Window Manager OR Why do all the systems look different?}
\begin{itemize}
\item A window manager runs on top of the X window system
\item Remember: X is based on a Client / Server infrastructure:
\begin{itemize}
\item The communication between client and server is redirected through the
window manager
\end{itemize}
\end{itemize}
\end{frame}
\begin{frame}
\frametitle{Architecture: Graphics / Graphics acceleration}
\begin{figure}[h]
\centering
\includegraphics[width=6cm]{images/x_arch.png}
\end{figure}
\end{frame}
\begin{frame}[fragile]
\frametitle{Configuration}
\begin{verbatim}
# First of all
cp /etc/X11/xorg.conf /etc/X11/xorg.conf.bak
# then you can do
$ Xorg -configure
# On debian based systems you can do
$ dpkg-reconfigure xserver-xorg
\end{verbatim}
\end{frame}
\begin{frame}[fragile]
\frametitle{Starting X}
\begin{verbatim}
# This will evaluate several files (Xsession, ...)
$ startx
# Evaluates xinitrc
$ xinit
# xinit can also explicitely start an application
$ xinit xclock
\end{verbatim}
\end{frame}
\begin{frame}
\frametitle{The display manager}
\begin{itemize}
\item Managing X sessions (select the window manager, ...)
\item Providing a login prompt
\item Examples:
\begin{itemize}
\item XDM
\item GDM
\item KDM
\item WDM
\item entrance
\end{itemize}
\end{itemize}
\end{frame}
\begin{frame}[fragile]
\frametitle{X on small systems}
KDrive aka TinyX:
\begin{itemize}
\item Part of the Xorg release since 7.1
\item Can directly run on on the framebuffer
\item Debian package: \textbf{xserver-xfbdev}
\item Can be built using something like:
\begin{verbatim}
./configure $XORG_OPTS \
--disable-xorg --disable-kdrive \
--enable-xfbdev --disable-glx \
--disable-dri
\end{verbatim}
\end{itemize}
\end{frame}
\begin{frame}
\begin{thebibliography}{1}
\bibitem{X} http://en.wikibooks.org/wiki/Guide\_to\_X11/Introduction
\bibitem{XFree} http://en.wikipedia.org/wiki/X\_Window\_System
\end{thebibliography}
\end{frame}
\input{tailpres}
|