YaST2 Developers Documentation: configuration of raid:

configuration of raid:

raid_lib.ycp

This module has an unstable interface.

---------------------- rd or Rd == raid device, a device like hda1 or /dev/system/usr that belongs to a raid

Imports

  • Mode
  • Partitions
  • Storage
  • Wizard

Local Functions

local get_raid_devices (map tg, integer raid_nr) -> list<term>

Build raid dev item list e.g.: [`item (`id ("/dev/md2"), "/dev/md2", false)]

Parameters:
tg
raid_nr
local IsRaidCreated (map tg, string device, symbol what) -> boolean

Checks if a RAID is currently created or if it was already

Parameters:
tg
device
what
local new_raid_list (list<term> all_raids) -> void

Update Raid ComboBox

Parameters:
all_raids
local isItemRd (map<string,map> tg, string id) -> boolean

belongs the the partition "id" already to a raid

Parameters:
tg
id
local CheckItemIsNotRaid (map<string,map> tg, string id) -> boolean

belongs the the partition "id" already to a raid if YES: popup a proper Message and return(false)

Parameters:
tg
id
local CheckItemIsRaid (map<string,map> tg, string id) -> boolean

belongs the the partition "id" already to a raid? if NO: popup a proper Message and return(false)

Parameters:
tg
id
local get_raid_widget_table (list<map> possRdList) -> list

partition list to widget table in: [ $["fsid":142, "fstype":"Linux raid", "nr":"var", "region":[255, 16], "type":`primary], $[ "fsid":131, "fstype":"Linux native", "nr":4, "region":[271, 844], ...

Parameters:
possRdList
local get_free_raid_nr (map<string,map> targetMap, integer min) -> integer

number for /dev/mdX, 0 for /dev/md0, 1 for /dev/md1

Parameters:
targetMap
min
local add_main_dev_to_partition_map (map<string,map> targetMap) -> map

Add the main device ( "/dev/hda") to the partition map. partition = $[ "nr" : 1, "main_dev": "/dev/hda", ...... ]; Use change !!!!!!!!!

Parameters:
targetMap all targets
Return value:
nil
local all_raid_partitions (map<string,map> targetMap) -> list<map>

Parameters:
targetMap all targets
Return value:
a list with all partition that have a key raid_name != "".