[PATCH v2 0/6] mdadm: POSIX portable naming rules

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jes,
To avoid problem with udev and VROC UEFI driver I developed stronger
naming policy, basing on POSIX portable names standard. Verification is
added for names and config entries. In case of an issue, user can update
name to make it compatible (for IMSM and native).

The changes here may cause /dev/md/ link will be different than before
mdadm update. To make any of that happen user need to use unusual naming
convention, like:
- special, non standard signs like, $,%,&,* or space.
- '-' used as first sign.
- locals.

Note: I didn't analyze configurations with "names=1". If name cannot be
determined mdadm should fallback to default numbered dev creation.

If you are planning release soon then feel free to merge it after the
release. It is a potential regression point.

It is a new version of [1] but it is strongly rebuild. Here is a list
of changes:
1. negative and positive test scenarios for both create and config
   entries are added.
2. Save parsed parameters in dedicated structs. It is a way to control
   what is parsed, assuming that we should use dedicated set_* function.
3. Verification for config entries is added.
5. Improved error logging for names:
   - during creation, these messages are errors, printed to stderr.
   - for config entries, messages are just a warnings printed to stdout.
6. Error messages reworked.
7. Updates in manual.

[1] https://lore.kernel.org/linux-raid/20221221115019.26276-1-mariusz.tkaczyk@xxxxxxxxxxxxxxx/

Mariusz Tkaczyk (6):
  tests: create names_template
  tests: create 00confnames
  mdadm: set ident.devname if applicable
  mdadm: refactor ident->name handling
  mdadm: define ident_set_devname()
  mdadm: Follow POSIX Portable Character Set

 Build.c                        |  21 ++--
 Create.c                       |  35 +++----
 Detail.c                       |  17 ++-
 config.c                       | 184 +++++++++++++++++++++++++++------
 lib.c                          |  76 +++++++++++---
 mdadm.8.in                     |  70 ++++++-------
 mdadm.c                        |  73 +++++--------
 mdadm.conf.5.in                |   4 -
 mdadm.h                        |  36 ++++---
 super-intel.c                  |  47 +++++----
 tests/00confnames              | 107 +++++++++++++++++++
 tests/00createnames            |  89 ++++------------
 tests/templates/names_template |  80 ++++++++++++++
 13 files changed, 551 insertions(+), 288 deletions(-)
 create mode 100644 tests/00confnames
 create mode 100644 tests/templates/names_template

-- 
2.26.2




[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux