RNUG Lotus User Group (www.vlaad.lv)

    Domino autostart on Linux

    Vladislavs Tatarincevs  27 March 2009 16:09:10
    This is a known script, but many people new to Lotus Domino on Linux are asking about it so, I decided to post it.
    How to automatically start Domino when starting the Linux OS
    http://www-01.ibm.com/support/docview.wss?rs=0&uid=swg21173499


    in addition to this, consider another technote about
    Domino for Linux on x86 configuration
    http://www-01.ibm.com/support/docview.wss?uid=swg21377724

    ========
    2. Domino is automatically started through /etc/init.d

    Starting a Domino server automatically when Linux is booted is typically accomplished by executing a script which resides in the /etc/init.d directory (in a "runlevel") . It is worth noting, however, that /etc/security/limits.conf settings are NOT respected when Domino is automatically started by a /etc/init.d script. Therefore, a line such as the following MUST appear in the "start" section of such a script:
    ulimit -n 20000
    ========


    How to automatically start Domino when starting the Linux OS

     Technote (FAQ)
     

    Question
    How do you automatically start a Lotus® Domino® server when starting the Linux® operating system?
     
    Answer
    To do this, follow these steps:
    1. Copy the script below to a file named /etc/init.d/domino
    #!/bin/bash
    # DOM_HOME is the variable that tells the script where the Domino Data
    resides
    DOM_HOME=/home/notesdata
    # DOM_USER is the Linux account used to run the Domino 6 server
    DOM_USER=notes
    # DOM_PROG is the location of the Domino executables
    DOM_PROG=/opt/lotus/bin
    start()
    {
    echo -n Starting domino:
    if [ -f $DOM_HOME/.jsc_lock ]; then
    rm $DOM_HOME/.jsc_lock
    fi
    /bin/su - notes -c "LD_PRELOAD=/lib/libpthread.so.0:/lib/librt.so.1;export
    LD_PRELOAD;$DOM_PROG/server -jc -c" > /dev/null 2>&1 &
    return 0
    }
    stop() {
    echo -n Stopping domino:
    /bin/su - notes -c "$DOM_PROG/server -q"
    return 0
    }
    case $1 in
    start)
    start
    ;;
    stop)
    stop
    ;;
    *)
    echo Usage: domino {start|stop}
    exit 1
    esac

    2. Give execute permission to the file by using the command:
    chmod +x domino
    3. Link the file to start and stop as linux startup service, as follows:

    from /etc/rc0.d
    ln -s /etc/init.d/domino K10domino
    from /etc/rc2.d
    ln -s /etc/init.d/domino S99domino
    from /etc/rc3.d
    ln -s /etc/init.d/domino S99domino

    3. Reboot the server to see the results.

    Note: For more details about this example of how you can start Domino automatically on Linux, refer to the Lotus Domino 6 for Linux Redbooks publication at http://www.redbooks.ibm.com
     


     




    Archives