Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mount: do not print "unknown" option to kclient #12465

Merged
merged 1 commit into from
Jan 12, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/mount/mount.ceph.c
Expand Up @@ -201,8 +201,10 @@ static char *parse_options(const char *data, int *filesys_flags)
skip = 0;
} else {
skip = 0;
if (verboseflag)
printf("ceph: Unknown mount option %s\n",data);
if (verboseflag) {
fprintf(stderr, "mount.ceph: unrecognized mount option \"%s\", "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that I look, I don't know... the verboseflag was set, so I think it's entirely reasonable to inform that the mount helper did not recognize the option. If we're worried about those sorts of messages then we shouldn't specify -v when mounting.

The message could be more clear though. For one thing, we should probably make it clear that it comes from "mount.ceph" and not "ceph". It should also go to stderr, IMO. Maybe:

fprintf(stderr, "mount.ceph: unrecognized mount option \"%s\", passing to kernel.\n", data);

...just to make it clear that it's not necessarily a problem.

"passing to kernel.\n", data);
}
}

/* Copy (possibly modified) option to out */
Expand Down