summaryrefslogtreecommitdiffstats
path: root/usr.sbin
Commit message (Collapse)AuthorAgeFilesLines
* MFC r258901:sbruno2014-01-051-1/+1
| | | | | | | | svn r251516 resized the buf argument a bit too much. Pass a hardcoded size of 6 to humanize_number() to resolve this. PR: bin/184405 Submitted by: jhb
* MFC r259870:pluknet2014-01-021-2/+2
| | | | Do not truncate the ``command'' column in ``ps'' output.
* MFC 258063,258064,258066,258097,258185,259134:jhb2013-12-272-53/+219
| | | | | | | | | | | | | | - Add an -s option to the regression tests that specifies a path to an alternate etcupdate.sh script to test. This allows a non-installed version of the script to be tested more easily. - Add a pre-world mode of updating similar to the -p option that can be passed to mergemaster. - Fix a couple of issues with -F: - Fix ALWAYS_INSTALL to take precedence over the FreeBSD ID checks. - Fix the -F option in the case that the only upstream change is a change in the FreeBSD ID and the local file is removed. - Refresh /etc/localtime after each update using tzsetup -r. - Regenerate /var/db/services.db when /etc/services changes.
* MFC 259013:jhb2013-12-241-16/+3
| | | | | | Fix the processor table entry structure to use a fixed-width type for 32-bit fields so it is the correct size on amd64. Remove a workaround for the broken structure from bhyve(8).
* MFC r256650: kldxref: Add static keyword to the new function only used in thejilles2013-12-221-1/+1
| | | | | | same file. The WARNS level is not such that the omission broke the build.
* MFC r259276,259468-259470,259472,259474,259476-259478,259480-259481,259570,dteske2013-12-194-311/+321
| | | | | | | | | | | | | | | | | | | | 259572, and 259597-259598... r259276: Fix bug in `services' script in adding dumpdev comment to rc.conf r259468: Ignore spurious escape generated by VMware's Ctrl-Cmd combination r259469: Mask errors in `config' script from newaliases(1) about non-FQHN r259470: Set atime=on for /var/mail zfsboot dataset to support mail server r259472: Accept NULL input for zfsboot SWAP to indicate SWAP of zero bytes r259474: Multiple changes, including bug-fixes and debugging improvements r259476: Change default ZFS disk layout, making it easier to resize r259477: fletcher4 is now the default (zfsboot related) r259478: De-uglify the geli(8)-setup infobox (zfsboot related) r259480: Fix ghosted zroot issue by always performing labelclear on swap r259481: Auto-enable 4k sector alignmet when geli(8) is enabled (zfsboot) r259570: Fix numerical comparison error (zfsboot) r259572: Mask spurious rm error in bsdinstall_log from `auto' script r259597: Fix zfsboot regression when installing to 3+ disks r259598: Set cachefile property of bootpool so it imports to new system
* MFC r259266:bdrewery2013-12-193-15/+186
| | | | | | | | | | | | | Fix multi-repository support by properly respecting 'enabled' flag. This will read the REPOS_DIR env/config setting (default is /etc/pkg and /usr/local/etc/pkg/repos) and use the last enabled repository. This can be changed in the environment using a comma-separated list, or in /usr/local/etc/pkg.conf with JSON array syntax of: REPOS_DIR: ["/etc/pkg", "/usr/local/etc/pkg/repos"] Approved by: bapt (mentor)
* MFC r259302,r259413grehan2013-12-182-2/+300
| | | | | | | | r259302 bhyve(8) man page r259413 mdoc: sort SEE ALSO
* MFC r259426, r259427:gjb2013-12-181-0/+3
| | | | | | | | | | | | | | | | | r259426: Add a pkg(8) repository configuration file for cdrom-based package installation. As part of the 'pkg-stage' target, copy the configuration file to the 'packages/repos/' directory on the DVD filesystem. r259427: Export 'REPOS_DIR' when the selected source medium for package installation is cdrom. This enables bsdconfig(8) to make use of the on-disc pkg(8) repository configuration, which fixes package selection and installation from the dvd installer. Sponsored by: The FreeBSD Foundation
* MFC r259132,r259133,r259143:eadler2013-12-161-1/+1
| | | | | | | | | | | | Per the resolution of POSIX bug 0000779 (note 0002050) add support for using 'i' as a case insensitive flag. Add regression test for recently added 'i' flag in r259132. the i modifier was added in r259132 since POSIX recently agreed to add it. Switch uses of /I to /i. PR: standards/184641
* MFC r259113, r259115, r259144, r259148:gjb2013-12-143-4/+5
| | | | | | | | | | | | | | | | | | | | | r259113 (dteske): Fix failed attempt to send pkg(8) stderr to /dev/null r259115 (dteske): Prevent truncating /tmp/bsdinstall_log each time we exec a module. r259144 (dteske): Fix a regression after successfully installing to encrypted ZFS root, the passphrase is not accepted and a message about "incorrect key" is displayed. r259148 (dteske): Fix a regression resulting in mountroot prompt after attempting to install to encrypted ZFS root (caused by a typo in a variable name -- ZFSBOOT_BOOT_FSNAME -> ZFSBOOT_BOOTFS_NAME). Sponsored by: The FreeBSD Foundation
* MFC r258076, r258077:ian2013-12-141-8/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes 3 problems in syslogd related to sizing receive buffers... - A call was misplaced at the wrong level of nested if blocks, so that the buffers for unix domain sockets (/dev/log, /dev/klog) were never increased at all; they remained at a way-too-small default size of 4096. - The function that was supposed to double the size of the buffer sometimes did nothing, and sometimes installed a wildly-wrong buffer size (either too large or too small) due to an unitialized 'slen' variable passed to getsockopt(). Most often it doubled the UDP buffers from 40k to 80k because accidentally there would be harmless stack garbage in the unitialized variables. - The whole concept of blindly doubling a socket's buffer size without knowing what size it started at is a design flaw that has to be called a bug. If the double_rbuf() function had worked at all (I.E., if the other two bugs didn't exist) this would lead to UDP sockets having an 80k buffer while unix dgram sockets get an 8k buffer. There's nothing about the problem being solved that requires larger buffers for UDP than for unix dgram sockets -- the buffering requirements are the same regardless of socket type. This change renames the double_rbuf() function to increase_rbuf() and increases the buffer size on all types of sockets to 80k. 80k was chosen only because it appears to be the size the original change was shooting for, and it certainly seems to be reasonably large (I might have picked 64k in the absence of any historical guidance). Add ENETUNREACH and EADDRNOTAVAIL to the list of errors that are potentially transient and shouldn't result in closing the socket and giving up forever.
* MFC r259182:trasz2013-12-131-0/+8
| | | | | | | | Fix handling for empty auth-groups. Without it, ctld child process would either exit on assertion, or, if assertions are not enabled, fail to authenticate the target. Sponsored by: The FreeBSD Foundation
* MFC r256657,r257018,r257347,r257423,r257729,r257767,grehan2013-12-1314-125/+268
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r257933,r258609,r258614,r258668,r258673,r258855 Pull in some minor bugfixes and functionality enhancements from CURRENT. These are candidates to be moved to 10.0-release. r258855 mdoc: quote string properly. r258673 Don't create an initial value for the host filesystem of "/". r258668 Allow bhyve and bhyveload to attach to tty devices. r258614 The 22-bit Data Byte Count (DBC) field of a Physical Region Descriptor was being read as a 32-bit quantity by the bhyve AHCI driver. r258609 Fix discrepancy between the IOAPIC ID advertised by firmware tables and the actual value read by the guest. r257933 Route the legacy timer interrupt (IRQ0) to pin 2 of the IOAPIC. r257767 Fix an off-by-one error when iterating over the emulated PCI BARs. r257729 Add the VM name to the process name with setproctitle(). r257423 Make the virtual ioapic available unconditionally in a bhyve virtual machine. r257347 Update copyright to include the author of the LPC bridge emulation code. hand-merge r257018 Tidy usage messages for bhyve and bhyveload. r256657 Add an option to bhyveload(8) that allows setting a loader environment variable from the command line. Discussed with: neel
* MFC r259156:eadler2013-12-131-2/+2
| | | | | | | | | mtest(8): use correct macro in mdoc The An macros is used for authors while the Ar macro is used for arguments. AFAIK mcast-addr and ifname are not authors. PR: docs/184649
* MFC r258927: Fix a regression introduced by SVN r257842 that preventsdteske2013-12-071-4/+6
| | | | | | Encryption from being enabled. Approved by: re (gjb)
* MFC r258842:trasz2013-12-051-2/+2
| | | | | | | Grammar fix. Approved by: re (gjb) Sponsored by: The FreeBSD Foundation
* MFC r258841:trasz2013-12-051-3/+3
| | | | | | | Fix typos. Approved by: re (gjb) Sponsored by: The FreeBSD Foundation
* MFC r258854:gjb2013-12-051-1/+1
| | | | | | | | Fix PKG_ABI detection in bsdconfig(8) after pkg-1.2 is released, since the format of 'pkg -vv' output has changed. Approved by: re (hrs) Sponsored by: The FreeBSD Foundation
* MFC r258550:gjb2013-11-301-24/+0
| | | | | | | | Do not create pkg.conf, as it is not necessary anymore and packagesite is deprecated Approved by: re (glebius) Sponsored by: The FreeBSD Foundation
* MFC r258348:bdrewery2013-11-291-2/+2
| | | | | | | Document 'enabled' as boolean instead of string. Approved by: bapt (implicit) Approved by: re (gjb)
* MFC r257879:delphij2013-11-281-2/+2
| | | | | | | | | | | Fix typo in r256646: We want to generate lists of directories in INDEX-OLD and INDEX-NEW and compare them, not generate the same list of directories from INDEX-OLD twice... Pointy hats to: cperciva & everybody who didn't proofread EN-13:04 enough Errata Notice: FreeBSD-EN-13:05.freebsd-update Approved by: re (gjb)
* MFC: r258456brooks2013-11-261-1/+7
| | | | | | | | | | | Fix mergemaster -U by forcing FreeBSD 9 compatiblity in mtree when mtree is nmtree. The mtree output used by mergemaster in this case was clearly not meant for computer consumption and an approach based on -f <file1> -f <file2> would probably be a better idea, but this is a minimal change. Approved by: re (glebius)
* MFC Revisions:dteske2013-11-2111-454/+1064
| | | | | | | | | | | | | | | | | 256549: man-page updates 256551: .Dd bump in manpage 256553: bootenv -> ROOT fix 257842: monster list of fixes 257843: minor touchup 257844: copy install log 257845: fixup to last 257872: mdoc fixup 257939: debug check 258021: MBR bootcode fixup Reviewed by: many Discussed on: -current Approved by: re (hrs)
* MFC r257755-257756,257780-257785,257787-257793, anddteske2013-11-2113-129/+520
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 257795,257817,257819,257937-257938,258029,258263-258267: 257755: SRV records 257756: fix spurious error message 257780: Whitespace 257781: Comments and funny syntax 257782: Debug file truncation is optional 257783: f_show_err for debugging 257784: f_eval_catch for debugging 257785: fix size calculations bug 257787: fix broken HTTP "any" media type 257788: more debugging 257789: Comments 257790: fix printf usage bug 257791: f_[v]sprintf added 257792: Comments 257793: fix off-by-one error in size calcs 257795: Replace pkg-tools with pkgng 257817: fix cosmetic typos 257819: Use `pkg -vv' to get ABI 257937: Adjustment to last 257938: Adjustment to last 258029: Comments 258263: Shuffle code around 258264: Remove unused code 258265: Debugging. Use f_eval_catch with pkg 258266: Shutdown media on exit from packages 258267: Fix pkg install from DVD Reviewed by: many Discussed on: -current Approved by: re (hrs)
* Fix typo.trasz2013-11-141-2/+2
| | | | | Approved by: re (gjb) Sponsored by: The FreeBSD Foundation
* Merge r257945 from head:glebius2013-11-141-2/+2
| | | | | | Do not use just freed memory. Approved by: re (kib)
* Merge r257888, r258049 from head:glebius2013-11-141-5/+0
| | | | | | | | - Use system libiconv, instead of trying to dlopen() it. - Just disable recoding support in libsmb if built WITHOUT_ICONV. PR: 183153 Approved by: re (kib)
* MFC r257749:gjb2013-11-091-2/+9
| | | | | | | | | Switch to using pkg(8) for the doc install in bsdinstall(8). This also bootstraps the system with pkg(8) for future use. Approved by: re (delphij) PR: 183488 Sponsored by: The FreeBSD Foundation
* MFC r257668:bdrewery2013-11-071-2/+2
| | | | | | | Use proper capitalization for FreeBSD.org Approved by: bapt Approved by: re (gjb)
* MFC r257505:bdrewery2013-11-042-23/+61
| | | | | | | | | | | | | Add -f support to 'pkg bootstrap' and 'pkg add' to force installation of pkg(8) even if already installed. This is useful if you somehow messup pkg(8) and need to reinstall from remote with it already being registered in the pkg(8) /var/db/pkg database. Also add some sanity checks to 'pkg add'. Approved by: bapt Approved by: re (glebius)
* MFC r257378,r257400,r257402,r257440:bdrewery2013-11-032-1/+263
| | | | | | | Add a pkg(7) manpage for bootstrap Approved by: bapt Approved by: re (gjb)
* MFC r257377:bdrewery2013-11-031-0/+9
| | | | | | | | Add a 'pkg bootstrap' command which will bootstrap pkg(8) without forwarding any command to it after installation. Approved by: bapt Approved by: re (gjb)
* MFC r257379:trasz2013-11-022-39/+39
| | | | | | | | | | | | | | | | | Rename '-h' option to '-p', and use "portal" instead of "host" or "address", in order to be consistent with iSCSI terminology. Besides, calling the option '-h' was just wrong. This changes usage for newly added iscsictl(8), and two newly added subcommands to ctladm(8). This breaks POLA between CURRENT and 10, but since 10.0 has not been released yet, it's still ok to do. MFC r257380: Bump .Dd after r257379. Approved by: re (glebius) Sponsored by: The FreeBSD Foundation
* MFC r256540, r256544:gjb2013-11-011-1/+9
| | | | | | | | | | | | r256540 (dteske): Add loader.conf(5) entries to import bootpool after boot when using full-disk encryption and ZFS. r256544 (dteske): Fix loader.conf(5) entries from r256540. Approved by: re (hrs) Sponsored by: The FreeBSD Foundation
* MFC r256865brooks2013-10-314-212/+0
| | | | | | | | | Remove the isf(4) driver. It was created by accident and is subset of the cfi(4) driver. It remained in the tree longer than would be ideal due to the time required to bring cfi(4) to feature parity. Sponsored by: DARPA/AFRL Approved by: re (gjb)
* MFC r257092grehan2013-10-301-31/+85
| | | | | | | | | | Fix bug in the ioapic emulation for level-triggered interrupts, where a pin assertion while a source was masked would result in the interrupt being lost, with the symptom being a console hang. The condition is now recorded, and the interrupt generated when the source is unmasked. Approved by: re (glebius)
* MFC r257293.neel2013-10-3013-596/+1103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for PCI-to-ISA LPC bridge emulation. If the LPC bus is attached to a virtual machine then we implicitly create COM1 and COM2 ISA devices. Prior to this change the only way of attaching a COM port to the virtual machine was by presenting it as a PCI device that is mapped at the legacy I/O address 0x3F8 or 0x2F8. There were some issues with the original approach: - It did not work at all with UEFI because UEFI will reprogram the PCI device BARs and remap the COM1/COM2 ports at non-legacy addresses. - OpenBSD GENERIC kernel does not create a /dev/console because it expects the uart device at the legacy 0x3F8/0x2F8 address to be an ISA device. - It was functional with a FreeBSD guest but caused the console to appear on /dev/ttyu2 which was not intuitive. The uart emulation is now independent of the bus on which it resides. Thus it is possible to have uart devices on the PCI bus in addition to the legacy COM1/COM2 devices behind the LPC bus. The command line option to attach ISA COM1/COM2 ports to a virtual machine is "-s <bus>,lpc -l com1,stdio". The command line option to create a PCI-attached uart device is: "-s <bus>,uart[,stdio]" The command line option to create PCI-attached COM1/COM2 device is: "-S <bus>,uart[,stdio]". This style of creating COM ports is deprecated. Approved by: re (glebius)
* MFC: r256770,r257142,r257145,r257146,r257147,r257148,bdrewery2013-10-294-89/+788
| | | | | | | | | | | | | | | | | | | | | r257149,r257150,r257158,r257159,r257164,r257168, r257193 - Support checking signature for pkg bootstrap from remote and for 'pkg add ./pkg.txz' - Be verbose on where pkg is being bootstrapped from. - Add support for reading configuration files from /etc/pkg. For now only /etc/pkg/FreeBSD.conf is supported. - Add test package signing key fingerprint into /etc/keys/pkg/trusted. - Disable fingerprint checking by default for now as the official packages are not yet signed. Approved by: bapt Approved by: re (glebius)
* MFC r257051:bdrewery2013-10-293-1/+9
| | | | | | | | | | | Add support for using "pkg+http://" for the PACKAGESITE. pkg 1.2 is adding this support as well. This should help lessen the confusion on why the default SRV PACKAGESITE does not load in a browser. Approved by: bapt Approved by: re (glebius)
* MFC: r256968, r256971, r256978bapt2013-10-293-3/+108
| | | | | | | | | | | | Improve SRV records support for the pkg(8) bootstrap: - order srv records by priorities - for all entries of the same priority, order randomly respect the weight - select the port where to fetch from respect the port provided in the SRV record Allow to bootstrap by doing pkg add ./a/path/to/a/pkg_package.txz Approved by: re (glebius)
* MFC r256646, r256767, r257038:cperciva2013-10-261-8/+25
| | | | | | | | | | | | | | | | When installing updates, install new directories first and remove old directories last. Allow ~ in file names so libtool droppings in contrib don't break updates. It has happened twice now, and is likely to happen again. Be more selective when filtering for lib*.so.N files. These are deleted at the end of the upgrade process, after warning users to upgrade any 3rd party software (e.g., from the ports tree) which might link to the libraries being removed. Approved by: re (gjb) Errata Notice: FreeBSD-EN-13:04.freebsd-update
* MFC r256926, r257005grehan2013-10-252-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | r256926 Fix AHCI ATAPI emulation when backed with /dev/cd0 - remove assumption that the backing file/device had 512-byte sectors - fix incorrect iovec size variable that would result in a buffer overrun when an o/s issued an i/o request with more s/g elements than the blockif api r257005 Export the block size capability to guests. - Use #defines for capability bits - Export the VTBLK_F_BLK_SIZE capability - Fix bug in calculating capacity: it is in 512-byte units, not the underlying sector size This allows virtio-blk to have backing devices with non 512-byte sector sizes e.g. /dev/cd0, and 4K-block harddrives. Approved by: re (glebius)
* MFC r256450:bdrewery2013-10-232-3/+6
| | | | | | | | Rename libbsdyml to libyaml, make private, and bump SHLIB_MAJOR to 1.0 Approved by: bapt Approved by: re (glebius)
* MFC r256645.neel2013-10-224-50/+49
| | | | | | | | | | | | | | Add a new capability, VM_CAP_ENABLE_INVPCID, that can be enabled to expose 'invpcid' instruction to the guest. Currently bhyve will try to enable this capability unconditionally if it is available. Consolidate code in bhyve to set the capabilities so it is no longer duplicated in BSP and AP bringup. Add a sysctl 'vm.pmap.invpcid_works' to display whether the 'invpcid' instruction is available. Approved by: re (hrs)
* MFC r256709:grehan2013-10-187-147/+60
| | | | | | | | | | | Eliminate unconditional debug printfs. Linux writes to these nominally read-only registers, so avoid having bhyve write warning messages to stdout when the reg writes can be safely ignored. Change the WPRINTF to DPRINTF which is conditional. Approved by: re (delphij)
* MFC r256709:grehan2013-10-181-1/+1
| | | | | | | | | | | Eliminate unconditional debug printfs. Linux writes to these nominally read-only registers, so avoid having bhyve write warning messages to stdout when the reg writes can be safely ignored. Change the WPRINTF to DPRINTF which is conditional. Approved by: re (gjb)
* MFC r256489:dteske2013-10-183-0/+8
| | | | | | | | | Add executable bit to docsinstall [old] and entropy [new] scripts. MFC r256541: Document BSDINSTALL_TMPBOOT environment variable introduced by SVN r256343. Approved by: re (gjb)
* MFC r256391:dteske2013-10-121-24/+34
| | | | | | Fix signed integer overflow detection in f_expand_number() of strings.subr. Approved by: re (glebius)
* MFC r256389grehan2013-10-121-5/+47
| | | | | | | | | | | | Implement the virtio block 'get-ident' operation. This eliminates the annoying verbose boot error of the form g_handleattr: vtbd0 bio_length 24 len 28 -> EFAULT The ident returned by bhyve is a text string 'BHYVE-XXXX-XXXX', where the X's are the first bytes of the md5 hash of the backing filename. Approved by: re (gjb)
OpenPOWER on IntegriCloud