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 here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
CEP: What about the action? iBot Complex Event Processing RSS News 0 02-15-2008 08:20 AM
perl cgi form action target garric Shell Programming and Scripting 4 12-08-2007 10:07 PM
Signal Default Action matrixmadhan High Level Programming 7 11-29-2007 05:42 PM
tracking user action xitrum UNIX for Advanced & Expert Users 7 03-07-2007 01:48 PM
any idea to repeat a action in VI myelvis UNIX for Dummies Questions & Answers 6 11-26-2003 03:21 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 07-27-2005
esham's Avatar
Registered User
 

Join Date: Nov 2004
Location: INDIA
Posts: 97
action command

Hi..

When i refered the script /etc/rc.sysinit...

i found the "action commands" like
Quote:
action $"Mounting proc filesystem: " mount -n -t proc /proc /proc
But this is not working in my shells..

the following error is coming...

Quote:
-bash: action: command not found
Please anybody help

Thanks in advance
esham
Reply With Quote
Forum Sponsor
  #2  
Old 07-27-2005
RTM's Avatar
RTM RTM is offline
Hog Hunter
 
Join Date: Apr 2002
Location: On my motorcycle
Posts: 3,039
Please post your OS and version. Also, is the example given,
Quote:
action $"Mounting proc filesystem: " mount -n -t proc /proc /proc
the one that is failing or is it some other line? Please provide the line that is failing and explain
Quote:
But this is not working in my shells..
- as the boot process running a shell script is not the same as a user running a shell script after the system is up.

Also see rc.sysinit script

Last edited by RTM; 07-27-2005 at 02:25 PM.
Reply With Quote
  #3  
Old 07-27-2005
esham's Avatar
Registered User
 

Join Date: Nov 2004
Location: INDIA
Posts: 97
My OS is RedHAT 9 kernel 2.6.10

what my problem is that i need to implement that [ OK ] like functionality in my script ..
so i refered the rc.sysinit so i found that its some command like "action" doing this..

If iam wrong,pls correct me...

esham
Reply With Quote
  #4  
Old 07-28-2005
infierno's Avatar
Registered User
 

Join Date: Jul 2005
Location: Asuncion, Paraguay
Posts: 79
it looks like that 'action' command is a fuction defined somewhere in another script ...
Reply With Quote
  #5  
Old 07-28-2005
infierno's Avatar
Registered User
 

Join Date: Jul 2005
Location: Asuncion, Paraguay
Posts: 79
here is it, partner... action is a function defined on /etc/rc.d/init.d/functions

Code:
# Run some action. Log its output.
action() {
  STRING=$1
  echo -n "$STRING "
  shift
  initlog $INITLOG_ARGS -c "$*" && success $"$STRING" || failure $"$STRING"
  rc=$?
  echo
  return $rc
}
I've found this on a RedHat 7.1, I'm pretty sure that is the same on your RH9
Reply With Quote
  #6  
Old 07-30-2005
esham's Avatar
Registered User
 

Join Date: Nov 2004
Location: INDIA
Posts: 97
Thank you very much for the support...
Reply With Quote
Google The UNIX and Linux Forums
Reply

Tags
linux

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 12:05 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0