dbus/udisks guru? 'dmedia/store' records should store information about physical storage device
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Dmedia |
Fix Released
|
High
|
David Green |
Bug Description
A dmedia FileStore (see dmedia/
>>> doc = {
... '_id': 'NZXXMYLDOV2F6Z
... 'type': 'dmedia/file',
... 'time': 1234567890,
... 'plugin': 'filestore',
... 'copies': 1,
... }
Similar to lp:692449, we want to use udisk to get information about the physical storage device and specific partition where the FileStore is located. We'll be getting the information from org.freedesktop
http://
As far as the physical device, we definitely want:
DeviceSize
DriveSerial
DriveWwn
DriveVendor
DriveModel
DriveRevision
As far as the partition, we definitely want:
PartitionSize
PartitionLabel
PartitionUuid
file system type (ext4, whatever)
By default, we will assume the physical device gives us a {'copies': 1} level of durability. If the system is using BIOS fakeraid, I'm not sure we can actually gather the needed information to determine the durability of the storage array. The user could always manually updated the copies value.
If the partition happens to reside on an mdadm array (quite likely as Novacut is targeting pro video on Ubuntu), then we can gather the information needed to determine durability. I have a hunch this will be controversial, but here's the durability we're going to assign for each mdadm raid level:
raid0 - {'copies': 0}
raid1 - {'copies': 2}
raid5 - {'copies': 1}
raid6 - {'copies': 1}
raid10 n2/f2/o2 - {'copies': 2}
raid10 n3/f3/o3 - {'copies': 3}
etc..
The controversy being that raid5 and raid6 only have {'copies': 1}. For people that feel this is unfair, I would suggest you read:
http://
Also, perhaps this will help:
Q: But raid1 and raid10 are too expensive, take twice as many drives!
A: Fine, then don't use raid at all... raid5 and raid6 are more expensive than LVM, save yourself some money!
Q: But I want the piece of mind that comes with knowing my data is more durably stored!
A: Then you have to pay for it... you don't get better durability without more copies.
Q: Then what's the point of raid5/raid6 anyway?
A: No idea.
Related branches
- Jason Gerard DeRose: Approve
-
Diff: 801 lines (+503/-22)8 files modifieddmedia/importer.py (+14/-2)
dmedia/schema.py (+245/-12)
dmedia/tests/test_core.py (+2/-0)
dmedia/tests/test_importer.py (+3/-1)
dmedia/tests/test_schema.py (+17/-6)
dmedia/udisks.py (+146/-0)
dmedia/views.py (+57/-1)
misc/debug-udisks.py (+19/-0)
description: | updated |
Changed in dmedia: | |
milestone: | 0.4 → 0.5 |
Changed in dmedia: | |
milestone: | 0.5 → 0.6 |
Changed in dmedia: | |
milestone: | 0.6 → 0.7 |
Changed in dmedia: | |
milestone: | 0.7 → 0.8 |
Changed in dmedia: | |
assignee: | nobody → David Green (david4dev) |
Changed in dmedia: | |
status: | Triaged → In Progress |
Changed in dmedia: | |
milestone: | 11.08 → 11.09 |
Changed in dmedia: | |
status: | In Progress → Fix Committed |
Changed in dmedia: | |
status: | Fix Committed → Fix Released |