summaryrefslogtreecommitdiffstats
path: root/sbin/fdisk
Commit message (Collapse)AuthorAgeFilesLines
* MFC r314655:ngie2017-05-301-1/+1
| | | | | | bin: normalize paths using SRCTOP-relative paths or :H when possible This simplifies make logic/output
* MFC r306731:sevan2016-10-161-4/+19
| | | | | | | | | | | | | | | | | Document the history of fdisk based on the original post to comp.unix.bsd by Julian Elischer [1] and the Mach 2. 5 Installation notes [2]. I was unable to pin point the exact version of Mach the fdisk utility appeared as I could not find documentation older than version 2.5 & no source code or repo history. fdisk utility appears as a separate utility[3] in v2.5. Due to this, I have avoided stating the exact version fd isk first appeared in Mach. Add authors section. Make correction pointed by igor [1] https://groups.google.com/d/topic/comp.unix.bsd/Hhi45vAHxDg/discussion [2] ftp://ftp.mcs.vuw.ac.nz/doc/misc/mach-i386-doc/i386_install.ps [3] ftp://ftp.mcs.vuw.ac.nz/doc/misc/mach-i386-doc/i386_manpages.ps PR: 212469 Approved by: bcr (mentor) Differential Revision: https://reviews.freebsd.org/D8104
* fdisk: drop unused macro and make use of roundup()/rounddown().pfg2016-04-301-16/+14
|
* Explicitly add more files to the 'runtime' package.gjb2016-02-091-0/+1
| | | | Sponsored by: The FreeBSD Foundation
* It's 2015, and some people are still trying to use fdisk and thentrasz2015-09-021-0/+7
| | | | | | | | | | | | | go asking what debug flags to set for GEOM to make it work. Advice them to use gpart(8) instead. Something similar should probably done with disklabel, but I need to rewrite the disklabel examples first. Reviewed by: wblock@ MFC after: 1 month Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D3315
* Add META_MODE support.sjg2015-06-131-0/+21
|\ | | | | | | | | | | | | | | | | | | | | 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
| * dirdeps.mk now sets DEP_RELDIRsjg2015-06-081-2/+0
| |
| * Merge sync of headsjg2015-05-271-2/+1
| |\ | |/ |/|
| * Merge head from 7/28sjg2014-08-191-10/+0
| |\
| * | Updated dependenciessjg2014-05-161-1/+0
| | |
| * | Updated dependenciessjg2014-05-101-0/+2
| | |
| * | Merge headsjg2014-04-281-3/+7
| |\ \
| * \ \ Merge head@256284sjg2013-10-131-2/+2
| |\ \ \
| * | | | Updated dependenciessjg2013-03-111-0/+1
| | | | |
| * | | | Updated dependenciessjg2013-02-161-2/+0
| | | | |
| * | | | Sync FreeBSD's bmake branch with Juniper's internal bmake branch.marcel2012-08-221-0/+22
| | | | | | | | | | | | | | | | | | | | Requested by: Simon Gerraty <sjg@juniper.net>
* | | | | Convert sbin/ to LIBADDbapt2014-11-251-2/+1
| |_|_|/ |/| | | | | | | | | | | Reduce overlinking
* | | | Remove ia64.marcel2014-07-071-10/+0
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This includes: o All directories named *ia64* o All files named *ia64* o All ia64-specific code guarded by __ia64__ o All ia64-specific makefile logic o Mention of ia64 in comments and documentation This excludes: o Everything under contrib/ o Everything under crypto/ o sys/xen/interface o sys/sys/elf_common.h Discussed at: BSDcan
* | | Fix fdisk(8) to create 2TB partitions on disks larger than 2TB, rather thanjmallett2013-11-271-3/+7
| |/ |/| | | | | | | | | | | | | | | | | | | | | only being able to create 1TB partitions: o) Use an unsigned 32-bit quantity to store the number of disk sectors. o) Detect overflow of said 32-bit quantity and clamp to 2^32. o) Rather than returning the disk sector count from get_params, return 0 on success, since its return value is only ever compared to -1 to detect failure. This would cause returning 2^32 sectors to be interpreted as an error. Reviewed by: bde ("good for a quick fix")
* | Sweep man pages replacing ad -> ada.pluknet2013-10-011-2/+2
|/ | | | | | Approved by: re (blackend) MFC after: 1 week X-MFC note: stable/9 only
* VMware environment is frequent nowadays. Add VMFS id.marck2012-04-161-0/+1
| | | | MFC after: 2 weeks
* Fix multi-line comment formatting.ae2011-11-071-2/+4
| | | | | Pointed by: jh MFC after: 1 week
* Improve error reporting when MBR can not be written.ae2011-11-071-36/+62
| | | | | | | | | Remove obsolete code which uses DIOCSMBR ioctl. When writing MBR first check that GEOM_MBR is available, if it is not available, then try write MBR directly to provider. If both are failed, then recommend to use gpart(8). MFC after: 2 week
* Initialize "acc" value inside the loop to reset failed attempts.ae2011-11-061-2/+2
| | | | | PR: misc/162262 MFC after: 3 days
* Add reference to gpart(8).ae2011-11-061-0/+1
| | | | MFC after: 3 days
* Add missing static keywords for global variables to tools in sbin/.ed2011-11-041-1/+1
| | | | | | 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.
* remove trailing whitespace...jmg2011-10-291-3/+3
| | | | MFC after: 1 week
* error if /boot/mbr is empty... This can happen on a system like armjmg2011-10-291-0/+2
| | | | | | | that doesn't have a /boot/mbr, and you touch it to get past the previous error message... MFC after: 1 week
* The decimal() function was changed in r217808 to take theae2011-08-191-1/+1
| | | | | | | | | | maximum value instead of number of bits. But for case when limitation is not needed it erroneously skips conversion to number and always returns zero. So, don't skip conversion for case when limitation is not needed. PR: bin/159765 Approved by: re (kib)
* The MBR uses a 32-bit unsigned integer to store the size of a slice, butrstone2011-07-171-4/+4
| | | | | | | | | | | | | | | | fdisk(1) internally uses a signed int. Should a user attempt to specify a slice containing more than 2^31 - 1 sectors, an error will be reported on systems with sizeof(long) == 4 and the slice size will be silently truncated on systems with sizeof(long) > 4. Instead use an unsigned long to store the slice size in fdisk(1). This allows the user to specify a slice size up to the maximum permitted by the MBR on-disk format and does not have any problems with silent truncation should the use specify an slice size larger than 2^32 on systems with sizeof(long) > 4. Submitted by: Mark Johnston (markjdb AT gmail DOT com) MFC after: 2 weeks
* Supply maximum value as an argument to the decimal() functionsobomax2011-01-251-27/+27
| | | | | | instead of supplying number of bits. Submitted by: bde
* o Cylinder numbers are 10 bits in the MBR;sobomax2011-01-241-19/+19
| | | | | | | | o Sector numbers are only 6 bits in the MBR; o bde'cize name of the local variable. Submitted by: bde
* Warn user when value entered is greated than the amount supportedsobomax2011-01-221-20/+31
| | | | | | | | | | | by the MBR for the given parameter and set that parameter to the maximum value instead of just truncating the most significant part silently. Could happen for example if the capacity of the device is more than 2TB, so that the number of sectors is greater than 2Mib. MFC after: 1 month
* Add support for identifying a journaled root filesystem.brian2010-09-161-1/+2
| | | | | | Fix support for identifying the given /dev/vinum/root example. MFC after: 3 weeks
* Handle geli-encrypted root disk devices.brian2010-09-061-2/+7
| | | | MFC after: 2 weeks
* - Back out the previous change in order to maintain compatibility.lulf2009-06-171-2/+2
|
* - The maximum number of heads is 255, not 256.lulf2009-06-151-2/+2
| | | | Pointed out by: marcel
* Bump the document date to reflect the 'p' command enhancements.brian2009-05-251-1/+1
| | | | Suggested by: trhodes
* Enhance the 'p' command so that it understands size qualifiers (K/M/G) andbrian2009-05-252-6/+118
| | | | | | | | so that it understands '*' as 'DTRT'. PR: 68312 Submitted by: Rene de Vries - rene at tunix dot nl (mostly) MFC after: 3 weeks
* Reword some entries for NTFS and DOS.luigi2009-01-141-2/+4
| | | | | | Add entries for DELL and ASUS recovery partitions. MFC after: 3 days
* Another change from Christoph:luigi2009-01-141-110/+101
| | | | | | | | | | replace the table of partition with a simpler and faster array of strings. The change in the array is done mechanically, using vi commands. Most entries in the table are probably 15+ years old and largely outdated, so the next step is to remove stale entries with more current values. Submitted by: Christoph Mallon, with small changes from me MFC after: 3 days
* more changes from Christoph:luigi2009-01-141-15/+14
| | | | | | | | pass a pointer instead of an index to print_part() so it does not depend on a static variable. Submitted by: Christoph Mallon MFC after: 3 days
* remove unused argument to print_s0()luigi2009-01-141-11/+8
| | | | | Submitted by: Christoph Mallon MFC after: 3 days
* Some small fixes submitted by Christoph Mallon, specifically:luigi2009-01-131-17/+16
| | | | | | | | | | | | | + Remove a dead field of a struct. It serves no purpose anymore. + Remove a \n at the end of the format string of err(); the err() function already adds a \n ; + remove many unnecessary casts which obfuscate the code. This file has a huge number of indentation bugs, but I'd rather fix them when/if we happen to modify the relevant parts of the code. Submitted by: Christoph Mallon MFC after: 3 days
* - Improve error message given on g_providername call failure.lulf2008-09-301-1/+1
| | | | | | - While there, make error messages consistent with the rest. Approved by: kib (mentor)
* Add missing library dependencies.ru2008-09-231-2/+2
| | | | | PR: bin/127573 Submitted by: Eygene Ryabinkin
* - Make use of the new and g_device_path utility function in libgeom to avoidlulf2008-09-071-49/+30
| | | | | | | | | duplication of code in fdisk and boot0cfg. Also make use of g_providername to fix an issue with fdisk and boot0cfg not using the correct provider when writing the MBR. Reviewed by: phk Approved by: pjd (mentor)
* Add a -q[uiet] flag for scripts.obrien2008-07-312-4/+12
|
* Add Apple HFS+ (0xAF) MBR partition type identificator.andre2007-05-061-0/+1
| | | | Submitted by: rpaulo (SoC2007 student)
* o Add -p flag: print a slice table in fdisk configuration file format.maxim2007-04-302-4/+36
| | | | | | | | Now it is possible to do something like fdisk -p ad0 | fdisk -f - ad1. PR: bin/110182 Submitted by: Jukka A. Ukkonen MFC after: 1 month
OpenPOWER on IntegriCloud