Home Help Center

Problems running demo Glacier

Note this is the first demo that I've attempted running, and that I've successfully run all the tests.

The instructions in 'Ice-1.1.0/demo/Glacier/session/README' are to create 3 windows and run './server', '../../../bin/glacierstarter --Ice.Config=config', and './client'; respectively.

In trying this, I get the following error in all windows:
../../include/IceUtil/Handle.h:44: IceUtil::NullHandleException

What am I doing wrong?

Comments

  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Hi Jeff,

    Sorry to hear you're having trouble. Rest assured that this isn't the expected behavior. :)

    Please run the server with the following option:

    $ ./server --Ice.NullHandleAbort=1

    This should cause a core dump to be generated when the situation causing the Ice.NullHandleException is detected, from which you can hopefully obtain a stack trace that should help us discover the source of the problem.

    Thanks,
    - Mark
  • Jeff HolleJeff Holle Member
    This is the results of the sugguested run:

    ./server --Ice.NullHandleAbort=1
    server: Exception.cpp:94: IceUtil::NullHandleException::NullHandleException(const char*, int): Assertion `false' failed.
    Aborted

    Any ideas?
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Was a core file generated? If so, you can generate a stack trace using gdb by doing the following:

    $ gdb server core
    (gdb) bt

    - Mark
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    A couple more things:
    • Which version of GCC are you using? (Run "gcc -v" to find out)
    • Are you able to start a test server manually? For example, change to the test/Ice/operations directory, and run "./server". Does it work, or do you get the same result as the Glacier demo?

    - Mark
  • Jeff HolleJeff Holle Member
    These are the results to your various requests:

    gdb server core
    GNU gdb 5.3-22mdk (Mandrake Linux)
    Copyright 2002 Free Software Foundation, Inc.
    GDB is free software, covered by the GNU General Public License, and you are
    welcome to change it and/or distribute copies of it under certain conditions.
    Type "show copying" to see the conditions.
    There is absolutely no warranty for GDB. Type "show warranty" for details.
    This GDB was configured as "i586-mandrake-linux-gnu"...
    /home/jholle/Ice-1.1.0/test/Ice/operations/core: No such file or directory.
    (gdb) bt
    No stack.

    gcc -v
    Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.3/specs
    Configured with: ./configure
    Thread model: posix
    gcc version 3.3

    In attempting to run 'Ice-1.1.0/test/Ice/operations/server' via './server', I get the same 'Null' exceptions.
    I can apparently run this server via the 'run.py' that is in this directory.

    Makes me think the problem is run-time needed environment variables.
    I tried defining ICE_HOME to point to '/home/jholle/Ice-1.1.0' because I found it referenced in your documentation, but this had no affect.
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    I agree, the fact that you can run the test using run.py, but not start the server manually, is a strong indicator that this problem is environmental. Unfortunately, I'm still not sure what environmental problem would cause this particular exception.

    Try this: in test/Ice/operations, start the server in the debugger and run these gdb commands:

    $ gdb server
    (gdb) run --Ice.NullHandleAbort=1
    <wait for it to abort>
    (gdb) bt

    Hopefully you can get a stack trace that way.

    You've set LD_LIBRARY_PATH to include $(ICE_HOME)/lib, correct?

    - Mark
  • Jeff HolleJeff Holle Member
    Yes, my LD_LIBRARY_PATH includes $(ICE_HOME)/lib, actually its value is:

    /usr/local/lib:/usr/X11R6/lib:/home/jholle/xerces-c-src2_1_0/lib:/home/jholle/Ice-1.1.0/lib:/usr/local/BerkeleyDB.4.1/lib

    Running gdb as instructed produceds this:

    $ gdb server
    run --Ice.NullHandleAbort=1
    Starting program: /home/jholle/Ice-1.1.0/demo/Glacier/session/server --Ice.NullHandleAbort=1
    [New Thread 16384 (LWP 9719)]
    server: Exception.cpp:94: IceUtil::NullHandleException::NullHandleException(const char*, int): Assertion `false' failed.

    Program received signal SIGABRT, Aborted.
    [Switching to Thread 16384 (LWP 9719)]
    0x403b4481 in kill () from /lib/i686/libc.so.6
    Current language: auto; currently c

    Just in case, this is the list of application specific environment variables that I declare in my .bashrc:

    PS1="[\[email protected]\h \W]\$"
    PATH=$PATH:$HOME/bin
    PYTHON_ROOT=/usr/bin
    PYTHON_VERSION=2.2
    PYTHON_INCLUDES=/usr/include/python2.2
    PYTHON_STDLIB_PATH=/usr/lib/python2.2
    XERCESCROOT=/home/jholle/xerces-c-src2_1_0
    XERCESC_HOME=/home/jholle/xerces-c-src2_1_0
    BOOST_BUILD_PATH=/home/jholle/boost_1_30_0
    LD_LIBRARY_PATH=/usr/local/lib:/usr/X11R6/lib:/home/jholle/xerces-c-src2_1_0/lib:/home/jholle/Ice-1.1.0/lib:/usr/local/BerkeleyDB.4.1/lib
    DB_HOME=/usr/local/BerkeleyDB.4.1/
    PATH=/usr/include:$PATH
    ICE_HOME=/home/jholle/Ice-1.1.0


    Do you see problems with this?
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    After the assertion failure occurs while running in gdb, please execute the "bt" command to generate a stack trace. This should tell us where the problem occurred.

    We suspect that this may be DNS related. Is DNS configured correctly on your host?

    For example, does the test/Ice/operations server run correctly if you do this?

    $ ./server --Ice.NullHandleAbort=1 --Ice.Default.Host=localhost

    - Mark
  • Jeff HolleJeff Holle Member
    Please excuse my gdb ignorance...

    The stack dump is:

    #0 0x403b4481 in kill () from /lib/i686/libc.so.6
    #1 0x40264acd in pthread_kill () from /lib/i686/libpthread.so.0
    #2 0x40264deb in raise () from /lib/i686/libpthread.so.0
    #3 0x403b4224 in raise () from /lib/i686/libc.so.6
    #4 0x403b576b in abort () from /lib/i686/libc.so.6
    #5 0x403ad745 in __assert_fail () from /lib/i686/libc.so.6
    #6 0x4023977c in NullHandleException (this=0x806d298,
    file=0x401e7a80 "../../include/IceUtil/Handle.h", line=44)
    at Exception.cpp:94
    #7 0x401535c1 in IceUtil::HandleBase<IceInternal::ObjectAdapterFactory>::operator->() const (this=0x806a2a4) at ../../include/IceUtil/Handle.h:44
    #8 0x401512b2 in IceInternal::Instance::destroy() (this=0x806a248)
    at Instance.cpp:643
    #9 0x4014ed1b in Instance (this=0x806a248, communicator=@0xbffff310,
    argc=@0xbffff420, argv=0xbffff464, properties=@0xbffff3d0)
    at Instance.cpp:492
    #10 0x40155219 in CommunicatorI (this=0x806a208, argc=@0xbffff420,
    argv=0xbffff464, properties=@0xbffff3d0) at CommunicatorI.cpp:266
    #11 0x40118049 in Ice::initializeWithProperties(int&, char**, IceInternal::Handle<Ice::Properties> const&, int) (argc=@0xbffff420, argv=0xbffff464,
    properties=@0xbffff3d0, version=10100) at Initialize.cpp:51
    #12 0x08060c04 in main (argc=1, argv=0xbffff464) at Server.cpp:73
    #13 0x403a17f7 in __libc_start_main () from /lib/i686/libc.so.6


    In searching for DNS related rpms via my package manager, there are such modules that are/were not installed on my system.

    I installed adns-1.0-6mdk libadnsl-1.0-6mdk , libadnsl-devel-1.0-6mdk and tmdns-0.1-11mdk but it seems to have no affect of this problem.

    I still have openldnap-back)dnssrv-2.0.27-4mdk, perl-Net-DNS-0.33-1mdk and perl-Net-DNS-SEC-0.08-2mdk to install if you request me to.
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Thanks for the stack trace.

    Can you try running the test server with --Ice.Default.Host=localhost and let us know if you still get the NullHandleException?

    - Mark
  • Jeff HolleJeff Holle Member
    The problem does not exibit itself when " --Ice.Default.Host=localhost " is part of a server's command line.
  • mesmes CaliforniaAdministrators, ZeroC Staff Mark SpruiellOrganization: ZeroC, Inc.Project: Ice Developer ZeroC Staff
    Originally posted by Jeff Holle
    The problem does not exibit itself when " --Ice.Default.Host=localhost " is part of a server's command line.
    Ok, in all likelihood this is being caused by a configuration problem with your operating system. A more descriptive exception is almost certainly being raised within Ice, but Ice's internal handling of this exception is what is causing the NullHandleException. This will be fixed in the next release, but let me know if you'd like a patch for Ice 1.1.0.

    - Mark
Sign In or Register to comment.