The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
shell script that would display installing.... when installign something eamani_sun Shell Programming and Scripting 1 05-14-2008 02:51 PM
Installing Patches in HPux Prem UNIX for Dummies Questions & Answers 1 04-02-2007 06:39 PM
pkgadd fails when installing Solaris 8 patches Deicide5997 UNIX for Dummies Questions & Answers 5 09-24-2006 12:04 PM
Installing patches meyersp SUN Solaris 7 06-08-2006 04:16 PM
Installing patches FredSmith SUN Solaris 7 11-01-2005 09:46 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 12-12-2003
viRaven viRaven is offline
Registered User
  
 

Join Date: Dec 2003
Location: The O.C.
Posts: 37
Installing Patches from a script

Hello all,

I'm hoping someone might be able to help me here. After installing Solaris, we use a script to copy site sepcific files over the machine. Now I want the script add the appropiate Sun patches as well. As the script hits that part it errors out, now the script finishes but the Patch part does not. I am not sure if its totally possible, but I am a firm believer that UNIX can be strecthed far and wide. I get the sense that the patch cannot run from within side the script, perhaps in its own shell? The purpose is to make all this non-interactive. So I'd like to be able run the script with no interaction.

Here is the part that spawns the patch part of the script, or is suppose to anyway:


#--------------------------------------------------------
case `uname -r` in
5.5.1)
# Install patches for 2.5.1
echo "Installing Patch cluster for Solaris 2.5.1"
/apps/patches/Solaris_2.5.1/2.5.1_Recommended/install_cluster -q
;;
5.6)
# Install Patches for 2.6
echo "Patches unavailable, Please install manually"
;;
5.7)
# Install Patches for 2.7
echo "Installing Patch Cluster for Solaris 7"
/apps/patches/Solaris_7/7_Recommended/install_cluster -q
;;
5.8)
# Install Patches for 2.8
echo "Installing Patch Cluster for Solaris 8"
./apps/patches/Solaris_8/8_Recommended/install_cluster -q
;;
5.9)
# Install Patches for 2.9
echo "Installing Patch Cluster for Solaris 9"
/apps/patches/Solaris_9/9_Recommended/install_cluster -q
;;
*)
;;

esac
  #2 (permalink)  
Old 12-12-2003
oombera's Avatar
oombera oombera is offline Forum Advisor  
Registered User
  
 

Join Date: Aug 2002
Location: Cleveland, OH
Posts: 804
You said the script errors out but then it finishes? So does the script end nicely or not? If not, what's the error you're getting?

Are you sure it's not just the last, default option that's being executed in the case statement and so nothing is being output to the screen?

Also, I noticed that only in one section of that statement did you use ./apps whereas the rest use /apps. This could be a big difference and could result in certain files not being found...
  #3 (permalink)  
Old 12-12-2003
viRaven viRaven is offline
Registered User
  
 

Join Date: Dec 2003
Location: The O.C.
Posts: 37
error

Error: for patch part

Patch Cluster install script for Solaris 9 Recommended

Determining if sufficient save space exists....
du: failed for /path/path: Cycle deteced
expr: syntax error

Then the script continues on finishing its other task. It seems to be doing a du in the directory where the script is sitting and not on the host machine.
  #4 (permalink)  
Old 12-12-2003
viRaven viRaven is offline
Registered User
  
 

Join Date: Dec 2003
Location: The O.C.
Posts: 37
I guess I have path issues, if i cd to the directory where the Patch Cluster resides it runs fine.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 03:18 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0