0

Click here to see the helpful picture

I want to use the two encrypted partitions. After I enter the login password it returns me the error message. I do not know the password and I have never used the two encrypted partitions.
Is there any way I could format the two partitions so that I could use them?
I would accept any method by which I could use the two partitions.

Other info: the partitioin is "BitLocker" maybe because the system was Win11 before. And now I do not know how to format it...

I run lsblk and it returns:

...
...
sda           8:0    0 931.5G  0 disk 
├─sda1        8:1    0     1K  0 part 
├─sda5        8:5    0 465.9G  0 part 
└─sda6        8:6    0 465.6G  0 part 
sr0          11:0    1  1024M  0 rom  
nvme0n1     259:0    0 238.5G  0 disk 
├─nvme0n1p1 259:1    0   512M  0 part /boot/efi
└─nvme0n1p2 259:2    0   238G  0 part /

I leave out the info with "loop" in the above returned info. The partitions I want to use are the two 500G part( sda5 and sda6). I think my ubuntu should be installed in the nvme0n1p2. I hope the method you provide will not impact my ubuntu.

Thx!

6
  • 1
    the two encrypted disks you mean partitions? Yes, format them like you would any partition Commented Aug 30, 2023 at 6:48
  • @Jaromanda I have just searched the methods you provided. And I met new problems, for which I just update my question. Commented Aug 30, 2023 at 8:19
  • superuser.com/questions/376533/… might be of use here
    – Journeyman Geek
    Commented Aug 30, 2023 at 8:24
  • But I do not know the password at all. Commented Aug 30, 2023 at 8:32
  • In which case you would probably want to delete the partitions entirely...
    – Journeyman Geek
    Commented Aug 30, 2023 at 8:35

2 Answers 2

0

Well - what I'd try the command line way of doing things

This will delete everything on the partition and let you reformat. If you want to mount the current disks, I've linked another post in the comments

Open a terminal window

run sudo fdisk /dev/sdc

Then press `m' and enter.

This will give you a menu that looks like this

Command (m for help): m

Help:

  DOS (MBR)
   a   toggle a bootable flag
   b   edit nested BSD disklabel
   c   toggle the dos compatibility flag

  Generic
   d   delete a partition
   F   list free unpartitioned space
   l   list known partition types
   n   add a new partition
   p   print the partition table
   t   change a partition type
   v   verify the partition table
   i   print information about a partition

  Misc
   m   print this menu
   u   change display/entry units
   x   extra functionality (experts only)

  Script
   I   load disk layout from sfdisk script file
   O   dump disk layout to sfdisk script file

  Save & Exit
   w   write table to disk and exit
   q   quit without saving changes

  Create a new label
   g   create a new empty GPT partition table
   G   create a new empty SGI (IRIX) partition table
   o   create a new empty DOS partition table
   s   create a new empty Sun partition table

You want d

Partition number (1-6, default 6): 5

Then repeat for partition 6

This will create a single unpartitioned space.

use n to create a new parition in the space.

Command (m for help): n
Partition number (1,4-128, default 1):
First sector (34-124927, default 2048):
Last sector, +/-sectors or +/-size{K,M,G,T,P} (2048-63487, default 63487):

Created a new partition 1 of type 'Linux filesystem' and of size 30 MiB.

These changes are NOT applied until you exit using the w menu option.

You can then format these partitions as per normal

4
  • I find my computer supports the UEFI. Is better to use g to create a gpt table? Commented Aug 30, 2023 at 10:12
  • You're not creating a new partition table tho, you're deleting existing partitions and creating new ones
    – Journeyman Geek
    Commented Aug 30, 2023 at 10:15
  • I have deleted them all. So is better to use g to create a gpt table? Commented Aug 30, 2023 at 10:34
  • Yes - it would be
    – Journeyman Geek
    Commented Aug 30, 2023 at 10:41
0

The following procedure will destroy all your data on the disks.

  1. First of all, open a terminal prompt (ctrl+alt+T). And elevate as root
    sudo su
    
  2. Then, run the following commands to identify your disk "mapper" (something like /dev/sdX). And share it to us.
    lsblk
    df -Th
    
  3. Once you identified the disk you want to wipe to zero (be carefull to choose it wisely, or you may break your system) (once the wipe is done, data are lost forever...except if you ask for it on an other question ^^), perform the following command (On your example its probably: /dev/sda)
    dd if=/dev/zero bs=4096 of=/dev/sda
    
  4. Once the complete WIPE is done. You have to recreate a partition table and partitions on the disk with fdisk. (o: create DOS partition table, n: create new partition, w: write on disk)
    (echo o;echo n;echo;echo;echo;echo w)|fdisk /dev/sda
    
  5. Finally, you have to create a filesystem for your new partition (here i did choose fat32, but you could do exfat, or ntfs as you wish)
     mkfs -t vfat /dev/sda1
    
  6. Once it is done, you may try to access your filesystem by unpluggin and replugging your disk or by commandline.
    mount /dev/sda1 /mnt
    echo "It works" > /mnt/myfileondisk.txt
    cat /mnt/myfileondisk.txt
    

Hope it helps.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .