Commit graph

8937 commits

Author SHA1 Message Date
Poul-Henning Kamp 7194d335cf Run a revision of the devstat interface:
Kernel:

Change statistics to use the *uptime() timescale (ie: relative to
boottime) rather than the UTC aligned timescale.  This makes the
device statistics code oblivious to clock steps.

Change timestamps to bintime format, they are cheaper.

Remove the "busy_count", and replace it with two counter fields:
"start_count" and "end_count", which are updated in the down and
up paths respectively.  This removes the locking constraint on
devstat.

Add a timestamp argument to devstat_start_transaction(), this will
normally be a timestamp set by the *_bio() function in bp->bio_t0.
Use this field to calculate duration of I/O operations.

Add two timestamp arguments to devstat_end_transaction(), one is
the current time, a NULL pointer means "take timestamp yourself",
the other is the timestamp of when this transaction started (see
above).

Change calculation of busy_time to operate on "the salami principle":
Only when we are idle, which we can determine by the start+end
counts being identical, do we update the "busy_from" field in the
down path.  In the up path we accumulate the timeslice in busy_time
and update busy_from.

Change the byte_* and num_* fields into two arrays: bytes[] and
operations[].

Userland:

Change the misleading "busy_time" name to be called "snap_time" and
make the time long double since that is what most users need anyway,
fill it using clock_gettime(CLOCK_MONOTONIC) to put it on the same
timescale as the kernel fields.

Change devstat_compute_etime() to operate on struct bintime.

Remove the version 2 legacy interface: the change to bintime makes
compatibility far too expensive.

Fix a bug in systat's "vm" page where boot relative busy times would
be bogus.

Bump __FreeBSD_version to 500107

Review & Collaboration by:	ken
2003-03-15 21:59:06 +00:00
Warner Losh e0a6103d7d manufacturer id is typically 4 bytes 2003-03-14 21:11:01 +00:00
Jake Burkholder a24fa5bdb2 Increase the size of the property buffer to 8192. 1024 wasn't enough to
retrieve certain nodes.
2003-03-14 16:12:42 +00:00
Peter Pentchev 2be1729151 Remove ftp2.it.FreeBSD.org from the list of mirrors.
Submitted by:	Alex Dupre <sysadmin@alexdupre.com>
Approved by:	silence on -arch
2003-03-14 15:47:14 +00:00
Warner Losh 62bac311fc Don't be so verbose about 'unknown' CIS tuples. We were printing each
one three times before we did the dump.  Also, we printed 0x00 for the
tuple type rather than the actual tuple type.  Now, we print the
actual tuple type.  This appears to have no ill effects.

Should get rid of the

Code NN not found
and
code Unknown ignored

messages.  The ignored messages are still generated for tuples tuples
who have a minimum length set and we find a tuple of that type that's
shorter than the minimum length.
2003-03-14 13:17:35 +00:00
Robert Drehmel 0357726594 - Align the function prototype of the external `crc' function with
how `crc' is actually defined.
 - Remove an unnecessary `extern' variable declaration.
Data type corrections:
 - Define a variable which contains a file byte offset value as type
   off_t as required by the `crc' function.
 - Change the type of a variable carrying a CRC checksum from `u_long'
   to `uint32_t'.
 - Substitute the wrong `extern' variable declaration of `crc_total'
   by putting a correct one in the shared header extern.h.
   `crc_total' is defined as an `uint32_t', thus fixing
   incorrect mtree checksums on big-endian LP64 machines.
2003-03-13 23:35:30 +00:00
Robert Drehmel fadcf8aec0 - Align the function prototype of the external `crc' function with
how `crc' is actually defined.
Data type corrections:
 - Define variables which contain file byte offset values as type
   off_t as required by the `crc' function.
 - Change the type of a variable carrying a CRC checksum from `u_long'
   to `uint32_t'.
 - Parse the length of a file with sscanf as `intmax_t'
   (as there is no conversion specifier for `off_t').
Style(9):
 - Put an empty line between #include directives for system and user
   header files.
2003-03-13 23:34:18 +00:00
Chris Costello 6cc0c63755 Break setfmac.8 into two actual man pages, and reword bits of the
setfsmac(8) documentation.

Obtained from:	TrustedBSD Project
Sponsored by:	DARPA, Network Associates Laboratories
2003-03-13 23:04:05 +00:00
Anton Berezin 53bd74b7e9 Fix two minor mismatch reporting output errors.
Reviewed by:	phk
MFC After:		3 weeks
2003-03-13 15:14:56 +00:00
Ruslan Ermilov 82c7cf3159 Complete the endianness support -- sparc64 can now do i386.
Tested on:	sparc64 -> i386, i386 -> sparc64
Debugged by:	elfdump(1)
2003-03-13 11:47:31 +00:00
Ruslan Ermilov 7148ee891c Make this work on different endianness machines.
Tested on:	sparc64

: FreeBSD/i386 bootstrap loader, Revision 1.1
: (ru@panther.freebsd.org, Tue Mar 11 05:31:14 PST 2003)
: Loading /boot/defaults/loader.conf
2003-03-11 13:48:58 +00:00
Ruslan Ermilov 8eb1c4caf9 Convert kgzip(8) to be an i386 cross-tool. This is needed for
cross-releasing i386 on different architectures.  This version
provides an i386 version of <a.out.h>, and handles endianness.

Tested on:	alpha, sparc64
2003-03-11 11:45:43 +00:00
Ruslan Ermilov 59aca3e42a Revert rev. 1.244 change -- only build kgzip(8) on i386.
(The cross-release needs will be satisfied another way.)
2003-03-11 11:37:07 +00:00
Ruslan Ermilov 4eeebba9c4 Make usage() match SYNOPSIS. 2003-03-09 21:41:30 +00:00
Ruslan Ermilov d6d4c35471 Get rid of the randomizing factor. 2003-03-09 21:39:52 +00:00
Dag-Erling Smørgrav 76131e39c3 Print FYI messages on stderr. Previously, they were printed on stdout,
and due to buffering they would sometimes come out after the actual
error message when mkheaders() failed due to an unknown device, so you'd
get an error messages followed by 20 or 30 lines of harmless warnings.

There are lots of other warning messages in config(8) that are printed
on stdout, but these were the most egregious (at least with LINT).
2003-03-09 15:08:47 +00:00
Garance A Drosehn 9ffd2d77ef Fix interactions between entries for a specific file vs entries for
a filename pattern, and also wrt filenames given on the command line.
Now if a file is listed as a specific entry, it will not *also* be
processed by an entry specifying a pattern.  And filename-patterns
will now only match existing files (ignoring directories, etc).

MFC after:	3 weeks
2003-03-09 03:19:52 +00:00
Robert Drehmel 47469b9f5c Remove a function prototype for `crc' and an associated comment which
were useless for at least seven years and eight months.
2003-03-09 02:28:04 +00:00
Garance A Drosehn 4ebd61a3cf The processing of files given on the command-line will work a little better
if we return the entire worklist, instead of just the last entry.  A minor
fix to revision 1.57.

MFC after:	15 days
2003-03-09 00:29:40 +00:00
Garance A Drosehn ae77078c25 Add a config-file flag of 'U' or 'u' to indicate that the pid-file
will contain the pid for a process group.  This means the file must
contain a negative value (as would be needed in the 'kill' commmand).
I still need to write man-page update before MFC-ing.

This started by rewriting the get_pid() routine.  Later I looked at
what OpenBSD has, and included a few ideas from their send_signal()
routine.  So, parts of this change are from OpenBSD, even though
OpenBSD does not actually have a 'U' flag.

PR:		bin/28435
Reviewed by:	no objections on freebsd-arch
MFC after:	3 weeks
2003-03-08 20:07:01 +00:00
Mark Murray 4b48036b9b KerberosIV deorbit sequence: Un-teach sysinstall about KerberosIV. I'm
not 100% sure that I've done this in the right way. If folks want to
revisit this, please be my guest.
2003-03-08 12:07:13 +00:00
Garance A Drosehn a42568171f Prefix all -n (noaction) "unix cmds" with tab, thus making it much easier
to sort out noaction messages from -v (verbose) messages.  This also
improves a few noaction messages.

Obtained from:	OpenBSD
MFC after:	3 weeks
2003-03-07 21:29:34 +00:00
Garance A Drosehn 40fe458d04 Move the -s (nosignal) processing, as newsyslog needs to print out a
warning message if -s is specified and it rotates a file that expects
to be compressed.  This warning message is not printed if -R is also
specified, because we assume a -sR request is coming from the process
which would have been signaled, and that it has already released the
logfile.

Indirectly noticed by:	sheldonh
2003-03-07 21:06:32 +00:00
Maxim Sobolev 3c1493dcbd Use correct interface name (it's different on -current).
Submitted by:	Brooks Davis <brooks@one-eyed-alien.net>
MFC after:	20 days
2003-03-05 18:50:18 +00:00
Maxim Sobolev 8ad8452bd4 Remove local hack that somehow slipped into the previous commit.
MFC after:	20 days
2003-03-05 18:48:47 +00:00
Maxim Sobolev c4020e6e93 Add missed description for the `ds' (disc(4)) pseudo-interface.
Sponsored by:	Porta Software Ltd
MFC after:	20 days
2003-03-05 18:07:59 +00:00
Ruslan Ermilov 4bfc36240e Further fix the syntax by ignoring empty and whitespace-only lines.
Prompted by:	Eugene Grosbein <eugen@kuzbass.ru>
2003-03-05 15:53:18 +00:00
Doug Barton 5750fb86d7 Put back the deletion of TEMPROOT/etc/passwd.
Noticed by: maxim
2003-03-05 12:42:08 +00:00
Doug Barton 40a392599f Better handle the recent (desirable) change to create login.conf.db at
install time, and make sure to catch any future .db files as well.
2003-03-05 08:20:55 +00:00
Warner Losh 8fa294a174 Start whining to stderr when people use obsolete flags. These flags
will be removed.  Give terse pointer to ifconfig h0h0 magic to use.
2003-03-04 14:59:48 +00:00
Warner Losh 4a854c9064 another obsolete flag 2003-03-04 14:55:58 +00:00
Warner Losh fb3d8ed1f3 Correct mistake in T flag: weptxkey is the replacement 2003-03-04 14:54:49 +00:00
Warner Losh 7a9f6aa26c Document the obsolete flags as obsolete, with pointers to their
ifconfig equivalents.  This is the first step in removing them from
the system.  Users of wicontrol to configure the wireless card are
strongly encouraged to change their scripts, as sometime in the future
all configuration of the cards that isn't in ifconfig will be removed
with extreme prejustice.
2003-03-04 14:47:19 +00:00
Ruslan Ermilov 41477f3f5c 3rd party modules live in /boot/modules nowadays. 2003-03-03 22:49:21 +00:00
Garance A Drosehn 69ea8786d6 Add missing 'static' on two routines, so they match their declarations.
PR:		29363 (a small part of)
Submitted by:	dinoex
MFC after:	3 weeks
2003-03-03 15:31:35 +00:00
Murray Stokely 72f455de8d Update the number of ports in the ports collection. Although we've
gained 400 ports since the last time this was updated, the disk space
estimate is still accurate.
2003-03-03 09:28:37 +00:00
Garance A Drosehn d4948dc25e A variety of cosmetic changes, mostly to (slightly) reduce diffs with
OpenBSD.  Except for one added '\n', the object code is not changed.

MFC after:	3 weeks
2003-03-03 02:53:35 +00:00
Garance A Drosehn 2f5d9e2994 Collapse two more parameters to dotrim() into the 'ent' parameter that is
already there.  This should not effect anything.

MFC after:	3 weeks
2003-03-03 01:58:33 +00:00
Garance A Drosehn e2fe500ec5 Change to using uid_t and gid_t instead of int. Also change this won't
bother doing a chmod() if neither of these two fields are set.

Obtained from:	OpenBSD
MFC after:	3 weeks
2003-03-03 01:23:34 +00:00
Garance A Drosehn 7cf31d2ff5 Fix the interactions between specific log files given on the command line,
and config-file entries which specify a filename-pattern (glob).  It is
still not perfectly-right, but at least it isn't completely-wrong.

Reviewed by:	no objections on freebsd-arch
MFC after:	3 weeks
MFC addendum:	(or after the code-freeze of 4.x is lifted)
2003-03-03 00:01:51 +00:00
Garance A Drosehn 9fb022b6d6 Add a command-line option of '-R somename', which indicates that newsyslog
should rotate all files given on the command, even if they don't seem to
need to be rotated.  This would be used by some other command that decides
the given log file(s) should be rotated, but wants the "how" of that rotation
to be determined by entries to newsyslog.  Wes expects to change syslogd to
take advantage of this.  Man page will be updated after we're sure this is
all working the way we want it to.

Reviewed by:	no objections on freebsd-arch
MFC after:	3 weeks
MFC addendum:	(or after the code-freeze of 4.x is lifted)
2003-03-02 23:23:11 +00:00
Garance A Drosehn f2c3715aa7 Add a command-line option of '-s', which indicates that newsyslog should
not send a signal to any processes.  Also add a config-file flag of 'N' or
'n', which indicates that the given logfile has no process which needs a
signal when it is rotated.  Both of these are based on changes NetBSD
has made, although the implementation is somewhat different.

PR:		bin/36553  (2nd half)
Reviewed by:	no objections on freebsd-arch
Obtained from:	NetBSD (in spirit, at least)
MFC after:	3 weeks
2003-03-02 22:05:17 +00:00
Ruslan Ermilov 3892c30012 mdoc(7) police: Nits. 2003-03-02 21:04:21 +00:00
Giorgos Keramidas 35adbc4d5c Remove traces of MAKEDEV & add xref to mount_devfs(8).
DEVFS is now mandatory in CURRENT.

PR:		docs/48095
Submitted by:	Grzegorz Czaplinski <G.Czaplinski@prioris.mini.pw.edu.pl>
2003-02-28 22:47:18 +00:00
Maxim Sobolev 9434c1a30b Add a new variable `noInet6', which if set disables IPv6 configuration
dialog for network interfaces.

MFC after:	20 days
2003-02-27 21:04:34 +00:00
Maxim Sobolev 892c3d7abc Increase size of the static buffer used to hold runtime dependency list
read from CD from 2k to 16k, because in the modern world of meta-packages
(Gnome et al) the length of this list could easily owerflow limit causing
strange things to happen, ranging from installation failure due to list
truncation to complete stack trashing (there is very vague bounds checking).
For example, x11/gnome2-fifth-toe runtime dependencies list is 2,418 bytes
long.

Due to obvious reasons, this is an immediate MFC candidate.

Sponsored by:	Porta Software Ltd
MFC after:	1 day
2003-02-27 20:43:52 +00:00
Maxime Henrion 356168f5cc Document the fact that VTY locking is easily bypassable when DDB
is compiled in the kernel.  Also add some useful xrefs to lock(1).
2003-02-27 18:25:26 +00:00
Tim J. Robbins 5c7f2892f7 "Advertizing" is ugly and possibly incorrect; use "Advertising" instead. 2003-02-27 14:07:49 +00:00
Doug Barton 04a2863cfd Try another solution for not expanding a CVS tag.
Submitted by:	roam
2003-02-27 08:29:30 +00:00
John W. De Boskey f3194000cb - Increase the maximum device name length.
- Actually check that the entered device name does not exceed the
  maximum device name length.

PR:		misc/18466
MFC after:	2 weeks
2003-02-27 03:57:17 +00:00