Commit Graph

340 Commits

Author SHA1 Message Date
peter 80f533ce07 Do a "flush all" when disabling pf. This also changes the restart case
to do a "flush all", while the reload case will only reload the rules without
flushing anything.

Suggested by Miles Nordin.
2005-03-15 18:22:03 +00:00
lukem f198807ca5 Explicitly REQUIRE mountcritremote, since this uses awk. 2005-03-15 12:06:12 +00:00
tv 0a66272c73 Revert previous, for now. We don't umount filesystems in the shutdown
process (we're -- probably inappropriately -- waiting for the kernel to do
that at the end), so cgdconfig -U won't do much until that situation changes.
2005-03-02 19:09:22 +00:00
tv e32d4e2d39 Unconfigure cgd devices on shutdown, so that underlying layers (i.e.,
RAIDframe) are happier.
2005-03-02 12:14:47 +00:00
dsainty 7e7f191f7d Add a missing space in a comment 2004-12-30 09:32:13 +00:00
lukem eca6f3c39f * Conditionalize flushing of IPv4 vs IPv6 rules based on the existance
of the appropriate configuration file.
  Based on PR 28757 from Jason White.

* Add comments explaining why we flush separately from the reload
  (backwards compat with older ipf(8) binaries).
2004-12-23 03:31:54 +00:00
kleink c17d5db72f Add the `shutdown' keyword, giving racoon a chance to flush the SAD
upon termination.
2004-12-07 17:37:15 +00:00
christos 573e338f96 Don't try to chmod ptys if we have none. 2004-11-10 05:04:51 +00:00
lukem 4ffd3a5be3 Redo previous (rev 1.12) in a manner that allows this rc.d script to operate
correctly on ipf(8) from prior to 4.1.3 (where -Fa flushes both protocols)
and 4.1.3 (where -Fa only flushes the current protocol).
Fix from Kimmo Suominen, per private discussion.
2004-11-08 02:09:01 +00:00
lukem 1ecb0d140f Use 'load_rc_config_var CMD VAR' to set VAR for "foreign" rc.conf(5)
variables that may be set in /etc/rc.conf.d/CMD instead of /etc/rc.conf.
Fixes PR 20768 from Pavel Cahyna.
2004-10-12 14:51:03 +00:00
lukem 573992ef57 Implement reload, using "amq -f".
Suggested by Hauke Fath in PR 26589.
2004-10-12 13:44:45 +00:00
lukem d65dca170c Fix for /bin/ksh, from Jukka Salmi in PR 27232. 2004-10-12 13:23:44 +00:00
christos 6e9a790e1f Use new style command substitution. 2004-10-11 15:00:51 +00:00
lukem c73be7a88d Explicitly REQUIRE: rpcbind since these services directly use RPC... 2004-10-11 14:11:43 +00:00
lukem 6ede50a341 Use load_rc_config `basename chrootdirscript` in a subshell to determine
the rc.conf(5) setting for chrootdirscript, incase the configuration
for that is in /etc/rc.conf.d/chrootdirscript.
Fixes PR 26478 from Jukka Salmi.
2004-10-11 13:29:52 +00:00
lukem ac418f52f5 Explicitly flush (-Fa) rules when loading or reloading IPv4 and IPv6 rules,
rather than relying upon running "ipf -Fa" beforehand (which only flushes IPv4)
Should fix PR 26885 and PR 26857.
2004-09-09 00:33:03 +00:00
atatat c41b76304f Quieten stat(1) with the -q flag.
Addresses PR bin/26711.
2004-08-19 04:44:10 +00:00
mycroft 7d2e1537c5 Add an _rc_subr_loaded variable, set to ":" by rc.subr. Scripts can use this
for a speedup by doing:
$_rc_subr_loaded . /etc/rc.subr
2004-08-13 18:08:03 +00:00
atatat 8fb0a9f1ca Switch the check to see if the corresponding db file needs to be
rebuilt from "newer than" to "not older than".  The latter check also
manages to take into account cases where the db file doesn't yet exist
because the source is "not older than" something that doesn't yet
exist.
2004-08-08 17:41:15 +00:00
atatat e0fb433b4f Add one more check to the sendmail auto-start heuristic: check the
value of MTAHost in the submit.cf.  If it doesn't indicate localhost,
we probably don't need the sendmail listener.

Addresses PR bin/26391.
2004-07-22 03:36:29 +00:00
atatat 89fc8be761 Change the default settings for sendmail.
(1) The stock sendmail.cf will only listen on the loopback interface.
(2) The stock submit.cf specifally connects to "localhost." which
    should be less susceptible to being confused or looking confused.
(3) The smtp listener starts by default, if needed.  The setting in
    /etc/default/rc.conf is still "no", but rc.d/sendmail detects the
    default setting and will change it to yes if need is determined.

Need is defined as "nothing else seems to have been changed about the
mail configuration but we'd like locally originated and locally
destined mail to be delivered".  If you change, eg, mailer.conf to
point to postfix or some other MTA, sendmail will not start.
2004-07-15 03:47:18 +00:00
atatat 5f89bdd921 Make the directory into which crash dumps are saved into something
that can be controlled via rc.conf.  The default is, of course,
/var/crash.
2004-07-15 03:29:55 +00:00
lukem 20fd132b8d * Add BEFORE: SERVERS, so state is restored much earlier in the boot sequence.
* REQUIRE: isdnd, so this will be shutdown before that, to prevent
  future problem if isdnd eve gets an explicit "shutdown" keyword.

Per discussion with Martin Husemann.
2004-07-05 08:21:15 +00:00
martin ebdc55a49e Make sure "downinterfaces" comes first - this means on shutdown this
script will run before downinterfaces destroys all state we try to
save here.
2004-07-05 07:53:03 +00:00
tron 313b9c84ab Install "pf" and "pflogd". 2004-06-30 09:22:41 +00:00
itojun de1993c88e rc.d fragment for PF. Peter Postma 2004-06-29 04:48:28 +00:00
abs eb24f87047 add rcvar 2004-06-03 16:29:15 +00:00
abs d5fc55fa51 Add rcvar="quota" 2004-06-03 16:27:44 +00:00
christos 367e1200da create /dev/random when chrooted. 2004-05-21 15:40:22 +00:00
lukem b997a4053a Update the paths to the required_files configuration files for the
move from /usr/X11R6/lib/X11/<app> -> /etc/X11/<app>.
Resolves PR [misc/25613] from Jukka Salmi.
2004-05-17 23:41:27 +00:00
lukem ee04d88971 Consistently use CONFIGFILES & CONFIGLINKS (which enable the 'configinstall'
target) instead of using home-grown 'distribution' targets or using
FILES with the 'install' target.
Add some etc/ subdir Makefiles where appropriate.

XXX: some of etc/Makefile install-etc-files could be converted to CONFIGFILES.
2004-05-16 09:53:09 +00:00
schmonz c8dd377ead Add RCS Id. 2004-04-25 16:52:19 +00:00
keihan f672be074d s/netbsd.org/NetBSD.org/ 2004-04-23 10:59:47 +00:00
christos 1d0fe2e424 Whitespace fixes, some code re-factoring, and a bit more verbose messages. 2004-04-21 19:35:13 +00:00
dbj 48019a3a47 simply logic and flow of check_part function 2004-04-21 18:27:26 +00:00
dbj 1b003e4b0c abstract superblock field reading into shell function 2004-04-21 18:06:06 +00:00
dbj 115f147f20 add function for reporting verbose messages 2004-04-21 17:26:42 +00:00
dbj 496faa9025 tweak return value of check_part function 2004-04-21 17:07:47 +00:00
dbj 324ebbbef7 some minor shell programming tweaks recommended by christos
use [ -n ] instead of [ ! -z ]
use $() instead of ``
use just "$@" instead ${1+"$@"}
2004-04-21 17:02:41 +00:00
dbj bbf17112c5 use shell constructs and cat instead of sed since
sed may not be available early in the rc.d sequence
2004-04-21 16:12:31 +00:00
dbj 4fe7bbb7da enable rc.d fixsb script
initial testing suggests that it is working and I am confident it
will not cause irrevocable damage
2004-04-18 04:02:27 +00:00
dbj 1195d38f2f add support for turning off fixsb in rc.conf
default is fixsb=YES
2004-04-18 03:49:43 +00:00
dbj d328d71583 This rc.d script attempts to correct problems
which may have been introduced by booting a netbsd-current kernel
from between April of 2003 and January 2004. For more information
see <http://mail-index.NetBSD.org/current-users/2004/01/11/0022.html>
This script was developed as a response to NetBSD pr install/25138

This should not be added to the Makefile or the default install until
it has been further tested
2004-04-16 14:52:52 +00:00
lukem 68909c287b Store the full path to the /usr/sbin/postfix in $postfix_command
and use the latter postfix_op() to implement start/stop/reload.
(We generally use full paths in rc.d scripts.)  Problem noted by Bill Squier.
2004-04-08 06:15:27 +00:00
mrg f79db8d04e move ipmon's "-D" argument from "command_args" to "ipmon_flags" so that
passing an (optional) filename argument (that must come last) works fine
from $ipmon_flags.  from PR#25006.
2004-04-04 13:59:36 +00:00
fredb f6e9f3cb15 Backout last change. I failed to note that the problem described in
PR bin/24653 had already been fixed with revision 1.9 of this file.
2004-03-31 18:01:07 +00:00
fredb ee6be08283 Take account of the fact that "ntpd" writes it's pidfile after chroot().
Closes PR bin/24653.
2004-03-31 17:52:06 +00:00
jonb c384cda06a Add ssh_keygen_flags variable to rc.conf to allow users to set the
size of auto-generated keys if desired.
2004-02-18 17:36:34 +00:00
christos 0120b80220 add identd 2004-02-01 02:32:58 +00:00
christos 1359f873c4 new identd script 2004-01-31 21:50:45 +00:00