how to add a run control script..?



how to add a run control script..?..

Answer / c. anthony francis

The following procedure describes how to add a run control
script:
1.. Create the script in the /etc/init.d directory.
#Vi /etc/init.d/<filename>
#chmod 744 /etc/init.d/<filename>
#chgrp sys /etc/init.d/<filename>
2. Create links to the appropriate /etc/init.d directory.
# cd /etc/init.d
# ln filename /etc/rc#.d/S##filename
# ln filename /etc/rc#.d/K##filename
For instance, you might link a file in /etc/init.d called
database to a file called /etc/rc3.d/S99database, with a
corresponding stop script called /etc/rc3.d/K99database.
3. Use the ls command to verify that the script has links
in the appropriate directories.
# ls -li /etc/init.d/filename
# ls -li /etc/rc#.d/S##filename
# ls -li /etc/rc#.d/K##filename
4. Test the filename by performing the following commands:
# /etc/init.d/filename start

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More Solaris AllOther Interview Questions

After installing kernal patch if system crashed,then how to recover?

2 Answers   HP,


what r the files need to edit for DNS configuration..?

2 Answers   Accel,


How to see the disk label and what information does that contains..?

2 Answers  


how to check network statstics..?

5 Answers  


What are the various clusters you have worked on?

1 Answers  






how to configure default router..?

3 Answers  


what is sc prompt in solaris? how can we get that sc prompt?

2 Answers  


How to brk the root pwd?

5 Answers  


What is RPC?

3 Answers  


what is port no for NFS?

5 Answers  


what are soft links and hard links, and differentiate them.

2 Answers   Bank Of America,


hoe many default no of groups there?

4 Answers  


Categories
  • Solaris Commands Interview Questions Solaris Commands (360)
  • Solaris Threads Interview Questions Solaris Threads (9)
  • Solaris IPC Interview Questions Solaris IPC (30)
  • Solaris Socket Programming Interview Questions Solaris Socket Programming (3)
  • Solaris System Calls Interview Questions Solaris System Calls (25)
  • Solaris General Interview Questions Solaris General (170)
  • Solaris AllOther Interview Questions Solaris AllOther (297)