Commit graph

5737 commits

Author SHA1 Message Date
Hajimu UMEMOTO 72d27857dc Make a command for pkg_info changeable like pkg_version in
/etc/periodic/weekly/400.status-pkg to be friendly with pkgng.

MFC after:	1 week
2012-10-13 14:45:42 +00:00
Peter Wemm 5c0b56183b Point freebsd.org cluster machines to mx1 for their smarthost. 2012-10-11 20:46:04 +00:00
Hans Petter Selasky f36911a33c Regenerate usb.conf
MFC after:	1 week
2012-10-01 06:48:59 +00:00
Hans Petter Selasky 08f950a302 Make sure moused is exiting as quick as possible after that the
umsX character device returns a read error. Update devd.conf rules
to use "DEVFS" events which are generated after that the umsX
character device node has been created/destroyed, and then there
should be no need for moused to wait up to 10 seconds for umsX to
be ready. Opening umsX should not fail except if the kernel is low
on memory. In that case the user can replug the USB mouse or use
"usbconfig" to reset the device. In case of USB mouse devices,
moused should neither retry to open its character device,
once the first read error has happened. This is an indication
of device detach.

MFC after:	1 week
2012-09-24 17:13:33 +00:00
Jim Harris a724927cf3 Integrate nvmecontrol(8) into the amd64 and i386 builds.
This includes adding NVMe header files to /usr/include/dev/nvme.

Sponsored by:  Intel
2012-09-17 21:41:38 +00:00
Andriy Gapon 07dddf4e84 rc.d/power_profile: use recently added Cmax for cx_lowest
Trying to determine current lowest C-state after an AC event is racy
with C-states actually being changed by ACPI platform and kernel driver.

MFC after:	3 weeks
2012-09-11 06:25:10 +00:00
David E. O'Brien 8801556beb Simply things so that "#REQUIRE: FILESYSTEMS" means the file
systems are fully "ready to go".

'FILESYSTEMS' states: "This is a dummy dependency, for services which
require file systems to be mounted before starting."  However, we have
'var' which is was run after 'FILESYSTEMS' and can mount /var if it
already isn't mounted.  Furthermore, several scripts cannot use /var
until 'cleanvar' has done its thing.  Thus "FILESYSTEMS" hasn't really
meant all critical file systems are fully usable.
2012-09-11 05:04:59 +00:00
David E. O'Brien 7e71f1e85c Add postrandom. 2012-09-11 04:53:32 +00:00
Dag-Erling Smørgrav c2b4a4036b Add a configtest command.
Submitted by:	gjb@
MFC after:	1 week
2012-09-04 21:56:16 +00:00
David E. O'Brien 203b2f2fa4 * Rather than run the same 'ps' command twice, add 'kenv' which often
gives machine unique values from the firmware.
* The kernel is more likely to be unique than /bin/ls (but no need to
  stuff many megabytes into /dev/random, so hash it).
* Change ordering to give larger variance across reboots to reduce
  predictability.
2012-09-04 21:47:09 +00:00
David E. O'Brien b8ea11cf79 Correct style. 2012-08-22 23:44:12 +00:00
David E. O'Brien b7aeb5b281 * Reinstate r128059's consumption of our best entropy first.
r128060 for "hardware-supplied entropy" reversed this without reason,
  seems a typo.
* Isolate "better than nothing" implementation to a function.

Submitted by:	obrien & Arthur Mesh <arthurmesh@gmail.com>
Sponsored by:	Juniper Networks
2012-08-22 23:37:24 +00:00
David E. O'Brien 2719ba5d0f The entire comment block is now spell checked this time -- I promise. 2012-08-22 22:34:55 +00:00
Xin LI 9130580bbd Allow - be used in the name of a provider. Without this change it's not
possible to specify a gptid in geli_devices.
2012-08-22 22:17:35 +00:00
David E. O'Brien 89e7132797 Fix comment misspelling.
Submitted by:	kargl
2012-08-22 20:56:53 +00:00
David E. O'Brien a23ec70a4e Depend on the new 'postrandom' instead of random.
We need to limit the amount of time between consuming the entropy seeds
and removing it in case of a kernel panic.
2012-08-22 18:49:02 +00:00
David E. O'Brien 7e7fd6c88d Remove old entropy seeding after consumption initializing /dev/random PRNG.
Not doing so opens us up to replay attacks.

Submitted by:	Arthur Mesh <arthurmesh@gmail.com>
Sponsored by:	Juniper Networks
2012-08-22 18:43:21 +00:00
David E. O'Brien 849d3c12df Add dependencies based on security(7). 2012-08-22 18:35:17 +00:00
Xin LI 82607d1ec1 As of r232844 we no longer need the maxpoll 9 workaround.
MFC after:	3 days
2012-08-20 18:45:16 +00:00
Dimitry Andric 7ae0e2c9f0 Upgrade our copy of llvm/clang to trunk r162107. With thanks to
Benjamin Kramer and Joerg Sonnenberger for their input and fixes.
2012-08-20 18:33:03 +00:00
Jun Kuriyama 9b9bfdcc30 - Allow to pass extra parameters for each jails.
- To achieve above, convert jail(8) invocation to use new style
  command line "-c" flag.

Reviewed at:	freebsd-jail@
2012-08-19 08:15:32 +00:00
Hans Petter Selasky f167692215 Regenerate usb.conf
MFC after:	2 weeks
2012-08-05 11:53:16 +00:00
Devin Teske 41e0047a15 Revert SVN r238628 (mistake). 2012-07-19 22:41:00 +00:00
Devin Teske f316f2c30c Fix syntax errors (s/:=/:-/).
Reviewed by:	emaste (mentor)
Approved by:	emaste (mentor)
MFC after:	3 days
2012-07-19 22:33:13 +00:00
Maksim Yevmenkin 78cf63fc10 Allow to specify no source-address-selection policy
MFC after:	1 week
2012-07-19 15:36:36 +00:00
Joerg Wunsch 5cb470c830 Add share/examples/libusb20 to the list of directories. 2012-07-19 11:18:41 +00:00
Dag-Erling Smørgrav d256f21a9a Move -n ${_jail} before ${_flags} so that any -n options in ${_flags}
will override ours instead of the other way around.
2012-07-18 23:01:23 +00:00
Brooks Davis ba7f643097 MFP4 214344:
Tighten the regular expression that checks for an md /tmp such that
no /tmp mount and an md / isn't improperly matched.

Sponsored by:	DARPA/AFRL
2012-07-13 20:10:59 +00:00
Kevin Lo 1424b561e1 Whitespace nit 2012-07-13 06:46:09 +00:00
Hiroki Sato 5a6d2079d5 Fix a missing ";". 2012-07-09 20:11:32 +00:00
Hiroki Sato ef23194991 - Add IFT_L2VLAN (vlan(4)) support.
- Add -P option to support PID file.  When -a is specified /var/run/rarpd.pid
  is used, and when an interface is specified /var/run/rarpd.<ifname>.pid is
  used by default.
2012-07-09 08:11:16 +00:00
Hiroki Sato 8efbd296e0 Make ipfw0 logging pseudo-interface clonable. It can be created automatically
by $firewall_logif rc.conf(5) variable at boot time or manually by ifconfig(8)
after a boot.

Discussed on:	freebsd-ipfw@
2012-07-09 07:16:19 +00:00
Dag-Erling Smørgrav 7f8492ba48 Name jails automatically.
MFC after:	1 week
2012-07-04 13:37:44 +00:00
Sean Bruno 55fb7f3673 Revert r238004 as more review has come in and there is now a discussion
on how to best proceed.
2012-07-02 17:55:29 +00:00
Sean Bruno 7402aad3c7 Cosmetic display change of Cx states via cx_supported sysctl entries.
Adjust power_profile script to handle the new world order as well.

Some vendors are opting out of a C2 state and only defining C1 & C3.  This
leads the acpi_cpu display to indicate that the machine supports C1 & C2
which is caused by the (mis)use of the index of the cx_state array as the
ACPI_STATE_CX value.

e.g. the code was pretending that cx_state[i] would
always convert to i by subtracting 1.

cx_state[2] == ACPI_STATE_C3
cx_state[1] == ACPI_STATE_C2
cx_state[0] == ACPI_STATE_C1

however, on certain machines this would lead to
cx_state[1] == ACPI_STATE_C3
cx_state[0] == ACPI_STATE_C1

This didn't break anything but led to a display of:
 * dev.cpu.0.cx_supported: C1/1 C2/96

Instead of
 * dev.cpu.0.cx_supported: C1/1 C3/96

MFC after:	2 weeks
2012-07-02 16:57:13 +00:00
Christian Brueffer e19c9e1ed5 Similar to all.log, mention that /var/log/console.log has to be created and chmod'ed
to make logging work.

PR:		168889
Submitted by:	Robert Simmons <rsimmons0@gmail.com>
MFC after:	1 week
2012-07-01 12:34:19 +00:00
John Baldwin f0e130f7b7 Only output a list of file systems that need to be dumped if the system
has a non-empty dumpdates file.

Reviewed by:	brooks
MFC after:	1 week
2012-06-20 20:01:51 +00:00
David E. O'Brien 2e0c6b7ac0 Install filemon.h into /usr/include for userland consumption. 2012-06-20 00:09:47 +00:00
Dag-Erling Smørgrav 3acb6d160f Passive mode is the default, and has been for a while.
MFC after:	1 week
2012-06-19 14:47:07 +00:00
Dag-Erling Smørgrav b4f560356a Switch the default password hash from md5 to sha512.
MFC after:	1 week
2012-06-19 14:46:18 +00:00
Dag-Erling Smørgrav 7c5a921699 Finally nuke auth.conf, nine years after it was deprecated. The only
thing it was still used for was to set the "global default" password
hash.  Since the stock auth.conf contained nothing but comments, the
global default was actually the first algorithm in crypt(3)'s list,
which happens to be DES; I take the fact that nobody noticed as proof
that it was not used outside of crypt(3).

The only other use in our tree was in the Kerberos support code in
in tinyware's passwd(1).  I removed that code in an earlier commit;
it would not have compiled anyway, as it only supported Kerberos IV.

The auth_getval() function is now a stub that always returns NULL,
which has the same effect as a functional auth_getval() with an
empty auth.conf.

MFC after:	3 weeks
2012-06-12 17:02:53 +00:00
Eitan Adler d81a84a9bc Don't attempt to delete .sujournal in /tmp
PR:		conf/163828
Submitted by:	Tatsuki Makino <tatsuki_makino@hotmail.com>
Approved by:	cperciva
MFC after:	1 week
2012-05-30 03:51:46 +00:00
Martin Wilke 57eef2a0b2 - FreeBSD ships a KDE PAM module in base, but it's missing support for passwordless login (kde-np),
and it doesn't really belong in base system.

PR:		misc/167261
Submitted by:	avilla@
Approved by:	rwatson (mentor)
MFC after:	3 days
2012-05-30 03:10:22 +00:00
Hans Petter Selasky 9d569918e6 Regenerate usb.conf
MFC after:	3 days
2012-05-21 15:01:35 +00:00
George V. Neville-Neil 4d37a12307 Add support for our own DTrace scripts and those from the DTraceToolkit
to the build system.  FreeBSD written scripts are stored in
src/share and the toolkit scripts are brought from the cddl directory
into a working tree via install.

MFC after:	2 weeks
2012-05-18 16:40:15 +00:00
Grzegorz Bernacki 7f725bcd5c Import work done under project/nand (@235533) into head.
The NAND Flash environment consists of several distinct components:
  - NAND framework (drivers harness for NAND controllers and NAND chips)
  - NAND simulator (NANDsim)
  - NAND file system (NAND FS)
  - Companion tools and utilities
  - Documentation (manual pages)

This work is still experimental. Please use with caution.

Obtained from: Semihalf
Supported by:  FreeBSD Foundation, Juniper Networks
2012-05-17 10:11:18 +00:00
Eitan Adler 833cabc9a1 Submitted by: gavin, pjd
Approved by:	cperciva
MFC after:	3 days
2012-05-09 17:29:07 +00:00
John Baldwin 25d56d8dcc Display dropped transmit packets in the daily network interface output.
PR:		conf/165956
Submitted by:	Jeremy Chadwick
MFC after:	1 week
2012-05-07 15:41:31 +00:00
Stanislav Sedov 51506f39f4 - Change kfd rc script to be more conformant with rcNG conventions:
o change rcname to kfd;
  o move mandatory options to command_args;
  o add missing "shutdown" keyword;
  o fix require line.  Kfd doesn't really need to be started before
    daemons.

Suggested by:	dougb
2012-05-06 20:46:04 +00:00
John Baldwin b8cb2346fc - Don't log messages saying that accounting is being disabled and enabled
if the accounting log file is atomically replaced with a new file
  (such as during log rotation).
- Simplify accounting log rotation a bit.  There is no need to re-run
  accton(8) after renaming the new log file to it's real name.

PR:		kern/167321
Tested by:	Jeremy Chadwick
2012-05-02 14:25:39 +00:00
Dimitry Andric dff0c46c97 Upgrade our copy of llvm/clang to trunk r154661, in preparation of the
upcoming 3.1 release (expected in a few weeks).  Preliminary release
notes can be found at: <http://llvm.org/docs/ReleaseNotes.html>

MFC after:	2 weeks
2012-04-16 21:23:25 +00:00
Eitan Adler bf98096218 - remove the length shortening on the path
- make the default prompt a bit more like scp
- make the user show as root even when using 'su' instead of 'su -'
- the key bindings didn't hurt anything but likely hide a bug
- merge history instead of overwriting it

