Linux-Noob Forums
Exit program & Messages trouble - Printable Version

+- Linux-Noob Forums (https://www.linux-noob.com/forums)
+-- Forum: Linux Noob (https://www.linux-noob.com/forums/forum-3.html)
+--- Forum: Tips and Tricks (https://www.linux-noob.com/forums/forum-59.html)
+--- Thread: Exit program & Messages trouble (/thread-1898.html)



Exit program & Messages trouble - lia - 2006-07-16


Is there any way of being able to EXIT a program without having all my windows to close?

 

EG. Ctrl+Alt+Del and then chose which program you wanna terminate (if its not responding etc)

 

Im on FC4 and FF

 

--------------------------

 

Also, here on the forum I have noticed lately that if I want to respond to a few comments under a same topic, my comments end up squeezed into ONE instead of multiple.

 

Why and what can I do about it?




Exit program & Messages trouble - anyweb - 2006-07-16


open a terminal

 

and do this

 

Quote:top
Code:
Tasks: 113 total,   5 running, 107 sleeping,   0 stopped,   1 zombie
Cpu(s):  5.5% us,  0.4% sy,  0.1% ni, 93.6% id,  0.3% wa,  0.1% hi,  0.0% si,  0Mem:    507396k total,   496892k used,    10504k free,    40692k buffers
Swap:  1048568k total,      152k used,  1048416k free,   178100k cached

PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
22406 anyweb    15   0  267m  33m  12m S 47.6  6.7  76:34.80 java_vm
2630 root      15   0  324m  59m  11m S  2.0 12.1  86:58.67 Xorg
2820 anyweb    15   0 63388 8428 7080 S  2.0  1.7   0:04.36 gnome-netstatus
1 root      15   0  1996  676  584 S  0.0  0.1   0:00.80 init
2 root      34  19     0    0    0 S  0.0  0.0   0:00.00 ksoftirqd/0
3 root      RT   0     0    0    0 S  0.0  0.0   0:00.00 watchdog/0
4 root      10  -5     0    0    0 S  0.0  0.0   0:00.09 events/0
5 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 khelper
6 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 kthread
8 root      10  -5     0    0    0 S  0.0  0.0   0:00.37 kblockd/0
9 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 kacpid
139 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 khubd
141 root      10  -5     0    0    0 S  0.0  0.0   0:00.03 kseriod
198 root      20   0     0    0    0 S  0.0  0.0   0:00.00 pdflush
199 root      15   0     0    0    0 S  0.0  0.0   0:00.04 pdflush
200 root      15   0     0    0    0 S  0.0  0.0   0:01.24 kswapd0
201 root      20  -5     0    0    0 S  0.0  0.0   0:00.00 aio/0




 

it should list a bunch of processes... (CTRL_C to quit top)

 

if you know which process you want to close (kill) then you must first find out it's PID (process identification number)

 

eg: if you want to kill/close FIREFOX then try this in a terminal

 

stage one: find it

 



Code:
ps aux |grep firefox




 

results below...

 

Quote:[anyweb@localhost ~]$ ps aux |grep firefoxanyweb 3531 0.0 0.2 4396 1064 ? S Jul14 0:00 /bin/sh /usr/lib/firefox-1.5.0.4/firefox -UILocale en-US

anyweb 23625 0.0 0.1 3912 648 pts/1 R+ 00:00 0:00 grep firefox
 

 

stage two: kill it (close the application)

 



Code:
kill -9 3531




 

 

the 3531 is the PID of the program, the second one listed is me actually grepping it in the firstplace...

 

if more than one PID is listed for your chosen program then you should kill each one individually or try

 

pkill PID

 

done !

 

cheers

anyweb




Exit program & Messages trouble - lia - 2006-07-16


That's interesting, I must try that some time BUT sometimes everything just hangs.. well it thinks.. and thinks... and nothing happens. Then I could click terminal but it wouldnt open because the pc is busy trying to figure out the previous command that made it 'crash' in the first place... what to do then?

 

And what about the messages in forum?

 

 

Quote:open a terminal 

and do this

 

<blockquote data-ipsquote="" class="ipsQuote" data-ipsquote-contentapp="forums" data-ipsquote-contenttype="forums" data-ipsquote-contentid="2369" data-ipsquote-contentclass="forums_Topic"><div>top
 

 



Code:
Tasks: 113 total,   5 running, 107 sleeping,   0 stopped,   1 zombie
Cpu(s):  5.5% us,  0.4% sy,  0.1% ni, 93.6% id,  0.3% wa,  0.1% hi,  0.0% si,  0Mem:    507396k total,   496892k used,    10504k free,    40692k buffers
Swap:  1048568k total,      152k used,  1048416k free,   178100k cached

PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
22406 anyweb    15   0  267m  33m  12m S 47.6  6.7  76:34.80 java_vm
2630 root      15   0  324m  59m  11m S  2.0 12.1  86:58.67 Xorg
2820 anyweb    15   0 63388 8428 7080 S  2.0  1.7   0:04.36 gnome-netstatus
1 root      15   0  1996  676  584 S  0.0  0.1   0:00.80 init
2 root      34  19     0    0    0 S  0.0  0.0   0:00.00 ksoftirqd/0
3 root      RT   0     0    0    0 S  0.0  0.0   0:00.00 watchdog/0
4 root      10  -5     0    0    0 S  0.0  0.0   0:00.09 events/0
5 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 khelper
6 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 kthread
8 root      10  -5     0    0    0 S  0.0  0.0   0:00.37 kblockd/0
9 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 kacpid
139 root      10  -5     0    0    0 S  0.0  0.0   0:00.00 khubd
141 root      10  -5     0    0    0 S  0.0  0.0   0:00.03 kseriod
198 root      20   0     0    0    0 S  0.0  0.0   0:00.00 pdflush
199 root      15   0     0    0    0 S  0.0  0.0   0:00.04 pdflush
200 root      15   0     0    0    0 S  0.0  0.0   0:01.24 kswapd0
201 root      20  -5     0    0    0 S  0.0  0.0   0:00.00 aio/0




 

it should list a bunch of processes... (CTRL_C to quit top)

 

if you know which process you want to close (kill) then you must first find out it's PID (process identification number)

 

eg: if you want to kill/close FIREFOX then try this in a terminal

 

stage one: find it

 



Code:
ps aux |grep firefox




 

results below...

 

Quote:[anyweb@localhost ~]$ ps aux |grep firefoxanyweb 3531 0.0 0.2 4396 1064 ? S Jul14 0:00 /bin/sh /usr/lib/firefox-1.5.0.4/firefox -UILocale en-US

anyweb 23625 0.0 0.1 3912 648 pts/1 R+ 00:00 0:00 grep firefox
 

 

stage two: kill it (close the application)

 



Code:
kill -9 3531




 

 

the 3531 is the PID of the program, the second one listed is me actually grepping it in the firstplace...

 

if more than one PID is listed for your chosen program then you should kill each one individually or try

 

pkill PID

 

done !

 

cheers

anyweb



</div></blockquote>



Exit program & Messages trouble - anyweb - 2006-07-16


if its hanging look at the hard disc activity LED on the computer, if its blinking then the computer is working (probably moving stuff on the swap partition, hence slow or non responsive)

 

what problem with messages on the forum ??




Exit program & Messages trouble - lia - 2006-07-17


Also, here on the forum I have noticed lately (sometimes) that if I want to respond to a few comments under a same topic, my comments end up squeezed into ONE instead of multiple.

 

Why and what can I do about it?

 

Quote:if its hanging look at the hard disc activity LED on the computer, if its blinking then the computer is working (probably moving stuff on the swap partition, hence slow or non responsive) 

what problem with messages on the forum ??



Exit program & Messages trouble - noriko - 2006-07-17


or you can just use the kde or gnome task monitor app.

 

it should be installed by default with the desktop env.

 

kde :: KSysGuard

gnome :: gnome-system-monitor




Exit program & Messages trouble - lia - 2006-07-17


What do they do and how do I work them?

Im a noob.

 

Quote:or you can just use the kde or gnome task monitor app. 

it should be installed by default with the desktop env.

 

kde :: KSysGuard

gnome :: gnome-system-monitor



Exit program & Messages trouble - noriko - 2006-07-18


Quote:What do they do and how do I work them?Im a noob.
 

well, they are ools very much like the windows task-manager [ctrl]+[alt]+[del]

 

 

 

i've simply uploaded some shots for to feast your eyes on.

 

the gnome system monitor - is prefixed : gsm-

the k[de] system guard - is prefixed : ksg-

 

[/url][url=http://rl.j2k.cc/sys]http://rl.j2k.cc/sys

 

 

they are launched with the commands ..

 

gnome-system-monitor

or

ksysguard

 

if they fail then you'll need to install them.

through yum or whatever the fed's package manager is.

 

B)

 

 

btw you don't need both.just thought i'd point it out since i don't know what your [de] is. i'd prefer gsm though.




Exit program & Messages trouble - tek-69 - 2006-07-21

I have an old and somewhat slow computer, and sometimes things hang like you mentioned(with heavy drive activity etc.). One thing that sometimes works for me is, instead of trying to open a graphical terminal. do a ctrl-alt-f1 to get into a real term. I don't know why but it seems to switch over to those terminals quicker than it can load a graphical term. From there you can kill processes like anyweb suggested. When your done, do ctrl-alt-f7 to go back to your desktop. It doesn't always help but it has gotten me through some rough spots. :)



Exit program & Messages trouble - noriko - 2006-07-21


might i also add :::

 

 

there is another program that comes along with teh 'kill' [tools[i think-well it is for me[on archlinux]]]

 

it's killall

 

that tool takes teh prcocess by name..

 

no instead of, top, kill pid..

 

you can simply do..

 

killall firefox

killall -g root, etc..

 

see killall --help or man killall for more..

 

sorry i forgot that one last post.. :)