Improve error reporting when running on an unsupported filesystem
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Object Storage (swift) |
Fix Released
|
Low
|
Matthew Oliver |
Bug Description
When you start Swift (specifically the object-server) with an unsupported filesystem (eg one that doesn't support XATTR) it does not complain. You don't get any errors until you try and PUT an object, at which point it dumps a stack trace into syslog (indicating IOError):
Mar 27 22:10:02 i-000001c9 object-server ERROR __call__ error with PUT /vdb/4548/
eb357cccde : #012Traceback (most recent call last):#012 File "/usr/lib/
#012 res = getattr(self, req.method)
.put(fd, tmppath, metadata)#012 File "/usr/lib/
back)#012 File "/usr/lib/
ymodules/
6/swift/
y", line 89, in write_metadata#012 setxattr(fd, '%s%s' % (METADATA_KEY, key or ''), metastr[:254])#012 File "/usr/lib/
hon2.6/
/python2.
ython2.
I suggest checking that the filesystem supports the necessary functionality (eg setting or checking an xattr) on process start so that the error appears when you start swift rather than when you try and PUT an object.
(fwiw, the user-visible error is just a 500 server error without any additional information.)
Changed in swift: | |
assignee: | Kun Huang (academicgareth) → nobody |
Changed in swift: | |
status: | In Progress → Confirmed |
Changed in swift: | |
importance: | Undecided → Low |
Changed in swift: | |
assignee: | nobody → Matthew Oliver (matt-0) |
Changed in swift: | |
milestone: | none → 2.2.1 |
status: | Fix Committed → Fix Released |
Aww man, this is so true. However, I am against checking for a list of supported filesystems (such as XFS). If we decide to fix this, we need to devise a test that actually stores an xattr. In Fedora, people run Swift on ext4, for example. This requires some coding and testing... Honestly, I'm tempted to punt it. I knew that xattrs were necessary when I installed Swift, even back in 2010.