Project

General

Profile

Actions

Bug #2687

closed

FileStore crashes when "osd_journal_size" is larger than the filesystem

Added by Greg Farnum almost 12 years ago. Updated over 11 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
OSD
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
Regression:
Severity:
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

See: http://permalink.gmane.org/gmane.comp.file-systems.ceph.devel/7282
If a user (on tmpfs, in this case) specifies a journal size which is larger than the available space, the OSD will crash when it runs out of space.

There are checks in the FileJournal to detect if the block device is smaller than the set journal size (and bail out), but I don't see any for files. We should add them.

Actions #1

Updated by Sage Weil almost 12 years ago

for files, i think the right approach is to fallocate(), which will reserve the space. we shouldn't have to look at e.g. statfs(2), which isn't reliable for this sort of thing anyway.

Actions #2

Updated by Sage Weil over 11 years ago

  • Tracker changed from Feature to Bug
Actions #3

Updated by Sage Weil over 11 years ago

  • Status changed from New to Resolved

this has called fallocate(2) for a while now.

Actions

Also available in: Atom PDF