ip-up local

Kevin Wang rightsock at gmail.com
Mon Aug 9 17:26:30 UTC 2004


My preference is to put files that I create in /usr/local/etc, and
then link them into /sbin and /etc/sysconfig/networking-scripts as
needed.

That way when I reinstall, it's easy to wipe the disk and start over. 
All my customizations are in a separate tree.

I also embed "how to install" instructions in the top of each script,
since I rebuild systems amazingly frequently.  for example:

# to install:
# ln -s /usr/local/etc/if-local /sbin/ifup-local
# ln -s /usr/local/etc/if-local /sbin/ifdown-local
# ln -s /usr/local/etc/if-local /etc/ppp/ip-up.local
# ln -s /usr/local/etc/if-local /etc/ppp/ip-down.local

and for scripts that end up going into /etc/init.d/, I make "install"
a command, just like "start" and "stop".

   - Kevin

On Sat, 7 Aug 2004 10:04:22 +0100, James Wilkinson
<james at westexe.demon.co.uk> wrote:
> Alexander Dalloz wrote:
> > Though /etc is no good place for executive scripts.
> 
> Sorry, am I "hearing" you correctly? You don't think executable scripts
> should live under /etc, just text based files with settings?
> 
> Would you mind justifying that? All the Unix-like operating systems of
> which I know put executable scripts in the /etc filesystem: in
> particular, the two common init systems (SysV and BSD) rely on a large
> number of executable scripts there. BSD init puts them directly in
> /etc.
> 
> Or do you just think that they should all be in subdirectories of /etc,
> not in /etc itself? Fedora *nearly* does that (on my system, autofs
> breaks that rule[1]), which is largely due to the preference of putting
> stuff in subdirectories of /etc if the program is complicated enough to
> need multiple files in /etc. Which *is* a good one: there's enough
> under /etc as it is...
> 
> But I thought that was just a side-effect, not something to be aimed at:
> I don't think I've ever come across a rule which says "no executable
> stuff in /etc"
> 
> A few figures:
> on a random AIX box:
> /etc$ find . -type f -perm -1 2>/dev/null | wc -l
>      162
> /etc$ ls -l |egrep ^-..x | wc -l
>       27
> 
> on this Fedora box:
> [james at howells etc]$ find . -type f -perm -1 2>/dev/null | wc -l
> 493
> [james at howells etc]$ ls -l |egrep ^-..x | wc -l
> 2
> 
> on a random SUSE box:
> $ find . -type f -perm -1 2>/dev/null | wc -l
>     124
> $ ls -l |egrep ^-..x | wc -l
>       1
> 
> (Errm: the numbers are the numbers of executable files in the /etc
> filesystem and directly in /etc, respectively...)
> 
> Thanks,
> 
> James.
> 
> [1] And cdrecord.conf: I'm not sure why that has to be executable...
> --
> E-mail address: james@ | When the revolution comes, we'll need a longer wall.
> westexe.demon.co.uk    |     -- Tom De Mulder
> 
> 
> 
> 
> --
> fedora-list mailing list
> fedora-list at redhat.com
> To unsubscribe: http://www.redhat.com/mailman/listinfo/fedora-list
>





More information about the fedora-list mailing list