Cd/dvd drive sharing on network

Is there a way to share CD/DVD drive attached to Rockstor server over the network? Optical drives are no longer in most of modern laptops, so it would be useful to be able to use the server for occasional need for reading cd/dvd disks.


@belka Hello again.

No, not as yet; but it’s a nice idea. Currently our lowest level disk scan scan_disks(), which initially decide the devices ‘of interest’ simply ignores, filters from the rest of the system, all devices of type ‘rom’ ie:

But there after we would need to ascribe a ‘role’ to this type of device (we already have a working role system used to identify the likes of the root drive, bcache backing/caching devices, and LUKS containers for instance) and then build up the rest of the system there after to be aware of that particular role; and mount it accordingly of course. So it’s a fairly non trivial addition but yes it’s a nice idea and entirely possible. And for those looking into how/where this ‘DVD’ role might be added see scan_disks()'s only caller/user _update_disk_state():

Which uses the following constants at the top of it’s file:

with _update_disk_state() having the following location and docstring:

and the role assignment begins later on in _update_disk_state() here:

So from the looks of it this would be a scan_disks() informed role as scan_disks() is already able to identify it by the existing mechanism that currently simply excludes it.

Could you share how you imagine this feature might be presented to the user; as currently we deal only in btrfs volumes via their pool (vol) share (subvol) components, but in the case of this new proposed CD/DVD (rom) type device surfacing we would have to add addition mount mechanisms to cope with ‘that sort of thing’. I imagine we would also need some kind of eject facility also. And quite possible a manual mount/unmount facility, which we don’t currently have either but would also be nice.

Anyway very nice idea and one that could very well dovetail nicely into other capabilities going forward.

Lets have this thread as an initial ‘design document’ / proof of interest for peoples ideas on how this would fit into Rockstor’s existing user interface as it’s obviously best if we try not to complicate the existing UI ‘flows’ and given CD/DVD’s mostly only have a single fs / partition on them I think we should be able to stretch, in time, to making this a real possibility.

Thanks for bringing this up. The idea has occurred to me and we also need to surface (present within the UI from the underlying operating system) tape drives as well so maybe the initial work on this feature could also serve to have them show up as well.

So initial steps are to remove the ‘ignore this’ block and then establish a role. And given unknown roles are mostly ignored that might at least get things rolling. The sharing component / treatment would most likely be the more complicated element: ie special arrangements for this device ‘role’. Maybe just an auto mount arrangement for this type of device (systemd) so we only deal with eject (with prior unmount) and a CD/DVD ‘fake share’ member or something.

Ideas or contributions anyone?

I think this would work best if done from an iso so that you do not to burn a physical CD/DVD not to mention how slow a physical optical drive is if your trying to network installs of linux or other software I think ISOs are the best option for this