Skip to main content
We’ve updated our Terms of Service. A new AI Addendum clarifies how Stack Overflow utilizes AI interactions.

Questions tagged [fdisk]

fdisk (for "fixed disk") is a command-line utility that provides disk partitioning functions.

Filter by
Sorted by
Tagged with
12 votes
1 answer
879 views

Why does mkfs.ntfs count one Byte less?

Apparently, ntfs.mkfs counts one byte less when checking if the block device is large enough; or I have made some kind of mistake. After creating a partition of 2048 512-byte sectors (exactly 1MiB ...
Fivos Theophylactou's user avatar
3 votes
2 answers
198 views

What should I backup before using parted or fdisk to resize a partition?

Let's say I have disk sda with format MBR and I have N partitions and I want to resize partition K (allocate more space on partition K) I will use a USB device and use a Linux installation medium so ...
Sul4ur's user avatar
  • 43
6 votes
1 answer
309 views

How to create partitions on a volume with the root filesystem mounted on the enitre disk

I have a server with the root filesystem / mounted on /dev/sda, i.e., the entire disk, which has no partitions. This situation makes me uncomfortable, and I would like to partition the disk and put ...
Dave_G's user avatar
  • 71
4 votes
3 answers
621 views

Can’t see partition device after creating GPT partition on 6TB disk

I have a 6TB disk in Debian Linux 12, let's say the disk is /dev/sdd. It's just for data; no parts of the OS are on it. Now I’m trying to use it as a normal disk with the full space in a single ...
chris01's user avatar
  • 1,039
3 votes
1 answer
212 views

How to extend a logical volume mounted on /home directory?

I was given a CentOS 9 Linux distribution server inside a virtual machine to whom I can connect using ssh protocol (from command line). I am running svn checkout command in order to clone a remote ...
tail's user avatar
  • 181
2 votes
0 answers
85 views

Partitioning or duplicating corrupted SSD

My SSD died and all its data seems to be inaccessible and my Windows computer won't boot anymore. After going to a local computer store I was told that they could fix it by wiping all the data. I can ...
st30's user avatar
  • 121
0 votes
0 answers
46 views

Need help for a manual calculation of MBR after /bin/dd of Virtualbox flat hard disk image to actual HDD on 32-bit P4 laptop (2003)

I have an old laptop which I am trying to install OpenStep 4.2 with Patch 3 pack (Which supports over 8GB and has a VESA driver) on to a 2003 laptop which is a 32-bit pentium 4 with 512MB RAM and a ...
Puha Technologies's user avatar
0 votes
1 answer
222 views

Extending Logical Volume Size Beyond 2TB in CentOS 7

I need to extend the size of the logical volumes in a CentOS 7 system and noticed that the current partition table cannot handle the updated disk size, which is around 5TB: Disk /dev/sda: 5497.6 GB, ...
yildizabdullah's user avatar
11 votes
2 answers
3k views

Why does fdisk create a 512B partition when I enter +256K?

I am trying to create a partition of 256KB on my flash device. I begin by entering the default values for the partition number (1) and first sector (2048). However, when I enter "+256K" for ...
Pranav Athreya's user avatar
0 votes
1 answer
328 views

Resize partition that is mounted on root or "/"

Not too sure whether this has been done before. I am trying to resize a partition /dev/sda3 on a single disk /dev/sda. When I tried to use "resize2fs /dev/sda3 10G" directly, the console ...
user1538798's user avatar
0 votes
1 answer
163 views

Problems partitioning HDD for windows 11 dualboot

I'm trying to set up a dualboot of windows 11 (currently installed) and archlinux. I've done this before on a machine running windows 10 and I had no problems, however with this machine I run into ...
chenel's user avatar
  • 11
0 votes
1 answer
346 views

fdisk: /dev/sd1c is not a character device

I hope this message finds you well. I am writing to you because I am attempting to format and partition a drive in OpenBSD but have been met with the following message: virtual-server# fdisk /dev/sd1c ...
SpreadingKindness's user avatar
0 votes
1 answer
57 views

Why does FDisk's Editor Close when Running the Command 'a'?

I hope this message finds you well.  I am writing because I ran the following in my OpenBSD device and am uncertain why it stops running: virtual-server# fdisk -e sd1 Enter 'help' for information sd1:...
SpreadingKindness's user avatar
0 votes
1 answer
66 views

how to provide the device name that related to LVM2_member

LVM2_member could be different according to device partition number example lsblk -f | grep LVM2_member | awk '{print $1}' └─sda3 or on other redhat machine lsblk -f | grep LVM2_member | ...
yael's user avatar
  • 14k
0 votes
1 answer
462 views

Resize Disk Image with Protective MBR and GPT table

I've got a disk image that I need shortened slightly (long story - but it deals with variances in flash drive sizes). The partitions are already short enough, but the drive size is not. Basically, I ...
johnnyb's user avatar
  • 101
2 votes
1 answer
130 views

fstab, mountpoint - what did I miss?

I can't figure out what I'm missing or done wrong. lsblk dose not show the mount points(?) NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS sda 8:0 0 1.8T 0 disk └─sda1 8:1 ...
Arelius's user avatar
  • 83
0 votes
0 answers
111 views

RHEL 7.2 + is it possible to resize partition sda2 when parted not support resizepart

we have old RHEL machines with version 7.2 ( RHEL 7.2 ) this machines has old parted version that not support resizepart so for example we can't use this syntax in order to resize sda partiton parted /...
yael's user avatar
  • 14k
0 votes
1 answer
491 views

Subpartition inside partiton not showed in lsblk or /dev/

I installed archlinux inside my /dev/sdb4 and used the guided partition scheme. After install i can't mount /dev/sdb4 (ext4). The error was VFS: Can't find ext4 filesystem. lsblk shows me: sdb 8:...
cat Man's user avatar
  • 88
0 votes
0 answers
94 views

I have multiple Home folders over several hard drives. I need to understand what I did wrong?

I am running ParrotOS on an old MacPro. I have 3 SSD's and 1 HDD. I was trying to move my Home folder to the HDD. Doesn't that seem like the right thing to do? When I run fdisk -l I only see three of ...
Warloxian's user avatar
0 votes
0 answers
339 views

unable to access usb in debian 12 through Home folder

when I plug the usb in and try this code : sudo fdisk -l I see my USB device in results but can't open it through HomeFolder, I see nothing. How to fix it in Debian 12 ? (thanks for help)
user598575's user avatar
6 votes
2 answers
813 views

How can I list partitions in storage order?

After telling general information (capacity, sector size and the like) fdisk shows 8 columns: sdXY, Boot, begin, end, # of sectors, size, flags, type. The partitions get sorted by Y in their sdXY ...
Adalbert Hanßen's user avatar
1 vote
2 answers
249 views

fdisk -l on an usb drive gives a very weird response

Today I nuked an old usb3 flash 8GB drive on a linux machine with: dd if=/dev/random of=/dev/sdb then I put it into a windows pc, it asked me to format it, I did an extended format with default ...
user3450548's user avatar
  • 3,104
0 votes
0 answers
371 views

Mounting an old JBOD array with two disks DOS formatted

I have a couple of 500GB disks with data inside that I would like to get back. The two disks were mounted inside a Lacie disk, part of a JBOD array and formatted FAT32. I don't have the external disk ...
Joe Mauri's user avatar
0 votes
1 answer
344 views

Scripting fdisk with filesystem signature issues

I'm trying to automatize fdisk with my Bash scripts. In my script, I have the following code block: echo "Creating root filesystem partition..." ( echo n echo 3 echo echo ...
katatonic's user avatar
1 vote
1 answer
147 views

fdisk partition type shown as empy when type is an UUID

I have two systems with same versions (Debian 11.7, util-linux 2.36.1-8+deb11u1). Why one system shows partition types as UUIDS and the second doesn't and also doesn't recognize that types showing &...
Noman_1's user avatar
  • 121
0 votes
1 answer
873 views

Linux Issue : Mount point automatically changes from primary to secondary or secondary to primary on reboot in linux, debian 11/12

I am using debian linux , and in this operating system , I am using 2 disk 1 -> Primary disk (/dev/sda1) 2 -> Secondary disk (/dev/sdb1) First disk is mounted on "/" and the 2nd disk ...
shubham gupta's user avatar
0 votes
1 answer
2k views

How to format RAID hard drive

I need to format(empty hdd) a RAID 0 HDD which is as follow: sdb 8:16 0 3.7T 0 disk └─md126 9:126 0 3.7T 0 raid0 └─md126p3 259:2 0 3.7T 0 part ├─rootvg01-swap 253:0 0 4G 0 lvm ├─rootvg01-...
Thu Ra's user avatar
  • 103
0 votes
1 answer
89 views

Unable to mount Full "md3" System Partition on CentOS Server, preventing Boot

I'm facing an issue with my server running CentOS. The system partition "md3" (raid1) is full due to a backup script error that failed to delete old data. As a result, my CentOS system has ...
node's user avatar
  • 1
0 votes
2 answers
1k views

fdisk shows partitions type Linux and dos on the same partitions

I have created a partition on my disk like this: root@vps-90446fc7:~# fdisk /dev/sdb Welcome to fdisk (util-linux 2.37.2). Changes will remain in memory only, until you decide to write them. Be ...
fguillen's user avatar
  • 103
2 votes
2 answers
1k views

Are UUIDs and PTUUIDs important for MBR disks? If so, how do I create them on my own?

I'm studying partitioning under Linux, starting with sfdisk. If I copy a partition table from one drive to another, it'll copy the device UUID and the PTUUIDs for each partition, but if I'm creating a ...
Tango's user avatar
  • 373
0 votes
1 answer
164 views

Cancelled ext4 shrink and now I can't seem to format the drive? parted, fdisk etc won't run with the drive

I was shrinking an ext4 partition, however it was taking too long so I thought I'd just start from scratch (making a new partition and wiping the data). However after I cancelled the resize (which was ...
Chris Stryczynski's user avatar
0 votes
0 answers
133 views

Problems after migrating drives to HBA-connected disk shelf

I had 4 drives (2x3TB, 1x4TB, 1x18TB) in USB SATA docks connected to my proliant server. I finally got my HBA to recognize my IBM disk array, and managed to get the drives recognized in Ubuntu server ...
Devin Gardner's user avatar
0 votes
1 answer
86 views

Regain full disk space after copying a small image file to a large USB device

I'm copying an image file (size: 2GB) to an USB disk on /dev/sda (size: 2TB) using dd: sudo dd if=2023-05-03-raspios-bullseye-arm64-lite.img of=/dev/sda bs=4M status=progress conv=fdatasync After dd, ...
Wolkenarchitekt's user avatar
-1 votes
1 answer
367 views

USB disk partitions disappeared, cannot mount

The USB partitions were deleted, only sdb remained. sdb1 does not exist. How do I partition the USB again? Now it shows up in the lsblk output, but I can't mount it. [xx@x ~]$ lsblk NAME MAJ:MIN RM ...
alaylihacker's user avatar
1 vote
1 answer
1k views

resize partition overlapping parted

parted -s -a opt /dev/sda "print free" Modèle: VMware Virtual disk (scsi) Disque /dev/sda : 268GB Taille des secteurs (logiques/physiques): 512B/512B Table de partitions : gpt Disk Flags: ...
Peutre's user avatar
  • 97
0 votes
0 answers
232 views

No free sectors available shown by fdisk in centos 7 minimal

This is the output of fdisk /dev/sdb [root@localhost ~]# fdisk /dev/sdb Welcome to fdisk (util-linux 2.23.2). Changes will remain in memory only, until you decide to write them. Be careful before ...
achhainsan's user avatar
4 votes
2 answers
1k views

Recovering accidentally deleted partition on a solid-state drive using "fdisk"

As far as I know, a solid-state drive (SSD) stores data in different locations that the operating system cannot control. If I accidentally delete a partition, and then enter the exact start and end ...
auzyveyauzyvey's user avatar
0 votes
0 answers
609 views

New USB stick freezes processes that come in contact with it (dd, fdisk, gparted, etc)

I bought a new USB stick to upgrade my os (debian) on my laptop. I used gnome-multi-writer to write the .iso file into the device. The writing process never showed a message of success or error so I ...
Laraconda's user avatar
  • 101
2 votes
0 answers
328 views

Recover data from deleted (still intact) raid 5

So through a shell script gone sideways I accidentally deleted my mdadm raid5 (3 HDDs) and the partitions from the disks (so disks still connected according to lsblk as {sdb|sdc|sdd}). I have not ...
50x's user avatar
  • 21
2 votes
1 answer
883 views

Why does free space differ when shown by fdisk and df?

Basically title. I'm running MX Linux from a 32GB live USB. When I run fdisk -l, I see the following: [...] Disk /dev/sda: 29.88 GiB, 32080200192 bytes, 62656641 sectors Disk model: Flash Drive ...
Vavřinec Kubíček's user avatar
1 vote
1 answer
3k views

fdisk command is not listing the required commands like 'a'

I am new to the Linux environment and using the Pop!_OS Distro. I was using fdisk to create partitions on an SD card, sudo fdisk /dev/sda But when I pressed 'a' to set the bootable flag on the 1st ...
Joe Race's user avatar
  • 113
0 votes
1 answer
1k views

Move disk space from /dev/sda3 to /dev/sda4

This is my current setup: Disk /dev/sda: 546.8 GiB, 587127480320 bytes, 1146733360 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/...
Bananas17's user avatar
0 votes
1 answer
1k views

Increasing Volume Group Size without new Disk

On my server (RHEL8) running on vCenter, I have a Volume Group that consists of 1 Disk. I want to increase the Volume Group size without adding a secondary virtual Disk in vCenter. Old Disk size: 50 ...
Armin's user avatar
  • 3
1 vote
0 answers
241 views

Disk Usage Analyzer Shows 100% After Expanding VMWare Hard Disk

I expanded my Hard Disk on my VMWare for this machine to 80GB, installed GParted and expanded the partition. But Disk Analyzer is still showing 100% usage. When I run fdisk -l the output is: Disk /...
Michael Shoe's user avatar
0 votes
2 answers
82 views

Re-allocate space on Centos7 RAID-1 volume from one mount to another

We have a set of Centos7 machines that were configured with 100GB /tmp and 400GB /scratch partitions. The tools we're using are consuming more /tmp space than anticipated so we need to re-allocate ...
srh's user avatar
  • 163
0 votes
1 answer
156 views

fdisk vs. vgdisplay - increase size of VG

After getting error messages that I was running out of disk space, I looked at the disks and found that the output from fdisk (127.101 GiB) did not coincide with the output from vgdisplay (57.43 GiB). ...
undigit's user avatar
  • 51
0 votes
1 answer
1k views

How to mount a sparsed disk image

I have an image of the mSATA SSD disk of a PC. The disk contains the operating system and has a capacity of 512GB. I do not have that free storage, so I have cloned the disk into an image with dd ...
Francisco de Javier's user avatar
1 vote
1 answer
4k views

Increase size of a volume group

I have a 16GB msata but my rootfs is only 4GB. I need to increase the size of a volume group /dev/mapper/vg-var/ for my embedded system to full capacity. $ lsblk NAME MAJ:MIN RM SIZE RO ...
void_brain's user avatar
0 votes
1 answer
43 views

revert logical partitions to original disk

I have a disk that somehow split into what appear to be logical partitions, but I am unsure. How to revert to the original disk? Here is the list of drives shown by fdisk -l: /dev/mmcblk0 /dev/...
colossalchicken's user avatar
1 vote
1 answer
533 views

Use free space to make a new filesystem

How would I go about using 50G of the free space from vg_root to make a new filesystem and then use that for /home nifle@rhel8box3 ~ $ sudo lsblk [sudo] password for nifle: NAME MAJ:MIN ...
Nifle's user avatar
  • 569

1
2 3 4 5
11