aboutsummaryrefslogtreecommitdiff
path: root/sbin/tunefs
Commit message (Collapse)AuthorAgeFilesLines
* Fix error check.Kirk McKusick2013-04-231-1/+1
| | | | | | | | Submitted by: Andrey Chernov (ache@) MFC after: 3 days Notes: svn path=/head/; revision=249789
* The purpose of this change to the FFS layout policy is to reduce theKirk McKusick2013-03-222-8/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | running time for a full fsck. It also reduces the random access time for large files and speeds the traversal time for directory tree walks. The key idea is to reserve a small area in each cylinder group immediately following the inode blocks for the use of metadata, specifically indirect blocks and directory contents. The new policy is to preferentially place metadata in the metadata area and everything else in the blocks that follow the metadata area. The size of this area can be set when creating a filesystem using newfs(8) or changed in an existing filesystem using tunefs(8). Both utilities use the `-k held-for-metadata-blocks' option to specify the amount of space to be held for metadata blocks in each cylinder group. By default, newfs(8) sets this area to half of minfree (typically 4% of the data area). This work was inspired by a paper presented at Usenix's FAST '13: www.usenix.org/conference/fast13/ffsck-fast-file-system-checker Details of this implementation appears in the April 2013 of ;login: www.usenix.org/publications/login/april-2013-volume-38-number-2. A copy of the April 2013 ;login: paper can also be downloaded from: www.mckusick.com/publications/faster_fsck.pdf. Reviewed by: kib Tested by: Peter Holm MFC after: 4 weeks Notes: svn path=/head/; revision=248623
* The .journal file needs to reside on the ROOTINO which must not extendPeter Holm2013-02-271-1/+1
| | | | | | | beyond direct blocks. A typo caused this check to fail. Notes: svn path=/head/; revision=247399
* Declare functions as static and move global variables to the top;Edward Tomasz Napierala2012-10-281-13/+12
| | | | | | | no functional changes. Notes: svn path=/head/; revision=242265
* Fix sbin/ build with a 64-bit ino_t.Matthew D Fleming2012-09-271-3/+3
| | | | | | | Original code by: Gleb Kurtsou Notes: svn path=/head/; revision=241013
* Fix warning when compiling with gcc46:Eitan Adler2012-01-101-2/+1
| | | | | | | | | | error: variable 'Sflag' set but not used Approved by: dim MFC after: 3 days Notes: svn path=/head/; revision=229911
* Add missing static keywords for global variables to tools in sbin/.Ed Schouten2011-11-041-2/+2
| | | | | | | | | 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
* After creating a filesystem using newfs -j the time stamps are allKirk McKusick2011-10-111-0/+10
| | | | | | | | | | | | | | zero and thus report as having been made in January 1970. Apart from looking a bit silly, it also triggers alarms from scripts that detect weird time stamps. This update sets all 4 (or 3, in the case of UFS1) time stamps to the current time when enabling journaling during newfs or later when enabling it with tunefs. Reported by: Hans Ottevanger <hans@beastielabs.net> MFC after: 1 week Notes: svn path=/head/; revision=226266
* Advertise growfs(8) a little better.Edward Tomasz Napierala2011-06-221-1/+2
| | | | Notes: svn path=/head/; revision=223430
* We now have multiple filesystems (UFS, ZFS, ...), so for tools that onlyGavin Atkinson2011-05-081-3/+3
| | | | | | | | | | | operate on one type of filesystem, mention this. While here, capitalise the use of "UFS" in growfs.8 to match other uses of the term in other man pages. MFC after: 1 week Notes: svn path=/head/; revision=221659
* When creating a directory entry for the journal, always read at leastKonstantin Belousov2011-02-121-10/+20
| | | | | | | | | | | | | | the fragment, and write the full block. Reading less might not work due to device sector size bigger then size of direntries in the last directory fragment. Reported by: bz In collaboration with: pho Reviewed by: jeff Tested by: bz, pho Notes: svn path=/head/; revision=218603
* Add support for FS_TRIM to user-mode UFS utilities.Konstantin Belousov2010-12-292-5/+50
| | | | | | | | | Reviewed by: mckusick, pjd, pho Tested by: pho MFC after: 1 month Notes: svn path=/head/; revision=216798
* - Round up the journal size to the block size so we don't confuse fsck.Jeff Roberson2010-05-181-4/+8
| | | | | | | | | | | | | | Reported by: Mikolaj Golub <to.my.trociny@gmail.com> - Only require 256k of blocks per-cg when trying to allocate contiguous journal blocks. The storage may not actually be contiguous but is at least within one cg. - When disabling SUJ leave SU enabled and report this to the user. It is expected that users will upgrade SU filesystems to SUJ and want a similar downgrade path. Notes: svn path=/head/; revision=208241
* Improve usage of tunefs:Edwin Groothuis2010-05-011-3/+4
| | | | | | | | | | Document -j switch in usage() to reflect recent SUJ work. Submitted by: Alastair Hogge MFC after: 1 week Notes: svn path=/head/; revision=207462
* - Use the path to the filesystem mountpoint to look up the statfsJeff Roberson2010-04-301-4/+4
| | | | | | | | | | | structure so that we correctly reload. Note that tunefs doesn't properly detect the need to reload if the disk device is specified for a read-only mounted filesystem. - Lessen the contiguity requirement for the journal so that it is more likely to succeed. Notes: svn path=/head/; revision=207421
* - Temporarily lower WARNS until I fix alignment warnings on sparc64.Jeff Roberson2010-04-241-0/+2
| | | | | | | Reported by: Florian Smeets Notes: svn path=/head/; revision=207145
* - Merge soft-updates journaling from projects/suj/head into head. ThisJeff Roberson2010-04-242-9/+567
| | | | | | | | | | | brings in support for an optional intent log which eliminates the need for background fsck on unclean shutdown. Sponsored by: iXsystems, Yahoo!, and Juniper. With help from: McKusick and Peter Holm Notes: svn path=/head/; revision=207141
* Quiet spurious warnings.Kirk McKusick2010-02-111-2/+2
| | | | Notes: svn path=/head/; revision=203769
* Raise WARNS for various tools where possible.Ed Schouten2010-01-171-1/+0
| | | | | | | Submitted by: Marius Nünnerich <marius@nuenneri.ch> Notes: svn path=/head/; revision=202532
* Implement NFSv4 ACL support for UFS.Edward Tomasz Napierala2009-12-212-11/+54
| | | | | | | Reviewed by: rwatson Notes: svn path=/head/; revision=200796
* The tunefs utility does not work on active filesystems.Remko Lodder2009-10-211-2/+2
| | | | | | | | | PR: docs/139705 Submitted by: Warren Block <wblock at wonkity dot com> Approved by: imp (mentor, implicit) Notes: svn path=/head/; revision=198316
* Switch the default WARNS level for sbin/ to 6.Ruslan Ermilov2009-10-191-0/+1
| | | | | | | Submitted by: Ulrich Spörlein Notes: svn path=/head/; revision=198236
* Slightly improve gjournal documentation.Edward Tomasz Napierala2009-04-291-1/+2
| | | | | | | Reviewed by: pjd Notes: svn path=/head/; revision=191656
* o s/filesystem/file system/g.Maxim Konovalov2007-09-231-2/+2
| | | | | | | | | Pointed out by: ru Approved by: re (bmah) MFC after: 3 days Notes: svn path=/head/; revision=172305
* o You have to reboot the system after tuning softupdates on the rootMaxim Konovalov2007-08-121-1/+3
| | | | | | | | | | filesystem on to make SU work. Approved by: re (hrs) MFC after: 1 week Notes: svn path=/head/; revision=171813
* Add -J flag to both newfs(8) and tunefs(8) which allows to enable gjournalPawel Jakub Dawidek2006-10-312-7/+45
| | | | | | | | | | | support. I left -j flag for UFS journal implementation which we may gain at some point. Sponsored by: home.pl Notes: svn path=/head/; revision=163842
* Expand *n't contractions.Ruslan Ermilov2005-02-131-1/+1
| | | | Notes: svn path=/head/; revision=141846
* Sort sections.Ruslan Ermilov2005-01-181-5/+5
| | | | Notes: svn path=/head/; revision=140415
* Remove advertising clause from University of California Regent's license,Mark Murray2004-04-092-8/+0
| | | | | | | | | per letter dated July 22, 1999. Approved by: core, imp Notes: svn path=/head/; revision=128073
* Fixed some style bugs in the residue of rev.1.14 (mainly initialization inBruce Evans2004-03-261-26/+23
| | | | | | | declarations, uncuddled elses and excessive braces). Notes: svn path=/head/; revision=127455
* Fixed some style bugs in or related to rev.1.13 (mainly misindentation ofBruce Evans2004-03-261-109/+128
| | | | | | | the getopt() case statement). Notes: svn path=/head/; revision=127441
* Remove another reference to ffsinfo.8Christian Brueffer2003-06-171-3/+1
| | | | Notes: svn path=/head/; revision=116507
* Remove references to ffsinfo(8) for now. It was disconnected fromChristian Brueffer2003-06-171-1/+0
| | | | | | | the build almost a year ago. Notes: svn path=/head/; revision=116499
* Use __FBSDID() to quiet GCC 3.3 warnings.David E. O'Brien2003-05-031-4/+4
| | | | Notes: svn path=/head/; revision=114589
* Sort options.Ruslan Ermilov2003-02-232-22/+22
| | | | Notes: svn path=/head/; revision=111287
* Bring in support for volume labels to the filesystem utilities.Gordon Tetlow2003-02-012-8/+35
| | | | | | | Reviewed by: mckusick Notes: svn path=/head/; revision=110174
* Fix problems with how libufs was used, with regard to mounted/active fs's,Juli Mallett2003-01-281-32/+16
| | | | | | | | in the new world order of libufs, where we also do statfs, and add a missing close. Notes: svn path=/head/; revision=109963
* Added UFS library to the bsd.libnames.mk namespace.Ruslan Ermilov2003-01-231-1/+1
| | | | Notes: svn path=/head/; revision=109725
* Make tunefs use libufs, it seems to do well enough for printing / settingJuli Mallett2003-01-202-108/+15
| | | | | | | things. Notes: svn path=/head/; revision=109597
* Consistentify output whitespace.Juli Mallett2003-01-181-1/+1
| | | | Notes: svn path=/head/; revision=109468
* Create a new 32-bit fs_flags word in the superblock. Add code to moveKirk McKusick2002-11-271-1/+1
| | | | | | | | | | | | | | | | | | | | 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
* s/clear/cleared/ for consistency (sigh)Robert Watson2002-10-161-2/+2
| | | | | | | Reported by: dd Notes: svn path=/head/; revision=105206
* Spell 'set' as 'cleared' where appropriate.Robert Watson2002-10-151-2/+2
| | | | Notes: svn path=/head/; revision=105177
* Teach tunefs to print the ACL and multilabel flag information whenRobert Watson2002-10-151-0/+4
| | | | | | | | | | inspecting a superblock. Obtained from: TrustedBSD Project Sponsored by: DARPA, Network Associates Laboratories Notes: svn path=/head/; revision=105162
* Correct some of the style problems in this file:Robert Watson2002-10-152-10/+10
| | | | | | | | | | | | I introduced a style problem when I sorted 'a' before 'A'; our preferred order sorts 'A' first. Correct. Use .Cm instead of .Ar. Submitted by: bde Notes: svn path=/head/; revision=105156
* Introduce -a [enable|disable] and -l [enable|disable] flags to the tunefsRobert Watson2002-10-142-7/+73
| | | | | | | | | | | command, permitting it to set FS_ACLS and FS_MULTILABEL administrative flags on UFS file systems. Obtained from: TrustedBSD Project Sponsored by: DARPA, Network Associates Laboratories Notes: svn path=/head/; revision=105120
* Removed vestiges of the -a and -d options.Bruce Evans2002-09-061-5/+3
| | | | | | | Fixed other bugs in the usage message so that it matches the man page. Notes: svn path=/head/; revision=103013
* Remove the -a maxcontig option, the kernel doesn't inspect fs_maxcontigPoul-Henning Kamp2002-09-062-27/+3
| | | | | | | | | anymore. Sponsored by: DARPA & NAI Labs. Notes: svn path=/head/; revision=103005
* Fix some 'SYNOPSIS' and 'usage' messages.Tom Rhodes2002-08-271-1/+1
| | | | Notes: svn path=/head/; revision=102464
* s/filesystem/file system/g as discussed on -developersTom Rhodes2002-08-212-18/+18
| | | | Notes: svn path=/head/; revision=102231