Commit Graph

2680 Commits

Author SHA1 Message Date
itojun 8306609bc4 correct -n handling. 2001-05-09 11:22:22 +00:00
itojun 219df672ab fix signal handling on ping6 -f <nonexisting peer>. from hash@iij.ad.jp.
sync with kame
2001-05-09 11:19:13 +00:00
tron d6be44d3c8 Add a new option "e" to "dump" which allows to eject tapes automatically
if a tape change is required.
2001-05-07 21:17:48 +00:00
kleink 017a840cd9 getopt(3): EOF -> -1. 2001-05-07 14:51:46 +00:00
simonb 1547b056d0 If the position of the formatted panic string can be found in the
message buffer, use that instead of the raw panic string.

Suggested by Jason Thorpe eons ago.
2001-05-06 13:36:51 +00:00
wiz bd49a98652 Improve wording of a sentence. misc/10893 by Jim Bernard, part 2. 2001-05-06 12:30:05 +00:00
wiz ccb6f40539 Improve usage of `comprise' according to Webster and misc/10893
by Jim Bernard.
2001-05-06 12:29:18 +00:00
fvdl 60f029933e Remove BUGS section, which only referred to performance tuning.
Instead, add a PERFORMANCE section which explains the most common
optimizations.
2001-05-02 12:18:45 +00:00
lukem 49137c3ddc clarify that -w updates the in-core label if changed, and if -r is
given as well, the on-disk label will then be updated.
2001-05-01 11:51:21 +00:00
itojun cb58c8c6b6 make -A a default. present MAC adderss on all ifconfig operations. 2001-04-28 04:11:10 +00:00
itojun 7d54359fb0 assume the presense of getifaddrs(3). 2001-04-28 00:00:06 +00:00
manu e0e227f2a3 Added a few examples and a reference to sysctl to enable IP forwarding
Approved by Christos
2001-04-27 19:33:06 +00:00
itojun 59ba739cf6 sync usage() more to the reality. document alias/-alias. 2001-04-27 09:10:04 +00:00
itojun be4c7a7c16 allow ifconfig to take "deprecated" and "-deprecated" for IPv6. sync with kame
sync usage() with reality.  take "up" and "down" outside of "[af ...],
as "up" and "down" are independent from interface address configuration.
2001-04-27 09:08:44 +00:00
wiz 09fc203c72 Add arch to Dt, and lots of whitespace fixes. 2001-04-21 14:44:13 +00:00
ad bd8e0b62fb Let '\377' be whitespace. 2001-04-17 13:31:00 +00:00
lukem f5cf87f961 add fix by Minoura Makoto to correctly support recursive extended partitions.
the offset of an extended sub-partition is the offset of the top-level
extended partition, not the partition before it (this is annoying, and
makes `clean' recursive mbr descent difficult).  fixes PRs 11829 and 12677.
2001-04-16 10:47:15 +00:00
itojun 5b3c802193 sync with if_lmcioctl.h change.
From: Bernd Ernesti <netbsd@arresum.inka.de>
2001-04-12 23:52:22 +00:00
agc c286afd376 "It's" is short for "it is". The possessive pronoun is "its". 2001-04-11 15:17:51 +00:00
mrg 32aec0200a add a section on swap priorities. document the round robin scheme.
fixes half of PR#12610.
2001-04-11 14:10:17 +00:00
wiz 8e78c80273 Make WARNS=2 safe, and set WARNS to 2. 2001-04-06 16:52:41 +00:00
wiz 14dbdf5518 Negative exit code cleanup: Replace exit(-x) with exit(x).
As seen on tech-userlevel.
2001-04-06 11:13:45 +00:00
jhawk 5e3565be65 Xr icmp(6), inet(6), ip(6) 2001-04-03 14:06:31 +00:00
jhawk 1277f0fe42 Xr icmp(4), inet(4), ip(4) 2001-04-03 14:00:09 +00:00
jdolecek 4fe147ddbf xref se(4) now that the manpage is built and installed 2001-04-03 11:51:33 +00:00
wiz 6fccda72ed Don't xref format(8) -- the man pages we have for it (hp300/vax) don't
seem very interesting at all, if not even obsolete.
Whitespace fixes while I'm here.
2001-04-03 11:21:57 +00:00
wiz b258a384eb Add section to .Xr. 2001-04-03 11:19:54 +00:00
wiz dd7acb43b8 Don't xref nonexisting se(4). 2001-04-03 11:18:53 +00:00
wiz 2d48dd26ee Xref send-pr 1, not 8. Whitespace fixes while I'm here. 2001-04-03 11:17:31 +00:00
wiz 7919f2a9a1 Don't xref gated(8) and htable(8), which we don't have. 2001-04-03 11:16:27 +00:00
wiz 4bb6958546 Xref rc.conf 5, not 8. Whitespace fixes while I'm here. 2001-04-03 11:09:01 +00:00
wiz 93709797b6 Xref newfs_lfs instead of newlfs; whitespace fixes while I'm here. 2001-04-03 11:07:50 +00:00
wiz f53dfc72b2 Xref exit 3, not 2. Whitespace fixes while I'm here. 2001-04-03 11:06:20 +00:00
ad 93e3741265 Remove superfluous newlines in calls to errx(). 2001-04-01 14:59:56 +00:00
drochner 98e00988ad Don't error out if the mbr cannot be read.
This makes "disklabel cd0" working also on platforms with MBR support.
2001-03-29 12:18:32 +00:00
itojun 4b72eeeee5 net.inet.ip.maxfragpackets defines the maximum size of ip reass queue
(prevents fragment flood from chewing up mbuf memory space).
derived from KAME net.inet6.ip6.maxfragpackets.
2001-03-27 02:24:38 +00:00
drochner 07c471d18e Do the last fix correctly: round the beginning of the .data segment,
otherwise an unaligned address gets passed to the linker. (which is
rounded there, so this is harmless)
XXX how about passing "-N" and killing all these hacks?
2001-03-26 15:50:20 +00:00
tsutsui 4dc9a92b20 Make and install ldconfig on ELF m68k ports. 2001-03-21 14:54:39 +00:00
itojun dc50d8510a examples. suggested by deraadt. sync with kame 2001-03-19 06:56:56 +00:00
thorpej 39dcc60032 Add a chkconfig(8) utility for managing rc.conf.d settings. Written
by Dan Mercer <dmercer@zembu.com>, inspired by the similar command that
appears in IRIX.
2001-03-14 03:51:46 +00:00
itojun 0a6cee32ec -Q is not there. some comsetic sync with kame. NetBSD PR 12384. 2001-03-12 03:42:17 +00:00
christos 4fea751ddc sync with version 2.24. Vernon says:
The most significant [fix] involves so called "remote" interfaces
configured in the kludge file to with what appear to be colliding
networks.  Edward Mascarenhas <eddiem@vihar.engr.sgi.com> found
the problem and the fix, and I think has tested it in the SGI
network.
2001-03-10 23:52:45 +00:00
chs 83d071a318 add UBC memory-usage balancing. we track the number of pages in use for
each of the basic types (anonymous data, executable image, cached files)
and prevent the pagedaemon from reusing a given page if that would reduce
the count of that type of page below a sysctl-setable minimum threshold.
the thresholds are controlled via three new sysctl tunables:
vm.anonmin, vm.vnodemin, and vm.vtextmin.  these tunables are the
percentages of pageable memory reserved for each usage, and we do not allow
the sum of the minimums to be more than 95% so that there's always some
memory that can be reused.
2001-03-09 01:02:10 +00:00
fair 676026bddb Clarify the description of "preen" mode, per PR 12110 2001-03-07 23:48:54 +00:00
thorpej 6f05b85270 Make this manual page a lot more helpful. 2001-03-06 20:12:33 +00:00
aymeric 93564fe83d Move reference to article on soft-updates from tunefs.8 to mount_ffs.8
OK'd by Ignatios.
2001-03-05 23:18:09 +00:00
ad edb647f542 Fix typo. 2001-03-02 17:57:34 +00:00
itojun db6f3bcf39 whitespace at EOL 2001-03-01 08:35:16 +00:00
itojun b57caf4727 on "tunnel" subcommand, use specified address family. 2001-03-01 08:34:10 +00:00
is 9b2152236c error code formatting 2001-02-25 20:41:43 +00:00
is 22bb5ac981 Note that the ados fs is read-only, and that mount_ados falls back to
read-only mounts now.
2001-02-25 20:37:15 +00:00
christos b58136d76c PR/12275:Kimmo Suominen: show -C in usage 2001-02-23 19:49:54 +00:00
christos 28e741ef5e fix compile errors. 2001-02-23 07:51:41 +00:00
is 05378de234 Silently fall back to read-only mounting, when we get EROFS.
We do not want to enforce read-only mounting (like mount_iso does)
because we want to write adosfs writing code eventually.
2001-02-22 21:34:57 +00:00
cgd d7666f6c7f use getprogname() 2001-02-20 23:22:49 +00:00
itojun 1e48b7fbb5 add SIOC[SG]LIFPHYADDR ioctl. greatly simplify tunnel address settings.
sync with kame.  old ioctls are supplied but not recommended for new code.
2001-02-20 15:35:19 +00:00
bjh21 0009ba56a7 Add a dependency on libm. 2001-02-20 00:15:56 +00:00
cgd 8a986b2e96 convert to use getprogname() 2001-02-19 22:48:57 +00:00
tsutsui 899149f1e5 Add x_mount, which does not include any MOUNT_PROGS.
Installer does not require all vfs progs and all binaries
are crunched after all.
2001-02-18 06:15:48 +00:00
lukem ed9bdbd8b9 - remove unused arg to getparts()
- clean up WARNS=2 problems
- implement getshort()
- use getshort() with MBR_MAGICOFF to test if the magic number is OK, rather
  than using hard-coded magic numbers
2001-02-18 03:36:07 +00:00
thorpej 617bd311bc Add a "deleteall" command that takes a src/dst/protocol. 2001-02-16 23:55:05 +00:00
minoura 2fafdf112c Descend to mount_* subdirs when cleandir, in addition to clean and distclean. 2001-02-14 14:21:08 +00:00
ad a42efe450c Fix typo. 2001-02-11 13:04:22 +00:00
itojun 22b473e0f6 during ip6/icmp6 inbound packet processing, do not call log() nor printf() in
normal operation (/var can get filled up by flodding bogus packets).
sysctl net.inet6.icmp6.nd6_debug will turn on diagnostic messages.
(#define ND6_DEBUG will turn it on by default)

improve stats in ND6 code.

lots of synchronziation with kame (including comments and cometic ones).
2001-02-07 08:59:47 +00:00
christos 180360ac44 remove redundant decl 2001-02-04 21:56:11 +00:00
christos df49c4a876 fix nested extern 2001-02-04 21:53:39 +00:00
christos aceee3f06d fix redundant decls 2001-02-04 21:52:02 +00:00
christos 93292f2f1a revert previous change; not needed. 2001-02-04 21:38:34 +00:00
christos abc5ad9724 fix nested extern 2001-02-04 21:38:01 +00:00
christos b9140b5b9f restore needs the rcmd operations. 2001-02-04 21:37:29 +00:00
christos 91a0880aad fix redundant decls 2001-02-04 21:33:19 +00:00
christos 566662ba06 remove redundant declarations 2001-02-04 21:25:54 +00:00
christos 422d686664 fix nested extern and duplicate declarations 2001-02-04 21:19:34 +00:00
christos 3aed6f1e40 avoid redundant declaration 2001-02-04 21:16:59 +00:00
christos a2c613b344 fix nested extern 2001-02-04 21:14:32 +00:00
christos 252e11ea2b fix nested extern. 2001-02-04 21:13:12 +00:00
christos f156d24d3f fix nested extern 2001-02-04 21:11:47 +00:00
christos 55692aa513 remove nested externs. 2001-02-04 21:09:07 +00:00
christos e2571306fb remove redundant prototypes. 2001-02-04 21:05:42 +00:00
christos a84f9073c7 fix nested extern 2001-02-04 20:09:40 +00:00
christos 158632e207 ifix nested extern. 2001-02-04 20:08:24 +00:00
christos 1e41af421a remove redundant declaration 2001-02-04 20:06:51 +00:00
christos f0cf3bcdfb fix nested externs 2001-02-04 20:05:20 +00:00
christos ccc59bf1d7 fix nested extern. While I am here assign copyright to TNF. 2001-02-04 20:04:02 +00:00
christos 8358095fd4 remove redundant declarations and nested externs. 2001-02-04 19:59:37 +00:00
christos ee002727d9 fix nested extern 2001-02-04 19:54:56 +00:00
itojun ad65d3d893 correct recvmsg() validation. 2001-02-04 00:35:20 +00:00
thorpej cab4d17202 Sprinkle some const. 2001-01-28 00:59:26 +00:00
oster 705631a231 Move parts of a RAID type mapping table from rf_layout.c to rf_configure.c.
This means we don't need to compile or link with rf_layout.c here.
2001-01-27 19:32:47 +00:00
itojun 08087050ed support -cloned command line flag.
i don't think anyone ever going to use it.
2001-01-27 04:53:13 +00:00
itojun 6a04f28b13 regen 2001-01-27 04:51:25 +00:00
itojun 16595a06cf add a keyword, cloned 2001-01-27 04:51:17 +00:00
itojun fee00b1a78 mark cloned routes with RTF_CLONED. present it with netstat -r by "c".
let static routes overwrite cloned routes, as cloned routes can come back again
if necessary.  behavior same as freebsd/bsdi, code partially from bsdi42.
(NRL rt->rt_parent was not added)
should fix PR 11916 and maybe some other PRs with ARP behavior.

recompilation of usr.sbin/route6d is suggested.
2001-01-27 04:49:31 +00:00
itojun ad678343e6 support RTF_BLACKHOLE.
XXX route show is total duplicate of netstat -r, we need to either remove
route show, or share the same source code, otherwise maintenance cost
bites (and is biting) us
2001-01-27 04:26:49 +00:00
itojun d9196c1881 remove use of uninitialized route (struct ortentry).
it seems that the bug was born during 4.3reno -> 4.4Lite1 transition.
2001-01-27 03:20:29 +00:00
hubertf 331005f88b Document that there's currently no registry for vendor sysctls.
After discussion with John Hawkinson and Frank van der Linden.
2001-01-26 21:13:23 +00:00
thorpej 9c45d4b02d In pass 5, check alternate superblocks for consistency with
the current in-core master superblock, and fix them up if
they're incorrect.  Move the code that writes the alternate
superblocks if (cvtlevel || doswap) into pass 5 for efficiency.

Reviewd by Charles Hannum, and used by me to fix up a curdled
file system.
2001-01-26 17:37:16 +00:00
itojun e42b253d93 more simpler signal handling. be more friendly with 4.3BSD-ish socket API
(linux/USAGI folks are using the code).  sync with kame.
2001-01-26 13:18:45 +00:00
enami cdf90f8e31 Remove incorrect advice for lint; the control may return from panic(). 2001-01-24 23:14:04 +00:00
garbled b17f8c01fa Fix the usage string so it displays the -b and s options to ifconfig -l 2001-01-24 18:06:51 +00:00
mycroft 1fa165bd82 Fix a rather glaring byte-swapping bug: di_size is 64 bits, not 16. 2001-01-23 02:35:51 +00:00
enami 2efd21a284 If possible, detect more case that file is missing on the tape.
XXX we still may lose if a file of highest inode number requested
XXX to extract was missing or one of multiple dump tape is lost.
2001-01-18 08:59:23 +00:00
fvdl 93beca224d Fix spelling. 2001-01-17 11:58:33 +00:00
fvdl 6129a28444 Document -o linux option. 2001-01-17 11:57:54 +00:00
itojun b3705ee26f unbroken slash notation (10.0.0.0/8) for IPv4. 2001-01-17 06:10:37 +00:00
itojun f3a31dc12d support "prefixlen n" for IPv4 too. 2001-01-17 06:07:32 +00:00
fvdl a7fede800b Add handling of -o linux. 2001-01-17 00:09:54 +00:00
cgd d594ce939b comment or delete text after CPP directives. 2001-01-16 02:50:27 +00:00
cgd 09995c7b56 generated source should include stdlib.h and string.h for prototypes. 2001-01-16 02:37:35 +00:00
itojun 7846de58b2 specify interface by using interface index (set/getsockopt with 0.0.0.0/8). 2001-01-15 13:19:12 +00:00
christos 8ce2d80d7a back out previous; it is better for now to handle the dependencies in
bsd.prog.mk
2001-01-14 09:41:41 +00:00
christos c26e2519ac add .NOTMAIN for good measure. 2001-01-14 09:24:30 +00:00
christos 726afedd26 don't use OBJS in the dependency line because it is not defined yet. 2001-01-14 09:22:01 +00:00
christos 9b6a2fbeb4 don't use OBJ in the dependency line cause it is not defined yet. 2001-01-14 09:21:24 +00:00
itojun b2f011d7b6 avoid signal handler race. help from deraadt 2001-01-12 19:13:41 +00:00
itojun 3a616a4855 correct use of howmany() for fd_set. commented by deraadt 2001-01-12 18:50:57 +00:00
martin 1bb8e47f65 Make option flag variables static. This avoids a conflict between
'int compress' in savecore.c and the function 'compress' in libz.
Gnu ld 2.10 (with BFD 2.10) used on sparc64 warns this conflict
(symbol "compress" changed size).
2001-01-11 20:27:12 +00:00
soren 65c1d02861 Remove extern __progname from enable_user(); no longer used. 2001-01-11 16:37:41 +00:00
lukem 0645f2f67b use explicit name rather than __progname in openlog 2001-01-11 01:34:28 +00:00
lukem 3efcec3cf5 remove unnecessary ":" in openlog ident 2001-01-11 01:33:35 +00:00
mycroft 521984e793 Whoops; call propagate() with the right child inode number. (Doesn't break
anything, but it would have made reconnect less efficient.)
2001-01-10 08:26:20 +00:00
mycroft f5a9d5eadc Abstract the code to attach a directory to its parent's child list into a
separate function, and call it from multiple places in linkup() to handle
reconnects and creation of /lost+found.
2001-01-10 08:22:20 +00:00
lukem d4b8ad46d7 don't use LOG_CONS
fix typo
2001-01-10 07:59:43 +00:00
lukem 790602fd72 deprecate LOG_ODELAY; it's the default 2001-01-10 03:47:41 +00:00
lukem f022cce90b use openlog correctly... 2001-01-10 03:41:35 +00:00
lukem 415d1abdd8 be consistent (both internally and with other programs):
log_err		fatal errors
	log_warning	non-fatal errors & warnings
	log_debug	debug messages (#ifdef DEBUG)
2001-01-10 03:33:16 +00:00
hubertf 44d7ee0289 * Document the vendor.* sysctl branch
* in sysctl.3, sort the list of CTL_ prefixes and sync with sysctl.h
2001-01-10 03:03:02 +00:00
lukem 37a54a1e9c deprecate LOG_ODELAY; it's the default 2001-01-10 03:01:41 +00:00
fvdl 4f289ff858 Number of toplevel names grew by one, account for it. 2001-01-09 21:31:02 +00:00
augustss e85ca50c79 Document what can happen with bad Rock Ridge info on the CD.
(Perhaps this can save someone the two hours I spent in the kernel
debugger tracking this down. :)
2001-01-09 20:51:26 +00:00
mycroft d722519e03 Make sure the rotor values are non-negative. 2001-01-09 11:20:00 +00:00
mycroft a48409305d A minor tweak. 2001-01-09 09:25:32 +00:00
enami 6c06fd4f9f Don't swap cg_clustersum(cg)[0]. It doesn't actually exists and it's
actually tail of free block bitmap.

XXX swap_cg() should be shared with newfs.
2001-01-09 09:08:35 +00:00
mycroft c4c9a7ecc0 Remove a bogus piece of code that was never used. 2001-01-09 06:05:10 +00:00
mycroft 66418680d4 The reconnect algorithm was historically O(n^4).
Some years ago I made it O(n^2).
Someone helpfully made it O(n^4) again.
Today I'm making it O(n).
If that's not good enough, I don't know what else to do.  B-)

Technical details:
* The graph traversal in propagate() is modified to be able to start from any
  point in the tree.  To handle certain exceptional cases, it is also modified
  to work in two passes, marking the tree with a special tag and then changing
  it to DFOUND.
* The reconnect case now modifies the child/sibling pointers and calls
  propagate() to propagate the connection state starting with the reconnected
  directory.

Pray that you never encounter a file system trashed enough for this to matter.
2001-01-09 05:51:14 +00:00
mycroft 3f2ff10f4c Try to cope with cs_ndir being wacky (too large or, particularly when using -b,
too damn small) by setting a minimum (1024) and maximum (maxino + 1).  This
prevents certain operations getting REALLY slow when -b is used, and also
avoids overallocating memory if the superblock is hosed.
2001-01-09 05:39:27 +00:00
itojun c5520fd00b uninitialized pointer. PR 11702 2001-01-08 14:06:12 +00:00
fvdl 275b941468 When -I is specified, we mean to initialize the label if it's not there
already. So, don't fail if there appears to be a corrupt label or
no 'fake' label; get the 'default' label (which is generated
from DIOCGDEFLABEL) instead.
2001-01-08 02:19:58 +00:00
joff 42ac80ad6d Fixed blockmap handling to properly use disk blocks rather than fragments.
Fixes an issue with fsck_lfs not detecting all duplicate blocks that may
exist in a corrupted filesystem.
2001-01-06 23:08:24 +00:00
cgd 169563b7c1 #warn is _not_ the GCC CPP directive that gives a warning, #warning is.
(this code has, apparently, always been wrong, but current GCC is kind
enough to warn about unknown CPP directives.)
2001-01-06 00:35:54 +00:00
lukem f7650338ca use %ll_ instead of the less standard %q_ 2001-01-05 02:02:57 +00:00
lukem ca48483336 minor knf 2001-01-05 01:41:34 +00:00
lukem 03c663afbc change verbose probe message to display "size xxx (yyy MB), offset zzz".
use %u instead of %d.
2001-01-04 00:57:14 +00:00
enami 0cd4f6f4aa Test read(2) failure by read(..., sizeof(n)) != sizeof(n) instead of
< sizeof(n) to avoid unwanted type promotion.
2001-01-03 06:57:57 +00:00
enami a48aa06c73 Kill whitespace at the end of line. 2001-01-03 06:55:30 +00:00
joda 7e74657e37 use gzip instead of compress 2001-01-02 21:39:37 +00:00
lukem 834e92eedc Bump the field width of `K to go' from 6 to 8; some systems have more
than 999999 KB of RAM... (this will suffice until it's common to have
~ 100 GB of RAM :)
2001-01-02 00:29:37 +00:00
itojun 1bc3ecd398 support IPv6. PR 11858 from ura@hiru.aoba.yokohama.jp 2000-12-31 06:03:52 +00:00
itojun f911e7eded indent and pedant. from deraadt. sync with kame 2000-12-31 05:04:15 +00:00
wiz 944d6ad333 Check return value of fgets. Approved by Greg Oster. 2000-12-31 01:58:03 +00:00
wiz 4b4b4ba4ae Fix typo in v1.38. 2000-12-30 15:32:19 +00:00
wiz f81de5856b sprinkle some const's 2000-12-30 15:03:23 +00:00
wiz 369f36b84f ANSIfy and de-__P() 2000-12-30 15:01:42 +00:00
wiz fb109fb5fa Handle NULL return value by fgets after shell prompt better. Also
improve '\n' slightly. Addresses bin/11847.
2000-12-30 14:46:21 +00:00
itojun 66927d4789 move racoon build framework from sbin/racoon to usr.sbin/racoon. 2000-12-29 02:33:38 +00:00
jdolecek f334b7ef55 make sure that elf_mod_sizes() uses data_hole size aligned to section alignment
this fixes a problem where elf_mod_sizes() would report size which would
be different (smaller) that the actual size of LKM code to be loaded in some
cases

Reviewed by: Johan Danielsson
2000-12-27 20:29:36 +00:00
lukem fbace08ced change behaviour of flags slightly:
-w	write in-core label if changed
-r	update on-disk as well as in-core label (with -w)
-f	force update (-w), even if there's been no change

-r behaviour suggested by matt green. what used to be `-f' is now `-wrf'
2000-12-27 04:22:11 +00:00
lukem a9dd32dbb7 more rewording
- mbrlabel updates the disklabel; it doesn't generate it
- it doesn't just affect the incore label, so remove the `incore' qualifier
2000-12-24 14:01:12 +00:00
lukem 747375caa2 i got sick of the brain damage that mbrlabel used to do, and had
gotten bitten by mbrlabel trashing my incore disklabel to a point where
the machine wasn't usable, so I reworked it:

* only update the incore (and on-disk) label if `-f' is given. by default,
  the proposed disklabel will be printed but no changes will occur
* add -q, to make the default operation a bit more quiet.
* leave existing `used' in-core partition slots alone, and only add entries
  to the incore label if:
	- there's not an existing partition of the same size and offset
	  (even of a different type)
	- there's a free partition slot (`unused', with size == 0)
