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

mon: MDSMonitor: proper error output if pool DNE on 'add_data_pool' #2773

Merged
merged 3 commits into from Nov 10, 2014

Conversation

jecluis
Copy link
Member

@jecluis jecluis commented Oct 22, 2014

Pull request also has two minor patches: one adding proper docs to a function
added in a previous pull request for #9794, another refactoring a function to
make it a bit saner according to the changes introduced when fixing #9794.

Fixes: #9852

Signed-off-by: Joao Eduardo Luis joao@redhat.com

Joao Eduardo Luis added 3 commits October 21, 2014 18:23
Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
Fixes: #9852

Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
Makes for readable, expectable, prettier code.

Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
@ghost ghost added the bug-fix label Oct 22, 2014
@@ -620,6 +620,10 @@ function test_mon_mds()
data3_pool=$(ceph osd dump | grep 'pool.*data3' | awk '{print $2;}')
ceph mds add_data_pool $data2_pool
ceph mds add_data_pool $data3_pool
ceph mds add_data_pool 100 >& $TMPFILE || true
check_response "Error ENOENT"
Copy link
Contributor

Choose a reason for hiding this comment

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

Shouldn't this be the ss << "pool '" << poolname << "' does not exist"; message that's set in filesystem_command?

Copy link
Member Author

Choose a reason for hiding this comment

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

could be, but it should start with 'Error ENOENT' so unless we change the error outputting of the ceph tool (where I think the parsing happens, and which will break most if not all the tests on this file) it's irrelevant whether we test for this string or the string you pointed out. In a way, it's fairly more probable that the string from filesystem_command() is subjected to change than the 'Error ENOENT' part. Keeping 'Error ENOENT' will safeguard us against the test erroring out due to a string that changed, when we only want to test is that the command fails with an ENOENT.

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh right, you get both strings in the output. Never mind.

@jecluis
Copy link
Member Author

jecluis commented Oct 24, 2014

wip-sam-testing

@ghost ghost added the core label Nov 5, 2014
@athanatos
Copy link
Contributor

I'm going to put this in wip-sam-testing, but this actually needs to go through I'm guessing an mds suite before merge?

@athanatos
Copy link
Contributor

wip-sam-testing

@jecluis
Copy link
Member Author

jecluis commented Nov 10, 2014

Went through a multimds suite over the weekend and all failures are also happening on next, master and giant, being unrelated to the changes on this branch. I'm confident enough to merge.

athanatos pushed a commit that referenced this pull request Nov 10, 2014
mon: MDSMonitor: proper error output if pool DNE on 'add_data_pool'

Reviewed-by: Joao Eduardo Luis <joao@redhat.com>
@athanatos athanatos merged commit 992a4a8 into master Nov 10, 2014
@athanatos athanatos deleted the wip-9852 branch November 10, 2014 22:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants