After some help from linuxdev2013, this is what I did:
The problem was that the partitions were somehow locked. So:
I right Clicked both sda2 and sda5 and chose "Deactivate".
I resized the extended (sda2) partition.
I resized the lvm (sda5) partition.
The problem was fixed.
I should add that in the VM the new space was not available, so I had to run ...
The issue is very similar to the one below, most likely there was a dd command ran over the device that caused the mismatch descriptor.
Ask Ubuntu: Unable to delete USB Drive partitions (Block size error)
The problem you are describing was caused by a low-level device tool (like dd) writing blocks at the wrong size directly onto the device.
To fix this, ...
Since you mentioned GParted, try this:
Launch GParted on the disk.
If any partitions are mounted (as indicated by a lock or key icon), unmount them.
Select Device->Create Partition Table.
The disk should now use MBR. You can also create partitions within GParted, if you like; however, the Windows installer can do this automatically if you ...
I'm not sure what the situation was 5 years ago, but today it's cake.
$ sudo udisksctl loop-setup -f disk.img
Mapped file disk.img as /dev/loop0.
$ gparted /dev/loop0
$ sudo udisksctl loop-delete -d /dev/loop0
To grow or shrink the disk after you could use truncate -s. Keep in mind that this would wipe out any backup partition table at the end of the disk, ...
You can resize the Windows partition, and it will still boot. Windows will give an error at start-up the first time saying the disk size doesn't match it's records, it will run checkdisk and update it's records, and then work fine. I've done this many times.
You cannot move the Windows partition though or it won't boot. It's worth pointing out that if you ...
Looks like you "soft" ejected the USB drive. Even though physically there's no separate medium you can eject you can still send an eject command to the USB drive. After that it's still being listed as an USB device but the storage is not "connected" anymore.
You can "insert" the medium again with:
eject -t /dev/<DEVICE> # short option
These two options are unfortunately listed along with the others that act in a different manner. The other options are all filesystem formats, where the new partition is created with the selected format. These two options of interest are essentially the two null options.
If one leaves a partition "unformatted" then no attempt to write filesystem data ...
I want to understand what is going on
Rufus developer here.
What way too many people fail to understand, because Linux ISOs are applying this method, but this is essentially a MAJOR HACK CALLED 'ISOHYBRID', is that, in most cases, you cannot simply take an ISO image and copy it byte for byte to a USB drive, and expect that too boot.
That is because the ...
The secondary label at the end of the volume is required by GPT; a disk without it is corrupted and may not be recognized by all systems. Using a corrupted format in order to gain a tiny amount of space, on a disk that's probably a few hundred gigabytes at least, doesn't make much sense.
However, the actual GPT label is only about 68 kilobytes in size. ...
It's the same flag. The "active" flag in Windows is called the "boot" flag in Linux.
Windows and Linux use different terminology for the same bootable
partition or drive
The term "active" is used for the bootable partition when you are in a
The term "boot" is used for the bootable ...
I'm not sure why libparted does this, but I have three hypotheses:
It may be a relic of times past. When using the old-style cylinder alignment, the number of sectors on a modern disk would seldom work out to an exact number of cylinders -- that is, the last cylinder would be partial. Thus, when partitioning MBR disks with cylinder alignment, it was once ...
You cannot install GParted on Mac OSX. You will have to use the Live Version. This is according to the GParted website itself.
Here is a screenshot of it:
You can definitely find GParted alternatives for Mac OSX here. I found something interesting here, that parted does not even compile for Mac OSX.
I don't want to steal someone else's work; the original contributor is Damiön la Bagh here: https://bugs.launchpad.net/ubuntu/+source/usb-creator/+bug/1708881
Be warned that by performing this procedure you will lose the data you have on your drive. When successful, you will end up with a usable drive, but no attempt is made here at recovering data from ...
GRUB is not showing a Windows partition; it's showing a Windows boot loader file. This is an important distinction because your misunderstanding is sending you on a wild goose chase. (It sounds like you haven't been chasing those geese for very far, though.)
On an EFI-based computer like yours, boot loaders are stored as ordinary files in the EFI System ...
On loop images
First of all, forget offset=, use losetup --partscan and just mount the partition via /dev/loop0p1.
# losetup --partscan /dev/loop0 myimage.img
# mount /dev/loop0p1 /mnt
To efficiently clear empty space within a partition, run fstrim on the loop-mounted filesystem, just like you would on an SSD. (This will actually make the image ...
You can move C: upward over the unallocated space, then move X: over the
newly displaced unallocated space, ending up with the unallocated space below X:,
ready to be merged via the resize of X:.
This will not change the numbering of the partitions, since the unallocated space
is not a partition and does not have a partition number.
Do not use GParted for ...
The most important rule of data recovery is do nothing that can change the data you have Creating a partition table is a bad idea, and fdisk and gparted are partition editors. They change the data and as such they risk destroying the data
I think we need to start with what actually happened to the data. If it was overwritten, it is very likely you are out ...
Apparently, one must first add the partitions, and apply those operations. After that one can change the flags.
Add all the partitions (without setting flags)
Press "Apply All Operations"
Partitions will now appear in list with some flags, in my case both the fat32 and the ntfs partitions have the flag msftdata
Right click, select Manage flags. This ...
UPDATE on Windows 10 1703
Microsoft finally did away with this ridiculous limitation. Since Windows 10 1703 (“Creators Update”) you can now access all partitions on removable drives.
Windows only supports the first partition on USB thumb drives (specifically, USB Mass Storage devices with the “Removable” bit set). There is nothing you can ...
This was the case for drives partioned with MBR (Master Boot Record). Modern PC's come with drives partioned in GPT (GUID Partition Table), which has a limit of 128 partitions.
You can find more information about the differences here.
Thanks for the fdisk and mount outputs.
the difference between the two fdisk outputs is just in Units used, hence the numbers are different.
The /dev/sda1 partition isn't yet resized, it's still ~20GB.
You will have to resize it first, best done when booted from the CD:
~# fdisk /dev/sda
Welcome to fdisk (util-linux 2.23.2).
Command (m for help): p
No, you don't need separate swap partitions.
You should be able to modify your /etc/fstab file in the Ubuntu system to point to the same location as the swap file in the Kali system. Then both linuxes will use the same partition.
What are those available partition table types in gparted useful for?
The options you mention (other than Atari) are covered below (and I guess Atari is there to support Atari partition tables).
The options correspond to the various partitioning systems supported
in libparted; there's not much documentation, but looking
at the source code:
The best solution I found for fixing the partition order:
Enter into the disk partition place:
Command (m for help): m
l list known partition types
m print this menu
p print the partition table
q quit without saving changes
w write table to disk and exit
x extra functionality (experts ...
grawity's answer is not entirely complete for this question. It is possible to move the contents of partition 2 to the end of the device. Simply right-click and copy the partition, and paste it at the end. After that succeeds,
delete partition 2.
It will cause partition 2 and partition 3 to switch in naming. After moving sda2 to the end of the device- sda3 ...
Use the right tool for the job. gparted is a partition editor, not a data mover. For that, you want something like dd. Check the manpage - it's an old program, and its commands are a bit atypical compared to modern tools - but it should be simple enough. You can copy entire disks (with all data, including boot records and partition tables), or just copy ...
Because the unallocated space is in front of your Linux partition, it cannot simply be extended. Instead, you’ll have to move the whole partition first. This is a dangerous operation, so make sure you have a backup.
Change the Extended Partition’s size so it also covers the free space
Move the Linux partition all the way to the start of the Extended ...