* use DIOCWDINFO instead of DIOCSDINFO, to update the incore as well as
  the on-disk label
* use showpartitions() from ../disklabel/printlabel.c

this should make mbrlabel a *lot* more useful.
2000-12-24 13:57:37 +00:00
lukem 45c96da8ec use MBR_IS_EXTENDED() instead of local test (which was missing a test case) 2000-12-24 13:32:41 +00:00
lukem 1c5cb88e30 move showinfo() and showpartition() into separate file, for use by
other programs.  slightly change argument signature so that globals
aren't depended upon.
2000-12-24 07:08:02 +00:00
lukem 35ccd2239b - convert to KNF ANSI style guide
- reorder arguments of runcmd(), getnum(), defnum() to be consistent
  with other functions (pass struct disklabel * first)
2000-12-24 05:59:11 +00:00
wiz c73aec3795 Add NTFS recognition per patch supplied by Dave Huang in bin/11804. 2000-12-24 01:54:20 +00:00
wiz 71288952b7 ANSIfy, de-__P() 2000-12-24 01:50:29 +00:00
enami 2f0c4425ee Don't swap clustersum[0]. It's not a cluster summery but block free bitmap. 2000-12-23 12:32:12 +00:00
itojun b7b4590361 call seteuid(getuid) too 2000-12-22 05:52:21 +00:00
itojun ef86e1e3da revoke root privilege earlierst possible. 2000-12-22 00:34:46 +00:00
itojun 8f5f80ebfe document net.inet6.icmp6.mtudisc_{lo,hi}wat. 2000-12-21 01:10:52 +00:00
cgd 2ed72303ae avoid use of ANSI C trigraph ??/ 2000-12-20 01:05:22 +00:00
cgd 30b3e4f5c7 __CONCAT does token pasting, not string concatnation. if something like:
__CONCAT("foo","bar");
actually works to concantate strings, it's because the preprocessor expands
it into "foo""bar" as separate strings, and then ANSI string concatenation
is performed on that.  It's more straightforward to just use ANSI string
concatenation directly, and newer GCCs complain (rightly) about misuse
of token pasting.
2000-12-20 00:31:41 +00:00
lukem 0f2402d559 * Recursively print out extended partition entries. An extended partition is
effectively an MBR with it's own partition table which contains another
  4 `slots', each of which can be another extended partition...
  This involved reworking some of the internal functions.
* Use off_t appropriately (so we can manipulate sectors past 4GB).
* Tweak to compile with WARNS=2
2000-12-19 16:01:28 +00:00
lukem b813a81a7c convert to ANSI KNF 2000-12-19 15:44:27 +00:00
lukem a67eb3719f list the options in a specific options list (as per the `traditional'
man page). i find this much easier to read than option descriptions
scattered amongst paragraphs of text.
2000-12-18 23:42:40 +00:00
simonb 6714e09fe2 Need an lfdir global variable now. 2000-12-14 00:32:22 +00:00
scw e89e2124d1 Global variables don't need to be initialised to zero. 2000-12-13 22:45:12 +00:00
scw 8c5df3aa33 `dev_bsize' needs to be declared extern. 2000-12-13 22:44:44 +00:00
scw 9482a2a194 Some more `extern's for initialised globals. 2000-12-13 22:38:15 +00:00
mycroft 078acb237c Fix an annoyingly incorrect message. 2000-12-13 03:04:51 +00:00
itojun e845d2144b make kerberos *.o conditional. 2000-12-12 22:41:51 +00:00
onoe 86d874c2bf Add powersave/powersavesleep into usage.
Fold usage output (still 14 lines...)
2000-12-12 20:27:42 +00:00
onoe f56e1f272f powersavesleep requires argument 2000-12-12 20:22:45 +00:00
thorpej f293b8799b Update for changes to KAME-current. racoon(8) now supports GSSAPI-Krb5
authentication for Phase 1 per dratf-ietf-ipsec-isakmp-gss-auth-06.txt.

