2 # Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
4 # Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
5 # CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
7 # This library is free software; you can redistribute it and/or
8 # modify it under the terms of the GNU Lesser General Public
9 # License as published by the Free Software Foundation; either
10 # version 2.1 of the License.
12 # This library is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 # Lesser General Public License for more details.
17 # You should have received a copy of the GNU Lesser General Public
18 # License along with this library; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 #log files localization
26 Username=`/usr/bin/whoami`
28 # kill OmniNames if exists
30 #killall -q -9 omniNames
34 mkdir -m 777 ${BaseDir}/logs
35 mkdir ${BaseDir}/logs/${Username}
36 touch ${BaseDir}/logs/${Username}/dummy
37 \rm -f ${BaseDir}/logs/${Username}/omninames* ${BaseDir}/logs/${Username}/dummy ${BaseDir}/logs/${Username}/*.log
39 echo "Name Service... "
40 aSedCommand="s/.*NameService=corbaname::`hostname`:\([[:digit:]]*\)/\1/"
41 aPort=`cat $OMNIORB_CONFIG | grep NameService | sed -e"$aSedCommand"`
42 omniNames -start $aPort -logdir ${BaseDir}/logs/${Username} &
44 # In LifeCycleCORBA, FactoryServer is started with rsh on the requested
45 # computer if this Container does not exist. Default is localhost.
46 # Others Containers are started with start_impl method of FactoryServer Container.
47 # For using rsh it is necessary to have in the ${HOME} directory a .rhosts file
48 # Warning : on RedHat the file /etc/hosts contains by default a line like :
49 # 127.0.0.1 bordolex bordolex.paris1.matra-dtv.fr localhost.localdomain localhost
50 # (bordolex is the station name). omniNames on bordolex will be accessible from other
51 # computers only if the computer name is removed on that line like :
52 # 127.0.0.1 bordolex.paris1.matra-dtv.fr localhost.localdomain localhost
54 # To start dynamically Containers on several computers you need to
55 # put in the ${OMNIORB_CONFIG} file a computer name instead of "localhost"
56 # example : ORBInitRef NameService=corbaname::dm2s0017
58 # If you need to use several omniNames running on the same computer, you have to :
59 #1. put in your ${OMNIORB_CONFIG} file a computer name and port number
60 # example : ORBInitRef NameService=corbaname::dm2s0017:1515
61 #2. start omninames with this port number in runNS.sh
62 # example : omniNames -start 1515 -logdir ${BaseDir}/logs/${Username} &
65 echo "to list contexts and objects bound int the context with the specified name : showNS "