Submitted by:	gavin, joel
Approved by:	cperciva
2012-04-11 14:13:22 +00:00
Stanislav Sedov 7e2d4dcd24 - Add rc.d script for kfd, kerberos forwarded tickets daemon. 2012-04-10 09:27:41 +00:00
Ivan Voras 1c78ab7317 Add MySQL port 3306
Obtained from:	http://www.iana.org/assignments/port-numbers
MFC after:	1 week
2012-03-26 11:48:47 +00:00
Eitan Adler 7ba657625c Fix build by adding new directory to mtree in r233429
Submitted by:	flo
Approved by:	cperciva
MFC after:	1 week
2012-03-24 21:10:19 +00:00
Eitan Adler 1233083107 - Make the default values for tcsh more user friendly
- Add an examples file with many of the not accepted suggestions from the discussion

PR:		conf/160689
Reviewed by:	many
Discussed on:	current
Approved by:	cperciva
2012-03-24 18:43:18 +00:00
Sergey Kandaurov 1554a84e91 Clean up of fs/fifofs include directory after fifo.h removal.
Glanced by:	kib
2012-03-23 10:12:35 +00:00
Stanislav Sedov ae77177087 - Update FreeBSD Heimdal distribution to version 1.5.1. This also brings
several new kerberos related libraries and applications to FreeBSD:
  o kgetcred(1) allows one to manually get a ticket for a particular service.
  o kf(1) securily forwards ticket to another host through an authenticated
    and encrypted stream.
  o kcc(1) is an umbrella program around klist(1), kswitch(1), kgetcred(1)
    and other user kerberos operations. klist and kswitch are just symlinks
    to kcc(1) now.
  o kswitch(1) allows you to easily switch between kerberos credentials if
    you're running KCM.
  o hxtool(1) is a certificate management tool to use with PKINIT.
  o string2key(1) maps a password into key.
  o kdigest(8) is a userland tool to access the KDC's digest interface.
  o kimpersonate(8) creates a "fake" ticket for a service.

  We also now install manpages for some lirbaries that were not installed
  before, libheimntlm and libhx509.

- The new HEIMDAL version no longer supports Kerberos 4.  All users are
  recommended to switch to Kerberos 5.

- Weak ciphers are now disabled by default.  To enable DES support (used
  by telnet(8)), use "allow_weak_crypto" option in krb5.conf.

- libtelnet, pam_ksu and pam_krb5 are now compiled with error on warnings
  disabled due to the function they use (krb5_get_err_text(3)) being
  deprecated.  I plan to work on this next.

- Heimdal's KDC now require sqlite to operate.  We use the bundled version
  and install it as libheimsqlite.  If some other FreeBSD components will
  require it in the future we can rename it to libbsdsqlite and use for these
  components as well.

- This is not a latest Heimdal version, the new one was released while I was
  working on the update.  I will update it to 1.5.2 soon, as it fixes some
  important bugs and security issues.
2012-03-22 08:48:42 +00:00
Gleb Smirnoff 004cb95bae Rotate auth.log and messages at the beginning of a year. Otherwise,
daily security checks 800.loginfail and 900.tcpwrap may produce
false positive alerts.
2012-03-19 09:30:40 +00:00
Hans Petter Selasky d2c5981310 Regenerate usb.conf to use new -n option when doing kldload.
MFC after:	1 week
2012-03-18 09:52:54 +00:00
Martin Matuska 9f6e964d17 Unhide /dev/zfs in devfsrules_jail.
The /dev/zfs device is required for managing jailed ZFS datasets.

Discussed with:	pjd, jamie
MFC after:	1 week
2012-03-16 21:30:26 +00:00
Ed Schouten 4c2c7b2c94 Make init(8) slightly more robust when /dev/console is missing.
If the environment doesn't offer a working /dev/console, the existing
version of init(8) will simply refuse running rc(8) scripts. This means
you'll only have a system running init(8) and nothing else.

Change the code to do the following:

- Open /dev/console like we used to do, but make it more robust to use
  O_NONBLOCK to prevent blocking on a carrier.
- If this fails, use /dev/null as stdin and /var/log/init.log as stdout
  and stderr.
- If even this fails, use /dev/null as stdin, stdout and stderr.

So why us this useful? Well, if you remove the `getpid() == 1' check in
main(), you can now use init(8) inside jails to properly execute rc(8).
It still requires some polishing, as existing tools assume init(8) has
PID 1.

Also it is now possible to use use init(8) on `headless' devices that
don't even have a serial boot console.
2012-03-14 16:22:09 +00:00
Ed Schouten 93bd0cdedd Hide stty(1) errors.
If rc(8) is executed without using a TTY, this error appears at the
beginning:

	stty: stdin isn't a terminal

Because this is to be expected and of course not harmful, it is better
to simply hide the error message.

MFC after:	1 week
2012-03-14 16:10:39 +00:00
Bjoern A. Zeeb 9f0b9a0853 Rather than printing the output from route add for all FIBs just print them
for the default FIB followed by a statement with a list of FIB numbers for
all the other FIBs we install the routes for.

Request by:	kib (to make it less noisy)
Tested by:	kib
MFC after:	3 days
2012-03-04 18:53:35 +00:00
David Chisnall a8ed63bb3d Reapply 227753 (xlocale cleanup), plus some fixes so that it passes build
universe with gcc.

Approved by:	dim (mentor)
2012-03-04 15:31:13 +00:00
Justin Hibbits 3cc28bd9bf Add backlight control to ATI-graphics PowerBooks and iBooks.
Approved by:	nwhitehorn (mentor)
MFC after:	1 week
2012-02-26 13:45:25 +00:00
Xin LI 90de8d2a65 Put the signal trap output to standard error instead of standard output.
Without this change, pressing ^T could result in rc.d script putting
junk strings like:

	Script <filename> running

in configuration files when redirecting standard output to these files.

MFC after:	2 weeks
2012-02-18 00:46:18 +00:00
Doug Barton 81ed1a1e1b Increase the default shutdown timer to 90 seconds. This will allow
certain systems that take a long time to shut down, without adversely
affecting things that shut down quickly. It's also 30 seconds less than
the default hard limit of 120 seconds in kern.init_shutdown_timeout.

PR:		conf/109272
Submitted by:	Radim Kolar SF.NET <hsn@sendmail.cz>
2012-02-17 07:59:37 +00:00
Bjoern A. Zeeb e17d7df80d Merge multi-FIB IPv6 support from projects/multi-fibv6/head/:
Extend the so far IPv4-only support for multiple routing tables (FIBs)
introduced in r178888 to IPv6 providing feature parity.

This includes an extended rtalloc(9) KPI for IPv6, the necessary
adjustments to the network stack, and user land support as in netstat.

Sponsored by:	Cisco Systems, Inc.
Reviewed by:	melifaro (basically)
MFC after:	10 days
2012-02-17 02:39:58 +00:00
Eitan Adler f85a4a2977 Style: prefer the use of line continuations to +=
Requested by:	marcel, dougb, bde
Approved by:	cperciva
MFC after:	3 days
2012-02-17 01:21:08 +00:00
Bjoern A. Zeeb 9dba179d5e IFC @231845
Sponsored by:	Cisco Systems, Inc.
2012-02-17 00:27:48 +00:00
Dimitry Andric b74cf6dcf1 Revert r231673 and r231682 for now, until we can run a full make
universe with them.  Sorry for the breakage.

Pointy hat to:	     me and brooks
2012-02-14 21:48:46 +00:00
David Chisnall 82dd5016bd Cleanup of xlocale:
- Address performance regressions encountered by das@ by caching per-thread
  data in TLS where available.
