| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
and fsirand(8)) should check the filesystem status and require that
fsck(8) be run if it is unclean. This requirement is not imposed on
fsdb(8) or clri(8) since they may be used to clean up a filesystem.
MFC after: 2 weeks
Sponsored by: Netflix
Notes:
svn path=/head/; revision=367035
|
|
|
|
|
|
|
|
|
|
| |
Remove single use of dubious srandomdev(3) + random(3) and replace with
arc4random(3), as is used already in this program.
Follow-up question: Do we really need this program anymore? In base?
Notes:
svn path=/head/; revision=355692
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
check hash to the filesystem inodes. Access attempts to files
associated with an inode with an invalid check hash will fail with
EINVAL (Invalid argument). Access is reestablished after an fsck
is run to find and validate the inodes with invalid check-hashes.
This check avoids a class of filesystem panics related to corrupted
inodes. The hash is done using crc32c.
Note this check-hash is for the inode itself and not any of its
indirect blocks. Check-hash validation may be extended to also
cover indirect block pointers, but that will be a separate (and
more costly) feature.
Check hashes are added only to UFS2 and not to UFS1 as UFS1 is
primarily used in embedded systems with small memories and low-powered
processors which need as light-weight a filesystem as possible.
Reviewed by: kib
Tested by: Peter Holm
Sponsored by: Netflix
Notes:
svn path=/head/; revision=341836
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
superblock has a check-hash error, an error message noting the
superblock check-hash failure is printed and the mount fails. The
administrator then runs fsck to repair the filesystem and when
successful, the filesystem can once again be mounted.
This approach fails if the filesystem in question is a root filesystem
from which you are trying to boot. Here, the loader fails when trying
to access the filesystem to get the kernel to boot. So it is necessary
to allow the loader to ignore the superblock check-hash error and make
a best effort to read the kernel. The filesystem may be suffiently
corrupted that the read attempt fails, but there is no harm in trying
since the loader makes no attempt to write to the filesystem.
Once the kernel is loaded and starts to run, it attempts to mount its
root filesystem. Once again, failure means that it breaks to its prompt
to ask where to get its root filesystem. Unless you have an alternate
root filesystem, you are stuck.
Since the root filesystem is initially mounted read-only, it is
safe to make an attempt to mount the root filesystem with the failed
superblock check-hash. Thus, when asked to mount a root filesystem
with a failed superblock check-hash, the kernel prints a warning
message that the root filesystem superblock check-hash needs repair,
but notes that it is ignoring the error and proceeding. It does
mark the filesystem as needing an fsck which prevents it from being
enabled for writing until fsck has been run on it. The net effect
is that the reboot fails to single user, but at least at that point
the administrator has the tools at hand to fix the problem.
Reported by: Rick Macklem (rmacklem@)
Discussed with: Warner Losh (imp@)
Sponsored by: Netflix
Notes:
svn path=/head/; revision=341608
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
document the libufs interface for fetching and storing inodes.
The undocumented getino / putino interface has been replaced
with a new getinode / putinode interface.
Convert the utilities that had been using the undocumented
interface to use the new documented interface.
No functional change (as for now the libufs library does not
do inode check-hashes).
Reviewed by: kib
Tested by: Peter Holm
Sponsored by: Netflix
Notes:
svn path=/head/; revision=340411
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Specifically reading is done if ffs_sbget() and writing is done
in ffs_sbput(). These functions are exported to libufs via the
sbget() and sbput() functions which then used in the various
filesystem utilities. This work is in preparation for adding
subperblock check hashes.
No functional change intended.
Reviewed by: kib
Notes:
svn path=/head/; revision=328426
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.
The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.
No functional change intended.
Notes:
svn path=/head/; revision=326276
|
|
|
|
|
|
|
| |
Sponsored by: Dell EMC Isilon
Notes:
svn path=/head/; revision=325188
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Specifically:
ROOTINO -> UFS_ROOTINO
WINO -> UFS_WINO
NXADDR -> UFS_NXADDR
NDADDR -> UFS_NDADDR
NIADDR -> UFS_NIADDR
MAXSYMLINKLEN_UFS[12] -> UFS[12]_MAXSYMLINKLEN (for consistency)
Also prefix ext2's and nandfs's NDADDR and NIADDR with EXT2_ and NANDFS_
Reviewed by: kib, mckusick
Obtained from: NetBSD
MFC after: 1 month
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D9536
Notes:
svn path=/head/; revision=313780
|
|
|
|
|
|
|
| |
Sponsored by: The FreeBSD Foundation
Notes:
svn path=/projects/release-pkg/; revision=295450
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Off by default, build behaves normally.
WITH_META_MODE we get auto objdir creation, the ability to
start build from anywhere in the tree.
Still need to add real targets under targets/ to build packages.
Differential Revision: D2796
Reviewed by: brooks imp
Notes:
svn path=/head/; revision=284345
|
| |
| |
| |
| | |
Notes:
svn path=/projects/bmake/; revision=284172
|
| |\
| |/
|/|
| | |
Notes:
svn path=/projects/bmake/; revision=283595
|
| |
| |
| |
| | |
Notes:
svn path=/projects/bmake/; revision=274694
|
| |\
| | |
| | |
| | | |
Notes:
svn path=/projects/bmake/; revision=274683
|
| |\ \
| | | |
| | | |
| | | | |
Notes:
svn path=/projects/bmake/; revision=270164
|
| | | |
| | | |
| | | |
| | | | |
Notes:
svn path=/projects/bmake/; revision=266219
|
| | | |
| | | |
| | | |
| | | | |
Notes:
svn path=/projects/bmake/; revision=265802
|
| | | |
| | | |
| | | |
| | | | |
Notes:
svn path=/projects/bmake/; revision=248169
|
| | | |
| | | |
| | | |
| | | | |
Notes:
svn path=/projects/bmake/; revision=246868
|
| |\ \ \
| | | | |
| | | | |
| | | | | |
Notes:
svn path=/projects/bmake/; revision=242545
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Requested by: Simon Gerraty <sjg@juniper.net>
Notes:
svn path=/projects/bmake/; revision=239572
|
| |_|_|/
|/| | |
| | | |
| | | | |
Notes:
svn path=/head/; revision=276737
|
| |_|/
|/| |
| | |
| | | |
Notes:
svn path=/head/; revision=274148
|
| |/
|/|
| |
| |
| |
| |
| |
| | |
PR: 191174
Submitted by: Franco Fichtner <franco@lastsummer.de>
Notes:
svn path=/head/; revision=267667
|
|/
|
|
|
|
|
| |
Original code by: Gleb Kurtsou
Notes:
svn path=/head/; revision=241013
|
|
|
|
|
|
|
|
|
|
| |
error: variable 'inumber' set but not used
Approved by: dim
MFC after: 3 days
Notes:
svn path=/head/; revision=229917
|
|
|
|
|
|
|
|
|
| |
These tools declare global variables without using the static keyword,
even though their use is limited to a single C-file, or without placing
an extern declaration of them in the proper header file.
Notes:
svn path=/head/; revision=227081
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
include sys/time.h instead of time.h. This include is incorrect as
per the manpages for the APIs and the POSIX definitions. This commit
replaces sys/time.h where necessary with time.h.
The commit also includes some minor style(9) header fixup in newfs.
This commit is part of a larger effort by Garrett Cooper started in
//depot/user/gcooper/posix-conformance-work/ -- to make FreeBSD more
POSIX compliant.
Submitted by: Garrett Cooper yanegomi at gmail dot com
Notes:
svn path=/head/; revision=217769
|
|
|
|
|
|
|
|
|
| |
It's a bit more pedantic regarding .Bl list elements. This has an added
benefit of unbreaking the ipfw(8) manpage, where groff was silently
skipping one list element.
Notes:
svn path=/head/; revision=214132
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Drop bogus quad_t cast for di_gen, it is a 32bit type
- Print di_gen with leading zeros, to get consistent output
Before this change, amd64 would print:
ino 18 gen 616ca2bd
ino 19 gen ffffffff95c2a3ff
ino 20 gen 25c3a3d5
ino 21 gen 8dc1472
ino 22 gen 3797056b
ino 23 gen 1d47853a
ino 24 gen ffffffff82d26995
After the change
ino 18 gen 616ca2bd
ino 19 gen 95c2a3ff
ino 20 gen 25c3a3d5
ino 21 gen 08dc1472
ino 22 gen 3797056b
ino 23 gen 1d47853a
ino 24 gen 82d26995
PR: bin/139994 (sort of)
Reviewed by: mckusick
Notes:
svn path=/head/; revision=208074
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
bottom of the manpages and order them consistently.
GNU groff doesn't care about the ordering, and doesn't even mention
CAVEATS and SECURITY CONSIDERATIONS as common sections and where to put
them.
Found by: mdocml lint run
Reviewed by: ru
Notes:
svn path=/head/; revision=208027
|
|
|
|
| |
Notes:
svn path=/head/; revision=132762
|
|
|
|
| |
Notes:
svn path=/head/; revision=131488
|
|
|
|
|
|
|
| |
Use WARNS?= instead of WARNS=.
Notes:
svn path=/head/; revision=126178
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the old 8-bit fs_old_flags to the new location the first time that the
filesystem is mounted by a new kernel. One of the unused flags in
fs_old_flags is used to indicate that the flags have been moved.
Leave the fs_old_flags word intact so that it will work properly if
used on an old kernel.
Change the fs_sblockloc superblock location field to be in units
of bytes instead of in units of filesystem fragments. The old units
did not work properly when the fragment size exceeeded the superblock
size (8192). Update old fs_sblockloc values at the same time that
the flags are moved.
Suggested by: BOUWSMA Barry <freebsd-misuser@netscum.dyndns.dk>
Sponsored by: DARPA & NAI Labs.
Notes:
svn path=/head/; revision=107294
|
|
|
|
| |
Notes:
svn path=/head/; revision=102231
|
|
|
|
| |
Notes:
svn path=/head/; revision=101828
|
|
|
|
| |
Notes:
svn path=/head/; revision=99501
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
filesystem expands the inode to 256 bytes to make space for 64-bit
block pointers. It also adds a file-creation time field, an ability
to use jumbo blocks per inode to allow extent like pointer density,
and space for extended attributes (up to twice the filesystem block
size worth of attributes, e.g., on a 16K filesystem, there is space
for 32K of attributes). UFS2 fully supports and runs existing UFS1
filesystems. New filesystems built using newfs can be built in either
UFS1 or UFS2 format using the -O option. In this commit UFS1 is
the default format, so if you want to build UFS2 format filesystems,
you must specify -O 2. This default will be changed to UFS2 when
UFS2 proves itself to be stable. In this commit the boot code for
reading UFS2 filesystems is not compiled (see /sys/boot/common/ufsread.c)
as there is insufficient space in the boot block. Once the size of the
boot block is increased, this code can be defined.
Things to note: the definition of SBSIZE has changed to SBLOCKSIZE.
The header file <ufs/ufs/dinode.h> must be included before
<ufs/ffs/fs.h> so as to get the definitions of ufs2_daddr_t and
ufs_lbn_t.
Still TODO:
Verify that the first level bootstraps work for all the architectures.
Convert the utility ffsinfo to understand UFS2 and test growfs.
Add support for the extended attribute storage. Update soft updates
to ensure integrity of extended attribute storage. Switch the
current extended attribute interfaces to use the extended attribute
storage. Add the extent like functionality (framework is there,
but is currently never used).
Sponsored by: DARPA & NAI Labs.
Reviewed by: Poul-Henning Kamp <phk@freebsd.org>
Notes:
svn path=/head/; revision=98542
|
|
|
|
|
|
|
|
|
| |
o ansi function definitions.
o main prototype removal
o unifdef __STDC__
Notes:
svn path=/head/; revision=92881
|
|
|
|
|
|
|
|
|
| |
Binary builds that cannot handle this must explicitly set WARNS=0.
Reviewed by: mike
Notes:
svn path=/head/; revision=87325
|
|
|
|
|
|
|
| |
- MAN[1-9] -> MAN.
Notes:
svn path=/head/; revision=74815
|
|
|
|
| |
Notes:
svn path=/head/; revision=74531
|
|
|
|
| |
Notes:
svn path=/head/; revision=70152
|
|
|
|
| |
Notes:
svn path=/head/; revision=68960
|
|
|
|
| |
Notes:
svn path=/head/; revision=68575
|
|
|
|
| |
Notes:
svn path=/head/; revision=59871
|
|
|
|
|
|
|
|
| |
the strings "FreeBSD" and "NetBSD". Use the .Fx or .Nx macro
instead.
Notes:
svn path=/head/; revision=56407
|
|
|
|
| |
Notes:
svn path=/head/; revision=50476
|