This work was done by Frank van der Linden of Wasabi Systems, Inc.
under contract from Zembu Labs, Inc.
2000-12-12 17:18:58 +00:00
thorpej b22f104458 Add powersave, -powersave, and powersavesleep to manipulate 802.11
power management parameters.
2000-12-12 04:08:40 +00:00
wiz 9bf97e8322 Back out sysctl part for now, awaiting the result of further discussion,
on request of Andrew Doran.
2000-12-11 14:33:51 +00:00
wiz 4c06e7a434 Output proper warning if dumplo == -1 (as it can happen on macppc without
swap partition), instead of "kvm_dump_mkheader: Pread: Invalid argument".
2000-12-08 22:03:23 +00:00
wiz ba968ca2e4 de-__P(), and generally try to be more conforming to the new NetBSD style.
Use %m in syslog strings where appropriate.
Reduce warnings with WARNS=2.
2000-12-07 03:55:44 +00:00
wiz a934922366 Don't mention rc(8), we're using rc.d now. 2000-12-07 03:18:03 +00:00
wiz e7fe5f1380 Fix argument handling, which was pretty broken.
If sysctl supports it, try to get the kernel name with CPU_BOOTED_KERNEL.
Get current kernels version string in all cases.
Adapt some error messages to the correct kernel name.
Reviewed by Simon Burge.
2000-12-07 03:17:17 +00:00
perseant 8a3e9fdf9d Add "-A" option to autoconfigure the segment size based on measured
bandwidth and seek time of the disk, using the "4 * bandwidth * seek
time" formula from Neefe-Matthews' 1997 paper.  An RZ25 disk with this
option gets 200K segments.  Reference the paper in the manual page.
2000-12-05 19:51:14 +00:00
scw 222e7ea5ea Fix a bug introduced by 4.4-Lite:
Don't try to subtract the address of "acg.cg_firstfield" from
"acg.cg_nextfreeoff", as it's already relative to the start of "&acg".
This always worked because the result of the subtraction was
always negative, thus could never be > "sblock.fs_cgsize" ...
2000-12-04 09:59:48 +00:00
itojun bbaa97fa45 sync with latest kame.
- validate strdup() error on argument parsing.
- use strlcat on complex string manipulation.
2000-12-02 02:54:21 +00:00
simonb c878d09614 For mount_mfs, allow an 'm' suffix to the file system size option to
specify the size of the mfs in megabytes.

