4.5 Configuring the Role Mapping Administrator for Automatic Startup

As first installed, the Role Mapping Administrator does not start automatically. You can configure the Role Mapping Administrator to automatically start when the server is started.

  1. From the Computer menu, select Gnome Terminal.

  2. Log in as root by entering su, then enter the root password.

  3. Copy the start.sh file from the /installation_directory/idmrmap directory to the /etc/init.d directory.

  4. Rename the file from start.sh to idmrmap.sh, for example.

    You can name the file anything you want that does not already exist in the /etc/init.d directory.

  5. Use a text editor to add the full path to the startup.sh file and to set the correct path for the Java installation. For example:

    #!/bin/sh
    export JAVA_HOME=/opt/novell/jdk1.5.0_11
    export JRE_HOME=$JAVA_HOME/jre
    export PATH=$JAVA_HOME/bin:$PATH
    /home/admin/idmrmap/tomcat/bin/startup.sh
    

    The default location of the startup. sh file is in the /installation_directory/idmrmap/tomcat/bin/startup.sh.

  6. Enter ls -l /etc/init.d/idmrmap to verify the file copied.

  7. Enter chown root:sys /etc/init.d/idmrmap to change the owner of the file.

  8. Enter chmod 700 /etc/init.d/idmrmap to change access to the file.

  9. Enter chkconfig -add idmrmap to add the script as a system service.

  10. Use the following two commands to verify whether idmrmap runs before or after ndsd and userapp in run-level 3 during the system start procedure.

    Ultimately, you must ensure that idmrmap starts after ndsd and userapp.

    NOTE:The first command uses a lowercase letter l twice. It is not the number 11.

    metaserver1:/home/admin # ll /etc/init.d/rc3.d/ |grep idmrmap
    lrwxrwxrwx 1 root root 10 2008-05-16 16:26 K12idmrmap -> ../idmrmap
    lrwxrwxrwx 1 root root 10 2008-05-16 16:26 S10idmrmap -> ../idmrmap
    
    metaserver1:/home/admin # ll /etc/init.d/rc3.d/ |grep ndsd
    lrwxrwxrwx 1 root root  7 2008-05-16 13:23 K11ndsd -> ../ndsd
    lrwxrwxrwx 1 root root  7 2008-05-16 13:23 S11ndsd -> ../ndsd
    

    Watch the SXX numbers (S10idmrmap and S11ndsd) that are prefixed to the script name. They indicate the start order. A higher number means the service is started after a lower number. If the numbers are the same, both services are started at the same time.

    In this case, idmrmap runs before ndsd, which is the opposite of what you want. Enter the following commands as a corrective action if the idmrmap number is the same or lower than the ndsd number:

    metaserver1:/home/admin # mv /etc/init.d/rc3.d/S10idmrmap /etc/init.d/rc3.d/S12idmrmap
    
  11. Repeat Step 10 using userapp instead of ndsd.

  12. Verify the startup order for run-level 5 (the same commands as Step 10, but instead of rc3.d, you now use rc5.d):

    metaserver1:/home/admin # ll /etc/init.d/rc5.d/ |grep idmrmap
    lrwxrwxrwx 1 root root 10 2008-05-16 16:26 K12idmrmap -> ../idmrmap
    lrwxrwxrwx 1 root root 10 2008-05-16 16:26 S10idmrmap -> ../idmrmap
    
    metaserver1:/home/admin # ll /etc/init.d/rc5.d/ |grep ndsd
    lrwxrwxrwx 1 root root  7 2008-05-16 13:23 K11ndsd -> ../ndsd
    lrwxrwxrwx 1 root root  7 2008-05-16 13:23 S11ndsd -> ../ndsd
    

    Enter the following commands as a corrective action if the idmrmap number is the same or lower than the ndsd number:

    metaserver1:/home/admin # mv /etc/init.d/rc5.d/S10idmrmap /etc/init.d/rc5.d/S12idmrmap
    
  13. Repeat Step 12 using userapp instead of ndsd.

  14. Start the Role Mapping Administrator by entering /etc/init.d/idmrmap start

  15. You must use the /installation_directory/idmrmap/stop.sh script to stop the Role Mapping Administrator.

    Entering /etc/init.d/idmrmap stop does not stop the Role Mapping Administrator.

  16. Enter exit twice to log out as root and close the Gnome Terminal.