Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

legato modele for domino

Status
Not open for further replies.

mlorencak

Programmer
Jul 13, 2003
36
SI
I have installed module for Lotus Domino server. Everything
semse to be OK. Vhen I backup may client I use nsrnotesv
command.
But backup of that client fail. It says "Unable to find
all notes files".
Both of computer; client and legato server are Linux machines. Variables like $Notes_ExecDirectory and $LD_LIBRARY_PATH are pointing to the file libnotes.so as it should.
Can someone help me please.

lp, mitja



 
What version of Networker Module for Lotus are you using? Also, what is specified in the Application Information field?
 
I am usin module version 2.1 and NW client 7. Don't know
where to find Aplication Infomation field.

lp, mitja
 
here is my script
........................

#!/bin/sh
#
# $Id: nsrnote.sh,v 1.12.4.1 2001/03/03 04:24:38 pjirak Exp $ Copyright (c) 2001, Legato Systems, Inc.
#
# All rights reserved.
#
# nsrnote
#
# This script is part of the Networker Module for Lotus Notes.
# Modification of this script should be done with care and only after reading
# the administration manual included with this product.
#
#
# ------ THIS SCRIPT SHOULD ONLY BE USED FOR SCHEDULED BACKUP -------
#
#
# Returns 0 on success; 1 on failure.
#
#
# ====================================================================
# Modify SECTION below to customize the backup.
#
# Here are my backup options:
myArgs="-R"

# Set the following to your Lotus user if not already correct:
LOTUSUSER=notes

#get the OS type
os=`/bin/uname`

# For Solaris
# Set the value for Notes_ExecDirectory variable to point to "libnotes.so"
# Set the value for LD_LIBRARY_PATH variable to point to "libnotes.so"
if [ "$os" = "SunOS" ]; then
Notes_ExecDirectory=/opt/lotus/notes/latest/sunspa
LD_LIBRARY_PATH=/opt/lotus/notes/latest/sunspa
LOTUSARCH=sunspa
fi

# For Linux
# Set the value for Notes_ExecDirectory variable to point to "libnotes.so"
# Set the value for LD_LIBRARY_PATH variable to point to "libnotes.so"
if [ "$os" = "Linux" ]; then
Notes_ExecDirectory=/opt/lotus/notes/latest/linux
LD_LIBRARY_PATH=/opt/lotus/notes/latest/linux
LOTUSARCH=linux
fi

# For AIX:
# Set the value for Notes_ExecDirectory variable to point to "libnotes_r.a"
# Set the value for LIBPATH variable to point to "libnotes_r.a"
if [ "$os" = "AIX" ]; then
Notes_ExecDirectory=/opt/lotus/notes/latest/ibmpow
LIBPATH=/opt/lotus/notes/latest/ibmpow
LOTUSARCH=ibmpow
fi

# For HPUX:
# Set the value for Notes_ExecDirectory variable to point to "libnotes.sl"
# Set the value for LIBPATH variable to point to "libnotes.sl"
if [ "$os" = "HP-UX" ]; then
Notes_ExecDirectory=/opt/lotus/notes/latest/hppa
LD_LIBRARY_PATH=/opt/lotus/notes/latest/hppa
LOTUSARCH=hppa
fi

# Set the value for PATH environmental variable:
#
# Set up PATH environment variable. This must be configured to include
# path to the "nsrnotesv" binary, the path to the Lotus Notes binaries ,
# path to the Lotus resource directory
# AND to the directory where 'notes.ini' resides (i.e. notes data directory).
#
PATH=/usr/sbin:/opt/lotus:/opt/lotus/bin:/opt/lotus/notes/latest/$LOTUSARCH:/opt/lotus/notes/latest/$LOTUSARCH/res/C:/bin:/usr/bin:/opt/networker/bin:/usr/bin/nsr
export PATH

#====================================================================
#
# Variable: PRECMD
# Default value: NONE
# Description: This variable can be used to run a command before dbspace and
# log file backups. This command can be used to run a command to check the
# database for corruption.
#
PRECMD=

#
# Variable: POSTCMD
# Default value: NONE
# Description: This variable can be used to run a command after dbspace and
# log file backups have completed. It can be used to check the status of
# the logical logs and dbspaces.
#
POSTCMD=

