Jump to content

How do you turn off/disable "X"?


Guest greeneggs
 Share

Recommended Posts

Guest greeneggs

I'm assuming "X" is XFree?. I remember in the old MDK 8.0, there used to be an icon on the desktop that said "kill X". I later read that "X" can cause a lot of problems. At the time I was a complete noob but knowing what I know now and the fact that "X" is causing me a LOT of headaches lately, IS there a way to kill it in MDK 9.1 and how exactly is this done and what is the effect of doing this?

 

Thanks

Link to comment
Share on other sites

I have stayed out because of the numerous knowledgable people already helping you. 8)

 

About "x".

 

What you remember seeing is not "Killx" but is rather "xkill", which is an excellent program that "kills" a dead gui without your having to log out or reboot your system. It will not kill x. It is called xkill because it runs in the windows environment. Kill is a command line program, xkill being its gui.

 

If you would like to stop using x, you can, but you will no longer have any graphic environment. x is needed to run any of the marvelous graphics and desktops of the linux world.

 

Finally, for what its worth, I think you have a hardware issue. I am saying this because I specialize in beaking things, and your situation(s) seem like a hardware issue. As for Mandrake, the current release is greatly improved over the first Mandrake I tried, which was 7.0. :wink:

Link to comment
Share on other sites

The easist and most immediate way to stop using X is to open a terminal and

 

su

init 3

 

This will put you in runlevel 3 and kill the x server. At that point, you can type init 5 to restart the x server.

 

It's not permanent though. If you want to restart and not have x running, just edit file /etc/inittab and look for this line.

 

id:5:initdefault:

 

Change the 5 in the line to a 3 and save. When you reboot, it will be run level 3.

Link to comment
Share on other sites

The easist and most immediate way to stop using X is to open a terminal and 

 

su 

init 3 

 

This will put you in runlevel 3 and kill the x server. At that point, you can type init 5 to restart the x server.

Init to run-level 3 does not kill the X server but simply stops the Display Manager (xdm, kdm, gdm) from running. You have confused the X Display Manager with the X server. The X server can start/run in both run-levels 3 and 5.
Link to comment
Share on other sites

From http://mandrakeusers.org/viewtopic.php?p=25510#25510 ,

If you want to have windows, the only mandatory thing is XFree (the free software version of X).
Not on linux, see http://www.directfb.org/ .

 

You could start X with only an Xterm (a window in which to issue commands).
That may not always be true. U could start the window manager (simplest one) TWM without any windows at all. U then have to click the mouse on the desktop and select the menu option for creating an xterm. Note that the desktop menu will work only if the global file /usr/X11R6/lib/X11/twm/system.twmrc has an useful configuration to begin with.
Link to comment
Share on other sites

If you want to have windows, the only mandatory thing is XFree (the free software version of X).
Not on linux, seehttp://www.directfb.org/
I should have said that my "article" only deals with X11 based graphics. X11 allows networked operation (thin clients), and access to dozens of already existing window managers, as well as thousands of X11 applications.
You could start X with only an Xterm (a window in which to issue commands).
That may not always be true. U could start the window manager (simplest one) TWM without any windows at all. U then have to click the mouse on the desktop and select the menu option for creating an xterm
That was an example WITHOUT a window manager (the simplest way to have more than one application, while at the same time avoiding a window manager. If you have a window manager, then you don't even need an xterm any more, except if U're a Guru ;-)

 

Yves.

Link to comment
Share on other sites

