From 7991e4548bf24e0f8532a87f1a6c4401d8ca8bd0 Mon Sep 17 00:00:00 2001 From: Kai Dohmen Date: Mon, 3 Jul 2017 17:20:02 +0200 Subject: [PATCH] Fix unknown partition-type Fat32 at mount and in fstab Only the string "fat32" and "fat16" will be replaced with vfat. If an case sensitive "Fat32" some problems occure: - mount: partition cannot be mounted (e.g. a fat32 efi partition) - fstab: system won't even boot because fstab does not know the type "Fat32" --- src/modules/fstab/main.py | 2 +- src/modules/mount/main.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/fstab/main.py b/src/modules/fstab/main.py index 384dadbb6..9c116b8a0 100644 --- a/src/modules/fstab/main.py +++ b/src/modules/fstab/main.py @@ -224,7 +224,7 @@ class FstabGenerator(object): def generate_fstab_line_info(self, partition): """ Generates information for each fstab entry. """ - filesystem = partition["fs"] + filesystem = partition["fs"].lower() mount_point = partition["mountPoint"] disk_name = disk_name_for_partition(partition) is_ssd = disk_name in self.ssd_disks diff --git a/src/modules/mount/main.py b/src/modules/mount/main.py index 68f042af9..c32c5bfdd 100644 --- a/src/modules/mount/main.py +++ b/src/modules/mount/main.py @@ -38,7 +38,7 @@ def mount_partitions(root_mount_point, partitions): # Create mount point with `+` rather than `os.path.join()` because # `partition["mountPoint"]` starts with a '/'. mount_point = root_mount_point + partition["mountPoint"] - fstype = partition.get("fs", "") + fstype = partition.get("fs", "").lower() if fstype == "fat16" or fstype == "fat32": fstype = "vfat"