diff options
author | OpenGnSys Support Team <soporte-og@soleta.eu> | 2024-05-06 19:04:16 +0200 |
---|---|---|
committer | OpenGnSys Support Team <soporte-og@soleta.eu> | 2024-05-06 19:08:12 +0200 |
commit | 8ecd57552ac9e18313ea8a4a8c37818853dd639d (patch) | |
tree | 4ecb7015c0040bbdbbeffd510c9ca4bc9561667b /src/live/ogOperations.py | |
parent | 2dd51059956ee7c9c9deb3ac4ab7b9755a00d25c (diff) |
live: restore partprobe before building filesystem
Otherwise mkfs silently fails because OS reports out-of-sync partition table.
Diffstat (limited to 'src/live/ogOperations.py')
-rw-r--r-- | src/live/ogOperations.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/live/ogOperations.py b/src/live/ogOperations.py index afb6c67..a43e756 100644 --- a/src/live/ogOperations.py +++ b/src/live/ogOperations.py @@ -348,6 +348,9 @@ class OgLiveOperations: cxt.write_disklabel() os.sync() + ret = subprocess.run(['partprobe', f'/dev/{diskname}']) + logging.info(f'first partprobe /dev/{diskname} reports {ret.returncode}') + for part in partlist: if part["filesystem"] == 'EMPTY': continue @@ -362,7 +365,7 @@ class OgLiveOperations: mkfs(fs, int(disk), partition) ret = subprocess.run(['partprobe', f'/dev/{diskname}']) - logging.info(f'partprobe /dev/{diskname} reports {ret.returncode}') + logging.info(f'second partprobe /dev/{diskname} reports {ret.returncode}') for part in partlist: if part["filesystem"] == 'EMPTY': |