Find the answer to your Linux question:
Results 1 to 5 of 5
Hi, In SGI IRIX6.2 operating system, one can close(kill) and xwsh window with the utility killxwsh. I am trying to close(kill) and xterm window in Linux but I do not ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    May 2009
    Posts
    45

    xterm


    Hi,

    In SGI IRIX6.2 operating system, one can close(kill) and xwsh window with the utility killxwsh. I am trying to close(kill) and xterm window in Linux but I do not know how.

    Can you help?

    Thx

  2. #2
    Linux Newbie
    Join Date
    Jan 2008
    Location
    Canada
    Posts
    109
    Hi fsimon
    If you type exit and hit enter it may exit the xterm. In most terminal windows this is the case. Cheers...

  3. #3
    Just Joined!
    Join Date
    May 2009
    Posts
    45

    xterm

    Hi

    I use "xterm -hold" option so I can see the problem in the xterm window with the process when the process has a problem and it stops. I am looking for the command line command to kill all those dead xterm windows. In SGI IRIX OS the command to kill the dead xwsh window is killxwsh. I am looking for the Linux equivalence.

    Thx

  4. #4
    Just Joined!
    Join Date
    Aug 2009
    Posts
    4
    Quote Originally Posted by fsimon View Post
    Hi

    I use "xterm -hold" option so I can see the problem in the xterm window with the process when the process has a problem and it stops. I am looking for the command line command to kill all those dead xterm windows. In SGI IRIX OS the command to kill the dead xwsh window is killxwsh. I am looking for the Linux equivalence.

    Thx
    Linux is for the lazy. It only takes a control-d to exit both xterm and console sessions.

    But, to answer your question on how to kill processes from a console:

    Killing with a SIGTERM signal

    # kill pid

    Killing with SIGKILL signal

    # kill -9 pid

    ps to get your user PID's

    # ps
    PID TTY TIME CMD
    11569 pts/1 00:00:00 bash
    12528 pts/1 00:00:00 xterm
    14307 pts/1 00:00:00 ps


    ps aux to get all user PID's

    # ps aux
    (Too many to copy/paste, so we grep)

    # ps aux | grep xterm
    root 12528 0.3 0.6 7368 1408 pts/1 S 20:37 0:00 xterm


    After far too many years of pounding out "ps aux | grep foobar", we become especially lazy and finally add an alias to .bashrc

    alias psg='ps aux | grep -v grep | grep $1'

    Now we only to need to type "psg foobar" to do the same thing as "ps aux | grep foobar"

    # psg xterm
    root 12528 0.3 0.6 7368 1408 pts/1 S 20:37 0:00 xterm


    # kill -9 12528

    Back home again.

    # ps
    PID TTY TIME CMD
    11569 pts/1 00:00:00 bash
    22795 pts/1 00:00:00 ps


    To kill multiple processes executing the same file, man killall (Read the doc)

    Again, Linux is for the lazy. Use your TAB key to auto-complete the names of commands and files. Your UP/DOWN arrow keys also cycle through previously used commands.

    (All assumptions being made that you are using the bash shell)

    .

  5. #5
    Just Joined!
    Join Date
    May 2009
    Posts
    45

    xterm

    Hi Kernel_Sanders

    Thx
    "
    killall -r xterm" is the equivalence to SGI killxwsh. It kills all the dead xterm windows just as killxwsh kills all the dead xwsh windows.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •