aboutsummaryrefslogtreecommitdiff
path: root/sbin
Commit message (Collapse)AuthorAgeFilesLines
* dumpon: warn if the configured netdump link is downMitchell Horne2022-05-141-4/+23
| | | | | | | | | | | | Previously we expected the DIOCSKERNELDUMP ioctl to return ENXIO if the interface was down, but it does not actually do this. Grab the link status using getifaddrs(3) instead, and downgrade this case from an error to a warning; the user might bring the link back up at a later time. Reviewed by: cem MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D35196
* ipfw.8: spell "layer2" consistently throughout the manual pageEugene Grosbein2022-05-131-3/+3
| | | | MFC after: 1 week
* Clean up comments in fsck.h.Kirk McKusick2022-05-101-56/+55
| | | | No functional change.
* newfs_msdos: Fix warnings that arise when compiled for makefsMark Johnston2022-05-101-2/+5
| | | | | MFC after: 2 weeks Sponsored by: The FreeBSD Foundation
* dmesg: Better wording from reviewWarner Losh2022-05-071-3/+4
| | | | | | | | | | | | | | | | I pushed the last changes before I'd noticed the better wording suggestions in the review. Also include a note that not all lines will have a timestampe. Some multi-line messages are generated with sbuf, and when those are pushed, only the first line will have the timestamp. Document this quirky behavior as well since fixing it likely won't happen soon. CAM periph drivers generate all the lines in their announce message together so they aren't intermingled with other things, for example. Suggested by: allanjude, emaste, rpokala Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D35139 Differential Revision: https://reviews.freebsd.org/D35141
* msgbuf: Allow microsecond granularity timestampsWarner Losh2022-05-071-1/+4
| | | | | | | | | | | | | | | | | | | Today, kern.msgbuf_show_timestamp=1 will give 1 second granularity timestamps on dmesg lines. When kern.msgbuf_show_timestamp=2, we'll produce microsecond level graunlarity. For example: old (== 1): [13] Dual Console: Video Primary, Serial Secondary [14] lo0: link state changed to UP [15] bxe0: NIC Link is Up, 10000 Mbps full duplex, Flow control: ON - receive & transmit [15] bxe0: link state changed to UP new (== 2): [13.807015] Dual Console: Video Primary, Serial Secondary [14.544150] lo0: link state changed to UP [15.272044] bxe0: NIC Link is Up, 10000 Mbps full duplex, Flow control: ON - receive & transmit [15.272052] bxe0: link state changed to UP Sponsored by: Netflix
* dmesg: Document kern.msgbuf_show_timestampWarner Losh2022-05-071-1/+14
| | | | | | | kern.msgbuf_show_timestamp=1 turns on timestamps in kernel's message buffer which dmesg(8) prints. Sponsored by: Netflix
* Improve description of the nocache option.Alexander Leidinger2022-05-061-2/+4
| | | | Discussed with: pstef
* Properly specify the level of indirect block being looked up.Kirk McKusick2022-05-051-1/+1
| | | | | The value is used only for diagnostic purposes so no functional change should result.
* If setkey(8) is used without ipsec.ko loaded beforehand,Eugene Grosbein2022-05-051-0/+15
| | | | | | | | | | | | its attempt to install SA/SPD into the kernel results in cryptic EINVAL error code. Let it be a bit more user-friendly and try to load ipsec.ko automatically if it is not loaded, just like ifconfig(8) does it for modules it needs. PR: 263379 MFC after: 2 weeks
* pkgbase: move devd's hyperv.conf to hyperv-tools packageMina Galić2022-05-031-1/+4
| | | | | | | | This devd config file is useless without hyperv-tools, so we're moving it into the hyperv-tools package. pr#263691 PR: 263691 MFC after: 3 days
* sbin/devfs: Correct usageEnji Cooper2022-04-301-1/+1
| | | | | | | | | | | The -s applies to rule keyword only and it follows the rule keyword. MFC after: 1 week PR: [[https://bugs.freebsd.org/bugzilla/show_bug.cgi?id= 263289|263289]] Submitted by: Yuichiro NAITO <naito.yuichiro@gmail.com> Fixes: c3e412c08333 sbin/devfs: clarify usage Reviewed by: ngie Differential Revision: https://reviews.freebsd.org/D34934
* fusefs: use the fsname mount option if setAlan Somers2022-04-291-2/+4
| | | | | | | | | | The daemon can specify fsname=XXX in its mount options. If so, the file system should report f_mntfromname as XXX during statfs. This will show up in the output of commands like mount and df. Submitted by: Ali Abdallah <ali.abdallah@suse.com> MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D35090
* setkey(8): Clarify language around AEAD ciphers.John Baldwin2022-04-271-26/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | AEAD ciphers for IPsec combine both encryption and authentication. As such, ESP configurations using an AEAD cipher should not use a seperate authentication algorithm via -A. However, this was not apparent from the setkey manpage and 12.x and earlier did not perform sufficient argument validation permitting users to pair an explicit -A such as SHA256-HMAC with AES-GCM. (The result was a non-standard combination of AES-CTR with the specified MAC, but with the wrong initial block counter (and thus different keystream) compared to using AES-CTR as the cipher.) Attempt to clarify this in the manpage by explicitly calling out AEAD ciphers (currently only AES-GCM) and noting that AEAD ciphers should not use -A. While here, explicitly note which authentication algorithms can be used with esp vs esp-old. Also add subsection headings for the different algorithm lists and tidy some language. I did not convert the tables to column lists (Bl -column) though that would probably be more correct than using literal blocks (Bd -literal). PR: 263379 Reviewed by: Pau Amma <pauamma@gundo.com>, markj Differential Revision: https://reviews.freebsd.org/D34947
* pf: Add per-rule timestamps for rule and eth_ruleReid Linnemann2022-04-221-0/+23
| | | | | | | | | | | Similar to ipfw rule timestamps, these timestamps internally are uint32_t snaps of the system time in seconds. The timestamp is CPU local and updated each time a rule or a state associated with a rule or state is matched. Reviewed by: kp Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D34970
* Add nullfs specific nocache option.Alexander Leidinger2022-04-221-1/+7
|
* pfctl tests: fix Ethernet output expectationsKristof Provost2022-04-213-3/+3
| | | | | | | Since a16732d670 we always print the l3 src/destination for Ethernet rules. Update the tests to account for this. Sponsored by: Rubicon Communications, LLC ("Netgate")
* ifconfig: Fix spelling errorWarner Losh2022-04-201-1/+1
| | | | | | s/discreet/discrete Reported by: Diane Bruce
* pfctl: always print 'l3' source/destinationKristof Provost2022-04-201-6/+4
| | | | | | | | | While the kernel only performs the L3 check for ETHERTYPE_IP/ETHERTYPE_IP6 we should always print the source and destination addresses. Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D34918
* pf: allow the use of tables in ethernet rulesKristof Provost2022-04-201-4/+6
| | | | | | | | Allow tables to be used for the l3 source/destination matching. This requires taking the PF_RULES read lock. Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D34917
* ping: split the visual part of -f into a new option -.Piotr Pawel Stefaniak2022-04-184-18/+59
| | | | | | | | | After this, we'll be able to ping a host and not spam the terminal, and no flooding will have to be involved. I've been doing this under Linux as ping -fi1 host. Reviewed by: rpokala, Pau Amma Differential Revision: https://reviews.freebsd.org/D34882
* savecore: add an option to save a live minidumpMitchell Horne2022-04-182-5/+250
| | | | | | | | | | | | | | | | | | | | | | | | | The new '-L' flag will cause savecore to invoke the new mem(4) kernel dump ioctl, taking a dump of the running system and writing the result to a temporary file. Validation of the dump header is performed, similar to regular crash dumps, and the final result is written to livecore.X[.zst|.gz]. Also added is the '-Z' flag, which instructs the kernel to compress the livedump compressed with zstd, akin to the existing -z flag. This option has no effect in normal savecore(8) operation, but in theory could be extended to perform such compression while reading the dump from the dump device. Encryption is unsupported for live dumps. For example: 'savecore -Lz /var/crash' would create: /var/crash/livecore.0.gz Reviewed by: markj MFC after: 2 weeks Sponsored by: Juniper Networks, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D34347
* savecore: factor out info file handlingMitchell Horne2022-04-181-32/+43
| | | | | | | | | | Move it to a separate function, allowing its reuse. Reviewed by: markj MFC after: 3 days Sponsored by: Juniper Networks, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D34822
* savecore: decrease filename buffer sizesMitchell Horne2022-04-181-6/+5
| | | | | | | | | | | | | | | | All files are now created relative to savedirfd, e.g. with openat(2). Therefore, we do not need character buffers to be PATH_MAX bytes long, just long enough to hold the complete filename. 32 bytes is long enough in all cases. These can be allocated on the stack. While here, fix an error message that attempts to use an uninitialized infoname. Reviewed by: markj MFC after: 3 days Sponsored by: Juniper Networks, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D34821
* savecore: fold maxdumps check into getbounds()Mitchell Horne2022-04-181-3/+2
| | | | | | | | | | So that new callers of getbounds() don't need to duplicate it. Reviewed by: markj MFC after: 3 days Sponsored by: Juniper Networks, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D34783
* pfctl: fix recursive printing of rulesMatteo Riondato2022-04-141-7/+5
| | | | | | | | | When asked to print rules recursively, correctly recurse for anchors included in pf.conf with "anchorname/*". PR: 262590 Reviewed by: kp MFC after: 3 weeks
* ifconfig.8: Note that -l accepts -g in addition to -d and -uMateusz Piotrowski2022-04-111-2/+3
| | | | | Fixes: 5533c5046ada ifconfig.8: Update -l synopsis MFC after: 3 days
* mount: use pidfile_signalMateusz Guzik2022-04-091-26/+1
| | | | | | | | | | This fixes a performance problem where poudriere -j 104 keeps remounting filesystems, which induce wanting to signal mountd, if running. The current code tries to do it by creating the pidfile in /var/run and unlinking it if the operation succeeds, inducing contention against anything doing an exec as it tries to look up /var/run/ld-elf.so.hints Differential Revision: https://reviews.freebsd.org/D34681
* fsck_ffs(8): Fix a typo in a source code commentGordon Bergling2022-04-091-1/+1
| | | | | | - s/it it/if it/ MFC after: 3 days
* routed(8): Remove a double word in a source code commentGordon Bergling2022-04-091-1/+1
| | | | | | - s/it it/it/ MFC after: 3 days
* hastd(8): Fix a typo in a source code commentGordon Bergling2022-04-091-1/+1
| | | | | | - s/proccesses/processes/ MFC after: 3 days
* umount(8): Remove a double word in a source code commentGordon Bergling2022-04-091-1/+1
| | | | | | - s/this this/this/ MFC after: 3 days
* ipnat(5): Fix a double word in the manual pageGordon Bergling2022-04-091-1/+1
| | | | | | - s/be be/be/ MFC after: 3 days
* dhclient(8): Fix a typo in a source code commentGordon Bergling2022-04-091-1/+1
| | | | | | - s/explicitely/explicitly/ MFC after: 3 days
* savecore: include '-u' flag in usage messageMitchell Horne2022-04-051-1/+1
| | | | | | Reported by: Pau Amma <pauamma@gundo.com> Fixes bc7ed46b635e ("Add '-u' switch that would...") MFC after: 3 days
* libpfctl: relocate implementations of pfr_add/get/set_addrsReid Linnemann2022-04-041-67/+17
| | | | | | Reviewed by: kp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D34740
* bectl: push space-in-name check down into libbeKyle Evans2022-04-031-7/+2
| | | | | | | | | | | | | This check was previously in `create` only, not applying to renames. It should really be applied at the libbe level, so that we can avoid writing about this restriction over and over again. While we're here: `bectl rename` always succeeds, even when it doesn't. Start returning the error. Reported By: Christian McDonald <cmcdonald netgate com> Reviewed by: rew, jwmaag_gmail.com (earlier version) Differential Revision: https://reviews.freebsd.org/D34605
* ipf(5): Fix a typo in the manual pageGordon Bergling2022-04-021-1/+1
| | | | | | - s/accomodate/accommodate/ MFC after: 3 days
* devd(8): Fix a typo in a configuration fileGordon Bergling2022-04-021-1/+1
| | | | | | - s/coresponding/corresponding/ MFC after: 3 days
* pf: handle duplicate rules gracefullyMateusz Guzik2022-04-011-2/+17
| | | | | | | Reviewed by: kp Reported by: dch PR: 262971 Sponsored by: Rubicon Communications, LLC ("Netgate")
* bectl: add some discussion about boot environment layoutsKyle Evans2022-03-311-1/+91
| | | | | | | | | | | | Discuss the standard type of layout, as well as the "deep" BE layout, and some of the properties of both. Point the various -r flags at this new section, to help users understand which they're working with and what the -r flag is actually doing. Note that we may just deprecate the -r flag in future versions, but the flag will be recognized as a NOP at that point. Reviewed by: pauamma_gundo.com, rew Differential Revision: https://reviews.freebsd.org/D34538
* ifconfig.8: Update -l synopsisMateusz Piotrowski2022-03-311-0/+1
| | | | | | The -g flag can be used together with the -l flag. MFC after: 2 weeks
* ifconfig.8: Document "ifconfig -g groupname"Mateusz Piotrowski2022-03-311-0/+50
| | | | | | | | | | | | "ifconfig -g groupname" prints a list of interface names, which could be confusing, because it differs from the behavior of "ifconfig -a -g groupname". While here, add two examples showing the difference between "ifconfig -a -g groupname" and "ifconfig -g groupname". Fixes: 0dad3f0e1512 Import interface groups from OpenBSD. MFC after: 2 weeks
* ifconfig.8: Remove commented-out Xr eon 5Mateusz Piotrowski2022-03-311-1/+0
| | | | | | | This reference has been present in the manual page since the initial import of BSD 4.4 Lite sbin Sources. It's time for it to be removed. MFC after: 2 weeks
* ifconfig.8: Remove remaining Xerox Network Systems(tm) bitsMateusz Piotrowski2022-03-311-20/+0
| | | | | | | Support for Xeros Network Systems seems to be long gone. There is no reason to keep this in the manual page. MFC after: 2 weeks
* ifconfig.8: Simplify examples by using canonical parametersMateusz Piotrowski2022-03-311-14/+8
| | | | | | Also, use Bd instead of Dl for multi line examples. MFC after: 2 weeks
* ifconfig.8: Mark address_family as optional in synopsisMateusz Piotrowski2022-03-311-0/+2
| | | | | | | Commands like "ifconfig wlan0 up" are valid. There is no need to always specify the address family. MFC after: 2 weeks
* ifconfig.8: Improve description of the address argumentMateusz Piotrowski2022-03-311-4/+10
| | | | | | | - Split paragraphs for clarity. - Add an example of setting a random MAC address. MFC after: 2 weeks
* ifconfig.8: Improve readability of address_family documentationMateusz Piotrowski2022-03-311-28/+30
| | | | | | | Also, move the description of the special case of "ifconfig -l ether" to the description of the -l flag. MFC after: 2 weeks
* ifconfig.8: Fix quotingJose Luis Duran2022-03-301-1/+2
| | | | | | Obtained from: https://github.com/freebsd/freebsd-src/commit/67d77afb0dde9aa627635a0c4e28a8fa5a64db6c#r69907135 Fixes: 67d77afb0dde ifconfig.8: Do not use ``'' for quoting MFC after: 2 weeks