[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cobalt-security] ipchains adding to rc.local



At 03:22 PM 7/25/01 -0700, shimi wrote:
>
>On Wed, 25 Jul 2001, R. Hamburg wrote:
>> 
>> So let's say I name the file servercommands
>> the in rc.local I call them by entering
>> 
>> ./etc/servercommands
>  ^^ not sure if works with the dot. should work. i do without. 

Well, if he uses the dot, which he should, there needs to be a space after
it.  The dot "sources" the file instead of executing it separately.  The
line would fail since the current directory (.) probably isn't /.  When
adding the space, make sure to keep the / before etc.  From 'man bash',
under "Shell Builtin Commands":

---
.  filename [arguments]
source filename [arguments]

Read and execute commands from filename in the current shell environment
and return the exit  status  of the  last  command  executed from filename.
 If filename does not contain a slash, pathnames in PATH are used to find
the directory containing filename.  The file searched for in PATH need not
be  executable. The  current  directory  is  searched  if no file is found
in PATH.  If any arguments are supplied, they become the positional
parameters when  file  is  executed.   Otherwise  the  positional
parameters  are unchanged.   The  return status is the status of the last
command exited within the script (0 if no com<AD> mands are executed), and
false if filename is not found.
---

-------------------------------------------------------------------------
Ted Behling, Web Application Developer, Monarch Information Systems, Inc.

43 Folly Field Road, Unit 4, Hilton Head Island, SC 29928-5434
E-mail: mailto:TBehling@xxxxxxxxxxxxx
Phone/Fax: 1-800-842-7894    Local or Outside the USA: 1-843-842-7894
Cell Phone (urgent issues): 843-816-7895
Cell Phone E-mail: mailto:TedPhone@xxxxxxxxxxxxx (116 letter limit)
Web site: http://www.monarchis.net
-------------------------------------------------------------------------