That was an example WITHOUT a window manager (the simplest way to have more than one application, while at the same time avoiding a window manager. If you have a window manager, then you don't even need an xterm any more, except if U're a Guru
There is no X session without a WM (window manager). Just because there are no windows at startup does not mean its not a WM. TWM is the simplest known WM (its also the only WM that is part of XFree86) and it is possible to start it up without any windows. Just remember that a window manager is one that manages windows. It does not have to create windows at startup to become a WM.

 

Here's a long list of WM's:

TWM

FVWM (1 and 2)

MWM

CDE

AfterStep

KDE

GNOME

.......

Link to comment
Share on other sites

Just remember that a window manager is one that manages windows................. Here's a long list of WM's: 

TWM 

FVWM (1 and 2) 

MWM 

CDE 

AfterStep 

KDE 

GNOME

eeeeh?..Heck I ran gnome2-2 earlier today without a wm :lol: ...If I disabled gnomes Alt>rt-click when on an app...it might have been quite nice..but I like windows though I hate borders. Gnome is a DE and metacity is its wm. If you killall metacity, you will be, as I did above, be running a DE without a wm. With the exception of kde (which has it's own -kwin- but can run others in its place), the others you mentioned are simply wm's that run scripts to do other things like set background and actual window management functions. E16 went as far as it could go as a wm so started E17 (a DE), which seems to have died, or I'll die before it's released :lol: So, X without a wm is possible and could be very functional but you have to create the environment yourself because the masses aren't screaming for one.
Link to comment
Share on other sites

I know it is possible to run an X app without running a WM. In your ~/.xinitrc put something like "exec xterm" and you can have an xterm without running a WM. The moment u kill the xterm, X will also quit. So, you do not have an X session in the real sense. But then, in this case you can call the parent xterm as your "session manager" since u can start other X apps from this xterm and killing this xterm quits X.

Link to comment
Share on other sites

ndeb, I learn something new everyday  So if I wanted to replace my NVIDIA drivers and to be safe, wanted my X server killed, what is the minimum runlevel I need to go to? 1 or 2? (is there a 2?)
U need 3 or 5. There are run-levels 0 to 6 (see /etc/inittab on ur system).
Link to comment
Share on other sites

Init to run-level 3 does not kill the X server but simply stops the Display Manager (xdm, kdm, gdm) from running. You have confused the X Display Manager with the X server.
exactly how are you seeing if the Xserver is running?.....because that doesn't seem to be the case with ML9.1/gdm, and definately not when starting X with startx from init3 with ML9.1 or Slackware9.0....AND what's up with not being able to do init 3 as user or root? I know I could do it as root in ML9.0;

#=======ps auxf in X with GDM========#

xfs        817  0.0  2.7  6716 5152 ?        S    Apr19   0:01 [xfs]

daemon     859  0.0  0.0  1392  104 ?        S    Apr19   0:00 [atd]

root       860  0.0  0.0 11872    0 ?        SW   Apr19   0:00 [gdm-binary]

root       910  0.0  0.0 12912    0 ?        SW   Apr19   0:00  _ [gdm-binary]

root       911  7.5 12.6 289348 24144 ?      SL   Apr19  12:46      _ /etc/X11/X :0 -deferglyphs 16 -nolisten tcp -auth /var/lib/gdm/:0.Xauth vt7

                                                                                             

#======after running init 3 in X=======#

[bvc@localhost bvc]$ init 3

bash: init: command not found

[bvc@localhost bvc]$ su

Password:

[root@localhost bvc]# init 3

[root@localhost bvc]#

                                                                                             

#======ps auxf at init 3 after "service dm stop" as root in X=======#

xfs        817  0.0  2.7  6716 5152 ?        S    Apr19   0:01 [xfs]

daemon     859  0.0  0.0  1392  104 ?        S    Apr19   0:00 [atd]

root       880  0.0  0.0  1356    4 ?        S    Apr19   0:00 /usr/sbin/acpid

root       905  0.0  0.0  1984    4 ?        S    Apr19   0:00 xinetd -stayalive -reuse -pidfile /var/run/xinetd.pid

root       974  0.0  0.1  4956  324 ?        S    Apr19   0:00 cupsd

root      1155  0.0  0.0  1408  120 ?        S    Apr19   0:00 crond

root      1268  0.0  0.6  2364 1260 ?        S    Apr19   0:00 [login]

bvc       2443  0.4  0.9  2940 1848 vc/2     S    01:51   0:00  _ -bash

bvc       2488  0.3  1.4  6280 2728 vc/2     S    01:51   0:00      _ vi xrun

root      1269  0.0  0.0  1332    4 vc/3     S    Apr19   0:00 /sbin/mingetty tty3

root      1270  0.0  0.0  1332    4 vc/4     S    Apr19   0:00 /sbin/mingetty tty4

root      1271  0.0  0.0  1332    4 vc/5     S    Apr19   0:00 /sbin/mingetty tty5

root      1272  0.0  0.0  1332    4 vc/6     S    Apr19   0:00 /sbin/mingetty tty6

root      2490  0.7  0.6  2352 1196 ?        S    01:51   0:00 [login]

bvc       2491  5.7  0.9  2940 1852 vc/1     S    01:52   0:00  _ -bash

bvc       2536  1.0  0.3  2592  732 vc/1     R    01:52   0:00      _ ps aux

No X

BTW--[offtopic]--I installed the new nvidia 4349 with -a --expert and so far so good. Had no plan to do so but because of the 4191 2D prob nvidia causes gnome2 to run slow and RenderAccel in XF86Config-4 wouldn't allow X to start. I didn't want to go back to what?..3123 or whatever :roll:

Link to comment
Share on other sites

exactly how are you seeing if the Xserver is running?.....
The files /tmp/.X*-lock will give u the PIDs for the corresponding X servers (numbered by display numbers).

 

because that doesn't seem to be the case with ML9.1/gdm, and definately not when starting X with startx from init3 with ML9.1 or Slackware9.0
Can u explain this part more ?

 

AND what's up with not being able to do init 3 as user or root? I know I could do it as root in ML9.0;
It can only be done as root. On my machine, this is the path:

root/> which init

/sbin/init

Make sure the package SysVinit-2.84-2mdk is installed.

Link to comment
Share on other sites

Well I did it again and there were no X*-lock files in /tmp. So....no X after service dm stop as root.

 

because that doesn't seem to be the case with ML9.1/gdm, and definately not when starting X with startx from init3 with ML9.1 or Slackware9.0

Can u explain this part more ?
Same as above...I'm just saying that no matter how you log out/exit init 5 to init 3, X is not running.

 

I could do init 3 as bvc in ML9.0......I guess msec wasn't doing its job :wink: If you look at my "code" above and below you'll see that I tried init 3 as root and it just gave me a prompt, which is why I'm having to do service dm stop. Yes, I have the same version of SysVinit.

#======after running init 3 in X=======#  

[bvc@localhost bvc]$ init 3  

bash: init: command not found  

[bvc@localhost bvc]$ su  

Password:  

[root@localhost bvc]# init 3  

[root@localhost bvc]#

 

Running a dm is fairly new to me. I've done it for kicks and then I go back to startx from init 3. I wonder if init 3 won't work with a dm running in ML9.1? Hmmm I'll have to check that out. My wife likes gdm , and I like it too but dm's are sooo slow.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...