- Add a __NO_TLS flag to cdefs.h to indicate where not available.
- Reorganise the xlocale.h definitions into xlocale/*.h so that they can be
  included from multiple places.
- Export the POSIX2008 subset of xlocale when POSIX2008 says it should be
  exported, independently of whether xlocale.h is included.
- Fix the bug where programs using ctype functions always assumed ASCII unless
  recompiled.
- Fix some style(9) violations.

Reviewed by:	brooks (mentor)
Approved by:	dim (mentor)
2012-02-14 12:03:23 +00:00
Doug Barton 20ceedfb69 Fix various issues with the NFS and RPC related scripts:
1. Add new functionality to the force_depend method to incorporate the
   tests for whether the service is enabled and/or already running.
2. Add a new option to bypass checking only that the service is enabled
   at boot time, and always check if it is running.
3. Use this new functionality to greatly simplify the rc.d scripts that
   use force_depend.
4. Add a force_depend for statd in lockd
5. Remove the check that either nfs_server or nfs_client is _enable'd
   from statd and lockd. This was always overkill, and prevented using
   the {one|force}start options, as well as stop'ing on the command line.
6. The yp* scripts had some of their arguments in various weird orders.
   Bring them into line with the model.
7. If mountd fails to create /var/db/mountdtab, err out.

Ideas, suggestions, and/or review from delphij and jilles.
Pointy hats are completely my responsibility however.
2012-02-14 10:51:24 +00:00
Hans Petter Selasky d45fe33ddc Re-generate /etc/devd/usb.conf
MFC after:	1 day
2012-02-13 07:47:16 +00:00
Andriy Gapon 5a197b4612 start watchdogd before most of other daemons/servers
The main benefit is that watchdogd would shutdown after most of other
daemons/servers and thus, for example, would remedy a system hang caused
by unlucky X server shutdown.

Reviewed by:	dougb (earlier version)
MFC after:	2 weeks
2012-02-12 14:58:50 +00:00
Ed Schouten 18568efd19 Avoid using BEFORE in the utx rc script.
Requested by:	dougb
2012-02-12 07:45:48 +00:00
Ed Schouten c21ae3a403 Move utmpx handling out of init(8).
This has the following advantages:

- During boot, the BOOT_TIME record is now written right after the file
  systems become writable, but before users are allowed to log in. This
  means that they can't cause `hidden logins' by logging in right before
  init(8) kicks in.

- The pututxline(3) function may potentially block on file locking,
  though this is very rare to occur. By placing it in an rc script, the
  user can still kill it with ^C if needed.

- Most importantly: jails don't use init(8). This means that a force
  reboot of a system running jails will leave stale entries in the
  accounting database of the jails individually.
2012-02-11 20:47:16 +00:00
Doug Barton f7451733fb In the days before r208307 addswap was running early in the second stage
of rcorder. Somehow in the intervening period addswap got moved to the
very end, which is almost certainly not what we want.

This change moves it to right after kld so that for users who need it,
they'll get it ASAP.
2012-02-11 06:21:16 +00:00
Eitan Adler b169a33235 Make etc/Makefile more conflict resistant
PR:		conf/163789
Submitted by:	gcooper (iXsystems)
Approved by:	cperciva
MFC after:	3 days
2012-02-09 20:44:20 +00:00
Jung-uk Kim cc43a851d2 Revert r211288 and move the logic to the acpi_timer itself. 2012-02-08 20:31:42 +00:00
Doug Barton 95208e20d0 As it stands right now, the default devfs rulesets are only loaded as a
side effect of something else using them. If they haven't been loaded
already but you want to use them, say for configuring a jail, you're out
of luck.

So add a knob to always load the default rulesets. While I'm here document
the other devfs_ knobs in rc.conf.5.
2012-02-08 08:52:40 +00:00
Glen Barber 2f1602a7d1 Add an option to 404.status-zfs (enabled by default) to list all
zfs pools on the system.

While here, document daily_status_zfs_enable in periodic.conf(5).

Discussed on:	-fs [1]
Reviewed by:	netchild [1]
Approved by:	jhb
MFC after:	1 week

[1] - http://lists.freebsd.org/pipermail/freebsd-fs/2011-June/011869.html
2012-02-08 00:08:21 +00:00
Hiroki Sato 86b84592a8 Fix $ipv6_network_interfaces handling in rc.d/routing. It could fail when
it was set to "auto", for example.

MFC after:	3 days
2012-02-04 18:14:49 +00:00
Bjoern A. Zeeb b202f3dc89 Install the IPv6 reject routes we do for the default FIB to all FIBs.
Sponsored by:	Cisco Systems, Inc.
2012-02-03 15:31:47 +00:00
Hiroki Sato d830cea6b7 Perform IPv6 DAD only in ifn_start. 2012-01-29 08:33:34 +00:00
Justin Hibbits c0c8fcb92d Remove the notify match from a couple devd apple events, the events don't
include notify tags.

Approved by:	nwhitehorn (mentor)
MFC after:	3 days
2012-01-28 02:52:22 +00:00
Hiroki Sato f6e5ba31d2 Fix several glitches in IPv6-related knobs:
- ipv6_enable + ipv6_gateway_enable should unset ACCEPT_RTADV by default for
  backward compatibility.

- Configurations in ipv6_prefix_IF should be recognized even if there is no
  ifconfig_IF_ipv6.

- DAD wait should be performed at once, not on a per-interface basis, if
  possible.  This fixes an issue that a system with a lot of IPv6-capable
  interfaces takes too long for booting.

MFC after:	1 week
2012-01-22 10:57:32 +00:00
Brooks Davis 2dd3bcd48d When creating the jails /dev/log symlink, do it by full path to avoid
creating stray "log" symlinks if the mount fails.  That apparently
happens in some ezjail configs.

PR:		conf/143084
Submitted by:	Dirk Engling <erdgeist at erdgeist.org>
Reviewed by:	simon
MFC after:	2 weeks
2012-01-20 22:55:19 +00:00
Eygene Ryabinkin edad1b5ba4 /etc/netstart: remove invocation of dhclient
dhclient is no longer a real service, it is a helper script
for /etc/rc.d/netif and devd.  Its direct invocation isn't
needed to bring the network up.

Approved by: jhb
2012-01-20 17:25:15 +00:00
Eygene Ryabinkin 1eea470950 dhclient: don't use syslog for logging non-DHCP interface errors
We should show the error to user, but it doesn't deserve syslog.

Approved by: jhb
2012-01-20 17:19:50 +00:00
Doug Barton 72fc1aafe2 If we're booting there is no need to waste time determining if the service
is running or not.

PR:		conf/150752
Submitted by:	YIN Xiaofeng <75394094@qq.com>
2012-01-20 10:31:27 +00:00
Doug Barton 61d4638e52 Now that its callers have been udpated, remove set_rcvar().
The concept of set_rcvar() was nice in theory, but the forks
it creates are a drag on the startup process, which is especially
noticeable on slower systems, such as embedded ones.
2012-01-14 08:59:02 +00:00
Doug Barton 801c438304 Prepare for the removal of set_rcvar() by changing the rcvar=
assignments to the literal values it would have returned.

The concept of set_rcvar() was nice in theory, but the forks
it creates are a drag on the startup process, which is especially
noticeable on slower systems, such as embedded ones.

During the discussion on freebsd-rc@ a preference was expressed for
using ${name}_enable instead of the literal values. However the
code portability concept doesn't really apply since there are so
many other places where the literal name has to be searched for
and replaced. Also, using the literal value is also a tiny bit
faster than dereferencing the variables, and every little bit helps.
2012-01-14 02:18:41 +00:00
Eygene Ryabinkin 0113cca483 rc.d: document 'quiet' prefix and fix dhclient/devd interaction
Document the current semantics of the 'quiet' command prefix
in the rc.subr(8).

Fix dhclient rc.d script: it should not call err() for
non-DHCP-enabled interface when it is called from devd, because the
latter just blindly calls 'service dhclient quietstart' on each "link
up" event.

Since the 'quietstart' will silence the message "Cannot 'start' <foo>.
Set <foo>_enable to YES in /etc/rc.conf or use 'onestart' instead of
'start'." and running dhclient on the non-DHCP-enabled interface is
the same thing as running the service <foo> without <foo>_enable set,
such modification is in sync with the current semantics of the 'quiet'
prefix.

Approved by: glebius
Reviewed by: freebsd-rc list
MFC after:	2 weeks
2012-01-12 06:48:11 +00:00
Gleb Smirnoff 5c39f7bdeb Bunch of fixes to pfsync(4) module load/unload:
o Make the pfsync.ko actually usable. Before this change loading it
  didn't register protosw, so was a nop. However, a module /boot/kernel
  did confused users.
o Rewrite the way we are joining multicast group:
  - Move multicast initialization/destruction to separate functions.
  - Don't allocate memory if we aren't going to join a multicast group.
  - Use modern API for joining/leaving multicast group.
  - Now the utterly wrong pfsync_ifdetach() isn't needed.
o Move module initialization from SYSINIT(9) to moduledata_t method.
o Refuse to unload module, unless asked forcibly.
o Improve a bit some FreeBSD porting code:
  - Use separate malloc type.
  - Simplify swi sheduling.

This change is probably wrong from VIMAGE viewpoint, however pfsync
wasn't VIMAGE-correct before this change, too.

Glanced at by:	bz
2012-01-09 08:50:22 +00:00
Doug Barton a194b02d88 There is no longer a need to abstract ${rcvar_manpage} as we are not
attempting to maintain compatibility with NetBSD for some years now.
2012-01-08 20:25:29 +00:00
Ulrich Spörlein 081dc98788 Spelling fixes for etc/ 2012-01-07 16:10:32 +00:00
Pawel Jakub Dawidek e3bf08680d Add 'nojail' keyword as auditd(8) can't really do anything useful when
inside a jail.

Discussed with:	rwatson
MFC after:	1 week
2012-01-06 14:00:31 +00:00
Pawel Jakub Dawidek 04d8001793 - Put one file into one line. This makes keeping local changes and merging
with FreeBSD easier for vendors.
- For optional files use variables starting with underscore.

Both changes make rc.d/Makefile look similar to sys/modules/Makefile.

Reviewed by:	dim
2011-12-15 21:06:37 +00:00
Gleb Smirnoff 84516ac070 Add compatibility support for specifing IPv4 aliases in
rc.conf without the "inet" keyword.

Obtained from:	hrs
2011-12-13 14:36:04 +00:00
Justin Hibbits 23ab37cb82 Fix style(9) issues from r228270.
Approved by:	nwhitehorn (mentor)
2011-12-05 14:13:21 +00:00
Justin Hibbits 6431ede397 Add a devd notification for closing/opening the lid on PowerBooks and iBooks.
Approved by:	nwhitehorn (mentor)
2011-12-05 00:12:10 +00:00
David E. O'Brien 59509bae0a Ensure kldxref is run first. Currently both 'kldxref' and 'kld' depend
on "FILESYSTEMS" and 'kld' is being run 8 scripts ahead of 'kldxref'.

Reported by:	dhw
2011-12-01 22:50:10 +00:00
David Chisnall 7a98470824 Import libc++ / libcxxrt into base. Not build by default yet (use
MK_LIBCPLUSPLUS=yes to enable).  This is a work-in-progress.  It works for
me, but is not guaranteed to work for anyone else and may eat your dog.

To build C++ using libc++, add -stdlib=libc++ to your CXX and LD flags.

Bug reports welcome, bug fixes even more welcome...

Approved by:	dim (mentor)
2011-11-25 20:59:04 +00:00
Gleb Smirnoff 74ffd254b4 Better use pkill(1) in last commit.
Submitted by:	pjd
2011-11-21 12:23:22 +00:00
Gleb Smirnoff 4ccbfb3f84 On some laptops it is important to re-open /dev/psm after resume. moused(8)
was capable to do this upon SIGHUP for more than a decade. Automate this
via rc.resume in default installation.
2011-11-15 12:59:07 +00:00
Doug Barton 398955cd68 The default setting, daily_accounting_compress="NO", was causing
only 1 old file to be saved, so fix this. Problem raised in the PR,
but actually required a different solution.

While I'm here, fix a very old off-by-one error causing 1 more file
than specified in daily_accounting_save to be saved because acct.0
was not taken into account (pun intended). Change that, and use a more
thorough method of finding old files to delete. Partly just because this
is the right thing to do, but also to silently fix the extra log that
would have been left behind forever with the previous method.

PR:		conf/160848
Submitted by:	Andrey Zonov <andrey@zonov.org>
2011-11-13 03:01:58 +00:00
Jilles Tjoelker e60150fafa rc.d: Eliminate some unnecessary non-POSIX constructs:
* set - ...
 * empty braces
 * ^ in character class
2011-11-08 23:02:32 +00:00
Dimitry Andric 66aa9b8dc9 Whenever you boot with nfsv4_server_enable=NO (the default) in rc.conf,
the /etc/rc.d/nfsd script sets vfs.nfsd.server_max_nfsvers to 3.

Then, when you set nfsv4_server_enable=YES in rc.conf, and restart nfsd
via the rc.d script, without rebooting, the sysctl does *not* get reset
to max version 4, so NFSv4 still doesn't work.

Fix this by explicitly setting vfs.nfsd.server_max_nfsvers to 4 when
NFSv4 is requested.

I also added resetting of the nfs_privport sysctls, since this has the
same issue: nfs_reserved_port_only=YES in rc.conf sets the nfs_privport
sysctl to 1, but in the other case, the sysctl doesn't get reset to 0.

Reviewed by:	rmacklem
Silence from:	rc@
MFC after:	3 days
2011-11-05 16:47:47 +00:00
Eygene Ryabinkin 0c4b17e1e7 Fix handling of rc_force in /etc/rc.d/dhclient
Variable 'rc_force' is accessible only at the time of rc_run_command,
so it can't be examined from the script's main code.

Spotted by:	hrs
Reviewed by:	hrs, des
Approved by:	des
MFC after:	2 weeks
2011-10-28 06:03:38 +00:00
Xin LI 8017fd8eb9 Increase default scrub threshold from 30 days to 5 weeks. Using
whole weeks makes it easier to predicate when the scrub would
happen.

MFC after:	1 week
2011-10-27 21:25:41 +00:00
Gavin Atkinson 349f3d11fb Remove example for linking /dev/vga to /dev/ttyv0, this hasn't been
required since X version 4.3.0.

PR:		conf/161847
Submitted by:	eadler
MFC after:	2 weeks
2011-10-27 20:39:20 +00:00
Gavin Atkinson 58fdb93577 Update the example rules in devfs.conf to reflect the changes since ATA_CAM.
While here, add another example rule, as many applications these days
expect to find /dev/dvd instead.

MFC after:	3 days
2011-10-27 20:35:21 +00:00
Hiroki Sato 0321b694c7 - Add support for a "!" character in regex matching in devd(8). It inverts
the logic (true/false) of the matching.

- Add "!usbus[0-9]+" to IFNET ATTACH notification handler in the default
  devd.conf to prevent rc.d/netif from running when usbus[0-9]+ is attached.

Reviewed by:	imp
2011-10-26 02:11:28 +00:00
Martin Matuska 4d428b10ae Correctly reassign copyright of etc/rc.d/static_ndp back to delphij@
as the project itself is no legal entity

Reported by:	Joe Dahl <joel@vnode.se>
MFC after:	3 days
2011-10-23 10:17:42 +00:00
Martin Matuska dbedf61ce3 Add etc/rc.d/static_ndp, analogous to etc/rc.d/static_arp.
Make sure that static ARP and NDP bindings are set before NETWORKING.

As static_ndp is based on static_arp, pass copyright to the project with
permission of the original author (delphij@).

Reviewed by:	delphij@FreeBSD.org
MFC after:	3 days
2011-10-23 09:08:42 +00:00
Hiroki Sato dec80d129b Add support for removing addresses added by ipv6_prefix_hostid_addr_up()
upon rc.d/netif stop.
2011-10-23 07:37:36 +00:00
Hiroki Sato 089ff57221 Fix an issue that 127/8 is not configured when $ifconfig_DEFAULT is not empty.
Spotted by:	ume
2011-10-23 05:56:59 +00:00
Hans Petter Selasky c8eeb97178 Add new USB IDs to RUN driver. Update usb.conf.
PR:		usb/161798
MFC after:	3 days
2011-10-19 10:09:01 +00:00
Stefan Eßer 8d68b75b54 Add missing default values for daily/800.scrub-zfs for documentation
purposes. No functional change, since all parameters are set to their
default values.
MFC after:	1 week
2011-10-17 14:37:24 +00:00
Stefan Eßer 3efd8ccdb5 Fix error message in case the backup storage directory does not exist and
cannot be created ($daily_backup_pkgdb_dbdir -> $daily_backup_pkgdb_dir).
MFC after:	1 week
2011-10-17 14:33:41 +00:00
Dag-Erling Smørgrav 32ca8e078d The rc_force test was inverted in the previous commit, so that dhclient ran
for interfaces which were not configured for DHCP *unless* rc_force was set;
the correct logic is to run dhclient for those interfaces *only if* rc_force
is set.

Broken by:	des@
Noticed by:	everybody and his dog
Submitted by:	rea@
PR:		bin/161733
2011-10-17 13:05:57 +00:00
Nathan Whitehorn b6faf3cfdb Add support for special keys (volume/brightness/eject) on Apple laptops with
ADB keyboards.

Submitted by:	Justin Hibbits <jrh29 at alumni dot cwru dot edu>
MFC after:	9.0-RELEASE
2011-10-16 21:01:42 +00:00
Dag-Erling Smørgrav 23f39c906b Make dhclient use a pid file. Modify the rc script accordingly; while
there, clean it up and add some error checks.

Glanced at by:	brooks@
MFC after:	3 weeks
2011-10-13 17:20:45 +00:00
Colin Percival b0efac1ceb Now that the portsnap buildbox is generating the raw bits for INDEX-9,
add it to the set of INDEX files built by portsnap.
2011-10-12 03:29:12 +00:00
Stanislav Sedov 7c450da7b4 - Import Heimdal 1.5 distribution. 2011-10-05 07:23:29 +00:00
Dimitry Andric 324d7156d7 Revive the LLVM and Clang license files, which were removed in my
too-thorough cleanup of unused files, in r213695.  Also make sure these
get installed under /usr/share/doc.

Submitted by:	rwatson, brooks
Pointy hat to:	dim
MFC after:	3 days
2011-09-29 18:12:40 +00:00
Stanislav Sedov 31f1e9c17f - Flatten the vendor heimdal tree. 2011-09-29 05:23:57 +00:00
Warren Block 762f55cd5f Fix a confusing sentence. [1]
Other wording tweaks.

Reviewed by:	imp [1]
Approved by:	gjb
2011-09-29 03:37:42 +00:00
Xin LI 89b1da1ba2 Test if the interface is afif in dhcpif() and syncdhcpif(), as
done in ipv6_autoconfif.

Reviewed by:	hrs (freebsd-rc@)
MFC after:	1 week
2011-09-28 19:01:15 +00:00
Konstantin Belousov a01fdfcef1 Install ciss(4) ioctl header (together with other .h files from sys/dev/ciss).
PR:	kern/109813
Discussued with:	Alex Samorukov <samm os2 kiev ua>
	(smartmontools maintainer)
MFC after:	1 week
2011-09-27 12:14:43 +00:00
Hiroki Sato 04303fd864 Use REQUIRE: line to reorder rc.d/bridge instead of BEFORE: line.
Pointed out by:	dougb
Approved by:	re (bz)
2011-09-20 00:37:35 +00:00
Hiroki Sato 33b9d9a8d2 Use resolvconf(8) to create /etc/resolv.conf, not directly overwrite it.
Approved by:	re (kib)
2011-09-19 15:56:50 +00:00
Hiroki Sato f8c5f6a6b8 Fix the script order to run rc.d/bridge after the initial network
interface configuration and before running network daemons.

Approved by:	re (kib)
2011-09-19 15:55:53 +00:00
Jaakko Heinonen 3fb4fa3574 Expose "log" in the default devfs rules. /etc/rc.d/jail creates /dev/log
as a symbolic link.

PR:		conf/160711
Submitted by:	Jase Thew
Approved by:	re (kib)
MFC after:	1 week
2011-09-15 13:32:43 +00:00
Doug Barton 073d48133f Correct the RFC number for the description of IPv6 privacy addressing
Reviewed by:	bz
Approved by:	re (kib)
2011-09-15 09:22:49 +00:00
Christian Brueffer 3ea459713b Minor spelling, wording and punctuation fixes in comments.
PR:		155984
Submitted by:	gcooper
Approved by:	re (kib)
MFC after:	1 week
2011-09-14 20:13:10 +00:00
Hiroki Sato d4358e709f - Add an warning when ifconfig_IF_ipv6 has no inet6 keyword in front
of an IPv6 address. (r225489)

- Use eval for ${ifconfig_args} to fix an issue fixed in r223506. (r225489)

Approved by:	re (bz)
2011-09-13 00:09:47 +00:00
Hiroki Sato 049087a0f3 Add $ipv6_cpe_wanif to enable functionality required for IPv6 CPE
(r225485).  When setting an interface name to it, the following
configurations will be enabled:

 1. "no_radr" is set to all IPv6 interfaces automatically.

 2. "-no_radr accept_rtadv" will be set only for $ipv6_cpe_wanif.  This is
    done just before evaluating $ifconfig_IF_ipv6 in the rc.d scripts (this
    means you can manually supersede this configuration if necessary).

 3. The node will add RA-sending routers to the default router list
    even if net.inet6.ip6.forwarding=1.

This mode is added to conform to RFC 6204 (a router which connects
the end-user network to a service provider network).  To enable
packet forwarding, you still need to set ipv6_gateway_enable=YES.

Note that accepting router entries into the default router list when
packet forwarding capability and a routing daemon are enabled can
result in messing up the routing table.  To minimize such unexpected
behaviors, "no_radr" is set on all interfaces but $ipv6_cpe_wanif.

Approved by:	re (bz)
2011-09-13 00:06:11 +00:00
Xin LI 4144951277 Sync pf.os with OpenBSD:
- Update OpenBSD fingerprints through OpenBSD 4.9
 - Fix typos.

Obtained from:	OpenBSD
MFC after:	2 weeks
Approved by:	re (kib)
2011-09-08 23:46:07 +00:00
Nathan Whitehorn 4cefd5cf3e Fix path to the handbook and provide a hint about how to install it if it
was not added at installation time.

Approved by:	re (blackend)
2011-08-26 14:05:48 +00:00
Xin LI aefb9fe04f Honor WITHOUT_IPX when installing etc/rc.d/ipxrouted.
MFC after:	1 week
Approved by:	re (kib)
2011-08-23 19:29:11 +00:00
Doug Barton 4116c8e738 Revert r224760, and enhance the sed patterns from r224659 to comment out
the _compat entries in the WITHOUT_NIS case rather then delete them.

Approved by:	re (kib)
2011-08-10 20:52:02 +00:00
Doug Barton c2aedca43b Rather than edit the nsswitch.conf file based on ${MK_NIS} == "no"
comment out the NIS _compat options by default, but leave them in
the file for the convenience of users who want to enable it.

Update the comment in the file accordingly.

Reviewed by:	ed
Approved by:	re (hrs)
2011-08-06 09:16:53 +00:00
Ed Schouten b41afd430d Remove NIS entries from /etc/nsswitch.conf for WITHOUT_NIS.
We already modify various configuration files in /etc based on build
configuration. This is not done for nsswitch.conf right now when setting
WITHOUT_NIS. This breaks various utilities, including crond, that depend
on working databases.

Approved by:	re (kib)
MFC after:	1 month
2011-08-05 17:33:12 +00:00
Doug Barton ab1779e30e Revert the apparently-unecessary module_path twiddling from r223917
Approved by:	re (kib)
2011-07-22 21:08:19 +00:00
Jilles Tjoelker 068c02de6d rc.d/routing: Fix ugly output with additional routing options.
Print a separate "Additional routing options" line for each address family
which has additional options, so that it does not get mixed up with the
output from adding routes.

This also reverts r224048 which added newlines to two arbitrary routing
options.
2011-07-17 14:52:55 +00:00
Doug Barton 75f93b2483 Commemorate the release of RFC 6303 by updating the comments regarding
our default empty zones.  No functional changes.
2011-07-17 06:20:47 +00:00
Doug Barton 3fed94a85e Pick up the 2011-06-08 update to this file, the addition of an IPv6
address for D.
2011-07-17 06:05:44 +00:00
Kevin Lo d99dc333db Remove "-n" from echo
Reviewed by:	dougb
2011-07-15 01:59:08 +00:00
Adrian Chadd eff1a1bc13 More Japan regulatory domain fixes:
* Add HT40 entries for the two new Japan bands
* Fix a channel separation bug in one of the new bands I introduced
  in a previous commit.
2011-07-14 05:49:35 +00:00
Adrian Chadd 7a9a76167a Japan regulatory domain update #1 - sync with CRDA entries.
Specifics:

* add 4920MHz-4980MHz for 11a and 11n/HT20
* add 5040MHz-5080MHz for 11a and 11n/HT20
* add 5500MHz-5700MHz for 11a and 11n/HT20 (DFS needed)
* add 5500MHz-5680MHz for 11n/HT40 (DFS needed)

TODO:

* add correct HT40 bands for 4920-4980 and 5040-5080

For the curious:

There's been many revisions to the Japan regulatory rules.
Apparently, the requirements require old cards certified on a previous
version of the rules to obey the older rules, not the newer rules.

The regdomain.xml outlines the -current- restrictions.

The card driver (eg the ath_hal regulatory domain code) may include
previous revisions of the Japan rules.

The ath_hal regdomain code populates the initial channel list based on
what the EEPROM indicates is possible. The regdomain.xml database imposes
further restrictions on this.

So regdomain.xml only needs to have the -current- rules. If the card
was certified on an earlier set of JP rules, it may only support a subset
of those channels - these are calculated at device attach and this
restricted list is kicked to net80211. regdomain.xml operates on -this-
list of channels.

And thus, the correct regulatory behaviour for Japan is handled with only
one regdomain.xml Japan database entry.

(phew.)

Obtained from:	Linux wireless-regdb
2011-07-14 05:19:28 +00:00
Doug Barton c2d900ef50 Make sure we load kernel modules from the same path as the running kernel 2011-07-10 23:47:03 +00:00
Rick Macklem 1e2cac7b7f Delete the /etc/rc.d/nfsserver script, since it is no
longer used by /etc/rc.d/nfsd and it is no longer necessary
to load the old nfs server by default, when nfs_server_enable="YES".

Tested by:	sgk at troutmask.apl.washington.edu
Reviewed by:	rc (Andrzej Tobola)
2011-07-08 00:49:50 +00:00
Rick Macklem c4c07ee035 Fix the /etc/rc.d/nfsd script so that it no longer uses
the /etc/rc.d/nfsserver script to load the old nfs server
module.

Tested by:	sgk at troutmask.apl.washington.edu
Reviewed by:	rc (hrs)
2011-07-07 20:59:42 +00:00
Sergey Kandaurov 1bb5e90ffd Run load_rc_config before stop_cmd definition, so that ${quotaoff_flags}
is correctly expanded inside stop_cmd instead of getting nothing.

PR:		conf/157687
Reported by:	Dmitry Banschikov <d.banschikov peterhost ru>
MFC after:	1 week
2011-06-28 14:26:34 +00:00
Hans Petter Selasky 88bf23ef94 Regenerate usb.conf after r223566. 2011-06-27 20:32:19 +00:00
Adrian Chadd 3b34e0a097 .. this wasn't supposed to be committed! sorry. 2011-06-26 14:29:49 +00:00
Gavin Atkinson 16169457f0 The SMCWUSBG is a zyd(4) device, not an uath(4) device. Remove from the
latter.

It appears that the addition to uath(4) came in through PR kern/135009,
which had tested another device, the SMCWUSBTG2, successfully with uath(4)
and included the SMCWUSBG as it "has the same chipset".  I can find no
other evidence that these two do actually share the same chipset.  Moreover,
Linux treats the SMCWUSBG as a zyd(4) device also.

This reverts r223537.

Discussed with:	hselasky, kevlo
MFC after:	1 week
2011-06-26 11:37:24 +00:00
Adrian Chadd 3cef2d90e3 I think 23dBm is the correct value to use here. CRDA uses 20dBm + 3dB max antenna
gain; I believe net80211 doesn't take antenna gain into account and leaves it
up to the driver to enforce. (ath_hal(4) certainly tries to do this.)
2011-06-26 10:34:01 +00:00
Adrian Chadd 1b8805b8aa Add a couple more frequency ranges to the FCC3 (FCC + DFS) regulatory domain.
The frequency range 5490MHz -> 5710MHz was opened up sometime in 2009, but
regdomain.xml wasn't updated.

FCC reference: (Section 15.407): http://louise.hallikainen.org/FCC/FccRules/2009/15/407/

The hole between 5600-5650MHz is due to a request from Airports using
a weather radar system which also utilises this range.
The GIT commit explaining this hole in more detail can be found here:

http://git.kernel.org/?p=linux/kernel/git/linville/wireless-regdb.git;a=commit;h=fcbf9225d56e82d9a4e506187d42285e76d81523
2011-06-26 10:32:09 +00:00
Adrian Chadd e43496e5e6 Replace tab with 8 spaces, bringing it in line with the rest of the file. 2011-06-26 09:32:46 +00:00
Hans Petter Selasky 72b92b5ef7 - Move bus_auto.conf back into /etc/devd/
- Rename bus_auto.conf into usb.conf

Requested by:	imp @
MFC after:	14 days
2011-06-25 17:01:46 +00:00
Hans Petter Selasky fe38e11f25 - Move auto-load devd config file into etc/defaults folder.
- Regenerate file after bugfix in the generator.

Suggested by:	Jeremy Messenger
MFC after:	14 days
2011-06-25 15:42:33 +00:00
Hans Petter Selasky 9c916c627f - Export more USB device ID's.
- Update bus_auto.conf accordingly.

MFC after:	3 days
2011-06-24 22:01:56 +00:00
Hans Petter Selasky 2854ca4726 - Add auto-load devd config file for USB kernel modules.
MFC after:	14 days
2011-06-24 21:32:03 +00:00
Sergey Kandaurov f253603f0c Add support for string values with white spaces for ifconfig(8)
parameters accepting them (such as description, group).

Changes discussed on freebsd-rc.

PR:		conf/156675
Reported by:	"Alexander V. Chernikov" <melifaro att ipfw ru>
Suggested by:	hrs
Analyzed with:	Alexander V. Chernikov via IRC
MFC after:	2 weeks
2011-06-24 14:56:38 +00:00
Adrian Chadd 0b73ba9c97 Fix another broken HT40 channel band reference. 2011-06-24 14:31:30 +00:00
Adrian Chadd 9b9fc082ba More incorrect HT/40 setups in FCC.
Noticed-by:	bschmidt@
2011-06-24 12:50:18 +00:00
Adrian Chadd 74024442b7 Fix an incorrect frequency band for HT/40 in the FCC SKU.
Noticed by: bschmidt@
2011-06-24 12:31:36 +00:00
Adrian Chadd 796fd09a90 Import one of the two missing US FCC DFS bands to FCC3.
The FCC opened up this band sometime in 2009 (and ath was updated);
but regdomain.xml wasn't updated.
2011-06-24 12:30:43 +00:00
Doug Barton ef247ddad1 I knew there was something funny about this line 2011-06-22 06:27:32 +00:00
Doug Barton 0ee974f9cf Blah, forgot to svn add the actual script from r223310 2011-06-19 22:59:54 +00:00
Doug Barton d732b516ea Add the netwait rc.d script. It waits for the specified period for the
network to become active.

PR:		conf/151063
Submitted by:	Jeremy Chadwick <freebsd@jdc.parodius.com>
2011-06-19 22:48:40 +00:00
Jilles Tjoelker 1cbcfc538b rc.subr: Make sure all functions are under if [ -z "${_rc_subr_loaded}" ]. 2011-06-19 15:23:32 +00:00
Jilles Tjoelker 5062455134 rc.subr: Eliminate a fork from check_kern_features, like r223227.
MFC after:	2 weeks
2011-06-19 11:42:48 +00:00
Doug Barton aff92fcbb9 Add rc.d/kld to load kernel modules after local disks are up.
This method is many times faster than doing it in /boot/loader.conf.
2011-06-18 19:41:05 +00:00
Jilles Tjoelker cfb739b854 rc.subr: Eliminate about 100 forks from the boot sequence.
With the current sh, placing eval in a command substitution always results
in a fork(), even if it is the only command and only executes a single
simple command. Therefore, avoid it where it can be avoided easily.

Side effect: values starting with a hyphen and all whitespace are preserved.
The values are defaults and names for rc.conf variables and messages to be
given about obsolete ones.

MFC after:	2 weeks
2011-06-18 11:05:30 +00:00
Ed Schouten 9f0c9022c2 Add WITHOUT_UTMPX switch to the build system.
This knob removes the tools that are exclusively used to view and
maintain the databases maintained by utmpx, namely last, users, who,
wtmpcvt, ac, lastlogin and utxrm.

The tool w is not in this list, because it has some other functionality
which is unrelated to utmpx; it is hardlinked to the uptime tool.
2011-06-17 21:30:21 +00:00
Ed Schouten f1c344b293 Don't omit ac(8) as part of WITHOUT_ACCT.
The WITHOUT_ACCT switch is supposed to omit tools related to process
accounting, namely accton and sa. ac(8) is just a simple tool that
prints statistics based on data in the utx.log database. It has nothing
to do with the former.
2011-06-17 20:47:44 +00:00
Josh Paetzel 00a3d0dae2 Eliminate extraneous pipelines and tr calls.
Approved by:	kib (mentor)
MFC after:	3 days
2011-06-15 19:33:02 +00:00
Gregory Neil Shapiro d84fd3a341 Minor change to force commit this file so new freebsd*.cf files are
built to use the new sendmail-8.14.5/cf tree.

MFC after:	4 days
2011-06-14 04:34:20 +00:00
Gregory Neil Shapiro 8259b3066b Update DNSBL information (MAPS has been acquired, used a generic example) 2011-06-14 04:33:43 +00:00
Josh Paetzel eb52d12531 Convert the allowed characters '-', '.', and ':' in a ZFS pool name to _
to avoid causing errors in the shell script.

Submitted by:	William Grzybowski <william88@gmail.com>
Approved by:	kib (mentor)
MFC after:	7 days
Sponsored by:	iXsystems
2011-06-13 19:45:01 +00:00
Hiroki Sato 1e1c0371e6 - Remove $ipv6_gateway_enable check.
- Use list_net_interfaces() instead of "ifconfig -l".
2011-06-11 21:41:44 +00:00
Hiroki Sato d3ae0231fe Add a helper function to check kern.features.* sysctls.
Discussed with:	dougb
2011-06-11 21:40:37 +00:00
Rick Macklem 34eb31ca42 Make three one line changes to the rc scripts so that
they work with the new NFS client being the default,
since the new NFS client's module name is nfscl and
not nfsclient.
2011-06-11 21:14:22 +00:00
Hiroki Sato 746b269075 Do not mark lo0 as IFDISABLED even if there is no $ifconfig_lo0_ipv6 line. 2011-06-06 11:36:10 +00:00
Hiroki Sato 73dda0356d Remove "ifconfig IF inet6 -accept_rtadv" when ipv6_gateway_enable=YES because
this is no longer needed.
2011-06-06 03:37:33 +00:00
Bjoern A. Zeeb 1dd53eaea3 No logner set an IPv4 loopback address by default in defaults/rc.conf.
If not specified, network.subr will add it automatically if we have
INET support (1).

In network.subr only call the address family up/down functions
if the respective AF is available.

Switch to new kern.features variables for inet and inet6 as the
inet sysctl tree is also available for IPv6-only kernels leading
to unexpected results.

Suggested by:	hrs (1)
Reviewed by:	hrs
Sponsored by:	The FreeBSD Foundation
Sponsored by:	iXsystems
MFC after:	20 days
2011-05-31 00:25:52 +00:00
Hiroki Sato 88492dfb20 Remove redundant keywords.
Submitted by:	wxs
2011-05-17 07:40:13 +00:00
Jilles Tjoelker b1865d5303 network.subr: Use printf(1) builtin for hexprint function.
Now that printf(1) is a shell builtin, there is no need to emulate it
anymore. The external printf(1) is /usr/bin/printf and therefore may not be
available in early boot.

It may be faster to use printf directly but the function is useful for
compatibility.
2011-05-14 12:22:58 +00:00
Rick Macklem a0c2c3691c Change the new NFS server so that it uses vfs.nfsd naming
for its sysctls instead of vfs.newnfs. This separates the
names from the ones used by the client.
2011-05-08 01:01:27 +00:00
Doug Barton f7e2bd0458 1. If PKG_DBDIR cannot be determined from make, set the default
2. Add the -H flag to tar in case /var/db/pkg itself is a symlink
3. Direct stderr to /dev/null to suppress the leading slash warning [1]

PR:		ports/156810 [1]
Submitted by:	Jeremy Chadwick <freebsd@jdc.parodius.com> [1]
2011-05-05 02:35:11 +00:00
Alexander Leidinger 6edc5d5ab4 The security run requests unmaskable output, even if the only output is to
tell that there is a separate email or that the output is logged to a file.

This commit changes the return code for the non-inline case to tell that
this message is not important enough and can be masked if necessary. The
messages from the security checks themself are not affected by this and
show up as before in the periodic security email/file.

The inline case still requests to not mask the output, as with the current
way of handling this there is no easy way to handle this.

PR:			138692
Analysis/patch atch by:	Chris Cowart <ccowart@timesinks.net>
X-MFC after:		on request
2011-05-04 12:48:02 +00:00
Alexander Leidinger df2f88d356 Use proper return codes (valuable output, invalid config, problems).
MFC after:	1 week
2011-05-04 12:37:10 +00:00
Dag-Erling Smørgrav 4a421b6336 Upgrade to OpenSSH 5.8p2. 2011-05-04 07:34:44 +00:00
Ruslan Ermilov a4638c5ce5 Updated `flags' field description. 2011-05-03 12:22:46 +00:00
Dimitry Andric 3b0f406639 Upgrade our copy of llvm/clang to r130700, from upstream's trunk. 2011-05-02 21:04:37 +00:00
Doug Barton 1d29baf81e Rather than trusting that nothing is going to sneak in before the
early_late_divider in the second run (and thus be skipped altogether),
keep a list of the scripts run early, and use that list to skip things
in the second run.

This has the primary benefit of not skipping a local script that gets
ordered too early in the second run. It also gives an opportunity to
clean up/simplify the code a bit.

Use a space-separated list rather than the more traditional colon for
maximum insurance against creativity in local naming conventions.

Reviewed by:	brooks
2011-04-29 21:10:41 +00:00
Rick Macklem afea74655f Fix module names and dependencies so the NFS clients will
load correctly as modules after r221124.
2011-04-27 20:42:30 +00:00
Rick Macklem 6bb544780b Update the /etc/rc.d scripts for mountd and nfsd so they
can use the "-o" option to force the old NFS server to run.
Running the old NFS server is enabled by setting
oldnfs_server_enable="YES". The scripts will only enable
providing service for NFSv4 if nfsv4_server_enable="YES"
is set.

Reviewed by:	dougb (rc)
2011-04-26 00:22:17 +00:00
Doug Barton fb91147e08 Create a function for the code from r192246 so that it can be used both
times mount is called.

Limit the automatic behavior to when AUTO is specified (as it is in
etc/defaults/rc.conf) and for everything else take advantage of all
of the goodness in checkyesno.
2011-04-25 06:03:22 +00:00
Doug Barton d63de2e297 Add svn:executable property 2011-04-25 05:57:01 +00:00
Doug Barton d7c2f00c7c As previously advertised, remove the error message for enable_quotas
prior to 9.0-RELEASE.

This change should not be MFC'ed.
2011-04-23 17:37:14 +00:00
Doug Barton b1850238b7 Improve the error handling for the new get_pidfile_from_conf() 2011-04-23 05:24:17 +00:00
Doug Barton 8028832653 Introduce to rc.subr get_pidfile_from_conf(). It does just what it sounds
like, determines the path to a pid file as it is specified in a conf file.

Use the new feature for rc.d/named and rc.d/devd, the 2 services in the
base that list their pid files in their conf files.

Remove the now-obsolete named_pidfile, and warn users if they have it set.
2011-04-23 04:26:31 +00:00
Doug Barton ed52acf61d The change in r206686 to allow the stop argument to work for a service
that is running even though not _enable'd had an annoying side effect.
If the service was already started at boot time by another means when
the related script came around again in rcorder it would start again,
regardless of _enable, because there was a valid pid. [1]

So, split the test into 2 parts, one for (!rcvar && !stop), and one
for (stop && !valid_pid). This preserves the behavior from r206686
while preventing the undesired side effect.

PR:		conf/156427 [1]
Submitted by:	Eugene Grosbein <eugen@grosbein.pp.ru> [1]
2011-04-17 22:31:36 +00:00
Dimitry Andric 6d67f69487 Remove libobjc and other Objective-C related components, as these are
extremely outdated, and not used by anything in the base system.

Silence from:	current@
2011-04-17 21:03:23 +00:00
David E. O'Brien 1e3f14466b * Add the readline(3) API to libedit. The libedit versions of
{readline,history}.h are in /usr/include/edit so as to not conflict with
  the GNU libreadline versions.  To use the libedit readline(3) one should
  add "-I/usr/include/edit" to their Makefile
  (spelled "-I${DESTDIR}/${INCLUDEDIR}/edit" within the FreeBSD source tree).

* Enable its use in the BSD licensed utilities that support readline(3).

* To make it easier to sync libedit development with NetBSD, histedit.h
  is moved into libedit's directory as history shows shown we keep merging
  it into that location.

Obtained from:	NetBSD
Sponsored by:	Juniper Networks
2011-04-05 18:41:01 +00:00
Edward Tomasz Napierala 14d90ef1e1 Add example devd.conf entry. 2011-03-30 18:35:02 +00:00
Edward Tomasz Napierala cb89c25099 Add startup script, to load rules from /etc/rctl.conf.
Sponsored by:	The FreeBSD Foundation
Reviewed by:	kib (ealier version)
2011-03-30 18:32:45 +00:00
Ed Schouten b15ce1ef26 Remove the reference to pseudo-terminals from the description.
Pseudo-terminals are no longer listed in this file, since the utmpx
implementation doesn't depend on ttyslot().
2011-03-30 08:22:29 +00:00
Ed Maste 86fdaae573 Replace ${SYSCTL_W} with ${SYSCTL} in rc.d scripts, as they are identical.
This is a further clean up after r202988.

SYSCTL_W is still initialized in rc.subr as some ports may still use it.
2011-03-30 01:19:00 +00:00
Doug Barton f09b508c66 Hook the 220.backup-pkgdb script I added to the build unconditionally
Hook up 610.ipf6denied based on MK_IPFILTER as 510.ipfdenied is now

Poked by:	Andrzej Tobola <ato@iem.pw.edu.pl>
2011-03-27 03:06:58 +00:00
Doug Barton baaa9dad0c Add svn:executable property on remaining period scripts without it 2011-03-27 03:03:29 +00:00
Doug Barton 22933fac2f Add a daily period script to back up /var/db/pkg
The final product contains work from the originator, and
Florent Thoumie <florent.thoumie@gmail.com>. The final
product contains considerable re-working by me, so all
responsibility for bugs rests under my pointy hat.

PR:		ports/145957
Submitted by:	Eitan Adler <EitanAdlerList@gmail.com>
2011-03-26 03:01:48 +00:00
Doug Barton 1533889cf7 Add the svn:executable property to the scripts that are missing it 2011-03-26 01:24:55 +00:00
Alexander Motin 89b172238a MFgraid/head:
Add new RAID GEOM class, that is going to replace ataraid(4) in supporting
various BIOS-based software RAIDs. Unlike ataraid(4) this implementation
does not depend on legacy ata(4) subsystem and can be used with any disk
drivers, including new CAM-based ones (ahci(4), siis(4), mvs(4), ata(4)
with `options ATA_CAM`). To make code more readable and extensible, this
implementation follows modular design, including core part and two sets
of modules, implementing support for different metadata formats and RAID
levels.

Support for such popular metadata formats is now implemented:
Intel, JMicron, NVIDIA, Promise (also used by AMD/ATI) and SiliconImage.

Such RAID levels are now supported:
RAID0, RAID1, RAID1E, RAID10, SINGLE, CONCAT.

For any all of these RAID levels and metadata formats this class supports
full cycle of volume operations: reading, writing, creation, deletion,
disk removal and insertion, rebuilding, dirty shutdown detection
and resynchronization, bad sector recovery, faulty disks tracking,
hot-spare disks. For Intel and Promise formats there is support multiple
volumes per disk set.

Look graid(8) manual page for additional details.

Co-authored by:	imp
Sponsored by:	Cisco Systems, Inc. and iXsystems, Inc.
2011-03-24 21:31:32 +00:00
Jeff Roberson aa0a1e58f0 - Merge in OFED 1.5.3 from projects/ofed/head 2011-03-21 09:58:24 +00:00
Hajimu UMEMOTO b7f8411df2 Add resolvconf(8) which manages resolv.conf. 2011-03-18 12:18:52 +00:00
Dag-Erling Smørgrav 6fe126c1a9 Forgot to commit this change along with r219563: pam_group(8) now issues
a warning if neither luser nor ruser is specified.  The correct option
for su(1) is ruser.

MFC after:	1 month
2011-03-15 10:13:35 +00:00
Nathan Whitehorn 12ad0bb143 Thanks to sysinstall for its 15 years of service. And now to sleep,
perchance to dream...
2011-03-14 13:47:17 +00:00
Doug Barton a3b50b5603 Revert r219578 2011-03-13 16:27:36 +00:00
Doug Barton 19cc9846fe Remove the svn:executable property on Makefile
Add it on hastd
2011-03-13 08:22:46 +00:00
Doug Barton e729c4f2fd Use the allexport option in load_rc_config() in order to avoid having
to repeatedly read the conf files. Depending on what is enabled the
files are being read anywhere from 15, 30, or more times currently.
By loading the values in the environment this is reduced to 1, with
perhaps a couple more, again depending on what is enabled.

The speed-up for boot and shutdown is negligible when rc.conf is
on local disk, noticable when accessing files over NFS, and dramatic
when pulling rc.conf values from a database.

This change also includes a minor optimization to the conditional
for $_rc_conf_loaded.
2011-03-12 21:13:08 +00:00
Pawel Jakub Dawidek 6be04ba681 Commit two more files missed in r219089.
MFC after:	1 month
2011-02-27 19:44:10 +00:00
Pawel Jakub Dawidek 35d77156fa Recognize 'reload' command, as hastd can be reloaded with the SIGHUP signal.
MFC after:	1 week
2011-02-27 11:40:20 +00:00
Gabor Kovesdan ad30f8e79b Add the BSD-licensed Citrus iconv to the base system with default off
setting. It can be built by setting the WITH_ICONV knob. While this
knob is unset, the library part, the binaries, the header file and
the metadata files will not be built or installed so it makes no impact
on the system if left turned off.

This work is based on the iconv implementation in NetBSD but a great
number of improvements and feature additions have been included:

- Some utilities have been added. There is a conversion table generator,
  which can compare conversion tables to reference data generated by
  GNU libiconv. This helps ensuring conversion compatibility.
- UTF-16 surrogate support and some endianness issues have been fixed.
- The rather chaotic Makefiles to build metadata have been refactored
  and cleaned up, now it is easy to read and it is also easier to add
  support for new encodings.
- A bunch of new encodings and encoding aliases have been added.
- Support for 1->2, 1->3 and 1->4 mappings, which is needed for
  transliterating with flying accents as GNU does, like "u.
- Lots of warnings have been fixed, the major part of the code is
  now WARNS=6 clean.
- New section 1 and section 5 manual pages have been added.
- Some GNU-specific calls have been implemented:
  iconvlist(), iconvctl(), iconv_canonicalize(), iconv_open_into()
- Support for GNU's //IGNORE suffix has been added.
- The "-" argument for stdin is now recognized in iconv(1) as per POSIX.
- The Big5 conversion module has been fixed.
- The iconv.h header files is supposed to be compatible with the
  GNU version, i.e. sources should build with base iconv.h and
  GNU libiconv. It also includes a macro magic to deal with the
  char ** and const char ** incompatibility.
- GNU compatibility: "" or "char" means the current local
  encoding in use
- Various cleanups and style(9) fixes.

Approved by:	delphij (mentor)
Obtained from:	The NetBSD Project
Sponsored by:	Google Summer of Code 2009
2011-02-25 00:04:39 +00:00
Brooks Davis 95d068b14b Enable the check for negative permissions (the group on a file can't do
something "everyone" can) by default.

X-MFC after:	never
2011-02-24 23:51:59 +00:00
Doug Barton e1c7c9d377 The new accounting file needs to be 644 so that unprivileged users
can use lastcomm(1)
2011-02-24 06:28:48 +00:00
Doug Barton 0a6cd3ac6d Update how accounting log files are rotated.
The old version had a race between the time that the old file was
cp'ed to acct.0 and the time that 'sa -s' was run that prevented
the commands that occurred in the meantime from being backed up.

It's also arguable that the old version was inefficient in using
cp which can be a problem on a space-constrained system.

This version avoids both problems, albeit it's considerably more
complicated. The advantage of putting the log rotation in the rc.d
script is that it can handle the _enable and _file questions without
having to do gymnastics to discover either value in the periodic script.

As a side effect of reviewing the rc.d script I cleaned it up a bit.
2011-02-22 21:13:40 +00:00
Ulrich Spörlein 423102c6fa Flesh out WITHOUT_GROFF support to DTRT.
A full featured groff is required during buildworld, so build it always
and don't rely on it being present on the host system.

vgrind(1) is tightly coupled to a roff processor and will not be
built/installed when groff is disabled. Also much of the roff'ed
documentation under share/doc will not be built/installed when
WITHOUT_GROFF is defined.

Reviewed by:	ru (partial)
2011-02-22 08:13:49 +00:00
Lawrence Stewart 071e1365c2 Actually install the example Khelp module committed in r218545.
Sponsored by:	FreeBSD Foundation
MFC after:	4 weeks
X-MFC with:	r218545
2011-02-21 13:22:29 +00:00
Dimitry Andric 2754fe609d Upgrade our copy of llvm/clang to r126079, from upstream's trunk.
This contains many improvements, primarily better C++ support, an
integrated assembler for x86 and support for -pg.
2011-02-20 19:33:47 +00:00
Doug Barton b28209aac3 Add a note about AXFR of important zones being available from ICANN 2011-02-20 00:59:39 +00:00
Nathan Whitehorn 2118f3873f Import bsdinstall. This is meant to be (eventually in conjunction with
pc-sysinstall) a replacement for sysinstall in the 9.0 release and beyond.
Currently supported platforms are sparc64, pc98, i386, amd64, powerpc, and
powerpc64. Integration into the build system will occur in the coming
weeks.

Merging with pc-sysinstall will use this code as a frontend, while
temporarily retaining the interactive partition editor here. This work
will be done in parallel with improvements on this code and release
integration.

Thanks to all who have provided testing and comments!
2011-02-18 14:54:34 +00:00
Konstantin Belousov 3b5a03b106 Install iodev.h.
Reviewed by:	attilio
MFC after:	1 week
2011-02-17 15:10:13 +00:00
Doug Barton 55a8000cd7 Remove in-addr.arpa from the list of zones it is possible to slave locally 2011-02-16 21:23:09 +00:00
Ulrich Spörlein 7e7f412139 Fix termcap entry typo.
MFC after:	2 weeks
2011-02-09 10:06:31 +00:00
Doug Barton 8bcbc83bdf Catch up with reality and references from the latest RFCs
(especially 5735) for our default empty zones.
2011-02-05 21:43:37 +00:00
Doug Barton 606fffda66 Let rpcbind clean up after itself 2011-01-31 21:03:08 +00:00
Maxim Konovalov 0f27aaf940 o Add user 'hast'. 2011-01-31 07:47:28 +00:00
Pawel Jakub Dawidek 1b0e519476 Change hast user home directory to /var/empty.
MFC after:	1 week
2011-01-28 22:29:38 +00:00
Pawel Jakub Dawidek 3468e4ce38 Add 'hast' user and 'hast' group that will be used by hastd (and maybe hastctl)
to drop privileges.

MFC after:	1 week
2011-01-28 22:28:12 +00:00
Josh Paetzel 9283f726be Fix logic error introduced in previous commit.
Along the way make some efficiency improvements.

Submitted by:	jilles
Approved by:	kib (mentor)
MFC after:	3 days
2011-01-25 13:41:48 +00:00
Josh Paetzel 16c4413fa6 This script parses output of userland tools. In the case of a faulted
zpool the output causes the script to bail out with syntax errors.
Since a scrub of a faulted zpool is pointless, just skip over any pools
marked as such.

PR:	conf/150228
Submitted by:	jpaetzel
Approved by:	kib (mentor)
MFC after:	3 days
MFC note:	only for RELENG_8
2011-01-23 17:13:29 +00:00
Ulrich Spörlein e17b9e4a7c Fix a small typo nit 2011-01-19 20:16:47 +00:00
Nathan Whitehorn ad10f5790b Remove /usr/share/examples/[lib]dialog, missed in the new dialog import.
Submitted by:	dim
2011-01-13 18:52:13 +00:00
Jaakko Heinonen 1fdd33fd31 Replace nfs4 with newnfs in netfs_types. nfs4 was removed in r192578 and
mount(8) has supported newnfs since r192930.

PR:		conf/153655
Submitted by:	Anonymous <swell.k@gmail.com>
MFC after:	3 weeks
2011-01-09 09:21:11 +00:00
Jaakko Heinonen 8ef92ea65e Warn if rules could not be read from a ruleset file. Now at least
something gets logged if the file has syntax errors.

PR:		conf/91342
Silence on:	freebsd-rc
2011-01-07 10:59:22 +00:00
Warner Losh 212dfb3236 Don't require /usr/lib/aout to be on the system. Test for its
existance since we don't generally need it.

MFC after:	1 week
2011-01-06 21:09:22 +00:00
Josh Paetzel 99d57ce828 Fix typo in default config file.
Approved by:	Warner Losh <imp@FreeBSD.org>
MFC after:	3 days
2011-01-04 23:00:54 +00:00
Colin Percival 2eaf566f2a Remove INDEX-6 from the default portsnap configuration file; the 6.x index
bits haven't been built since December 1st, although the mirrors are still
distributing the bits as they were at the EoL.

Reminded by:	Alex Kozlov
2010-12-30 01:13:42 +00:00
Doug Barton be59eea018 Add pidfile [1]
While I'm here, don't run the sysctl frob unconditionally, and
s/sysctl/$SYSCTL/

PR:		conf/153460 [1]
Submitted by:	Grigory Rechistov <ggg_mail@inbox.ru>
2010-12-27 22:52:47 +00:00
Shteryana Shopova 5b56d5b347 Add (disabled) sample configuration lines needed to enable snmp_target(3) module
and configure minimal target addresses & notifications needed for bsnmpd(1)
to send SNMPv3 notifications.

Sponsored by:	The FreeBSD Foundation
Reviewed by:	philip
Approved by:	philip
2010-12-20 17:28:15 +00:00
Kevin Lo 1fd114b406 Add pf in quiet mode 2010-12-17 09:38:55 +00:00
Shteryana Shopova 5289aac4fa Fix typos. 2010-12-08 17:34:07 +00:00
Shteryana Shopova 3e06e033a7 Add (disabled) sample configurations needed to enable the snmp_usm and
snmp_vacm modules and minimal user/view configurations needed to for
the modules to work properly.

Sponsored by:   The FreeBSD Foundation
Reviewed by:    philip@ (mostly)
Approved by:    philip@
2010-12-08 17:27:59 +00:00
Doug Barton 5c0612b199 Add a sync to the shutdown step. In the common case this will be harmless
at worst. On a heavily loaded server it will give the fs a chance to do
its business without the axe hanging over its head.

Submitted by:	ivoras
2010-11-25 18:20:28 +00:00
Pawel Jakub Dawidek 24b7ca3412 Add gptboot_enable rc variable, which allows to turn gptboot reporting off in
case user wants to implement his own actions and doesn't want the attributes to
vanish.

Obtained from:	Wheel Systems Sp. z o.o. http://www.wheelsystems.com
MFC after:	3 days
2010-11-24 15:25:17 +00:00
Michael Tuexen ead95d9d86 Add for existing protocol entries the missing SCTP port allocations
and add protocol entries for protocols which have SCTP port allocations.
These entries are according to
http://www.iana.org/assignments/port-numbers
as of today. Also add SCTP port allocation entires for the
echo, daytime, and chargen service.
Discussed with rwatson@

MFC after: 3 days.
2010-11-13 17:52:04 +00:00
Brooks Davis 7cdc1c0007 Add an (off by default) check for negative permissions (where the
group on a object has less permissions that everyone).  These
permissions will not work reliably over NFS if you have more than
14 supplemental groups and are usually not what you mean.

MFC after:	1 week
2010-11-13 00:40:43 +00:00
Maksim Yevmenkin e97af4eedf Add firmware downloader for Atheros AR3011 based USB Bluetooth devices.
Hardware donated by:	Rusty Nejdl rnejdl at ringofsaturn dot com
Tested by:		Rusty Nejdl rnejdl at ringofsaturn dot com
Tested by:		Andrzej Tobola ato at iem dot pw dot edu dot pl
MFC after:		3 weeks
2010-11-12 19:43:12 +00:00
Xin LI 65a1c46588 Hide 460.chkportsum in MK_PKGTOOLS != no case.
Submitted by:	Alex Kozlov <spam rm-rf kiev ua>
MFC after:	2 weeks
2010-11-09 18:46:44 +00:00
Julian Elischer 136347a147 Add a jails directory in the examples section
MFC after:	2 weeks
2010-10-24 23:19:11 +00:00
Gordon Tetlow 42e2c9f18f No longer install /etc/manpath.config since the BSDL man utilities
don't use it.

Approved by:	wes (mentor)
2010-10-04 01:07:04 +00:00
Ed Maste 17332126d1 Commit the rest of r213270.
Thanks to Anonymous <swell dot k at gmail.com> for spotting this.
2010-09-29 22:59:49 +00:00
Ed Maste e64241487f /etc/rc.d/defaultroute currently bails immediately if all interfaces
set to use DHCP have no carrier.  This can cause grief as it may take
some time for link to be established, and defaultroute may terminate
before this happens.

Introduce a defaultroute_carrier_delay variable and then wait that long
in defaultroute before bailing if no interfaces have carrier.  With the
default settings defaultroute will wait for five seconds for this, and
the original 30 second wait for a default route to appear is unchanged.
Note that there is in discussion an alternative approach to the broader
problem of waiting for DHCP-configured routes.  However, this change
addresses a real problem in the current defaultroute script.

Discussed on:	freebsd-rc@
2010-09-29 13:08:23 +00:00
Warner Losh 8f3ec30476 Prefer echo over printf 2010-09-27 15:55:39 +00:00
Pawel Jakub Dawidek 867b3ba46a Add gptboot script that is responsible for:
- looking for partition with 'bootonce' attribute alone (without 'bootme'
  attribute), removing it and logging that we successfully booted from this
  partition.
- looking for partitions with 'bootfailed' attribute, removing it and
  logging that we failed to boot from this partition.

Reviewed by:	arch (Message-ID: <20100917234542.GE1902@garage.freebsd.pl>)
Obtained from:	Wheel Systems Sp. z o.o. http://www.wheelsystems.com
MFC after:	2 weeks
2010-09-24 19:53:55 +00:00
Hiroki Sato d3a8a8b9fa Split $ipv6_prefer into $ip6addrctl_policy and $ipv6_activate_all_interfaces.
The $ip6addrctl_policy is a variable to choose a pre-defined address
selection policy set by ip6addrctl(8).
The keyword "ipv4_prefer" sets IPv4-preferred one described in Section 10.3,
the keyword "ipv6_prefer" sets IPv6-preferred one in Section 2.1 in RFC 3484,
respectively.  When "AUTO" is specified, it attempts to read
/etc/ip6addrctl.conf first.  If it is found, it reads and installs it as
a policy table.  If not, either of the two pre-defined policy tables is
chosen automatically according to $ipv6_activate_all_interfaces.

When $ipv6_activate_all_interfaces=NO, interfaces which have no corresponding
$ifconfig_IF_ipv6 is marked as IFDISABLED for security reason.

The default values are ip6addrctl_policy=AUTO and
ipv6_activate_all_interfaces=NO.

Discussed with:	ume and bz
2010-09-13 19:55:40 +00:00
Hiroki Sato 95f15c1589 Localize $_punct_c in get_if_var() and whitespace clean-ups.
Based on:	changes in r206408 by dougb
2010-09-13 19:53:54 +00:00
Hiroki Sato fa3b84643a - Check some specific IFs first in ipv6_autoconfif().
- $ipv6_enable supports YES|TRUE|ON|1 as in checkyesno().

Based on:	changes in r206408 by dougb
2010-09-13 19:53:22 +00:00
Hiroki Sato abe3ac576a Add $ipv6_privacy to support net.inet6.ip6.use_tempaddr. Note that this
will be replaced with a per-IF version later.

Based on:	changes in r206408 by dougb
2010-09-13 19:52:46 +00:00
Hiroki Sato e5481092bb Fix $ipv6_network_interfaces and set it as AUTO by default.
Based on:	changes in r206408 by dougb
2010-09-13 19:52:04 +00:00
Hiroki Sato c5ad71aff5 Revert changes in r206408.
Discussed with:	dougb, core.5, and core.6
2010-09-13 19:51:15 +00:00
Bernhard Schmidt b6c44f6440 Create the var/run/wpa_supplicant directory where the wpa_supplicant
RC script wants to save a pidfile for each interface.

MFC after:	2 weeks
2010-09-10 08:27:02 +00:00
Daichi GOTO 6f0bcd4110 Avoid to try to remove suj journal file (.sujournal) and conventional
snapshot directory (.snap) from cleartmp rc.d script.
2010-09-05 05:44:40 +00:00
Maxim Konovalov e62f433662 o Correct typo.
Submitted by:	Bojidara Marinchovska via -stable
MFC after:	1 week
2010-08-25 08:37:18 +00:00
Alexander Leidinger 3dd9aad270 - Change the threshold from 'running next scrub the <value+1>th day after the
last one' to 'running next scrub the <value>th day after the last one'.
- Improve wording.

Requested by:	jhell <jhell@DataIX.net>
MFC after:	1 week
2010-08-25 08:09:42 +00:00
Doug Barton 15539a8a80 Fix silly typo on my part (s/quotas_enable/quota_enable/)
Submitted by:	ed
2010-08-14 22:28:07 +00:00
Doug Barton a7112b557f Give people some warning before removing enable_quotas 2010-08-14 18:58:05 +00:00
Jung-uk Kim 4a2637c486 Consistently use full pathnames for external commands. 2010-08-13 21:23:13 +00:00
Jung-uk Kim ca988da3ca Do not fork a subshell unnecessarily. 2010-08-13 21:04:43 +00:00
Jung-uk Kim ed82feee0c Enforce ACPI timer as the timecounter hardware before we change sleep state
unless it is the current timer.  When we have resumed successfully, restore
the previous timecounter hardware if it was changed earlier.  Only the ACPI
timer is guaranteed to increase monotonically between S-state changes.
2010-08-13 20:43:19 +00:00
Oliver Fromme 686fdc1fc1 Connect the new script 490.status-pkg-changes (see r210863)
to the build, so it gets actually installed.

Approved by:	des (mentor)
MFC after:	17 days
2010-08-10 12:58:44 +00:00
Gabor Kovesdan c2f40dcd3f - Fixes to the chkportsum script to handle better some special cases,
like spaces in filename

Submitted by:	Alex Kozlov <spam@rm-rf.kiev.ua>
Approved by:	delphij (mentor)
2010-08-10 11:15:17 +00:00
Oliver Fromme 6ece019fcf Add a daily script to the periodic framework that reports
changes to the package database, i.e. any packages that
have been added, updated or deleted in the past 24 hours.
The format is intentionally simple and concise.

That information is particularly useful on servers that
are maintained by multiple administrators.  When someone
adds, updates or deletes a package, the others will see
it in the daily periodic output.

This script is disabled by default.

PR:		conf/113913
Submitted by:	olli
Approved by:	des (mentor)
MFC after:	3 weeks
2010-08-05 15:53:33 +00:00
Hajimu UMEMOTO b3cae08659 /etc/rc.d/network_ipv6 was deprecated.
Reported by:	Alex Kozlov <spam__at__rm-rf.kiev.ua>
2010-08-05 15:11:03 +00:00
Hajimu UMEMOTO 478e8b2dc1 /etc/rc.d/ip6fw was deprecated.
Reported by:	Alex Kozlov <spam__at__rm-rf.kiev.ua>
MFC after:	3 days
2010-08-05 15:07:28 +00:00
Jilles Tjoelker 32c50473a8 Allow starting /etc/rc.d/ipmon if ipnat is enabled but ipfilter is not
(in /etc/rc.conf).

This fixes an apparent confusion between test(1) and sh(1) syntax for
AND/OR.

PR:		conf/149036
Submitted by:	pluknet
MFC after:	1 week
2010-08-01 15:41:00 +00:00
Shteryana Shopova ffc9a38171 Add a (disabled) configuration line to enable the snmp_wlan(3) module.
Sponsored by:	The FreeBSD Foundation
2010-07-26 16:20:52 +00:00
Ed Schouten ffd1746d03 Upgrade our Clang in base to r108428.
This commit merges the latest LLVM sources from the vendor space. It
also updates the build glue to match the new sources. Clang's version
number is changed to match LLVM's, which means /usr/include/clang/2.0
has been renamed to /usr/include/clang/2.8.

Obtained from:	projects/clangbsd
2010-07-20 17:16:57 +00:00
Gabor Kovesdan d8456aa881 - Add a periodic script, which can be used to find installed ports' files with
mismatched checksum

PR:		conf/124641
Submitted by:	Alex Kozlov <spam@rm-rf.kiev.ua>
Approved by:	delphij (mentor)
2010-07-19 20:19:14 +00:00
Benedict Reuschling a32e2a86af Fix spelling of "weirdo" in /etc/gettytab comment.
PR:             docs/148500
Submitted by:   Warren Block (wblock at wonkity dot com)
Approved by:    ed@
MFC after:      1 week
2010-07-12 19:09:18 +00:00
Pawel Jakub Dawidek aac0676809 Use spaces, not tabs. 2010-06-28 08:05:30 +00:00
Warner Losh 4bbc5bd8e0 Bring in Kris Moore's pc-sysinstall shell script from PC-BSD. This
shell script is the back end logic necessary for an installer.  It
contains both query routines to allow a front-end installer to present
reasonable choices to the user and also action routines which allow
the front end installer to put a FreeBSD distribution onto a disk.  It
supports installing onto the usual suspects, as well as advanced
features like Mirroring, ZFS, Encryprion and GPT labels.

While this is only the back-end of the installer, it can do unattended
scripted installations.  In PC-BSD's world view, all installations are
scripted and all the front-end does is write the script.  As such, it
is useful in its own right.

This has been extensively tested over the past several releases of
PC-BSD.  However, differences between that environment and FreeBSD
suggest there will be a period of shake-out while those differences
are discovered and corrected.

A text-based front-end is in the works.  For the GUI-based front-end,
you can use the PC-BSD distribution.

Kris' BSDcan paper on pc-sysinstall is linked off his talk on the
BSDcan site:
	http://www.bsdcan.org/2010/schedule/events/173.en.html

The man page is written by Josh Paetzel, and I wrote the Makefiles for
the FreeBSD integration.  Kris wrote the rest.

This represents version r7010 in the PC-BSD repo.
http://svn.pcbsd.org/pcbsd/current/pc-sysinstall

Submitted by:	kris@
Sponsored by:	iX Systems
2010-06-24 22:21:47 +00:00
Brian Somers 5fa77f4fe4 Remove vestiges of 'slip'.
PR:		145648
Submitted by:	alexbestms at wwu dot de and spam at rm-rf dot kiev dot ua
MFC after:	1 week
2010-06-19 09:21:34 +00:00
Doug Barton 998ef62e74 Add the AAAA address for i.root-servers.net 2010-06-18 08:11:52 +00:00
Alexander Leidinger 92dee8c3a0 - add the zfs scrub script
- move the zfs status script into the MK_ZFS conditional to respect
  WITHOUT_ZFS

Noticed by:	Andrzej Tobola <ato@iem.pw.edu.pl>
2010-06-17 12:25:47 +00:00
Andriy Gapon ac79617984 device.hints: do install when WITHOUT_BOOT is set
Discussed with:	imp
MFC after:	2 weeks
2010-06-16 07:52:44 +00:00
Alexander Leidinger 63669de232 Add a periodic zfs scrub script.
Features:
 - configurable amount of days between scrubs (default value or per pool)
 - do not scrub directly after pool creation (respects the configured
   number of days between scrubs)
 - do not scrub if a scrub is in progress
 - tells how to see the status of the scrub
 - tells how many days since the last scrub if it skips the scrubbing
 - warns if a non-existent pool is specified explicitely
   (default: no pools specified -> all currently imported pools are
   handled)
 - runs late in the periodic run to not slow down the other periodic daily
   scripts

Discussed on:	fs@
2010-06-15 08:58:16 +00:00
Warner Losh f62a0233c8 Merge from tbemd, with minor tweaks:
Search from most specific ($MACHINE) to least specific
($MACHINE_CPUARCH) when looking for the tty file to use.  Also add an
.error case if none exist.
2010-06-13 16:35:20 +00:00
Roman Divacky 6513cfc82f Hook clang into the build on i386/amd64/powerpc.
Approved by:	ed (mentor)
2010-06-09 19:57:20 +00:00
Jung-uk Kim 07e547fe26 Add a new build option, MAN_UTILS. This option lets you control building
utilities and related support files for manual pages, which were previously
controlled by MAN.  For POLA, the default depends on MAN, i.e., WITHOUT_MAN
implies WITHOUT_MAN_UTILS and WITH_MAN implies WITH_MAN_UTILS.  This patch
is slightly improved by me from:

PR:		misc/145212
2010-05-19 23:56:26 +00:00
Doug Barton 2822c33f8c This change does the following for the scripts that run up through
FILESYSTEMS (the default early_late_divider):
1. Move sysctl to run first
2. Move as many BEFOREs to REQUIREs as possible.
3. Minor effect, move hostid_save from right before mdconfig to right
   after.

A lot of the early scripts make use of sysctl one way or another so
running this first makes a lot of sense given that system-critical
values are often placed in sysctl.conf.

My original purpose for working on this was that while doing some
debugging on other stuff I noticed that the order of execution was
different in the first pass through the early scripts and the second.
In practice that doesn't matter because the scripts are not executed the
second time. However this _can_ result in problems if the difference in
the rcorder moves a script from the late section to the early section in
the second pass (which would mean the script would not get executed).
So, I wanted to make the order of execution of the scripts in the early
section more deterministic.

In the course of debugging the ordering problems I noticed that moving
the BEFOREs to REQUIREs prevented the changes in order from the first
pass to the second pass without having to make any substantial changes.
(Of course it's no secret that I think BEFORE should be avoided as much
as possible, but this is a good example of why.)

Reviewed by:	silence on freebsd-rc@
MFC after:	8.1-RELEASE
2010-05-19 19:03:19 +00:00
John Baldwin 4d84f49da4 Prevent unloading a kld for a driver that has subinterfaces (vlan and/or
wlan interfaces) from being automatically reloaded via devd shutdown
event handlers.
- Revert part of my previous changes to call ifn_stop on subinterfaces
  when an interface is detached.  It is better to destroy the interfaces
  first so that an 'ifconfig foo0.blah down' doesn't result in ifconfig
  auto-loading if_foo.ko.  The ifconfig command will not be invoked if
  foo0.blah is gone when ifn_stop() is called.  Furthermore, it is not
  necessary to explicitly invoke ifn_stop() after the subinterface is
  destroyed as devd will already do that.
- Pass -n to ifconfig when destroying interfaces so that destroying a
  cloned interface does not kldload any drivers.

Reviewed by:	dougb
MFC after:	4 days
2010-05-17 19:51:34 +00:00
Jilles Tjoelker 18bd63b7c5 Change the commented msgs examples in profile/csh.login from -f to -q.
Starting something that wants input on login seems strange and can be
dangerous. In some configurations, causing output can be bad, but it is not
as dangerous.

I do not expect this msgs invocation to be uncommented often.

PR:		conf/96015
MFC after:	4 days
2010-05-15 17:49:56 +00:00
Doug Barton 2557f5bf0a Remove trailing white space. No functional changes. 2010-05-14 04:53:57 +00:00
David E. O'Brien 680e78b305 Non-GCC gcc compatible compilers may provide the same multimedia intrinsic
headers as GCC, but of their own implementation.  So put the GCC ones into
their own header "namespace".

Requested by:	ed
2010-05-12 19:59:32 +00:00
Martin Matuska 81ad83880d Import of liblzma, xz, xzdec, lzmainfo from vendor branch
Add support for xz and lzma to lesspipe.sh (xzless, lzless)
Bump __FreeBSD_version

Approved by:	delphij (mentor)
MFC after:	2 weeks
2010-05-10 06:59:50 +00:00
Doug Barton fd73ccb143 Make address assignment via ipv6_prefix_IF work again 2010-05-04 01:46:58 +00:00
Doug Barton a16334d031 In the case where named_chroot_autoupdate is NOT set, but
named_chrootdir IS set, named-checkconf fails because it
cannot find the conf file. Fix this by making checkconf a
variable that includes "-t $named_chrootdir" as needed.
Notice of the bug and suggested direction for the fix from [1].

Using required_files for named.conf is overkill ever since
I added the named-checkconf call, so rather than update the
logic to handle the case described above, remove it. This
also handles the case where named_chroot_autoupdate IS set
but the symlink doesn't exist yet.

PR:		conf/145904
Submitted by:	J R Matthews
2010-04-28 22:29:17 +00:00
Hajimu UMEMOTO b13cc627c7 Better handling of ipv6_default_interface using
net.inet6.ip6.use_defaultzone=1.  Now, it works IPv6 link-local
unicast addresses as well as IPv6 link-local multicast addresses.

MFC after:	1 week
2010-04-26 15:31:58 +00:00
Andrew Thompson 3acd904d85 Change usb devd events from fake attach to a notify. The ugen device is not a
proper device_t so it faked the devctl event to appear like one, this is now a
notify which allows more information to be passed.

We notify for both the device attach/detach and for each usb interface. A devd
rule can now match on the interface properties, including composite devices
which may have a uvideo interface and also usound and possibly uhid too.

An example to match a umass device with a scsi subclass and BBB protocol would be

notify 100 {
	match "system"          "USB";
	match "subsystem"       "INTERFACE";
	match "type"            "ATTACH";
	match "intclass"        "0x08";
	match "intsubclass"     "0x06";
	match "intprotocol"     "0x50";
	action ...
};

The old attach devctl event has been retained for the moment to make merging to
8.1 easier. This was never compatible with 7.x or earlier due to the ugen regex
change needed.

Reviewed by:	warner
MFC after:	1 week
2010-04-21 21:51:14 +00:00
Andriy Gapon ee9c0bb32b indent.pro example: actually install the sample file 2010-04-21 12:17:01 +00:00
Rui Paulo 9eb448a7e6 Use ubthidhci_enable="NO" to avoid the bootup warning.
Submitted by: 	Jilles Tjoelker <jilles@stack.nl>
MFC after:	3 days
2010-04-17 21:31:42 +00:00
Doug Barton 1a58736816 In case a user wants to configure only an IPv6 link-local address
add an example that shows how to do it.
2010-04-17 18:48:18 +00:00
Rui Paulo 7a246d0b14 Add ubthidhci.
MFC after:	2 days
2010-04-16 16:49:42 +00:00
Doug Barton d52bba9301 If a service is running, make 'stop' work even if ${name}_enable
is not set.

PR:		conf/130414
Submitted by:	Dominic Fandrey <kamikaze@bsdforen.de>
Reviewed by:	freebsd-rc@
2010-04-15 21:18:24 +00:00
Pawel Jakub Dawidek ceab1828a0 Use spaces instead of tab for indent here. 2010-04-15 16:43:43 +00:00
Hajimu UMEMOTO b2a99c9e28 Fix grammar in comment.
Submitted by:	"b. f." <bf1783__at__googlemail.com>
MFC after:	3 days
2010-04-11 15:31:09 +00:00
Rui Paulo c6c608b33d Add rc.d/ubthidhci. This small script calls usbconfig(1) to change a USB
Bluetooth controller from HID mode to HCI mode.

MFC after:	1 week
2010-04-09 17:32:38 +00:00
Doug Barton 8aa4c57946 Improve the handling of IPv6 configuration in rc.d. The ipv6_enable
and ipv6_ifconfig_<interface> options have already been deprecated,
these changes do not alter that.

With these changes any value set for ipv6_enable will emit a
warning. In order to avoid a POLA violation for the deprecation
of the option ipv6_enable=NO will still disable configuration
for all interfaces other than lo0. ipv6_enable=YES will not have
any effect, but will emit an additional warning. Support and
warnings for this option will be removed in FreeBSD 10.x.

Consistent with the current code, in order for IPv6 to be configured
on an interface (other than lo0) an ifconfig_<interface>_ipv6
option will have to be added to /etc/rc.conf[.local].

1. Clean up and minor optimizations for the following functions:
ifconfig_up (the ipv6 elements)
ipv6if
ipv6_autoconfif
get_if_var
_ifconfig_getargs
The cleanups generally were to move the "easy" tests earlier in the
functions, and consolidate duplicate code.

2. Stop overloading ipv6_prefer with the ability to disable IPv6
configuration.

3. Remove noafif() which was only ever called from ipv6_autoconfif.
Instead, simplify and integrate the tests into that function, and
convert the test to use is_wired_interface() instead of listing
wireless interfaces explicitly.

4. Integrate backwards compatibility for ipv6_ifconfig_<interface>
into _ifconfig_getargs. This dramatically simplifies the code in
all of the callers, and avoids a lot of other code duplication.

5. In rc.d/netoptions, add code for an ipv6_privacy option to use
RFC 4193 style pseudo-random addresses (this is what windows does
by default, FYI).

6. Add support for the [NO]RTADV options in ifconfig_getargs() and
ipv6_autoconfif(). In the latter, include support for the explicit
addition of [-]accept_rtadv in ifconfig_<interface>_ipv6 as is done
in the current code.

7. In rc.d/netif add a warning if $ipv6_enable is set, and remove
the set_rcvar_obsolete for it. Also remove the latter from
rc.d/ip6addrctl.

8. In /etc/defaults/rc.conf:

Add an example for RTADV configuration.

Set ipv6_network_interfaces to AUTO.

Switch ipv6_prefer to YES. If ipv6_enable is not set this will have
no effect.

Add a default for ipv6_privacy (NO).

9. Document all of this in rc.conf.5.
2010-04-09 01:35:09 +00:00
Hajimu UMEMOTO 296fe257cc Disambiguate `IPs' to a more specific term.
Submitted by:	Garrett Cooper <yanefbsd__at__gmail.com>
MFC after:	3 days
2010-04-08 15:19:57 +00:00
Hajimu UMEMOTO 3bcad5b785 firewall_trusted_ipv6 was gone by r202460. Remove stale comment about
it as well.
2010-04-07 18:14:30 +00:00
Doug Barton a6f9d19c1e In wait_for_pids(), pwait(1) can return when the process exits, but
still exists as a zombie. The 'kill -0' test in this function can
therefore return true even if the process isn't actually running.
This could lead to wait_for_pids() printing an endless string of the
pid number until the zombie finally exits.

Solve this problem by moving the sleep up to after the 'kill -0' test, but
only after we've run through the function once already. In the common case
(only one pid in the list) this will always do the right thing. On the rare
occasion that there is more than one pid in the list this will sleep 1
second per zombie process which will allow that process, and any other
in the list a chance to exit.

While I'm here, local'ize the variables that this function uses.
2010-04-06 05:20:46 +00:00
Dag-Erling Smørgrav 7336187439 Add -k to the recommended fingerd(8) command line.
MFC after:	2 weeks
2010-04-01 13:13:09 +00:00
Joerg Wunsch 42492c2c04 Add .snap to daily_clean_tmps_ignore; /tmp/.snap ist not supposed to
be auto-removed (and /tmp is a filesystem of its own now by default).

MFC after:	3 days
2010-03-23 06:19:44 +00:00
Ed Schouten 799c1824b1 Slightly improve my previous commit.
Just comment out the atrun line instead of completely removing it. It is
not a bad idea to leave it as a reference in case someone decides to
install atrun by hand afterwards.
2010-03-19 15:53:02 +00:00
Ed Schouten 5743a283c2 Don't add the atrun-line to the crontab when MK_AT is set.
This prevents spurious calls to sendmail every 5 minutes.

MFC after:	1 week
2010-03-19 11:59:02 +00:00
Jaakko Heinonen 7d4bbea850 Use an unique directory name instead of hardcoded /tmp/.diskless.
A malicious user could create a file named /tmp/.diskless and cause
the script to misbehave.

PR:		conf/141258
Reported by:	Jon Passki
MFC after:	1 week
2010-03-13 12:02:44 +00:00
Ed Schouten 43902e3587 Improve the contents of termcap.small.
- Remove dosansi, pc and pc3. I suspect nobody ever needs these.
- Add vt100, screen and xterm-color.

This file is now probably more than sufficient in most cases, even for
common use outside single user mode, where people just use the console
driver, a graphical terminal emulator and a terminal multiplexer.
2010-03-07 08:54:06 +00:00
Ed Schouten 52a7be6c43 Install termcap.small.
Right now we have a termcap.small in the tree, but we don't install it.
If we do install this file by default, it is more likely for
applications to work in single user mode.

I am not entirely happy with the contents of this file. In my opinion we
should remove the `dosansi', `pc' and `pc3' entries and replace them
with `vt100' in case someone uses a serial console.

The file does already have entries for `cons25' and `xterm', which is
used most often.

Requested by:	brucec
2010-03-07 08:30:21 +00:00
Doug Barton 5d3cc6a4f7 Implement the idea of parallel-only-at-start-time in a cleaner, more
rc.d'ish way.

Not objected to by:	netchild
2010-03-07 04:26:21 +00:00
Alexander Leidinger 333fb1c996 Redirect stdin from /dev/null when starting a jail:
At least in RELENG_7 this fixes some start problems for some programs
  from the ports. It is also more correct, as a jail shall not expect
  input (interactivity) from the jail-host.

Revert the current behavior of starting jails in the background and
make it optional only for the start of jails (jail_parallell_start=YES
in rc.conf):
 - The stop can not be done in the background, the system needs to wait
   until everything is stopped correctly before it can reboot or power
   down.
 - The start should not be done in parallel by default, this not only
   breaks POLA for people comming from RELENG_x, it may also break a
   dependency chain with other scripts in the jail-host, which need to
   do some stuff after the jails are up and running (e.g. hardlinking
   a mysql socket from one jail into another one).

Discussed on:	freebsd-jails@
2010-03-05 14:34:33 +00:00
Hajimu UMEMOTO f0cba49cf4 Add the shutdown KEYWORD.
Pointed out by:	dougb
MFC after:	3 days
2010-02-27 19:02:21 +00:00
Antoine Brodin 0a8ea2771a usr/share/examples/bc no longer exists. 2010-02-27 17:31:00 +00:00
Pawel Jakub Dawidek c3a9f615e6 Add missing KEYWORD line.
Pointed out by:	dougb
2010-02-19 09:18:26 +00:00
Xin LI 1b228b942e Create a directory for hast's examples. 2010-02-19 02:34:25 +00:00
Pawel Jakub Dawidek bc6237f5b0 Remove some lines left over by accident. 2010-02-18 23:20:15 +00:00
Pawel Jakub Dawidek 32115b105a Please welcome HAST - Highly Avalable Storage.
HAST allows to transparently store data on two physically separated machines
connected over the TCP/IP network. HAST works in Primary-Secondary
(Master-Backup, Master-Slave) configuration, which means that only one of the
cluster nodes can be active at any given time. Only Primary node is able to
handle I/O requests to HAST-managed devices. Currently HAST is limited to two
cluster nodes in total.

HAST operates on block level - it provides disk-like devices in /dev/hast/
directory for use by file systems and/or applications. Working on block level
makes it transparent for file systems and applications. There in no difference
between using HAST-provided device and raw disk, partition, etc. All of them
are just regular GEOM providers in FreeBSD.

For more information please consult hastd(8), hastctl(8) and hast.conf(5)
manual pages, as well as http://wiki.FreeBSD.org/HAST.

Sponsored by:	FreeBSD Foundation
Sponsored by:	OMCnet Internet Service GmbH
Sponsored by:	TransIP BV
2010-02-18 23:16:19 +00:00
Jung-uk Kim 5f19cffe55 Remove COMPILATIONDATE from the default section. This string is no longer
being substituted since r162063.

PR:		bin/143976
MFC after:	1 month
2010-02-16 01:07:06 +00:00
Maksim Yevmenkin fafa9c3c9a Introduce new rc.conf variable firewall_coscripts. It can be used to
specify list of executables and/or rc scripts that should be executed
after firewall starts/stops.

Submitted by:	Yuri Kurenkov <y dot kurenkov at init dot ru>
Reviewed by:	rhodes, rc@
MFC after:	1 week
2010-02-08 18:51:24 +00:00
Bruce M Simpson 243cecf517 Add sane-port (Scanner Access Now Easy) as port 6566.
Obtained from:  http://www.iana.org/assignments/port-numbers
MFC after:      3 days
2010-02-06 21:22:01 +00:00
Hajimu UMEMOTO e60d067996 Add rc.d script for the rtsold(8) daemon.
The rtsol(8) handles just one RA then exit.  So, the OtherConfig flag
may not be handled well by rtsol(8) in the environment where there are
multiple RA servers on the segment.  In such case, rtsold(8) will be
your friend.

Reviewed by:	hrs
MFC after:	2 weeks
2010-02-03 16:18:42 +00:00
Hajimu UMEMOTO af765eeb61 ManageSieve has been added as port 4190:
http://www.iana.org/assignments/port-numbers

Obtained from:	http://www.iana.org/assignments/port-numbers
MFC after:	3 day
2010-02-01 13:30:06 +00:00
Hajimu UMEMOTO 98255d746a Allow use of -6 option to "server" and "peer" in ntp.conf.
MFC after:	1 week
2010-01-30 16:34:52 +00:00