Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Software
idms-linux-installer
Commits
8f16a86f
Commit
8f16a86f
authored
Jul 13, 2020
by
Nigel Kukard
Browse files
Set MDRAID boot_hint
parent
3bd88fe8
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/idmslinux_installer/plugins/disk_usage/mdraid.py
View file @
8f16a86f
...
...
@@ -87,15 +87,14 @@ class DiskUsageMDRAID(Plugin):
if
raid_level
:
ili_state
.
output_callback
(
'Creating MDRAID arrays'
)
efi_disk
=
ili_state
.
install_disks
[
0
]
boot_disk
=
'/dev/md/0'
root_disk
=
'/dev/md/1'
mdadm
=
Mdadm
()
# Add all part3 to array
mdadm
.
create
(
boot_disk
,
1
,
[
get_partition
(
x
,
3
)
for
x
in
ili_state
.
install_disks
],
output_callback
=
ili_state
.
output_callback
)
boot_attribs
=
mdadm
.
create
(
boot_disk
,
1
,
[
get_partition
(
x
,
3
)
for
x
in
ili_state
.
install_disks
],
output_callback
=
ili_state
.
output_callback
)
# Add all part4 partitions to array
mdadm
.
create
(
root_disk
,
raid_level
,
[
get_partition
(
x
,
4
)
for
x
in
ili_state
.
install_disks
],
output_callback
=
ili_state
.
output_callback
)
...
...
@@ -111,5 +110,9 @@ class DiskUsageMDRAID(Plugin):
for
disk
in
ili_state
.
install_disks
:
ili_state
.
add_boot_mbr
(
disk
)
# Set the hint to use to find the boot fs
boot_uuid
=
boot_attribs
[
'MD_UUID'
].
replace
(
':'
,
''
)
ili_state
.
boot_hint
=
f
'mduuid/
{
boot_uuid
}
'
# Add mdadm to the base packages
ili_state
.
add_base_package
(
'mdadm'
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment