OS Signal Handling problem

Hi, I have a problem trying to handle operating system signals. The exception I get is: Exception already handled by de JVM.
The enviroment that runs my application is:
-IBM AIX 4.3
-IBM JRE 1.3.0
The process is launched with "nohup"
The complete line is: nohup java -jar -Dlog4j.configuration=log.xml etec.jar >/dev/null 2>/dev/null &The code is:
try
  if (senyalInterrupcion != null)
    Signal.handle(new Signal (signalName), new SignalHandler ()
      public void handle(Signal arg0)
        System.exit(0);
catch (IllegalArgumentException ex)
  ex.printStackTrace ();
}I know that the use of com.sun.* classes is not recommended by Sun, but I need to communicate the JVM in wich my application run with the shell, if anyone knows a better method (except RMI) please let me know.
P.S. Sorry for my english
Thanks in advance,
Juanjo

As of jdk1.3, run w/ Java -Xrs option (i.e., java -Xrs myProg) so default JVM signal handlers are not run. Then, you can install your own signal handlers using sun.misc.Signal and SignalHandler and they will not conflict with the JVM's handlers. See the following article for excellent coverage of the topic:
http://www-106.ibm.com/developerworks/ibm/library/i-signalhandling/

Similar Messages

  • Signal Handling by JVM : a probable bug

    I am facing the following problem. when i kill a running java code by (CTRL C SIGINT), then the sub processes created by the parent java program using "exec" call didn't get terminated. I ran the code on Solaris machine. This OS supports cascading termination meaning 'if a parent is dead then all the childs get terminated recursively". But i guess JVM calls its signal handler and didn't follow the rule of cascading termination. I THINK IT IS A BUG. can some one acknowledge/correct me on this issue

    I really don't think so.
    On unix boxes one can 'fork'. A fork creates a sub process (not a process.) Killing a sub process might or might not kill child sub processes.
    Runtime.exec() produces a process, not a sub process. So I would never expect that killing the parent would kill the other process.
    This would suggest that exiting the process would also kill the exec() process. There is a similar analog in perl. On unix it allows for fork and system/exec calls. An 'exec' terminates the perl script immediately. Using the same from the above, it would be useless since it would also immediately terminate the process just started with 'exec'.

  • 64-bit sigaction() Signal Handler for aio_write()

    I'm having trouble using a sigaction() specified signal handler when built as a 64 bit executable (-xarch=v9).
    The siginfo_t argument gets passed to the signal handler just fine. The problem is with the si_value.sival_ptr member. The other members (sig, type, pid ) are all okay.
    When built for 32-bits everything works fine.
    When built for 64-bits all I get is the high 32-bits of the sival_ptr, the low 32-bits are always 0.
    The signal is being generated as a result of a call to aoi_write().
    Please help - I'm in a hurry and I can't seem to find the answer.
    I can do a work-around using sival_int (it's in union with sival_ptr) and indexing a table for an address, but that's a hassle, while the pointer method is clean.
    Any help will be appreciated.
    Bruce.

    Be careful that the program is built at compile time
    with the correct 64-bit library and not inadvertantly
    with a 32-bit version. The fact that the failure is
    a seg-fault and dbx can't resolve the symbol make the
    system lib a suspect and the problem a 32 bit vs.
    64 bit version.

  • [SOLVED] fglrx(0): [drm] failed to remove DRM signal handler

    Hello!
    I'm new to Arch so please forgive me if I'm asking about something obvious.
    After spending many hours on reading and comprehension of Arch philosophy I finally dared to install Arch 2007.08-02 (Don't Panic) on my computer Fortunately I was prepared for text-mode configuration, but obviously not prepared enough... My first major problem is with the X server. I have followed strictly the instructions from the wiki and installed xorg and catalyst drivers afterwards (for Radeon X800 Pro). Now probably something is wrong with my xorg.conf, which you can see below, but there's also a bit more sophisticated problem causing this type of message in /var/log/Xorg.0.log
    (II) fglrx(0): Shutdown CMMQS
    (EE) fglrx(0): [drm] failed to remove DRM signal handler
    (II) fglrx(0): [drm] removed 1 reserved context for kernel
    (II) fglrx(0): [drm] unmapping 8192 bytes of SAREA 0x2000 at 0xb7c78000
    (II) fglrx(0): [drm] Closed DRM master.
    I couldn't find a solution either on this board and on the web as well, so I dare to ask for a little tip what to do to solve this
    Thx in advance.
    P.S. My xorg.conf
    # Auto-generated by Archie mkxcfg
    Section "ServerLayout"
    Identifier "My Layout"
    Screen 0 "aticonfig-Screen[0]" 0 0
    InputDevice "Keyboard0" "CoreKeyboard"
    InputDevice "Mouse1" "CorePointer"
    EndSection
    Section "Files"
    # FontPath "/usr/share/fonts/75dpi:unscaled"
    # FontPath "/usr/share/fonts/75dpi"
    # Additional fonts: Locale, Gimp, TTF...
    # FontPath "/usr/share/lib/X11/fonts/latin2/75dpi"
    # FontPath "/usr/share/lib/X11/fonts/latin2/100dpi"
    # True type and type1 fonts are also handled via xftlib, see /etc/X11/XftConfig!
    # FontPath "/usr/share/fonts/Type1"
    RgbPath "/usr/share/X11/rgb"
    ModulePath "/usr/lib/xorg/modules"
    FontPath "/usr/share/fonts/misc:unscaled"
    FontPath "/usr/share/fonts/misc"
    FontPath "/usr/share/fonts/100dpi:unscaled"
    FontPath "/usr/share/fonts/100dpi"
    FontPath "/usr/share/fonts/PEX"
    FontPath "/usr/share/fonts/cyrillic"
    FontPath "/usr/share/fonts/ttf/western"
    FontPath "/usr/share/fonts/ttf/decoratives"
    FontPath "/usr/share/fonts/truetype"
    FontPath "/usr/share/fonts/truetype/openoffice"
    FontPath "/usr/share/fonts/truetype/ttf-bitstream-vera"
    FontPath "/usr/share/fonts/latex-ttf-fonts"
    FontPath "/usr/share/fonts/defoma/CID"
    FontPath "/usr/share/fonts/defoma/TrueType"
    EndSection
    Section "Module"
    # Load "ddc" # ddc probing of monitor
    # Load "type1"
    # Load "synaptics"
    Load "dbe"
    Load "dri"
    Load "extmod"
    Load "glx"
    Load "bitmap" # bitmap-fonts
    Load "freetype"
    # Load "record"
    EndSection
    Section "ServerFlags"
    Option "AllowMouseOpenFail" "true"
    EndSection
    Section "InputDevice"
    Identifier "Keyboard0"
    Driver "kbd"
    Option "XkbModel" "logiaccess"
    Option "XkbLayout" "pl"
    Option "XkbOptions" "compose:rwin"
    EndSection
    Section "InputDevice"
    Identifier "Mouse1"
    Driver "mouse"
    Option "Protocol" "ExplorerPS/2"
    Option "Device" "/dev/input/mouse1"
    Option "Buttons" "7"
    Option "ZAxisMapping" "4 5"
    Option "ButtonMapping" "1 2 3 6 7"
    EndSection
    Section "Monitor"
    Identifier "aticonfig-Monitor[0]"
    Option "VendorName" "ATI Proprietary Driver"
    Option "ModelName" "Generic Autodetecting Monitor"
    Option "DPMS" "true"
    EndSection
    Section "Device"
    Identifier "aticonfig-Device[0]"
    Driver "fglrx"
    EndSection
    Section "Screen"
    Identifier "aticonfig-Screen[0]"
    Device "aticonfig-Device[0]"
    Monitor "aticonfig-Monitor[0]"
    DefaultDepth 24
    SubSection "Display"
    Viewport 0 0
    Depth 24
    EndSubSection
    EndSection
    Section "DRI"
    Mode 0666
    EndSection
    Last edited by Zibi1981 (2008-02-20 10:49:20)

    Hello quad3d@work Thanks for the interest, but I've already solved this problem. I think it was something with my xorg.conf file, because when I made some changes to it, suddenly all started to work. If You are still interested in the output of the above command, well, here it is
    [zibi1981@felipe ~]$ cat ~/.xinitrc
    #!/bin/sh
    # ~/.xinitrc
    # Executed by startx (run your window manager from here)
    # exec gnome-session
    # exec startkde
    # exec startxfce4
    # exec icewm
    # exec openbox
    # exec blackbox
    # exec fluxbox
    # exec ratpoison
    # exec dwm
    # ... or any other WM of your choosing ...
    # exec xterm
    All the lines are commented, because I use Entrance with appropriate input in /etc/inittab file
    [zibi1981@felipe ~]$ cat /etc/inittab
    # /etc/inittab
    #  Runlevels:
    #    0    Halt
    #    1(S)       Single-user
    #    2    Not used
    #    3    Multi-user
    #    4    Not used
    #    5    X11
    #    6    Reboot
    ## Only one of the following two lines can be uncommented!
    # Boot to console
    #id:3:initdefault:
    # Boot to X11
    id:5:initdefault:
    rc::sysinit:/etc/rc.sysinit
    rs:S1:wait:/etc/rc.single
    rm:2345:wait:/etc/rc.multi
    rh:06:wait:/etc/rc.shutdown
    su:S:wait:/sbin/sulogin -p
    # -8 options fixes umlauts problem on login
    c1:2345:respawn:/sbin/agetty -8 38400 vc/1 linux
    c2:2345:respawn:/sbin/agetty -8 38400 vc/2 linux
    c3:2345:respawn:/sbin/agetty -8 38400 vc/3 linux
    c4:2345:respawn:/sbin/agetty -8 38400 vc/4 linux
    c5:2345:respawn:/sbin/agetty -8 38400 vc/5 linux
    c6:2345:respawn:/sbin/agetty -8 38400 vc/6 linux
    ca::ctrlaltdel:/sbin/shutdown -t3 -r now
    # Example lines for starting a login manager
    #x:5:respawn:/usr/bin/xdm -nodaemon
    #x:5:respawn:/usr/sbin/gdm -nodaemon
    #x:5:respawn:/opt/kde/bin/kdm -nodaemon
    #x:5:respawn:/usr/bin/slim >& /dev/null
    x:5:respawn:/usr/sbin/entranced -nodaemon >& /dev/null
    # End of file
    Anyway, thanks for the interest once more

  • OCCI & Signal Handling

    Hello,
    Before calling any OCCI function my signal handling (ie for SIGTERM) works, however, after calling OCCI environment/connection my signal handling no longer works. I believe the OCCI version is 9.2.0.6.0. Does anyone have an example of using signals with OCCI? It seems OCCI is 'stealing' my signals! Below is the basic test program.
    Thankyou in advance!
    Ross.
    The problem area: (c++)
    oracle::occi::Environment *env;
    oracle::occi::Connection *conn;
    oracle::occi::Statement *stmt;
    oracle::occi::ResultSet *rset;
    ::signal(SIGINT, signal_handle);
    ::signal(SIGTERM, signal_handle);
    ::signal(SIGPIPE, sigpipe_handle);
    cout << "Attempting to connect to server" << endl;
    try
    env = oracle::occi::Environment::createEnvironment (oracle::occi::Environment::DEFAULT);
    conn = env->createConnection ("usr", "pswd", "db");
    cout << "Connection Estabolished OK" << endl;
    string sqlStmt = "SELECT I_STATUS FROM K_INC";
    stmt = conn->createStatement (sqlStmt);
    rset = stmt->executeQuery ();
    while (rset->next ())
    cout << "Result!" << rset->getString(1) << endl;
    stmt->closeResultSet (rset);
    conn->terminateStatement (stmt);
    catch(oracle::occi::SQLException ex)
    cout<<"Exception thrown for displayAllRows"<<endl;
    cout<<"Error number: "<< ex.getErrorCode() << endl;
    cout<<ex.getMessage() << endl;
    cout << "We have a problem!" << endl;
    }

    hi Ross,
    I think there is no problem of signal stealing . I am able to use the signal handling before the connection, after the connection and even after insertion of rows into the table.
    I implicitly raised a signal in all the above three cases and also explicitly from another process using kill -15 <process ID >, and the signal handler seems to work fine.
    the code is attached below , see if it helps.
    thanks
    varun
    #include <iostream>
    #include <occi.h>
    #include<csignal>
    using namespace oracle::occi;
    using namespace std;
    int i=1;
    class occidml
    private:
    Environment *env;
    Connection *conn;
    Statement *stmt;
    public:
    occidml (string user, string passwd, string db)
    env = Environment::createEnvironment (Environment::DEFAULT);
    conn = env->createConnection (user, passwd, db);
    ~occidml ()
    env->terminateConnection (conn);
    Environment::terminateEnvironment (env);
    * Inserting a row into the table.
    void insertRow ()
    string sqlStmt = "INSERT INTO varun VALUES (111, 'ASHOK')";
    stmt = conn->createStatement (sqlStmt);
    try{
    stmt->executeUpdate ();
    cout << "insert - Success" << endl;
    }catch(SQLException ex)
    cout<<"Exception thrown for insertRow"<<endl;
    cout<<"Error number: "<< ex.getErrorCode() << endl;
    cout<<ex.getMessage() << endl;
    conn->terminateStatement (stmt);
    void term(int sig)
    cout << "handling signal no." << sig << endl;
    i=i+1;
    int main (void)
    string user = "SCOTT";
    string passwd = "TIGER";
    string db = "";
    signal(SIGTERM,term); // register a SIGTERM handler
    while(i==1){}
    printf("Before Connection\n");
    occidml *demo = new occidml (user, passwd, db);
    while (i==2){}
    printf("After Connection\n");
    cout << "Inserting a record into the table author_tab " <<endl;
    demo->insertRow ();
    while(i==3){}
    delete(demo);
    printf("Complete");
    }

  • Signal handler in Tuxedo

    Hi,
    We are using Tuxedo 8.0 in our application.
    Our servers are crashing due to some code in our app...
    We want to use C signal handler to trap this signals to trace the code, before crashing. This way we can easily fix the code.
    But for some reason when I use signal, its not catching SIGBUS. I also used Usignal, but still to no success...
    Please suggest...
    Thanks
    Rama

    Hi,
    I have not encountered any problem with signal trapping with Tuxedo 6.5 and 8.1, i have not worked on 8.0. May i know how you are using signals in your service. In our case we are using as --
    service A()
    signal(SIGBUS , SigCatcher) ;
    signal(SIGSEGV , SigCatcher) ;
    signal(SIGINT , SigCatcher) ;
    signal(SIGTERM , SigCatcher) ;
    signal(SIGQUIT , SigCatcher) ;
    signal(_SIGKILL , SigCatcher) ;
    int SigCatcher(int signo)
    /* CODE to Handle signal *****************/
    Regds
    -Ashish

  • Signal Handling on Alpha machines

    Could any one of you tell me how to trap 'Ctl-C' on Alpha machines or OSF1 OS ? The following piece of code works fine on Linux and Solaris bt not on alphas ?
    I know sun.misc.* is not not guranteed to work on all platforms but wanted to see if any of you ran into this problem and has a solution?
    Thanks
    Sreenath
    import sun.misc.Signal;
    import sun.misc.SignalHandler;
    public class InterruptSignalHandler implements SignalHandler {
    public static boolean USER_INTERRUPTION = false;
    private String SIG_INT = "INT";
    private String SIG_TERM = "TERM";
    private Signal intSignal = null;
    private Signal termSignal = null;
    public InterruptSignalHandler() {
    public void install() {
    intSignal = new Signal(SIG_INT);
    termSignal = new Signal(SIG_TERM);
    Signal.handle(intSignal, this);
    Signal.handle(termSignal, this);
    * The <code>handle</code> method here.
    * @param sig a <code>Signal</code> value
    public void handle(Signal sig) {
    System.out.println("Tried to kill me...");
    if (USER_INTERRUPTION == false) {
    USER_INTERRUPTION = true;
    System.out.println("I am interrupted.."+USER_INTERRUPTION);
    * The <code>main</code> method here.
    * @param args[] a <code>String</code> value
    public static void main(String args[]) {
    System.out.println("Try to destroy me by pressing CTRL-C");
    InterruptSignalHandler intSigHandler = new InterruptSignalHandler();
    intSigHandler.install();
    // Start infinite loop
    for (;;){
    System.out.print(".");
    }

    Wasn't it enough to simply reply to your other (duplicate) question you posted yesterday??? Does my answer have no relevancy whatsoever???
    http://forum.java.sun.com/thread.jsp?thread=511180&forum=31&message=2429068

  • Signal Handler

    hi all.
    I encountered a very strange problem recently on Solaris 8 and forte C++ 6.2.
    #include "signal.h"
    extern "C" sig_handler(int)
    // do something
    if (signal(SIGUSR1, sig_handler) == SIG_ERR) {
    cerr << "Errors aborting!" << endl;
    else{
    cout << "OK" << endl;
    First, it is compiled and gives me OK when I start the program.
    but when SIGUSR1 is used, nothing happens.
    I change signal(SIGUSR1, sig_handler) to sigset(SIGUSR1, sig_handler) ,
    then it is working.
    Any idea?
    Thanks
    CC

    So what? How should iPlanet or any other product be able to change signal handlers in other processes? That's simply impossible.
    When using the old (obsolete?) signal() call the signal handler must reestablish itself via signal() after it got called.
    signal() has severe problems that's why sigaction() was introduced. I'd recommend to use sigaction()...

  • Exception Handling Problem In BPM

    All
    I am facing an exception handling problem I am using BPM and , I have caught exception in the transformation step but when there is any data problem in that mapping(mentioned in the transformation)
    it is not throwing the exception . is there any option to collect these type of system exception in  the bpm and give a alert thru mail
    is there any way to collect these type of exception happened in the BPE and raise alert thru generic alert
    Thanks
    Jayaraman

    Hi Jayaraman,
        When you say there is any data problem, does that fail the message mapping that you have defined?
    If the message mapping used in the tranformation fails, it should raise an exception in the BPM.
    Did you test the message mapping using the payload and see if it really fails or not?
    Regards,
    Ravi Kanth Talagana

  • GUI event handling problems appear in 1.4.1 vs. 1.3.1?

    Hi,
    Has anyone else experienced strange event handling problems when migrating from 1.3.1 to 1.4.1? My GUI applications that make use of Swing's AbstractTableModel suddenly don't track mouse and selection events quickly anymore. Formerly zippy tables are now very unresponsive to user interactions.
    I've run the code through JProbe under both 1.3 and 1.4 and see no differences in the profiles, yet the 1.4.1 version is virtually unusable. I had hoped that JProbe would show me that some low-level event-handling related or drawing method was getting wailed on in 1.4, but that was not the case.
    My only guess is that the existing installation of 1.3.1 is interfering with the 1.4.1 installation is some way. Any thoughts on that before I trash the 1.3.1 installation (which I'm slightly reluctant to do)?
    My platform is Windows XP Pro on a 2GHz P4 with 1GB RAM.
    Here's my test case:
    import javax.swing.table.AbstractTableModel;
    import javax.swing.*;
    import java.awt.*;
    public class VerySimpleTableModel extends AbstractTableModel
    private int d_rows = 0;
    private int d_cols = 0;
    private String[][] d_data = null;
    public VerySimpleTableModel(int rows,int cols)
    System.err.println("Creating table of size [" + rows + "," + cols +
    d_rows = rows;
    d_cols = cols;
    d_data = new String[d_rows][d_cols];
    int r = 0;
    while (r < d_rows){
    int c = 0;
    while (c < d_cols){
    d_data[r][c] = new String("[" + r + "," + c + "]");
    c++;
    r++;
    System.err.println("Done.");
    public int getRowCount()
    return d_rows;
    public int getColumnCount()
    return d_cols;
    public Object getValueAt(int rowIndex, int columnIndex)
    return d_data[rowIndex][columnIndex];
    public static void main(String[] args)
    System.err.println( "1.4..." );
    JFrame window = new JFrame();
    window.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    JPanel panel = new JPanel();
    Dimension size = new Dimension(500,500);
    panel.setMinimumSize(size);
    panel.setMaximumSize(size);
    JTable table = new JTable(new VerySimpleTableModel(40,5));
    panel.add(table);
    window.getContentPane().add(panel);
    window.setSize(new Dimension(600,800));
    window.validate();
    window.setVisible(true);
    Thanks in advance!!
    - Dean

    Hi,
    I've fixed the problem by upgrading to 1.4.1_02. I was on 1.4.1_01.
    I did further narrow down the symptoms more. It seemed the further the distance from the previous mouse click, the longer it would take for the table row to highlight. So, clicking on row 1, then 2, was much faster than clicking on row 1, then row 40.
    If no one else has seen this problem -- good! I wouldn't wish the tremendous waste of time I've had on anyone!
    - Dean

  • Unix Signal Handling in Oracle Apps

    I have a number of questions regarding Signal Handling
    on Unix platforms within Oracle client code. I would like
    to ensure that my signal handling requirements do not clash with
    those of Oracle within an application.
    1. Does the Database client code register any Unix signal
    handling routines within a user application?
    2. If it does, which signals does it handle?
    3. What is the scope of these handler routines, i.e. when are
    they registered and when do
    they become de-registered?
    4. When registered, do these handler routines attempt to pass
    signals on to previously registered
    handlers (i.e. do previously registered handlers get chained)?
    5. When they are de-registered do they attempt to re-instate any
    previously registered signal handlers?
    thank you in advance for your help,
    John Tresadern
    IBM UK.
    null

    This can certainly be done, assuming you have sufficient hardware/storage resources.
    Each instance will need to have a separate Unix account (e.g. applvis, appldev etc).
    The actual details of the cloning process are outlined in MOS Doc 230672.1 (Cloning Oracle Applications Release 11i with Rapid Clone)
    HTH
    Srini

  • Labview slider event handling problems - revisited

    This topic asked a question that was very close to a problem I am having:
    Labview slider event handling problems
    That is, how do I, using an event structure and/or other means, only read out the value of a slider control after the value change is finalized?
    The extra constraint I'd like to place on this, which I believe will invalidate the answer given in the thread above, is that my slider control also has a digital display which can also be used to change the value without ever using the mouse. I cannot look for a value change followed by a mouse-up event if the mouse was not used to change the value.
    Any ideas how this might be accomplished? FWIW, I am using LabVIEW 7.0

    Each and every incremental value-change event generated by the movement of the slider is still detected and queued up for use by the event structure and the event structure loop wades through them all before it's done.
    I have come up the attached "fix" (LV v7.0) for this problem. While it is not as clean a solution as I had hoped it would be, it's the best I can manage given what LabVIEW offers me to work with and it does work in the situation where I need to use it.
    Now, within the Finalize Slider Events subVI, I'm keeping track of the most-recent values seen by the subVI, checking to see if they have changed, and reporting out that fact. That gives me a Changed/Not-Changed bit within the event case that I can use to control what code then gets executed. If the event case is just playing catch-up to the real value of the control, I can now see that fact and ignore it.
    In this version I've also dumped the variant output and limited the VI to using DBL values. I decided it added complication to something that was too complicated already and I wanted the output terminals for other purposes anyway (reporting of the correct "OldVal" of the control).Message Edited by Warren Massey on 04-28-2005 03:56 AM
    Attachments:
    slider_events[5].llb ‏77 KB

  • Je n arrive  signaler un probleme sur l appli dans l apple store

    je n arrive pas a executer une appli que j ai achetee. je ne trouve pas la fonction "signaler un probleme" sur l appli dans l apple store
    merci

    Quel est ton accès au réseau ? Un accès wifi de type freewifi, par ex., autorise assez mal les téléchargements conséquents.
    Après échec, as-tu détruit les fichiers partiels téléchargés ?
    Si tu as un Apple store près de chez toi, tu peux télécharger Mavericks gratuitement, et avec un bon débit.

  • Signaler un probleme sur vidéo !

    où signaler un probleme sur une vidéo acheté SVP ?
    Falco saison 1 épisode 3 =  fige d'image durant environ 1 minute à la fin de l'épisode !

    Bonjour,
    restait il suffisament de mémoire disponible sur le disque au moment où l'erreur s'est produite?
    Quand vous parlez de temps indéterminé, est ce un temps relativement long ou le problème peut se produire très rapidement.
    Avez-vous de nouveau été confronté à la même erreur depuis le reformatage?
    Avez-vous pu tester le même exemple sur un autre PC?
    Merci pour les informations complémentaires.
    Cynthia Arickx
    National Instruments France

  • JVM Signal Handling on NT and HP-Unix

    Hi
    I'm trying to catch various JVM shutdown signals in my application so that the application can do some clean-up before shutting down. Here is the code that i've written...
    sun.misc.SignalHandler jvmSignalHandler = new sun.misc.SignalHandler()
    public void handle(sun.misc.Signal sig)
    // Do some cleanup
    // Call handler on interrupt signal (CTRL-C)
    sun.misc.Signal.handle(new sun.misc.Signal("INT"), jvmSignalHandler);
    // Call handler on terminate signal
    sun.misc.Signal.handle(new sun.misc.Signal("TERM"), jvmSignalHandler);
    // Call handler on abort signal
    sun.misc.Signal.handle(new sun.misc.Signal("ABRT"), jvmSignalHandler);
    If i run this process on NT in a dos box, the applicatin behaves fine by responding to all these signals...
    e.g. If i press CTRL-C (INT), or i close the dos box (TERM), or i shutdown NT (ABRT).
    However on UP-Unix, i tried kill -2 (TERM), kill -6 (ABRT) and kill -15 (INT)... Out of these, only kill -6 (ABRT) works, while the others just "kill" the application and there is no clean-up. Can anyone help if i need to use any other codes on HP-Unix, or do i need to catch any other signals in my application.
    Thanks in advance
    Regards
    Kashif

    Hope the following info(from HP-UX $man kill) is useful to you.
    Signal Names and Numbers
    The following table describes a few of the more common signals that
    can be useful from a terminal. For a complete list and a full
    description, see the header file <signal.h> and the manual entry
    signal(5).
    signum signame Name Description
    0 SIGNULL Null Check access to pid
    1 SIGHUP Hangup Terminate; can be trapped
    2 SIGINT Interrupt Terminate; can be trapped
    3 SIGQUIT Quit Terminate with core dump; can be trapped
    9 SIGKILL Kill Forced termination; cannot be trapped
    15 SIGTERM Terminate Terminate; can be trapped
    24 SIGSTOP Stop Pause the process; cannot be trapped
    25 SIGTSTP Terminal stop Pause the process; can be trapped
    26 SIGCONT Continue Run a stopped process
    BTW, do you have JavaDoc for sun.misc.Signal class in hand? I havn't. I'm not sure the name-rule for signals between HP-UX and Windows is same or not.

Maybe you are looking for