0

I am trying to install Lubuntu on a laptop but not even 10 seconds into the start of the install, I receive an error saying that the partitioning failed. The error message is the following:

The installer failed to create a partition table on WDCWD10JPVX-60JC3T1

======================================================

Create a new partition table (type: gpt) on 'dev/sda'

====================================================== ======================================================

Job: Create a new partition table (type: gpt) on 'dev/sda' ====================================================== =======================================================

Command: sfdisk /dev/s

===================================================== I suspect that it has to do with the boot/efi partition, but I am not sure. The laptop is currently booting on UEFI mode and has Windows 10 installed which will be overwritten once I am done. Here's my latest partitioning table that failed for some reason:

/boot/efi, 1.0 GiB with "boot" flag

no mount point, 16.0 GiB with "swap" flag

/ (root), 30.0 GiB with "root" flag

/home, 100.0 GiB with no flag

The rest of the space has no mount point and is just formatted with ext4 for storage.

Is something wrong with my configuration? I feel like I need a partition with GRUB (or something similar) mount point. I tried to stay true to the recommended partitioning scheme that I read on the Ubuntu wiki. Any help is highly appreciated.

UPDATE:

It turns out that there was a partition (on the current state of my hard drive) with a lock sign and a cd-rom mount point that could not be unmounted/modified in any way. I erased that partition on Windows 10 and now the installing is running fine, so far at least.

  • 1
    The wiki may need to be updated: 20.04 by default will use a swapfile, rather than a partition. 30G for the root partition seems small, currently I'm using 36 GB. My /boot/efi is a very small bit of a 512 MB partition. You may have a different problem if you still have Win10 on the machine, however. There are some limits on the number of primary partitions that can be used - 4 seems to be the limit unless the partition table is GPT – Charles Green Feb 13 '21 at 22:13
  • I haven't used the default settings but for the 10-20 times i have installed Ubuntu variants so far, they all have worked. I have been reading about partitioning for Ubuntu for the last few days and I wanted to experiment with manual partitioning and hopefully learn about what causes this error. I added the error message to the post if it helps.

    Also, I thought. that Lubuntu is lightweight and would do fine with 30 GiB of memory? Even Windows 10 doesn't use that much. But If I am creating a new partitioning table, should Windows 10 mess with it somehow? Won't It will be overwritten anyway?

    – Unrivalled confusion Feb 13 '21 at 22:18
  • 1
    If you are creating a new partitioning table (GPT?) all your disk gets "factory reset": you lose all data immediately, windows and all. – Levente Feb 13 '21 at 22:27
  • Yes, I am aware of that. I have already uploaded all my data to my cloud storage. I want to "wipe" the disk and get rid of everything in it completely. Do you have any ideas what could cause this problem? I mean, is my partitioning scheme correct in the first place? I think I will reformat the disk to ext4 first with KDE partition manager. Maybe something comes out this way. – Unrivalled confusion Feb 13 '21 at 22:30
  • 1
    No, I have not seen this type of error. But if you indeed add a new GPT table, that makes you start from a clean start. On the other hand, you cannot format an entire disk for ext4. You can format only partitions. And one of your partitions, the EFI one needs to be FAT32. OOps, now I read the error again, it cannot create the GPT partition table! Maybe it's some kind of "write-protection" that Windows has set on the disk? – Levente Feb 13 '21 at 22:32
  • Oh, do you mean that the boot/efi partition should be FAT32? If I do that, does my partitioning scheme make sense to you? I suspect that I may have added/missed a flag or mounting point.

    On the other hand, there is one partition with a lock sign next to it in my current scheme. I attempted and failed to use unetbootin to run Lubuntu installer from a hard drive partition a few hours ago (before I found my USB drive). It is that very same partition (with a cd-rom mount point). I cannot unmount or modify it using KDE partition manager, I think this may cause the problem I am having.

    – Unrivalled confusion Feb 13 '21 at 22:35
  • You write: "I cannot unmount" a partition. I don't understand why even it is mounted, if you are running from the USB. That's your problem: EVERYTHING on the internal disk needs to be unmounted. If anything is mounted and you cannot unmount it, then restart the machine, and boot from the USB again. Then no partition from the internal disk should get mounted at all. And thus the formatting should work then. – Levente Feb 13 '21 at 22:45
  • Also, looking at what @mct writes, indeed, when you boot from the USB and see the Grub menu for the USB, pick the "UEFI mode" variant from the Grub menu. Then you are prepared well for the GPT stuff and setting up the EFI partition right. – Levente Feb 13 '21 at 22:49
  • I see, and just to make sure, is my partitioning scheme valid? Or is there some sort of a mistake that would prevent an installation? And should I enlarge the root partition? Should 40GB suffice? – Unrivalled confusion Feb 13 '21 at 22:51
  • 1
    I would encourage you to just use the default partitioning that Ubuntu can perform. There's nothing wrong with it, and it does eliminate guesswork while you're learning about the system – Charles Green Feb 13 '21 at 22:53
  • I am aware that it would be easier, I am doing this on principle to be honest. Just to make sure that my understanding is correct. – Unrivalled confusion Feb 13 '21 at 22:56
  • I'm unsure about the partitioning info you share. I would say no "boot" flag is necessary on the EFI partition. (I recall, the "boot" flag was used only for MBR?) But I'm not even 100% sure what "flags" are. Then: why do you have a flag on /, but then no flag on "home"? That's not consistent. Also, if you plan an additional data partition formatted as ext4, then why so big home? If you keep your data in the additional ext4 data partition, then 10GB would plenty suffice for a home partition. Make the root (/)a bit bigger, minimum 40GB. EFI is recommended at 512MB, but 1GB can't hurt much... – Levente Feb 13 '21 at 22:59
  • Flag your home somehow with some home flag (so that the installer recognizes your intent) – Levente Feb 13 '21 at 23:00
  • Thank you. I gave "boot" flag to the EFI partition because when I didn't, it give me a warning that my system "may" fail to start. It may have been a placeholder, but I guess adding that flag won't hurt much? The reason I gave no flag to the "home" partition because there was no such option on the list of flags. Isn't the mount point sufficient enough to recognize the home partition?

    In that case, I will make the root partition 45 GB and see how it works.

    I'll just try out this manual scheme and if it gives me too much headache, I'll switch to the default options.

    – Unrivalled confusion Feb 13 '21 at 23:01
  • 1
    Okay, I get the thing about the "boot" flag. However, if you want to use an independent partition for your data, then you will have extra hurdles, are you prepared for that? Look here what I mean: https://askubuntu.com/a/1309681/1157519 – Levente Feb 13 '21 at 23:02
  • Are you sure that is the complete error message? it looks like it's missing details, particularly the command "sfdisk /dev/s" looks incomplete.. Did you read the release notes? as they included a number of possible errors & the work-arounds for them, I can't point you to which may relate as that part of the message looks invalid/redacted. (I was reluctant to provide link as you didn't say if you used 20.04, 20.04.1, 20.04.2 and they differed slightly - https://lubuntu.me/focal-2-released/) – guiverc Feb 13 '21 at 23:11
  • Just for this time, I'll take the risk of using an independent partition. If it becomes unbearable, I'll reinstall with regular settings.

    Regarding the error message, I thought the same but there was nothing else to show. I tried scrolling but nothing else came up. If it comes up again, I'll check more carefully. In any case, please let me know if my partition scheme is at least theoretically alright.

    – Unrivalled confusion Feb 13 '21 at 23:18
  • 1
    Yeah, I myself also use a dedicated data partition, separate from home. Just wanted you to know that it's extra work :) – Levente Feb 13 '21 at 23:20
  • 1
    re: your boot may fail, refer https://askubuntu.com/questions/1273421/lubuntu-installer-giving-error-after-partition-creation-your-system-may-or-may/1276789#1276789 – guiverc Feb 13 '21 at 23:20
  • @CharlesGreen in the first comment you mention wiki; if official Ubuntu & esp. Lubuntu wiki I'm interested in which. We (Lubuntu) have a few docs on swapfile; 20.04/20.10 (no swap file by default; swap partition if user sets up), & 21.04/later (swapfile default as calamares can finally handle it; same applies Ubuntu Studio using calamares) – guiverc Jul 26 '22 at 22:51
  • @guiverc Gosh that was long ago (I was smarter back then too) - the OP originally mentioned to Ubuntu Wiki, this i believe is here - I should login and edit some of this, as it uses some bad practices such as fallocate to create space for a swap file – Charles Green Jul 27 '22 at 16:35
  • Yeah sorry; I didn't scan dates well enough @CharlesGreen; I tend to re-scan open Lubuntu questions & should have noticed my own comment was >12 months ago, alas I didn't sorry. – guiverc Jul 27 '22 at 22:36
  • @guiverc - Sadder still: I've developed prostate cancer (go get screened if applicable, please) and the drugs make you foggy in the brain. I look at my posts from a year ago, and I was a lot smarter back then. It's really quite scary – Charles Green Jul 27 '22 at 22:49

1 Answers1

2

In my scenario, I had to manually create my partitions by installing and using gparted in the live environment, then setting up the partitions manually. This was because I wanted to keep my existing /home partition.