9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have been running a program mseed2sac using the following command
cd IV
find . -type f -exec /swadmin/mseed2sac '{}' \;
The problem is that I end up with a lot of files in directory IV.
Instead I would like to select the designator HHZ, create a
directory IV.SAC and all the files output... (11 Replies)
Discussion started by: kristinu
11 Replies
2. Shell Programming and Scripting
Hi,
I have a script which does couple of database connection and run some SELECT queries to get some output in the file.
I am surprised to see :eek: that when i run my script some times it gives the desired out put and sometimes it shows some error :confused: .
Suppose if i execute it say... (3 Replies)
Discussion started by: Sharma331
3 Replies
3. Shell Programming and Scripting
I am using blow script :--
#!/bin/bash
FIND=$(ps -elf | grep "snmp_trap.sh" | grep -v grep) #check snmp_trap.sh is running or not
if
then
# echo "process found"
exit 0;
else
echo "process not found"
exec /home/Ketan_r /snmp_trap.sh 2>&1 & disown -h ... (1 Reply)
Discussion started by: ketanraut
1 Replies
4. UNIX for Dummies Questions & Answers
I have created this script and does not seem to be behaving well.
Basically I am in a directory, I just want to do down two directories, run the script
georom_replaceText.tcsh
This will produce a file in the subdirectory, which I then run. Finally go back to where I started. Afterwards I... (4 Replies)
Discussion started by: kristinu
4 Replies
5. Shell Programming and Scripting
Hi, I have about 10 directories in which I run the same code. But this code is only run in a directory when the computation in the previous directory was successful (explained below).
My directories are named as :
VF_50, VF_100, VF_150, VF_200.............
As you can see the number after _... (6 Replies)
Discussion started by: lost.identity
6 Replies
6. Shell Programming and Scripting
hi,
in a directory called dir1 with subdir :
dir11
dir12
dir13
dir14
i'm using this kind of request in ksh:
find /dir1 -name '*txt' |wc -l
i want now to run the same request but without going down in the subdir dir14
is there a simple way to do that ?
if not what do you... (4 Replies)
Discussion started by: Nicol
4 Replies
7. Shell Programming and Scripting
Hello all,
Here's the deal...I have one directory with many subdirs and files.
What I want to find out is who is keeping old files and directories...say files and dirs that they didn't use since a number of n days, only one level under the initial dir. Output to a file.
A script for... (5 Replies)
Discussion started by: ejianu
5 Replies
8. Shell Programming and Scripting
I am working on a script that checks two arguments at the command line. The first argument is a search pattern, the second can be a file or a directory, if it is a file a second script is called that checks it for the search pattern. If the second argument is a directory, it checks for the search... (5 Replies)
Discussion started by: Breakology
5 Replies
9. Solaris
Hi,
i have a script which need to do behave differently when run as a startup process from init.d/ rc2.d script and when run manually from shell.
How do i distinguish whether my script is run by init process or by shell??
Will the command
/proc/$$/psinfo | grep "myscript" work well???... (2 Replies)
Discussion started by: vickylife
2 Replies