summaryrefslogtreecommitdiff
path: root/sbin/mount
AgeCommit message (Collapse)Author
2023-11-10MNT_SOFTDEP and mount -o softdep no longer have any effectIngo Schwarze
OK kn@ jmc@
2023-11-09link to showmount(8); OK deraadtKlemens Nanni
2023-07-23use SMALL to save a shave mfs and tmpfs bits in install mediaKlemens Nanni
RAMDISK* has MFS and TMPFS disabled, so the installer can't use them. OK deraadt
2022-12-04userspace: remove vestigial '?' cases from top-level getopt(3) loopsScott Soule Cheloha
getopt(3) returns '?' when it encounters a flag not present in the in the optstring or if a flag is missing its option argument. We can handle this case with the "default" failure case with no loss of legibility. Hence, remove all the redundant "case '?':" lines. Prompted by dlg@. With help from dlg@ and millert@. Link: https://marc.info/?l=openbsd-tech&m=167011979726449&w=2 ok naddy@ millert@ dlg@
2022-04-09fix grammar in comment: successfully -> successfulDave Voutila
2020-12-11pass down the `skip' flag to the mountfs() function in the case ofRobert Nagy
manually mounting a device which is not present in fstab(5) so that the `-s' flag can be used in this case as well. ok millert@, deraadt@
2019-07-19Adapt to POSIX realpath(3); if it returns NULL, use the mount path as-is.Todd C. Miller
Fixes an inability to mount via diskuid. Also use mntpath, not *argv, on error for more accurate messages. OK martijn@ mlarkin@
2019-06-28When system calls indicate an error they return -1, not some arbitraryTheo de Raadt
value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
2019-03-10delete whitespace before a full stop on a text line;Ingo Schwarze
patch from Alessandro dot Gallo at syssegv dot org
2018-01-18Mark up mount(8) options with Cm.Anthony J. Bentley
2017-07-09remove redundant variable declarations in Makefiles, since those areMarc Espie
the default. okay millert@
2017-02-06Postpone pledge call until after the getopt switch and hoist the call toTheo Buehler
readlabelfs over it. This avoids a pledge abort due to the fact that the ioctl DIOCGDINFO may not be allowed on the given file: mount /dev/tty /tmp. ok benno
2017-01-25Some simple cleanup:Theo Buehler
* check strdup for malloc failure * remove obvious /* NOTREACHED */ * return instead of exit from main * err(1, NULL) instead of err(1, "malloc") * mark usage as __dead ok deraadt
2017-01-24whitespaceTheo Buehler
2016-10-06On noperm mount points honor the permissions of the root directory, soMartin Natano
access can be locked down. ok deraadt tb
2016-10-06fix HISTORY;Ingo Schwarze
patches from Sevan Janiyan <venture37 at geeklan dot co dot uk>; verified using minnie.tuhs.org/cgi-bin/utree.pl
2016-10-04Improve description of the noperm option.Martin Natano
ok jmc (on an earlier version of the diff), tb (who found a typo) and deraadt
2016-09-10sort the options list; also, the full stop in (FFS only.) wasn;tJason McIntyre
doing much, so i zapped it;
2016-09-10Add a noperm mount flag for FFS to be used for building release setsMartin Natano
without root privileges. This is only the kernel/mount flag; additional work in the build Makefile's will be necessary such that the files in $DESTDIR are created with correct permissions. tedu couldn't find anything wrong with it in a quick review idea & ok deraadt
2016-09-04strlen + malloc + snprintf == asprintfMichal Mazurek
ok martijn@ deraadt@
2016-08-27further tweak previous: use the same text for norw as ro; ok teduJason McIntyre
2016-08-27for completeness, document (no)rw and ro options.Ted Unangst
2016-07-14kern.usermount is currently a no-op;Jason McIntyre
ok deraadt
2016-06-26somebody forgot to look at format string warningsTed Unangst
2016-06-20Add a bit more verbosity to tmpfs mount(8) output.Antoine Jacoutot
ok millert@ feedback/ok natano@
2016-06-19a little nicer formatting; from miodJason McIntyre
2016-05-29sort mount options, and shorten slightly the wxabort text;Jason McIntyre
2016-05-27W^X violations are no longer permitted by default. A kernel log messageTheo de Raadt
is generated, and mprotect/mmap return ENOTSUP. If the sysctl(8) flag kern.wxabort is set then a SIGABRT occurs instead, for gdb use or coredump creation. W^X violating programs can be permitted on a ffs/nfs filesystem-basis, using the "wxallowed" mount option. One day far in the future upstream software developers will understand that W^X violations are a tremendously risky practice and that style of programming will be banished outright. Until then, we recommend most users need to use the wxallowed option on their /usr/local filesystem. At least your other filesystems don't permit such programs. ok jca kettenis mlarkin natano
2016-05-25remove knowledge of MNT_EXKERBTheo de Raadt
2016-05-21Remove the -x flag from mount_msdos and always assume the execute bitMartin Natano
for readable directories, while making it subject to the mask option (-m in mount_msdos), so it is still possible to mount with non-executable directories, but with semantics that are easier to comprehend. This makes directory listings with default mount options work again. ok deraadt@
2015-11-23Use pledge "disklabel" as needed. The theory here is these tools become moreTheo de Raadt
resistant against memory correctup, if a corrupt filesystem is given to them. ok krw
2015-01-16Replace <sys/param.h> with <limits.h> and other less dirty headers whereTheo de Raadt
possible. Annotate <sys/param.h> lines with their current reasons. Switch to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where sensible to avoid pulling in the pollution. These are the files confirmed through binary verification. ok guenther, millert, doug (helped with the verification protocol)
2014-09-08Additional cleanup for procfs removalDoug Hogan
ok guenther@
2014-09-08Delete procfs; it's always had races and is now unused: no one noticed forPhilip Guenther
months that I broke it before the 5.5 release. confirmed as not being required by ports by sthen@, ajacoutot@, dcoppa@
2014-07-17Convert a couple calloc()s that were originally malloc()s to reallocarray()s.Philip Guenther
The child after fork() should use _exit() instead of exit(). Fix comment typo. ok millert@
2014-07-15add -N to usage()/SYNOPSIS and tweak previous;Jason McIntyre
rather than adding "net" to the -o list, claudio points out that -o net and -o noauto are really noops, so remove "noauto"; help/ok claudio
2014-07-14remove the never installed getmntopts.3 page, as well as theJason McIntyre
corresponding comment in Makefile; ok claudio deraadt
2014-07-13Introduce a -N option to mount and a 'net' mount option.Claudio Jeker
File systems marked with net will not be mounted by default. mount -a -N will mount all those file systems instead. This will be used to mark file systems needing network to work -- in other words which depend on iscsid. "Get it in" deraadt@
2014-06-24remove the noaccesstime synonym for noatime which was previously added for ↵Daniel Dickman
BSD/OS compatibility. ok deraadt@, miod@i, millert@
2013-12-17Xr mount_tmpfs, trivial ok deraadt@Marc Espie
2013-09-23Revert. It seems people don't agree about which device should be used.Antoine Jacoutot
req. by krw@ millert@
2013-09-23cd0a -> cd0c for consistency with the FAQ.Antoine Jacoutot
discussed with and ok miod@
2013-04-21When mount(1) is run in verbose mode, display f_mntfromspec if it differsJoel Sing
from f_mntfromname. ok krw@
2012-08-23remove unneccessary .Pp;Jason McIntyre
2012-08-23get rid of mount_nnpfsTheo de Raadt
2012-05-29Make 'mount nfssrv:/path' without mount point work again :Landry Breuil
- dont error out in realpath() check if argv contains @ or : (ie, is a nfs remote path) - relax getfsspec() call so that it succeeds for nfs remote paths too, not only for duid devices. Now we behave like Linux & FreeBSD (at least).. Prompted by a diff from giovanni@ for xfce4-mount ok jsing@ krw@
2011-04-12Make mount work when the special is provided as a DUID.Joel Sing
Diff from Alexander Polakov. ok phessler@
2011-04-06Avoid using NULL in non-pointer contexts: use 0 for integer values and '\0'Miod Vallat
for chars.
2011-04-05Remove portalfs.Thordur I. Bjornsson
While it is a terribly cool idea, it's just awful and since noone has stepped up to the plate to keep it up with the current vop state, retire it to the attic. ok krw@, deraadt@, guenther@, miod@. comments from jmc@
2010-09-28document disklabel uids and move a little text to improve readability; theJason McIntyre
duid text was supplied by krw ...after much discussion with jsing and krw ok krw