Then
created the symbolic links under "/etc/rc.d/rc2.d"
Code:
-r-xr-xr-x 1 root system 326 Jun 13 2017 Ssshd
-r-xr-xr-x 1 root system 325 Jun 13 2017 Ksshd
-r-x------ 1 root system 2545 Jun 13 2017 Kwpars
-rwxr-xr-x 1 root system 175 Jun 13 2017 S00ct_boot
lrwxrwxrwx 1 root system 24 Aug 22 14:36 S80app7 -> /etc/rc.d/init.d/app.sh
lrwxrwxrwx 1 root system 24 Aug 22 14:47 K90app7 -> /etc/rc.d/init.d/app.sh
Result: Not as expected
LPAR was shutdown; stop script ran successfully before shutdown.
But Issue is stop script ran again during LPAR activation/restart as well.
My intention is only to run stop script before shutdown and start script after the lpar restart.
Scenario 2)
under "/etc/rc.d/rc2.d"
Code:
-r-xr-xr-x 1 root system 326 Jun 13 2017 Ssshd
-r-xr-xr-x 1 root system 325 Jun 13 2017 Ksshd
-r-x------ 1 root system 2545 Jun 13 2017 Kwpars
-rwxr-xr-x 1 root system 175 Jun 13 2017 S00ct_boot
lrwxrwxrwx 1 root system 24 Aug 22 14:36 S25app7 -> /etc/rc.d/init.d/app.sh
and
after reading IBM tech note (ref to step 5 in IBM tech note)
I run the following command using the command line. I need to run the same command in shell script :
./sas.server start
start is a parameter that passes to start.server to startup services within start.server.
the path to sas.server is /path/Lev1
Here is my code:
#!/bin/sh
set... (3 Replies)
Hello,
I have script that start and shutdown the application.
where should i place my script so that it can execute at my OS shutdown ?
Pls help me... (2 Replies)
Hi
I have 100 files under file A labled 1.txt 2.txt.....100.txt(made up name)
I have 1 files under file B labled name.txt
How can i run the same perl script on 100 files and file name.txt
I want to run
perl script.pl A/1.txt B/name.txt
perl script.pl A/2.txt B/name.txt
.......
perl... (3 Replies)
Hi I am working in a java application. I need to execute a perl script(linux) which is in remote machine in java application from local machine(windows). I need to do this process automatically that is without manual intereption. Now I will explain the process clearly, at present to run the... (1 Reply)
In my cronjob, I would like to schedule my script.sh to run every minutes. I crontab -e and have in line below but it didn't seems to run at all.
* * * * * script.sh
When I run it manually, I can run it. Is that anything wrong with the above line?
If I change it to something like below,... (4 Replies)
Hi,
I want to run a Perl script on multiple files, with same name ("Data.txt") but in different directories (eg : 2010_06_09_A/Data.txt, 2010_06_09_B/Data.txt).
I know how to run this perl script on files in the same directory like:
for $i in *.txt
do
perl myscript.pl $i > $i.new... (8 Replies)
Stop the application before shutdown the server ..
I have application need to be started with the system and also need to be stop before shutdown the system
This is the path of the application:
/usr/appstart
/usr/appstop
to start the application with the startup of the... (2 Replies)
I'm trying to do some cleanup (write open files) when Linux shuts down. I thought the right method would be to trap SIGTERM and do the necessary processing. Here's my sample code:
#include <stdio.h> // for File I/O
#include <signal.h> // for signals
#include <unistd.h> // for sleep()
void... (6 Replies)
I have a ksh script that does a bunch of things, then runs
telnet server_b
I then manually login, manually run one command (which launches an application with display back to my workstation), then logout at which point the main script takes back over, runs something else, then ends.
Is... (4 Replies)