Date: Mon, 06 Jun 2011 11:00:17 -0700 From: Xin LI <delphij@delphij.net> To: FreeBSD Current <freebsd-current@FreeBSD.ORG> Subject: [RFC] 'failok' mount(8) flag Message-ID: <4DED15B1.8020701@delphij.net>
next in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format. --------------050908080205000307070202 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Hi, I think sometimes it's desirable to mark a few file systems as 'failok', which means it's Ok to have these mounts failed on boot and something else (a script, cron job, etc) will handle the case. Here is a proposed patch to implement that, I'll document it if there is no objection on the functionality itself. Cheers, - -- Xin LI <delphij@delphij.net> http://www.delphij.net/ FreeBSD - The Power to Serve! Live free or die -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (FreeBSD) iQEcBAEBCAAGBQJN7RWxAAoJEATO+BI/yjfBEKEH/0yenOjZMhl3UdtUNDGs5UBN v2Zhx3DcgvU4LCkwJEYYNXXCBYCKXMh0jBAYKhGUuKr8yOps74u9sHGDb278dn3+ hOOV/Xw4IZdjUGutezzRT8iImkVis4okEjuXX4fU/58y95jwIrcL7QXLGqerCsfe n1U6T/RcIw5AB1R184+BxeuOEVhEl/siR8AdswKxc06UgkMPc3942WRCwHvfi2qz 44m9jYV+JM3Y2eYtriBRFlqdicbzbiUAXnLFtQigpl/bUKRUyXdfOaT94Jfy48uO 9LX6aNftF5rdfDKFfRKXnFbXjn/to4r+1H5ck8ZDsnShlYVlsQbZaTvD6cP8d4Y= =VRq0 -----END PGP SIGNATURE----- --------------050908080205000307070202 Content-Type: text/plain; name="patch-mount.c" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="patch-mount.c" SW5kZXg6IG1vdW50LmMKPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09 PT09PT09PT09PT09PT09PT09PT09PT09PT09PQotLS0gbW91bnQuYwkocmV2aXNpb24gMjIy NzY1KQorKysgbW91bnQuYw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ogCQkJCQlydmFsID0gMTsKIAkJCX0KIAkJfSBlbHNlIGlm IChmc3RhYl9zdHlsZSkgewpAQCAtNzE3LDYgKzcyMSwxNCBAQAogCQkJCSAqIGJlZm9yZSBt b3VudGQgc3RhcnRzLgogCQkJCSAqLwogCQkJCWNvbnRpbnVlOworCQkJfSBlbHNlIGlmIChz dHJjbXAocCwgImZhaWxvayIpID09IDApIHsKKwkJCQkvKgorCQkJCSAqICJmYWlsb2siIGlz IHVzZWQgdG8gcHJldmVudCBjZXJ0YWluIGZpbGUKKwkJCQkgKiBzeXN0ZW1zIGZyb20gYmVp bmcgY2F1c2luZyB0aGUgc3lzdGVtIHRvCisJCQkJICogZHJvcCBpbnRvIHNpbmdsZSB1c2Vy IG1vZGUgaW4gdGhlIGJvb3QKKwkJCQkgKiBjeWNsZSwgYW5kIGlzIG5vdCBhIHJlYWwgbW91 bnQgb3B0aW9uLgorCQkJCSAqLworCQkJCWNvbnRpbnVlOwogCQkJfSBlbHNlIGlmIChzdHJu Y21wKHAsICJtb3VudHByb2ciLCA5KSA9PSAwKSB7CiAJCQkJLyoKIAkJCQkgKiAibW91bnRw cm9nIiBpcyB1c2VkIHRvIGZvcmNlIHRoZSB1c2Ugb2YK --------------050908080205000307070202--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4DED15B1.8020701>