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

What is process id of init daemon?

3 Answers  


what is milestone and what is use of it in Solaris

6 Answers   IBM,


How would switch a service group?

2 Answers  


How can you unencapsulate a boot disk in VxVM?

5 Answers  


1.how to see global zone name residing in non global zone?

6 Answers   CSC,






How do you give a user access to an application or program that needs to run as root without giving them the root password?

3 Answers  


how to create nis master,slave,client

2 Answers   IBM,


How to identify multiple paths for a disk.?

2 Answers  


What is VTS..??

3 Answers  


What is the difference between private and public regions in Veritas Volume manager?

4 Answers  


Unable to telnet any of my servers in the network..? wht may be the reason

3 Answers   HP,


What is a Split brain scenario ?

2 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)