#
# Shell and environment variables not configured by user.
#
getdate="date '+%a %b %d %H:%M:%S %Y'"
Verbose=0 # Are we generating verbose output?
Pid=0 # Which process to kill when we are cancelled
nsrNote=""

#
# Run the pre-processing command. This can be used to shut down
# a database.
#
run_precmd()
{
if [ "${PRECMD}" = "" ]; then
return 0
fi

vecho
vecho "Executing pre-processing command '${PRECMD}' at `eval $getdate`"
vecho

${PRECMD}
return_status=$?

vecho
vecho "Pre-processing command '${PRECMD}' finished at `eval $getdate`"
vecho

return $return_status
}

#
# Run the post-processing command. This can be used to start a database.
#
#
run_postcmd()
{
if [ "${POSTCMD}" = "" ]; then
return 0
fi

vecho
vecho "Executing post-processing command '${POSTCMD}' at `eval $getdate`"
vecho

${POSTCMD}
return_status=$?

vecho
vecho "Post-processing command '${POSTCMD}' finished at `eval $getdate`"
vecho

return $return_status
}

#
# Process arguments supplied by savegrp.
#
processargs()
{
while [ $# -gt 0 ]; do
case "$1" in
-s ) # Specify server
nsrNote="${nsrNote} $1 $2"
shift
shift
;;
-v ) # Verbose
Verbose=1
shift
;;
-N ) # Specify a new save set name
NSR_SAVESET_NAME="$2"
nsrNote="${nsrNote} $1 $2"
shift
shift
;;
-b ) # Specify pool
nsrNote="${nsrNote} $1 $2"
shift
shift
;;
-g ) # Specify group
nsrNote="${nsrNote} $1 $2"
shift
shift
;;
-l ) # Specify level
nsrNote="${nsrNote} $1 $2"
shift
shift
;;
*) # Something we do not handle
shift
;;
esac
done
}

#
# Make sure all environment variables are exported.
#
export_environment_variables()
{
export LIBPATH
export LD_LIBRARY_PATH
export Notes_ExecDirectory
export LOTUSUSER
}

#
# Actual backup
#
backup_notes()
{

#
# Pass NetWorker arguments to nsrnotesv.
#
if [ "$LOTUSUSER" != "" ]; then
su $LOTUSUSER -m -c "nsrnotesv $nsrNote $myArgs"
Pid=$!
wait $Pid

ret_status=$?
if [ $ret_status != 0 ]; then
echo "nsnotesv returned status of "$ret_status
echo $0 "exiting."
exit 1
fi
else
### Can not backup without LOTUSUSER being set.
echo "Unable to run nsrnotesv, LOTUSUSER variable not set in nsrnote.sh"
echo "LOTUSUSER variable must be set in order to run nsrnotesv and backup Lotus."
echo "Exiting without backing up Lotus."
exit 1
fi
}

#
# Echo the arguments only if in verbose mode.
#
vecho()
{
if [ $Verbose -gt 0 ]; then
echo "nsrnotesv: $@"
fi
}

#
# Handle cancel signals sent by savegrp when user stops the group.
#
handle_signal()
{
if [ $Pid != 0 ]; then
kill -2 $Pid
fi
exit 1
}

#
# The main portion of this shell.
#
# Process arguments
# Export variables
# Execute a pre-command (if any)
# Execute Lotus Notes backups
# Execute a post-command

echo "calling processargs"
processargs "$@"

export_environment_variables

#
# Make sure we respond to savegrp cancellations.
#
trap handle_signal 2 15

#
# Handle pre-processing
#
run_precmd
precmd_status=$?
if [ $precmd_status != 0 ]; then
echo "Pre-processing command failed. Ending session."
exit 1
else
vecho "Pre-processing command succeeded."
fi

#
# Handle dbspace backups
#
backup_notes

#
# handle post-processing
#
run_postcmd
postcmd_status=$?
if [ $postcmd_status != 0 ]; then
echo "Post-processing command failed. Ending session."
exit 1
else
vecho "Post-processing command succeeded."
fi

exit 0

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top