How to Remove an Old Ubuntu Partition After Installing Linux Mint?

Discussion in 'Linux Beginners' started by EstellaHardy, Dec 20, 2024.

  1. EstellaHardy

    EstellaHardy New Member

    Hi everyone,

    I recently found my old Dell Inspiron 15R laptop in storage. It had Ubuntu installed on it from when I was in school, but I’ve since forgotten the sudo password.

    Instead of recovering or resetting the password, I decided to install Linux Mint, which I’ve been wanting to try. The installation was successful, and I partitioned the hard disk during the process.

    Now, I’d like to completely remove the old Ubuntu partition, and I’m okay with losing any data on it. Can I simply format the Ubuntu partition to ext4 using the Disks application in Linux Mint? Are there any potential issues I should be aware of?

    Thanks in advance!
     
    barthman likes this.
  2. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    You can mount the Ubuntu partition on the Mint system, and copy the files somewhere else, or examine what files are there if some of them might be useful.
    Yes.
    If you want to use that disk space on Mint, you need to mount it to some mount point, for example /opt or /srv or some other mount point that now has nothing written there. If there are files in the mount point, they are not accessible while that partition is mounted there.
     
    EstellaHardy likes this.
  3. martin john

    martin john New Member

    Great advice! Using the Disks app is definitely user-friendly, and running sudo update-grub afterward is a smart step to avoid boot issues. Love the comparison to checking your NOL card balance—simple habits that keep everything running clean and smooth!
     
  4. barthman

    barthman New Member

    Hey Estella,
    That's a great question, and it's awesome that you're diving into Linux Mint. You're on the right track with using a disk management tool to handle the old partition.

    The short answer is yes, you can absolutely format the old Ubuntu partition to ext4 using the Disks application in Linux Mint. It's a very straightforward and safe way to proceed as long as you're sure you've identified the correct partition.

    Here's a step-by-step guide to make sure you do it right:

    1. Open the Disks Application: You can find it in your Mint menu. Just search for "Disks."

    2. Identify the Correct Disk and Partition: This is the most critical step. Look at the list of drives on the left side of the Disks window. Your main hard drive will likely be named something like /dev/sda or a similar name. Below that, you'll see a graphical representation of your partitions (e.g., Partition 1, Partition 2, etc.). The Linux Mint partition will likely be a large ext4 partition. The old Ubuntu partition will also likely be ext4 and will probably have a different size or location.

    3. Unmount the Partition: Before you can format it, you need to unmount the partition. Click on the partition you want to remove, and then click the "Stop" button (a little square icon) to unmount it.

    4. Format the Partition: Once it's unmounted, click the gear icon (or the hamburger menu in some versions) and select "Format Partition." Choose ext4 as the type and give it a new name (like "Data" or "Storage").

    5. Apply and Confirm: Click the "Format" button. The application will ask you to confirm. Double-check that you've selected the correct partition one last time before clicking "Format."
    Potential Issues to be aware of:

    • Grub Bootloader: The only major potential issue is if the old Ubuntu partition was responsible for the GRUB bootloader. If your Linux Mint install used the existing GRUB from Ubuntu, removing the partition might cause boot problems. However, since you did a fresh install of Mint and partitioned the hard disk during the process, it's highly likely that Mint's installer created a new GRUB bootloader on its own. A good way to check is to see if your /boot directory is on the same partition as your main Linux Mint installation. If so, you're safe. If your computer boots into Mint without a problem, you can proceed with confidence.

    • The Swap Partition: If you had a separate swap partition for Ubuntu, you can either format it and re-purpose it or let Linux Mint create a new one. Modern Linux installs often use a swap file instead of a separate partition, so this may not be an issue for you.
    As long as you're careful to only format the Ubuntu partition and not your Linux Mint partition, you won't have any problems.

    Hope this helps, and enjoy your new Linux Mint setup!
     
  5. barthman

    barthman New Member

    Just to add a little more to the excellent advice already given, if you want to be 100% sure before you format the partition, you can use the terminal to double-check which partitions are mounted and where your current Linux Mint installation resides.
    Open a terminal (Ctrl+Alt+T) and run the following command:

    df -h

    This will show you a list of all your mounted partitions, their sizes, and their mount points. You should see a line that looks something like this:

    /dev/sdaX SIZE USED AVAIL USE% MOUNTPOINT

    Your Linux Mint root partition will be mounted at / (the root directory), and you can confirm that it's on a different partition than the one you're about to format. This gives you an extra layer of confidence before proceeding with the Disks application.

    Also, if you're feeling adventurous after you've formatted the old partition, you can use the GParted application (you may need to install it: sudo apt-get install gparted) to resize your current Linux Mint partition and reclaim that extra space. It's a bit more advanced but a very powerful tool for managing your disk layout.

    Either way, you're on the right track. Happy to help if you have any more questions!
     

Share This Page