Skip to content

Commit

Permalink
Merge pull request #1202 from vojtechtrefny/3.9-devel_raid-populate-a…
Browse files Browse the repository at this point in the history
…ssemble

Try to assemble MD arrays during populate (#2236356)
  • Loading branch information
vojtechtrefny authored Feb 23, 2024
2 parents 715c186 + bcf49c2 commit 94adfec
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion blivet/populator/helpers/mdraid.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
from ...devicelibs import raid
from ...devices import MDRaidArrayDevice, MDContainerDevice
from ...devices import device_path_to_name
from ...errors import DeviceError, NoParentsError
from ...errors import DeviceError, NoParentsError, MDRaidError
from ...flags import flags
from ...storage_log import log_method_call
from .devicepopulator import DevicePopulator
Expand Down Expand Up @@ -222,6 +222,12 @@ def run(self):

self._devicetree.handle_device(array_info, update_orig_fmt=True)

if flags.auto_dev_updates and md_array and not md_array.status and md_array.complete:
try:
md_array.setup()
except MDRaidError:
log.warning("failed to activate MD array %s", md_array.name)

def update(self):
# update array based on current md data
pass

0 comments on commit 94adfec

Please sign in to comment.