Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am accessing a computer via ssh and vnc. However I left it running in gnome. That sucks because it uses around 40MB of my 128MB RAM. So I want to kill X. I type
ps -A | grep X
get the processnumber and kills it. Unfortunately it reappears right after with a new number and it still uses the same amount of memory. What do I do? I guess I could reboot it without it starting up in X. What file do I edit?
case $1 in
start)
gprintf "Starting display manager: "
# /etc/X11/prefdm & <===== comment this one
success "Display manager startup"
ret=$?
echo
if [ $ret = 0 ]; then
touch /var/lock/subsys/dm
fi
;;
Then you can reboot, X won't start
Note that this is on a Mandrake 10.0
might change depending on your distro
Originally posted by aargh It is true my /etc/inittab sets X to respawn. How exactly do I use telinit to change that? The line is
x:5:respawn:/etc/X11/prefdm -nodaemon
use Fedora.
I don't know Fedora very well, but this looks like the line I commented out on my Mandrake.
Why don't you try commenting it out (by adding a # at the begining of the line) and reboot?
I suggest you make a copy of any of those /etc files before touching them.
You can use telinit 3 this will take you out of X windows. Also if you look at the /etc/inittab, there is a line in there that sets the default run level. It should be set to 5 (graphical login), just change to 3 (text login). This way when you reboot X-windows will not be stated. While in text login, you can always start X windows via startx
Whenever I'm in graphical mode (runlevel 5) and I want to kill X temporarily to save memory, I type the command "/sbin/init 3" as root. This changes the system's runlevel to 3 until you reboot.
If you want to use runlevel 3 (the command-line-only mode) as the default runlevel, then just edit your /etc/inittab file like people have been saying so far.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.