Name

visudo

Synopsis

visudo [options]

Edits sudo’s control file sudoers in the vi editor. Using visudo instead of editing directly prevents two users from performing edits at once. Also, visudo will not save edits to sudoers if they are not syntactically correct.

-c

Syntax check on the file’s contents, without editing. Exits with 0 if it’s valid, or 1 if not.

-f filename

Specifies an alternate location for the sudoers file.

-q

Quiet mode. When used with -c, do not print errors.

-s

Strict checking. An alias used before it is defined is an error.

-V

Print the version number.

Get Mac OS X Tiger in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.