#!/bin/sh

######################################################
# SERVICE ENABLE
######################################################
if [ ! -e "/sbin/init.d/exem-manager-agent" ]; then
  cp __INST__EXEM_HOME__/manager/service/exem-manager-agent_hpux /sbin/init.d/exem-manager-agent

  ln -s /sbin/init.d/exem-manager-agent /sbin/rc2.d/S999exem-manager-agent
  ln -s /sbin/init.d/exem-manager-agent /sbin/rc2.d/K999exem-manager-agent

  chmod 755 /sbin/init.d/exem-manager-agent
  chmod 755 /sbin/rc2.d/S999exem-manager-agent
  chmod 755 /sbin/rc2.d/K999exem-manager-agent
fi

echo "exem-manager-agent is enabled [service_start.sh]"


######################################################
# SERVICE START
######################################################
/sbin/init.d/exem-manager-agent start

echo "exem-manager-agent is started [service_start.sh]"
