?
Solved

Running background process using KSH

Posted on 1998-07-24
1
Medium Priority
?
620 Views
Last Modified: 2013-12-16
I am new with solaris 2.5.1. so , I would like to know how to run process ( file) automatically when the system booting or reboting using KSH . and how and where to put the script
that running the process.
0
Comment
Question by:mahadir
1 Comment
 
LVL 4

Accepted Solution

by:
jlms earned 150 total points
ID: 1812362
I would not recommend to use ksh (I have never tried myself). The standard shell to do this is the Bourne shell (/bin/sh).

Now, there is a series of directories in /etc called rc0.d, rc1.d, rc2.d, rcS.d and so on. Each directory has a series of file whose names are Knnsomething or Snnsomething.

When the machine boots, it executes the scripts begining with S in ascending order and gives the start parameter to each one of them. If you pay attention, most of these scripts are in reality links to the real thing under /etc/init.d

So you should put your script in /etc/init.d and then make a link in /etc/rc2.d pointing to your script. The link should be called Snn<something sensible> where nn is a number (choose a high one so your script executes at the end). Your script should be able to deal with the start parameter properly, but if it just executes is ok.


0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.
Suggested Courses

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question