start page | rating of books | rating of authors | reviews | copyrights

Learning the Unix Operating System

Learning the Unix Operating SystemSearch this book
Previous: 2.1 Introduction to WindowingChapter 2
Using Window Systems
Next: 2.3 Running Programs
 

2.2 Starting X

There are several ways to start X and its window manager. This section explains a few of the most common ways. Figure 2.2 shows some steps along a few different paths to starting X. If your display is like any of the following, refer to the section noted. (If none of these fits your situation, skim through the next three sections or ask your system administrator for help.)

Figure 2.2: Some possibilities

Figure 2.2

2.2.1 A. Ready to Run X (with xdm)

Some terminals, like the one shown in Figure 2.2A, are probably ready to use X. Your terminal has probably been set up to use xdm, the X display manager; xdm logs you in to your UNIX host and (usually) starts the window manager.

When you start, there's a single window in the middle of the screen that says something like "X Window System on hostname." The window has two prompts, "Login:" and "Password:". A cursor (a vertical bar) sits to the right of the "Login:" line. Type your username (login name) and press [RETURN]. Do the same for your password. The login window disappears.

If a display something like Figure 2.1 or Figure 2.2D appears, You're ready to use X! You can skip ahead to "Running Programs."

If you get a display like Figure 2.2C, read Section C below. Or, if you get a blank display, try pressing and releasing your mouse buttons one by one, slowly, to see if a menu pops up.

2.2.2 B. Starting X from a Standard UNIX Session

If your terminal shows something like Figure 2.2B, with a standard UNIX "login:" prompt (not in a separate window; the whole screen looks like a terminal), then X is not running. Log in (as Chapter 1, Getting Started , explains) and get a shell prompt (like %). Next, you need to start X. The default command is:

% xinit

though your system may use another command (startx, for instance) instead. If all goes well, your screen will sprout at least one window. If the window looks like Figure 2.2C, without a frame from a window manager, read Section C. Otherwise, your window manager is running; skip ahead to the next main section, "Running Programs."

2.2.2.1 Problem checklist

No windows open. I get the message "Fatal server error: No screens found."

Your terminal may not be able to run X. Ask the system administrator.

2.2.3 C. Starting the Window Manager

Once you have a window open with a shell prompt in it (usually % or $), you can start the window manager program. Your account may have been set up to do this automatically. If a window manager is not running, windows won't have frames (with titles, control boxes, and so on). Also, if you move the pointer to the root window (sometimes called the "desktop") and press the mouse buttons, menus won't appear unless the window manager is running.

If you need to start the window manager, move your pointer into the window. Then enter this command at the shell prompt to start the Motif window manager:

% mwm &
[1] 12345
%

(To start twm, olwm, or another window manager, the command you'd type would be the name of that window manager.) In a few moments, the window should have a frame. (For more about starting programs, refer to "The xterm Window" section, later in this chapter.)


Previous: 2.1 Introduction to WindowingLearning the Unix Operating SystemNext: 2.3 Running Programs
2.1 Introduction to WindowingBook Index2.3 Running Programs

The UNIX CD Bookshelf NavigationThe UNIX CD BookshelfUNIX Power ToolsUNIX in a NutshellLearning the vi Editorsed & awkLearning the Korn ShellLearning the UNIX Operating System