Problem logging out of KDE (Linux Mandrake 6.5)

Posted on 2000-01-12
Medium Priority
Last Modified: 2013-12-06
I bought Linux 6.5 yesterday, read the book and installed. Its setup to use KDE. When I logout of KDE my computer goes to sleep, not a command line. When I reboot to Linux it complains and runs fsdsk (or whatever it's called). Tried using shutdown (-r now|-h now) from a console window, same thing.

How can I go from KDE to a shell, how can I logout/reboot gracefully? (New IBM Aptiva 7172/60A)
Question by:savage011200

Author Comment

ID: 2347846

Expert Comment

by:Jan Louwerens
ID: 2348000
I use KDE, and I usually just use CTRL+ALT+Backspace to exit to a shell

Author Comment

ID: 2348034
Thanks, I'll try that. I don't think its in the book :(
(I have RTFM <g>)
The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.


Expert Comment

ID: 2348473
u have xdm enabled remove it

Accepted Solution

gruse earned 150 total points
ID: 2348518
Using CTRL-ALT-BS just kills your Xserver hard, do that only in emergencies. Also, just rebooting (I presume power cycle or hard reset) is a *BAD THING* on Unix boxen; eventually you'll break some filesystem and lose data.

The easiest way to get a virtual console from X is typing CTRL-ALT-F1 for first virtual terminal, CTRL-ALT-F2 for second and so on. The X server lives on F7. Once out of X, ALT-Fx changes virtual terminals. If you don't want a KDM-Login (this is the KDE equivalent to xdm), type

init 3

in a virtual terminal. X will go down. On next reboot (type "reboot" or "halt" for that) however, X will come up again. To change that once and for all, you'll have to edit /etc/inittab. Careful there, or your Linux won't boot correctly! There's a line that reads


Change that to


and X won't come up on reboot. If you want to use X now,

startx &


init 5

"startx  &" starts your desktop without requiring another login, "init 5" does.

Author Comment

ID: 2348839
Thanks, I think I can follow your answer, but I'm completely unfamiliar with Linux/Unix so some of the terms (X, KDM, Virtual terminal) are greek to me. I'll look at the eDocs. RAKS04 suggested I disable XDM. Have you just explained how to do that?!

Thanks again.

Laurie Savage

Expert Comment

ID: 2349009
Hmmm, in a way, yes, but not completely... This is a bit complex, but I'll try my best.

Let's begin with those terms.

Virtual terminal -- Once upon a time B-) UNIX boxen only had terminals, connected to the computer by a serial interface. Most of those terminals were pretty dumb, they could only display characters that were send to them on screen and send characters that were typed in to the computer.
PCs, on the other hand, have a graphics card and can talk to the keyboard directly. So, Linux, being a UNIX derivative, emulates a terminal (thus having a Virtual terminal). But they get even more virtual B-), as there is not only one, but up to twelve of those virtual terminals, accessible via ALT-Fx. Just like having up to twelve real terminals, without the hardware clutter.

X -- Terminals are great, but a GUI makes some tasks easier. The X server is the program that knows how to talk to your graphics card to to switch from text to graphics mode, change resolution, draw lines etc. It even provides windows, but not as you might use the term. Close buttons, title bars and so on are not provided. For those
little things you need a

Window Manager -- This program provides th look & feel. As you use KDE, your window manager is kwm, the KDE window manager.

KDM -- Is the KDE Display Manager. Always having to start X by hand (typing "startx") quickly becomes a drag, if that's your preferred environment. kdm (or xdm if you do not use KDE) starts X for you, but requires a login.

I hope we'll have those terms sorted out. Now, what did I tell you to do?

Hm, some more basics first. A Linux box has several distinct run levels. Runlevel 0 stands for shutdown, Runlevel 6 stands for shutdown & reboot. Runlevel 1 is Single User Mode for maintenance and repairs. Runlevels 2-5 are Multiuser Mode, "normal" run state for a UNIX box. Runlevel 2 is "No network, but ordinary users can log in via modem/terminal", Runlevel 3 is "Network and network services active, but no X" and runlevel 5 is "Network and X active". Further explanations await you by reading "man init" and "man inittab".

Doing "init 3" tells your box to go into runlevel 3, shutting down X but leaving the network active. You can shutdown your computer by typing "init 0" instead of "halt", too. So doing "init 3" effectively disables kdm, yes.

But I told you that if you reboot, X will come up again. The reason for that is the "initdefault" entry in /etc/inittab, which tells init which runlevel to boot into. If that line reads


you're booting into runlevel 5, with an active kdm. If you change that to


you will boot into runlevel 3, without kdm and therefore without X.

But again: *BE CAREFUL* when editing /etc/inittab! An error can stop your computer from booting, and then you'll have to boot from floppies, mount your linux partition and repair /etc/inittab. Always make backups first! A simple

cp /etc/inittab /etc/inittab.bak

will suffice.

Hope I didn't confuse you too much B^).

Author Comment

ID: 2350855
Ctrl - Alt Fx gets me out of a KDE session, and then my computer goes blank (with the fans still on) if I reboot I have to fsck! I can reboot or shutdown quite successfuuly if I am at a text based command line not in a KDE session. But I can't exit KDE gracefully. I want to work in a GUI rather than text shell - graphics, web design etc.

This is confusing!! my email is savage@netwit.net.au

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to show how we can create Linux Mint virtual machine using Oracle Virtual Box. To install Linux Mint we have to download the ISO file from its website i.e. http://www.linuxmint.com. Once you open the link you will see …
Virtualization software lets you run different versions of Windows, Ubuntu Linux and other versions of Linux all at the same time, rather than running each one directly from your computer's hard drive.
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses

601 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question