Inspired by the Solaris tmpfs "-o size=sz" option.
2000-12-01 12:48:09 +00:00
simonb b234617a20 Put extern variable declarations in "extern.h". 2000-12-01 12:03:27 +00:00
simonb 06cbcf7494 ANSIfy. 2000-12-01 11:52:54 +00:00
perseant ea919b5343 Change "cpg" to "cpg/sgs" in the printed partition table header, in an
attempt to avoid confusion.  (PR #9230)
2000-11-27 23:13:12 +00:00
ad 1b9fadaf46 typo 2000-11-26 15:13:19 +00:00
perseant 262e70b7e7 Initialize inodes' generation number to 1, consistent with their version
number.
2000-11-23 23:09:57 +00:00
perseant 7c5a881d60 Check/fix accounting of lfs_dmeta. Patch from Jesse Off
<joff@gci-net.com> (PR #11534).
2000-11-21 06:24:26 +00:00
lukem ddbba91107 fix incorrect comment; -d does work! 2000-11-17 12:35:09 +00:00
mrg f44b54e376 support new `swapctl -z' that shows the dump device. 2000-11-17 11:43:41 +00:00
jdolecek bec09f2dd9 also visit mount_* for 'make clean' and 'make distclean'
Pointed out by Minoura Makoto in private e-mail.
2000-11-16 08:07:55 +00:00
abs fc52578672 xref (disklabel.8, fdisk.8, mbrlabel.8) as appropriate 2000-11-14 11:06:19 +00:00
perseant 9683b76b99 Try to prevent running more than one active cleaner on a filesystem at a time.
Let lfs_cleanerd record its pid in /var/run like other daemons.  Make
mount_lfs not start another cleaner when updating the mount, unless it is
being upgraded from read-only to read-write; when downgrading to read-only,
kill the cleaner using the recorded pids.
2000-11-13 22:12:49 +00:00
jdolecek 57e4e7265b add mount_* to SUBDIR for 'make obj', so that the obj directories get
created and used. Some ramdisks compile individual mount_* commands
directly and hence need the obj dirs setup in order to allow shared
source tree.
Noted in private mail by Andrew Brown <atatat@atatdot.net>.
2000-11-13 05:29:31 +00:00
perseant a3bb9e16b4 Report, and detect and correct inconsistencies in, the number of clean
segments.  Patches from Jesse Off <joff@gci-net.com> (PR #11470).
2000-11-13 00:30:48 +00:00
perseant 5975446609 Add "-f" flag to match fsck(8) manual page. This flag currently has no
effect.  Fixes PR #11129.
2000-11-11 22:26:10 +00:00
itojun a21e536042 improve spec conformance of node information query (07).
sync with kame.
2000-11-11 00:46:36 +00:00
enami d86faab485 Cosmetic change; actually split a line which looks like as if two lines. 2000-11-10 03:12:45 +00:00
eeh 59da39b946 Document new hw.cnmagic sysctl(8) variable. 2000-11-08 22:48:32 +00:00
hubertf 1320b80b0e xref lfs_cleanerd(8) in SEE ALSO 2000-11-08 19:43:16 +00:00
hubertf cf64122954 xref dump_lfs(8), newfs_lfs(8) in SEE ALSO 2000-11-08 19:40:04 +00:00
hubertf 4fdbe215a1 In SEE ALSO:
* it's dump_lfs(8), not dumplfs(8)
 * xref mount_lfs(8)
2000-11-08 19:37:46 +00:00
itojun 9df2062a31 - fix -s with small number (like < 8). kame 1.97 -> 1.99
- add fflush.  kame 1.96 -> 1.97
- alpha friendly (printf format - %ld and others)  kame 1.93 -> 1.94
sync with kame
2000-11-08 12:05:09 +00:00
itojun 374c623f95 show IPv6 interface address status "deprecated" (preferred lifetime = 0).
RFC2462.  sync with kame.
2000-11-07 14:47:59 +00:00
lukem 279552d3db fix up various .Nm abuses:
- keep the case consistent between the actual name and what's referenced.
  e.g, if it's `foo', don't use '.Nm Foo' at the start of a sentence.
- remove unnecessary `.Nm foo' after the first occurrence (except for
  using `.Nm ""' if there's stuff following, or for the 2nd and so on
  occurrences in a SYNOPSIS
- use Sx, Ic, Li, Em, Sq, and Xr as appropriate
2000-11-07 06:43:24 +00:00
lukem 42039d09f9 use .Xr 2000-11-07 05:40:17 +00:00
jdolecek 73367a6dad convert to use regex (it used compat regexp previously), g/c now unneded stuff 2000-11-06 14:05:54 +00:00
jdolecek 252a9be46b use mkdtemp(3) instead of mktemp(3)
call daemon(3) before the mount(2) call, so that we can fill correct pid
   to mount tag argument (previous code used getpid() + 1!)
2000-11-06 14:00:38 +00:00
jdolecek 7e315846e9 put in some commas, remove newlines 2000-11-06 13:53:53 +00:00
jdolecek bb40143374 fix typo 2000-11-06 12:34:25 +00:00
minoura f23be04b99 #include <string.h> for strlen() and strcpy(). 2000-11-06 07:48:28 +00:00
thorpej 7d56b25984 Visit wdogctl. 2000-11-04 18:54:13 +00:00
thorpej fb6f7d6f21 Add a program to manipulate watchdog timers. 2000-11-04 18:53:30 +00:00
jdolecek 33e5945c93 also install mount_ufs manpage links
Fixes bin/11412 by Andrew Brown.
2000-11-02 18:02:16 +00:00
veego 3cae956077 Add a 'CLEANFILES+= checkname.c' to remove that file during a make clean. 2000-11-01 08:45:20 +00:00
enami 4952afaa4f Factor out some function declarations into a header file. 2000-11-01 04:10:02 +00:00
enami 290c3a67ba When failed to read disklabel to deduce filesystem type,
- don't warn.  It's just too verbose when we know there is
	  no disklabel and want to use the default filesystem type.
	- close the file descriptor so that further mount success.
2000-11-01 04:06:49 +00:00
enami a56e1ec458 Cosmetic changes. 2000-11-01 04:01:45 +00:00
lukem 4e9651bacd - use opendisk(3) instead of homegrown solution
- separate items in -s output with commas; much easier to read
- add maxOutstanding (aka queue len) to -s output
- sort #includes (per knf)
2000-10-31 14:18:39 +00:00
jdolecek 366b58f084 mount(8) now includes code for all mount_*(8) but mount_portal(8) and
mount_mfs(8); the mount_*(8) are hardlinked to mount (appropriate mount routine
is called depending on program name) - this saves approx. 1.7MB of /sbin
space
mount.c: make all local symbols static
2000-10-30 21:31:49 +00:00
jdolecek 3d64d110ca fix copyright (damned copy&paste) 2000-10-30 20:58:20 +00:00
jdolecek debb6d80a3 make the code includable into other programs:
* make static all symbols which do not need to be exported
* rename main() to mount_FOO()
* new main() now just calls mount_FOO(), main() is only compiled in if
  MOUNT_NOMAIN is not defined
* a_gid(), a_uid() and a_mask() were put into ../mount/fattr.[ch], local
  versions removed
2000-10-30 20:56:57 +00:00
itojun 00f86cf2f4 use YHEADER, not YFLAGS+=-d. from kre 2000-10-29 12:32:06 +00:00
oster 617759aa4c - cleanup wording and add additional comments on such things as
"component1" and "raidctl -A yes"
- add a note about how to build a RAID set with a limited number of disks
    (thanks to Simon Burge for suggestions)
- improve layout of 'raidctl -i' discussion (thanks to Hubert Feyrer)
- add a (small) section on Performance Tuning
2000-10-27 02:40:37 +00:00
jdolecek 6a6f9705de add couple of missing entries, update kern.maxptys entry - it is not raise only 2000-10-26 07:35:56 +00:00
fvdl 2753597fd4 Disable VERBOSE_BLOCKMAP by default; it allocates huge amounts of
memory, causing immediate fsck_lfs failure for big filesystems.
2000-10-19 14:58:40 +00:00
kleink e90b215b52 Don't make references to _10Mb/s_ Ethernet where not appropriate; from
Christian Weisgerber.
2000-10-18 07:27:11 +00:00
simonb 9b22175a26 Remove INSTALLFLAGS=-fschg, as per change to usr.bin/ssh/ssh/Makefile. 2000-10-18 00:24:18 +00:00
wiz af69e93eb8 change mentioning of `login' to a .Xr in one place 2000-10-17 01:07:43 +00:00
itojun 055f6cd999 have description on -v. sync with kame 2000-10-15 13:43:51 +00:00
bjh21 c6f45d411c Ah, so _that_'s how you get a backslash in a macro argument.
Thanks to itojun for pointing it out.
2000-10-15 13:40:53 +00:00
bjh21 ebd0b719b0 Various formatting cleanups (mostly to use .Ql).
Note that getting a single backslash inside Ql seems to need SIXTEEN
of them in the source!
2000-10-15 13:21:40 +00:00
itojun 593affa94c do not segv on too many args. sync with kame 2000-10-12 10:35:48 +00:00
he 5b7047ce18 The type of sizeof() can be u_long, so cast to that and print with %ld. 2000-10-11 21:08:54 +00:00
he e3ab5a24f9 Format fixup. size_t can be long, so cast to u_long and print with %ld. 2000-10-11 21:02:05 +00:00
he ecaef6e7a4 Better fix for format warnings.
The type of time_t varies between ports, so we need to cast
before printing.  It appears to be sufficient and safe to use (int).
2000-10-11 20:25:29 +00:00
abs 5d868db883 When determining the filesystem type automatically, only try the raw device
for the disklabel if the given device fails with EBUSY. Also make disklabel
errors non fatal (just fall back to ffs as per pre-autofilesystem behaviour)
Based on further discussion with Launey Thomas <ljt@alum.mit.edu>
2000-10-11 17:56:05 +00:00
itojun 874bb03cac make the directory suitable with with latest racoon
- add random.c.
- don't suppress warning.
2000-10-11 05:41:18 +00:00
briggs 1e8e167a26 Fix format warnings 2000-10-11 04:57:42 +00:00
is 9979da6cbb Format string cleanups by Bill Sommerfeld. 2000-10-10 20:24:49 +00:00
itojun d72739fb8a on "route monitor", print RTM_IFANNOUNCE, RTM_IFINFO (new #), and others. 2000-10-10 09:35:05 +00:00
christos c4c61b5a08 allow -I -i to install a new label interactively. 2000-10-08 23:32:50 +00:00
bjh21 162b0b6410 Miscellaneous -mdoc cleanups. 2000-10-08 09:53:00 +00:00
bjh21 30ee56ec59 Mention that ldconfig is a.out only.
Should fix PR bin/10299.
2000-10-08 09:33:13 +00:00
darrenr a2d10b89c2 initialize kernel to _PATH_UNIX and remove local variables in functions
which are essentially copies of kernel.
2000-10-08 07:04:28 +00:00
itojun b91818e7e8 fix truncated response handling; sync with kame 2000-10-08 00:26:38 +00:00
itojun 794318ceff avoid fd_set overflow. see openbsd select(2). 2000-10-07 06:50:43 +00:00
itojun c0de460728 repair fd_set size attack. from deraadt.
some of cleanups from kame (inet_ntop error check, unnecessary headers,
stddev computation like ping(8)).
$NetBSD$.
2000-10-07 06:36:50 +00:00
ad 5b09090e8e insure -> ensure 2000-10-05 12:35:33 +00:00
enami 9b6f3e1ce2 Don't explain -s twice. 2000-10-05 03:24:41 +00:00
jdolecek cf8b00f58b setup(): use calloc() for blockmap allocation, instead of malloc() followed
by bzero(); the net result is that the test for allocation failure
is actually sensible now
2000-10-04 11:37:54 +00:00
itojun 72beb4728a add config file directory 2000-10-04 00:27:48 +00:00
itojun f0dc76db35 a test build tree for racoon IKE daemon.
you need KAME tree to compile this (point the top by ${KAMEROOT}
in Makefile.inc).

XXX maybe too big for /sbin...869K with certificate support, and 574K without
certificate support (i386, stripped, static-link)
2000-10-04 00:21:17 +00:00
itojun 4bfd9169a9 support rijndael-cbc. 2000-10-03 21:48:33 +00:00
bjh21 9626c2fdbb Put the sections in the canonical order.
Fix formatting of '=' and '+='.
File names are .Pa, not .Ar.
2000-10-03 14:33:16 +00:00
thorpej 9e992b012b In tunnel_status(), if we have an IPv6 kernel, but a driver doesn't
support IPv6 tunnel endpoint addresses, fall back on the sockaddr
version of the ioctls.
2000-10-02 22:30:40 +00:00
hubertf c58e6bf54d We don't ship format(8), so don't x-ref it. 2000-10-02 21:17:04 +00:00
abs 5087b081db When opening a partition to automatically determine the filesystem type,
always use the raw partition in case it is already mounted and this is
an 'update' mount. Patch from Launey Thomas <ljt@alum.mit.edu>
2000-10-02 18:52:47 +00:00
perseant 7d6de39e20 Handle "-m 0" properly (PR #11112). 2000-10-02 16:06:48 +00:00
darrenr 3904e69e83 savecore was looking up dumpdev, etc, from the wrong kernel 2000-10-01 02:27:06 +00:00
fvdl 00a8c99503 Modification to previous: only build for ports that are a.out or used
to be a.out. No sense in building for ports that never were a.out.
2000-09-29 19:00:59 +00:00
fvdl 989e0d2613 Build this on ELF as well. When on an ELF system, only look in
_PATH_EMUL_AOUT/etc/ld.so.conf.
2000-09-29 17:47:52 +00:00
thorpej c77c2baf89 Add vlan(4) support. From Andy Doran <ad@netbsd.org>. 2000-09-27 23:00:24 +00:00
jdolecek 08d0274af3 fix typo (remplaced --> replaced) 2000-09-26 13:28:27 +00:00
gmcgarry 69a9911e49 Fix spelling. 2000-09-20 22:08:01 +00:00
abs 7dea4938ea If device and mountpoint are given without -t, and without a : in the
device, check the disklabel for filesystem type. Fall back to ffs as ever.
2000-09-18 10:48:23 +00:00
abs 3b81524ad0 if readboot() calls pfatal(), we need to print a \n before exiting 2000-09-15 22:11:41 +00:00
perseant 15c84d56e5 Do not report write errors if the user specified the -N flag.
Also, change the segment size report to include the total size of the disk,
similar to newfs, e.g.

  newfs_lfs -N -F -B 65536 /dev/rsd0b
  272.7MB in 4363 segments of size 65536
  super-block backups (for fsck -b #) at:
  16, 55824, 111632, 167440, 223248, 279056, 334864, 390672, 446480, 502288
2000-09-11 01:32:21 +00:00
jdolecek f973bb5351 document kern.maxptys/KERN_MAXPTYS
note that kern.maxvnodes is raise only
2000-09-09 17:06:34 +00:00
perseant 9c7f8050f4 Various bug-fixes to LFS, to wit:
Kernel:

* Add runtime quantity lfs_ravail, the number of disk-blocks reserved
  for writing.  Writes to the filesystem first reserve a maximum amount
  of blocks before their write is allowed to proceed; after the blocks
  are allocated the reserved total is reduced by a corresponding amount.

  If the lfs_reserve function cannot immediately reserve the requested
  number of blocks, the inode is unlocked, and the thread sleeps until
  the cleaner has made enough space available for the blocks to be
  reserved.  In this way large files can be written to the filesystem
  (or, smaller files can be written to a nearly-full but thoroughly
  clean filesystem) and the cleaner can still function properly.

* Remove explicit switching on dlfs_minfreeseg from the kernel code; it
  is now merely a fs-creation parameter used to compute dlfs_avail and
  dlfs_bfree (and used by fsck_lfs(8) to check their accuracy).  Its
  former role is better assumed by a properly computed dlfs_avail.

* Bounds-check inode numbers submitted through lfs_bmapv and lfs_markv.
  This prevents a panic, but, if the cleaner is feeding the filesystem
  the wrong data, you are still in a world of hurt.

* Cleanup: remove explicit references of DEV_BSIZE in favor of
  btodb()/dbtob().

lfs_cleanerd:

* Make -n mean "send N segments' blocks through a single call to
  lfs_markv".  Previously it had meant "clean N segments though N calls
  to lfs_markv, before looking again to see if more need to be cleaned".
  The new behavior gives better packing of direct data on disk with as
  little metadata as possible, largely alleviating the problem that the
  cleaner can consume more disk through inefficient use of metadata than
  it frees by moving dirty data away from clean "holes" to produce
  entirely clean segments.

* Make -b mean "read as many segments as necessary to write N segments
  of dirty data back to disk", rather than its former meaning of "read
  as many segments as necessary to free N segments worth of space".  The
  new meaning, combined with the new -n behavior described above,
  further aids in cleaning storage efficiency as entire segments can be
  written at once, using as few blocks as possible for segment summaries
  and inode blocks.

* Make the cleaner take note of segments which could not be cleaned due
  to error, and not attempt to clean them until they are entirely free
  of dirty blocks.  This prevents the case in which a cleanerd running
  with -n 1 and without -b (formerly the default) would spin trying
  repeatedly to clean a corrupt segment, while the remaining space
  filled and deadlocked the filesystem.

* Update the lfs_cleanerd manual page to describe all the options,
  including the changes mentioned here (in particular, the -b and -n
  flags were previously undocumented).

fsck_lfs:

* Check, and optionally fix, lfs_avail (to an exact figure) and
  lfs_bfree (within a margin of error) in pass 5.

newfs_lfs:

* Reduce the default dlfs_minfreeseg to 1/20 of the total segments.

* Add a warning if the sgs disklabel field is 16 (the default for FFS'
  cpg, but not usually desirable for LFS' sgs: 5--8 is a better range).

* Change the calculation of lfs_avail and lfs_bfree, corresponding to
  the kernel changes mentioned above.

mount_lfs:

* Add -N and -b options to pass corresponding -n and -b options to
  lfs_cleanerd.

* Default to calling lfs_cleanerd with "-b -n 4".


[All of these changes were largely tested in the 1.5 branch, with the
idea that they (along with previous un-pulled-up work) could be applied
to the branch while it was still in ALPHA2; however my test system has
experienced corruption on another filesystem (/dev/console has gone
missing :^), and, while I believe this unrelated to the LFS changes, I
cannot with good conscience request that the changes be pulled up.]
2000-09-09 04:49:54 +00:00
kleink 2caf6aacdd For commands and utilities, use EXIT STATUS rather than RETURN VALUES as
appropriate (and documented in mdoc(7)).
2000-09-04 07:30:07 +00:00
lukem 6c94f4bee8 in cmd_name(), put the default prompt into a temporary buffer rather
than overwrite the existing d_packname.  noted by enami@.
2000-09-04 02:09:26 +00:00
hubertf 26b6647470 Document the FAT types we support, and add a bugs section (suggested
by ws@netbsd.org).
2000-08-28 15:31:05 +00:00
joda 6532bb554c document -s 2000-08-28 13:27:37 +00:00
enami 3403ff66ff Pull down the changes I've just accidently commited into 1.5 branch.
Mainly, .Pa fixes.
2000-08-26 13:45:20 +00:00
itojun 152da24bd9 implement net.inet6.ip6.{anon,low}port{min,max} sysctl variable. 2000-08-26 11:03:45 +00:00
itojun 3c7320bedf document net.inet.ip.lowport{min,max} 2000-08-26 11:00:41 +00:00
joda 4f419afab1 initialize sflag to zero; discovered on Digital UNIX, where I got
random (no pun intended) functionality
2000-08-25 16:47:17 +00:00
lukem 003803c5d4 - add rc.conf.d to list of items to link
- update man page to reflect reality
- use mdoc macros correctly...
2000-08-22 12:06:46 +00:00
soren fac5e7d742 Add space in summary printf. 2000-08-19 21:31:58 +00:00
oster 8b77995122 It is impolite to poll in a tight loop. (Thanks to Christos for noting
the problem.)
2000-08-19 19:51:17 +00:00
lukem 4c8c86856e * use strcasecmp() instead of strcmp() so that filesystem type and disk type
searchs (amongst others) are case insensitive.
* in interactive mode (-i), when editing entries display supported disk types
  and filesystem types when given `?' (when ``[?]'' appears in the prompt
  this feature is supported for the question).
* support `m' as a suffix equivalent to `M'
* in interactive mode, be a bit more sensible about handling errors and EOF
* implement dumpnames(), which takes a char ** and size, and displays
  as per ls -F (sorted, listed vertically) but indented by one tab
* don't assume d_typename and d_packname are NUL terminated
* fix up some comments and some warning messages (bad cut & pastos :)
* deprecate deffstypename() and getfstypename()
* be consistent when using sizeof()
2000-08-14 22:37:08 +00:00
deberg 31064c0014 use CURDIR where appropriate 2000-08-14 16:38:40 +00:00
itojun 940be0cfdc - bugfix: truncated FQDN printing
- allow < 1 second interval on -i (root only).  from openbsd
2000-08-14 02:54:43 +00:00
wiz fb3d40deab add two letters in strategically important places, and replace one
ifconfig by .Nm
2000-08-13 17:17:26 +00:00
jhawk df711325aa "boostrap" => "bootstrap" 2000-08-12 18:52:42 +00:00
oster ff1bb25d60 Clarify a few things about parity. Add more documentation about RAID on RAID,
and root on RAID.
2000-08-10 15:14:14 +00:00
itojun 1b2be13d48 DNS compression support.
be more picky about DNS label validation.
(sync with kame)
2000-08-09 14:36:00 +00:00
mrg f3f04801b2 enable edlabel on sparc64, too. 2000-08-09 11:37:34 +00:00
leo d9f85c81c0 standarize -> standardize. From Thomas Klausner. 2000-08-05 19:09:37 +00:00
enami 4be9c3c33c Stop parsing once encountered non directive line as documented in man page. 2000-08-04 07:33:55 +00:00
leo 032c2e34d9 Fix number of parameters in a usage printf. Noticed by Thomas Klausner. 2000-08-03 20:05:48 +00:00
castor d02d10e226 Fix an evil ugly bug which causes files placed into lost+found to
be inconsistent, and unremovable. From Ethan Solomita <ethan@geocast.com>.
Reviewed by fvdl.
2000-08-03 14:52:39 +00:00
eeh baf03fd97c time is a `struct timeval' not a `time_t', so read it in properly. 2000-08-01 16:46:27 +00:00
jhawk f66c42de08 Xr for mount_overlay(8) 2000-07-30 15:17:14 +00:00
jdolecek cf8bbdf82f in SEE ALSO, add missing comma between moun(8) and mount_null(8) 2000-07-30 10:41:29 +00:00
itojun 1048b82bf1 nuke net.inet*.ip*.*ratelimit. 2000-07-28 04:08:44 +00:00
thorpej c849d97e50 Pull in <md5.h> rather than defining our own MD5 structures (!). 2000-07-27 16:34:31 +00:00
itojun 348dcd5529 add net.inet.tcp.rstppslimit 2000-07-27 11:37:46 +00:00
jdolecek 339275db14 backoff rev 1.18 & 1.19 - it's made obsolete by last rc.d changes and using
arbitrary hard time limit for /etc/rc.shutdown is not right anyway
2000-07-25 19:02:15 +00:00
jdolecek 9ada2e4d0c backoff rev 1.36 - it's made obsolete by last rc.d changes and using
arbitrary hard time limit for /etc/rc.shutdown is not right anyway
2000-07-25 18:59:44 +00:00
onoe afa6a922a6 also note that the WaveLAN/IEEE Gold cards accept the 104 bits key.
pointed out by jhawk.
XXX this doesn't match to wiconfig(8), which is probably wrong.
2000-07-21 18:31:03 +00:00
onoe 05079cfc6d Clarify the restrictions in length for argument of the nwid and nwkey. 2000-07-21 17:37:12 +00:00
onoe 9efdccbdb5 Add nwkey and -nwkey keywords, to enable/disable WEP,
and to set WEP encryption key for IEEE802.11 wireless network interfaces.
2000-07-21 04:53:03 +00:00
thorpej ef220cfa40 Make sure IS_PASSIVE gets set on a parm's int_state when the
passive option is used in an if=xxx clause.
2000-07-21 00:22:38 +00:00
thorpej 9b5aaf80be In walk_supply(), test for IS_PASSIVE in ifp->int_state, not
ifp->int_if_flags (IFF_* bits).
2000-07-20 22:50:16 +00:00
thorpej 5bf452f867 Add a -C flag, to list all available network interface cloners. 2000-07-20 18:42:02 +00:00
jdolecek 3a7c71f3b9 fix synopsis line so that the -T syntax is right 2000-07-20 17:46:57 +00:00
jdolecek 02ca64b4c6 when running /etc/rc.shutdown, don't want on it until it completes
indefinitely - by default, wait maximum of 300 seconds only
the timeout is settable via new -T flag
Adjust history to mention addition of shutdown hooks and -T option on manpage

This fixes bin/10637.
2000-07-20 17:33:57 +00:00
jdolecek 94021a19a5 when running /etc/rc.shutdown, don't wait on it until it completes
indefinitely - by default, wait maximum of 300 seconds only
the timeout is settable via new -T flag
Adjust history to mention addition of shutdown hooks and -T option on manpage,
also move description of -D further up and slighly adjust.

This fixes bin/10637.
2000-07-20 17:33:56 +00:00
enami 8db557a393 Free storage allocated by fparseln. 2000-07-19 10:05:43 +00:00
enami 3a6b928e7a Free storage allocated by fparseln. 2000-07-19 09:58:03 +00:00
enami 1c1b132cda - Fix off-by-one error in previous.
- Fix a typo of ioctl name in warning message.
2000-07-19 06:01:24 +00:00
onoe f989129a77 check the length of nwid argument before copy to avoid SEGV.
pointed out by enami-san
2000-07-19 04:43:34 +00:00
itojun 4941457b0a sync with the current usage. from kame.
note th at the file will not be installed into locations like
/usr/sibn or /sbin.
2000-07-18 23:32:19 +00:00
itojun 6a202d75eb sync with recent net/pfkeyv2.h change (sorry forgot to commit). from kame 2000-07-18 23:29:48 +00:00
mrg 1fdc1c0300 implement `# KEYWORD:' support, with two new arguments to rcorder, to kill
and skip keywords from the output list:

	-k keyword	only files with `# KEYWORD: keyword' will be printed.
	-s keyword	files with `# KEYWORD: keyword' will not be printed.

(multiple keywords can exist on a single line, and multiple lines may exist,
as with other special rcorder lines).

requested by lukem.
2000-07-17 14:16:22 +00:00
itojun 36abc851d1 correct hard-to-understand indentation. 2000-07-16 14:06:08 +00:00
jdolecek d015a6b7a6 note addition of rrcaseins in history 2000-07-16 08:20:04 +00:00
jdolecek 24c327fe78 Add an option to do case-insensitive lookups even on Rock-Ridge CD-ROMS.
Add 'rrcaseins' option to mount_cd9660(8).

This addresses kern/2419 by Jason Downs.
2000-07-15 21:40:42 +00:00
jdolecek a8b345d374 add extatt, gens, nojoliet, norrip options - names taken from FreeBSD
add nrr as an alias for norrip, for compatibility with Solaris
retire -e, -g, -j, -r: they are still recognized and handled, but are
	not listed in mount_cd9660's SYNOPSIS and are documented as
	obsolete in mount_cd9660(8)
update history for joliet support and nomaplcase option
2000-07-15 13:54:45 +00:00
simonb a6273c2690 Handle KERN_MSGBUF and KERN_CONSDEV gracefully. 2000-07-15 07:07:02 +00:00
itojun c6910190d6 sync with sys/sysctl.h change (is it the right way to workaround this?) 2000-07-15 01:44:35 +00:00
mycroft 9496d82675 Add a missing newline in one message.
(The fact that I got this message using softdep should probably disturb
someone...)
2000-07-14 02:43:44 +00:00
ad 7101b4c03f Back out previous two - didn't follow the code properly. 2000-07-13 11:24:40 +00:00
ad 08d4945681 Fix previous. From Micheal Eriksson <eramore@era-t.ericsson.se>. 2000-07-13 11:19:54 +00:00
msaitoh c832841f5e s/ ar / are / 2000-07-13 10:33:52 +00:00
hubertf 6f0558d9f6 'disklabel -i' on a disk without a label recommends to use -I. Document
that in the usage.
2000-07-13 01:47:22 +00:00
itojun 6ab897e3e4 document sysctl variable "net.inet.icmp.errppslimit". 2000-07-10 09:34:38 +00:00
itojun fa7948bec2 add description for net.inet6.icmp6.{errppslimit,nd6_maxnudhint} 2000-07-09 13:31:14 +00:00
kleink 141d219082 Use .Pa. 2000-07-08 10:28:17 +00:00
he 7ea7848d3c Make sure .Dl has the line to be shown as argument (on same line). 2000-07-07 17:58:37 +00:00
enami bc7d39c732 Extract file flags of symbolic link. 2000-07-07 13:24:33 +00:00
itojun ddf8cb2acb warnx?/errx? audit. don't pass variable/function return value alone.
use with "%s".  from openbsd.
2000-07-07 12:29:09 +00:00
fair f7f2fe622e Add example text to answer PR 10232. 2000-07-07 09:25:36 +00:00
thorpej 6d78b8c024 When fetching the disk's hardware geometry, first attempt the
DIOCGDEFLABEL ioctl, then fall back onto the DIOCGDINFO ioctl
if that fails.  This ensures that we will get the actual hardware
geometry info rather than any bogus info that might have been
previously written to the disk's label area.
2000-07-06 17:22:43 +00:00
hannken c269775813 Fix type of WSKBDIO_?ETENCODING. 2000-07-06 16:30:47 +00:00
ad 92cca24f4e printf fmt string without %s, from OpenBSD. 2000-07-06 14:01:06 +00:00
onoe b4a8e334e8 hexadecimal digits for nwid. 2000-07-06 11:02:02 +00:00
onoe 27f79f7369 cast u_char for ctype (nwid stuff) to fix possible overrun problems. 2000-07-06 08:20:51 +00:00
onoe 197deeeff8 warn instead of print 802.11 nwid with bad length field. 2000-07-06 00:50:49 +00:00
msaitoh f6f00e2615 remove extra period in SEE ALL section 2000-07-05 15:45:28 +00:00
oster e828ccd7df Add a .Sq for single quotes, instead of doing it by hand.
Fixes a formatting problem noted by Hubert Feyrer (Thanks Hubert!).
2000-07-05 02:42:39 +00:00
onoe 807a12c8cd change the argument of SIOCS80211NWID and SIOCG80211NWID ioctls from
u_int8_t array to struct ieee80211_nwid to prepend length field.
The length field is necessary because IEEE 802.11 spec doesn't prohibit
even '\0' for SSID.
Though the name and the value of SIOC... macro is unchanged, this change
breaks binary compatibility.  The only affected userland program on the
tree is ifconfig(8).
As Jason suggested on tech-net, it is better than live with problems
since there are no releases for this ioctls yet.
2000-07-05 02:35:53 +00:00
perseant 48d7c317e8 Tweak how lfs_avail is initialized, corresponding to changes in the
kernel.

Don't make more superblock segments than we have a record of in
the superblock; and print these out as we go, like newfs.

Add am "-M" flag to specify the number of reserved segments, with a note
in the man page not to use it.
2000-07-04 22:35:04 +00:00
thorpej a00a01e514 Default the root directory and lost+found directory to mode 0755,
as in FFS.
2000-07-03 21:51:05 +00:00
enami a6edd9cf2f - Remove description about trailers/-trailers since they are no longer
a meaningful option.
- Don't captialize the word address or interface when it refers an arugment.
- Use .Ar macro for dest_address since it is not a keyword.
2000-07-03 09:18:52 +00:00
enami 34c3137212 Sort the SEE ALSO list first by section and kill the comma at the
end of the list.
2000-07-03 08:55:14 +00:00
matt 0f6818e4eb More include fixups and GCC 2.96 nonsense 2000-07-03 03:37:59 +00:00
perseant 9a38f49c57 User-level changes corrseponding to my latest kernel changes.
newfs_lfs gives lfs_minfreeseg a value of 1/8 of the total segments on
the disk, based on rough empirical data, but this should be refined in
the future.
2000-07-03 01:49:11 +00:00
thorpej f70c591ad2 Add `create' and `destroy' commands. 2000-07-02 00:28:00 +00:00
itojun 914e93c4db mention resesrved SPI range, which is not usable from userland 2000-07-01 01:04:04 +00:00
thorpej 1a9289d09a - Add `tunnel' and `deletetunnel' commands, which issue the ioctls
that gifconfig(8) would issue to configure tunnel endpoints.  This
  allows IP tunnel interfaces (`gif' right now, and `gre' later) to
  be configured with ifconfig(8), and via /etc/ifconfig.<interface>.
  Partially taken from similar changes in OpenBSD.
- Const poison the command functions a bit.  We really need to clean
  up the command function interface.
2000-06-30 17:45:11 +00:00
perseant 61d1fe8df3 User-level changes for filling the disk.
Set MINFREE to 80, since that's a more reasonable value according to the
literature than FFS' 90.  Remove a bunch of other unused FFS cruft from
config.h.

Initialize lfs_bfree correctly vis-a-vis MIN_FREE_SEGS, so the
filesystem doesn't over-represent the amount of free space it has.
Initialize lfs_dmeta so the kernel can estimate starting from a
reasonable value.
2000-06-27 21:06:24 +00:00
mrg a461faa506 <vm/vm_param.h> is now <uvm/uvm_param.h> 2000-06-27 09:10:24 +00:00
bjh21 df36d174d2 Remove spurious colon from error message; clnt_pcreateerror provides one. 2000-06-26 21:53:34 +00:00
mrg ad91bba6a6 we now need <uvm/uvm_param.h> 2000-06-26 15:37:26 +00:00
sommerfeld e62920cf2e revised rndctl which can display pool statistics. 2000-06-20 02:40:10 +00:00
simonb 73dfacb53d If "SMALL" is defined don't include kvm support, primarily for install
media.
2000-06-20 01:49:20 +00:00
simonb 6a2c167125 The default core file is /dev/mem, not /dev/kmem. 2000-06-20 01:47:03 +00:00
fvdl d65482091f Adapt to new RPC interface. Use getaddrinfo(), not gethostbyname(). 2000-06-20 00:45:24 +00:00
fvdl 27ddcb91ce Handle unsupported protocols (i.e. no v6 support on the other side)
a tad better.
2000-06-19 23:19:20 +00:00
simonb 643cb3c341 Don't check namelist when choosing to use the sysctl interface. 2000-06-16 03:51:00 +00:00
simonb 907def68ca ANSIfy. 2000-06-16 03:42:12 +00:00
simonb b75d5299d7 Oops, forgot to commit this file - actually remove the kmem setgid bit. 2000-06-16 03:41:37 +00:00
simonb a7d9e1f93d Use new KERN_MSGBUF sysctl if running on a live kernel, and remove
setgid kmem bit from executable.
2000-06-16 00:20:23 +00:00
fvdl 474a72e217 Disable (unifdef for now) tunefs -n <disable|enable>, this is done via
a mount option now.
2000-06-15 22:37:17 +00:00
fvdl 56fb6920d7 Enable -o softdep. 2000-06-15 22:36:46 +00:00
fvdl 5422b85358 Enable and document the -o softdep option. 2000-06-15 22:36:07 +00:00
wiz 334298998c Fix QNX partition IDs, confirmed by looking at FreeBSD's fdisk.
Note: 77 == 0x4d
2000-06-14 19:35:50 +00:00
perseant 75453f286d Add "-i" flag to specify the location of the index file inode, to
examine alternate checkpoints.  Regularize usage of maxino.  Remove olf
debugging cruft.
2000-06-14 18:43:57 +00:00
cgd db755e7c76 sweep of my licenses (userland files w/o only my copyright) for
consistency.  (no functional changes)
2000-06-14 17:24:02 +00:00
cgd d220ca5ba3 fix up NetBSD RCS Ids to match the standard, and the leading comment as
to match as well.  No functional changes.
2000-06-14 06:48:47 +00:00
itojun 01014585ed update examples, so that they would at least pass the parser. 2000-06-14 03:02:12 +00:00
itojun 11a42bf1f4 move setkey(8) from usr.sbin to sbin, to enable us to initialize
IPsec manual key before /usr mount..
(based on "don't use cvsmove" discussion i have seen, I did not use cvsmove)
2000-06-13 15:15:21 +00:00
itojun 07098cd363 better conformance to draft-ietf-ipngwg-icmp-name-lookups-05.
the old code was chimera of 03 and 05 draft.

-n by default, since IPv6 reverse lookup takes too much time.
use -H to enable reverse name lookup.
2000-06-12 16:21:02 +00:00
christos 88f6fad445 Revert 1.18 -> 1.19; causes infinite loops on machines that use ppp and
do active routing.
2000-06-11 23:43:17 +00:00
enami 4582a90f6d Sync with rev. 1.19 of vnconfig.c. 2000-06-09 15:06:31 +00:00
enami 9974e53bda Force -t or -N flag disables -u flag (but -t case is just for sanity). 2000-06-09 09:05:02 +00:00
fvdl 43ffff9e2c Update to be more address-family independent, and adapt to TI-RPC
interface.

XXX this code needs a cleanup, especially the retry-loop.
2000-06-09 00:06:36 +00:00
mason 46cae96db6 Fixed typo - zonbie -> zombie 2000-06-08 20:43:16 +00:00
itojun 204ee4d791 make sure to clear ni_flags field on -w. 2000-06-08 13:56:22 +00:00
augustss 73053385f4 Note that sysid 0 marks a partition as unused. 2000-06-07 22:40:59 +00:00
itojun 8183434ff7 s/PIMCTL/PIM6CTL/ to avoid future confusion. 2000-06-07 04:40:46 +00:00
chs 09218270f0 change ``-a'' to be a synonym for ``-A''.
addresses PR 7629.
2000-06-06 07:09:14 +00:00
thorpej 0ffb5bb96d Use CMSG_*() correctly when sending file descriptors. 2000-06-05 16:30:43 +00:00
oster 3fa8f52b84 In certain cases (e.g. where it makes sense) read/display the
component label for spare disks too.
2000-06-03 16:59:36 +00:00
oster f26e8d9a17 Slight wording improvement on the 'raidctl -R' case. 2000-06-02 04:11:46 +00:00
matt 1d7db13f9f make ldconfig.c not always fail. 2000-06-01 18:17:06 +00:00
fvdl bb159432ef Add a -I flag which, combined with -e, gives the user the opportunity
to edit and create a new label on a virgin disk.
2000-05-31 14:13:48 +00:00