libstorage-ng
Loading...
Searching...
No Matches
storage::ActivateCallbacks Class Referenceabstract

Other storage subsystems are activated automatically, e.g. More...

#include <Storage.h>

Inheritance diagram for storage::ActivateCallbacks:
[legend]
Collaboration diagram for storage::ActivateCallbacks:
[legend]

Public Member Functions

virtual bool multipath (bool looks_like_real_multipath) const =0
 Decide whether multipath should be activated.
virtual std::pair< bool, std::string > luks (const std::string &uuid, int attempt) const =0
 Decide whether the LUKS with uuid should be activated.
Public Member Functions inherited from storage::Callbacks
virtual void message (const std::string &message) const =0
 Callback for progress messages.
virtual bool error (const std::string &message, const std::string &what) const =0
 Callback for errors.

Detailed Description

Other storage subsystems are activated automatically, e.g.

LVM and MD RAID. This cannot be controlled since it is partly done by udev. This also means that the callbacks may change anytime when e.g. udev changes.

Member Function Documentation

◆ luks()

virtual std::pair< bool, std::string > storage::ActivateCallbacks::luks ( const std::string & uuid,
int attempt ) const
pure virtual

Decide whether the LUKS with uuid should be activated.

The result of the callback is cached (for the lifetime of the program). So the callback for a specific LUKS will not be called again (not even if Storage::activate() is called again) if 1. the activation was canceled or 2. the activation was successful.

TODO Also allow to return a key file?

◆ multipath()

virtual bool storage::ActivateCallbacks::multipath ( bool looks_like_real_multipath) const
pure virtual

Decide whether multipath should be activated.

The looks_like_real_multipath parameter is not reliable.


The documentation for this class was generated from the following file:
  • /home/abuild/rpmbuild/BUILD/libstorage-ng-4.5.261-build/libstorage-ng-4.5.261/storage/Storage.h