Search Results

Search: Posts Made By: arunsoman80
10,438
Posted By arunsoman80
Can you please paste here the code for both the...
Can you please paste here the code for both the scripts that you are using? Would be much more easier for me to find what the issue is...

regards,
Arun.
2,107
Posted By arunsoman80
Issue with mail attachment
Hi Unix Gurus,

Need your help regarding a weird issue that I'm facing. I have an automated unix script that sends out PGP encrypted reports/feeds to our users as mail attahments. Every thing has...
2,473
Posted By arunsoman80
Did you even try the code that rakesh and I...
Did you even try the code that rakesh and I posted here?

regards,
Arun.
2,473
Posted By arunsoman80
Try this: for file_name in `ls...
Try this:

for file_name in `ls /opt/grid/1022/store`
do
if [[ ! -z `/opt/dev/chktool -getstat $file_name |grep "DONE"` ]]; then
rm -f ${file_name}
fi
done

regards,...
12,758
Posted By arunsoman80
Try if [ $1 -eq 0 ]; then Or if [ $1 =...
Try
if [ $1 -eq 0 ]; then

Or
if [ $1 = "0" ]; then

regards,
Arun.
10,438
Posted By arunsoman80
In your script updatevs, I would say add exit $?...
In your script updatevs, I would say add exit $? at the end of the script. That way, the wrapper would be able to trap the correct return code.

The wrapper was failing because of a missing then
...
15,155
Posted By arunsoman80
Find command is doing a recursive search which is...
Find command is doing a recursive search which is causing files from sub-directories to be moved. Instead of

find . -name "PNT.2*" -print | ls -1 /$ROOTDIR/scp/inbox/ > FilesToProcess.tmp

...
3,704
Posted By arunsoman80
That's exactly what the code that I suggested in...
That's exactly what the code that I suggested in my previous post does... Did you try that?

regards,
Arun.
15,155
Posted By arunsoman80
gfile is just a variable... I just used the same...
gfile is just a variable... I just used the same variables that you pasted in the actual piece of code...
for gfile in `ls -1 /$ROOTDIR/scp/inbox/PNT.2*`

Basically filesToProcess.tmp would be a...
3,704
Posted By arunsoman80
Modify the sql to generate the mailx commands in...
Modify the sql to generate the mailx commands in the spool file and then execute the commands in the shell script:

Modified SQL Code:

SELECT 'mailx -s " Locked out Info: user id - '
...
15,155
Posted By arunsoman80
You could probably write the list of all the...
You could probably write the list of all the files to be processed into a temporary file and then use that temp file for further processing...

Sample code (Not tested):
...
8,157
Posted By arunsoman80
We had a similar requirement once and we used the...
We had a similar requirement once and we used the third option that cambridge has suggested here... Check the size of the file over a 30 second interval and if the size remains static that means the...
10,438
Posted By arunsoman80
Rather than doing a search in the log files to...
Rather than doing a search in the log files to check if the script updatevs completed successfully or not, I think a better way to do accomplish would be to do the following:
1. Modify the script...
15,155
Posted By arunsoman80
From the error message, it seems the following...
From the error message, it seems the following line is failing:

for gfile in `ls -1 /$ROOTDIR/scp/inbox/PNT.2*`

Seems like the ls command is returning a huge list of files...

regards,
Arun.
2,328
Posted By arunsoman80
There might be other better ways to do it, but...
There might be other better ways to do it, but this works too...


x=`grep -n "mango" test_file |cut -d":" -f1`
if [[ -z $x ]]; then
echo "cannot find the pattern"
return 1;
else
...
Forum: What is on Your Mind? 06-24-2009
2,242
Posted By arunsoman80
What's this Bits and Banking?
Hey Guys,

This is a lame one... Today I noticed this link 'Banking' next to my user name and when I click on it, it shows some bits, some checking/saving account and all...

Just curious on...
19,098
Posted By arunsoman80
FYI, My job has the following 2 components: ...
FYI, My job has the following 2 components:

remoteFtpServerCleanUp.ksh: Goes through the local archive directory and creates a list of all the old files that need to be deleted. Then it...
2,040
Posted By arunsoman80
Refer...
Refer https://www.unix.com/shell-programming-scripting/103371-scripting-problem-when-file-not-found-i-want-return-menu.html

This issue is quite similar to yours...

regards,
Arun.
19,098
Posted By arunsoman80
Let me know if you need any help. I can provide...
Let me know if you need any help. I can provide you with the scripts I developed for this if you want...

regards,
Arun.
19,098
Posted By arunsoman80
In my case, we had a daily job that would...
In my case, we had a daily job that would download new files from the remote ftp server and then place it in an archive directory in local machine after processing those files. Since identifying old...
63,049
Posted By arunsoman80
Try this: SET MARKUP HTML ON ENTMAP ON...
Try this:


SET MARKUP HTML ON ENTMAP ON SPOOL ON PREFORMAT OFF ;
SPOOL MY_TEST_FILE.xls;
SELECT * FROM EMP;
SPOOL OFF;


regards,
Arun.
31,190
Posted By arunsoman80
Try this: HFR_MAIL=NO PRP_MAIL=NO ...
Try this:

HFR_MAIL=NO
PRP_MAIL=NO
MC_MAIL=NO
if [[ "$HFR_MAIL" == "NO" && "$PRP_MAIL" == "NO" && "$MC_MAIL" == "NO" ]]; then
echo "NO "
else
echo "YES"
fi


regards,
Arun.
6,428
Posted By arunsoman80
I'm just a starter in UNIX Scripting but think...
I'm just a starter in UNIX Scripting but think you could try the following:
1. Reason why it doesn't read the last line might be due to missing newline. Open your text file again in VI editor and...
6,682
Posted By arunsoman80
wget can also be used if you always need to only...
wget can also be used if you always need to only download the new/modified files. We do have a unix script running in PROD that uses "wget" to sync up the local directory with the remote ftp server...
2,548
Posted By arunsoman80
Try this: regards, Arun.
Try this:



regards,
Arun.
Showing results 1 to 25 of 44

 
All times are GMT -4. The time now is 06:06 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy