Questions tagged [fdisk]

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

Filter by
Sorted by
Tagged with
1
vote
2answers
2k views

fdisk hangs on “Syncing disk” when resizing a raw QEMU image

I'm using fdisk to resize the partitions on a raw QEMU image. When I write the new partition table, it hangs at "Syncing disks." Note that I'm running fdisk as non-root since I don't need root to ...
1
vote
1answer
49 views

Fdisk Error Message

So basically i was messing around in Linux and i wiped the fileystem from a partition with wipefs and then decided to delete this partition (/dev/sda2) so i went on parted and deleted it. After this ...
1
vote
1answer
36 views

Output fdisk bash command to multiline variable

I can't seem to figure out how I can put a fdisk command from a bash script in a multiline variable. Here is my code hdds="$(sudo fdisk -l | grep "Disk /dev/sd" | awk '{print$2}' | sed 's/://g')" ...
1
vote
1answer
46 views

What is the deal with this usb drive with a second block device?

I have a giveaway usb stick and when I plug it into my computer and run lsblk it shows two block devices, i.e. sdb and sdc. sdb of them contains almost all the free space ( ~15G) and the sdc one is ...
1
vote
1answer
276 views

fdisk warning: (Extended) Partition does not start on physical sector boundary

is there a problem if an Extended Partition does not start on physical sector boundary? Partition 4 does not start on physical sector boundary. ... /dev/sda4 639635454 1953521663 ...
1
vote
1answer
60 views

Check for disks added to the system

So I am working a script that basically check if a disk has been added to the system, and if so, then do something with it (like format it or whatever). So, the main question is...how do I list disks ...
1
vote
1answer
455 views

linux gdisk (on 4TB USB drive) followed my mkfs — but mkfs doesn't see new partitions

I just bought two new 4TB external USB disks for backups http://www.bestbuy.com/site/wd-my-passport-4tb-external-usb-3-0-portable-hard-drive-black/5605533.p that came performatted with a single ...
1
vote
1answer
679 views

What is fdisk o option for?

When partitioning a hard drive with fdisk , the o option help says "create a new empty dos partition table". what does this do actually..?
1
vote
1answer
2k views

Using fdisk from a script [closed]

I'm creating an ISO image containing 2 partitions, from a .sh script with: fdisk $image_name <<EOF o n +64M a t c n w EOF Is there a way to do this in a cleaner way via fdisk, avoiding the ...
1
vote
2answers
1k views

Partition disk into two equal partitions in a shell script

I am trying to partition my disk into two equal partitions. So far I was doing everything manually using fdisk command and then modifying fstab file with UUID for both the partitions and I have around ...
1
vote
1answer
208 views

Why aren't sda3 and sda4 displayed with fdsik -l?

I wanted to display all my partitions, so I entered "fdisk -l". AFAIK, the format of the device file for a scsi hard disk reads like: sd_whichharddisk_whichpartition. To my surprise, after hitting "...
1
vote
1answer
1k views

Can't create partition table on SSD with Slackware 14

I'm trying to install Slackware 14 from a DVD. It boots fine from the DVD. When I try to use fdisk or cfdisk to create the Linux and swap partitions on the SSD, it complains about a missing or ...
1
vote
1answer
584 views

“df -h” and “fdisk -l” in amazon server [closed]

When you do a df -h you can see: Filesystem Size Used Avail Use% Mounted on /dev/xvda1 7 . 9G 1.7G 6.2G 22% / But, when you do fdisk -l you see: Disk /dev/xvda1: 26.8 GB, 26843545600 bytes 255 ...
1
vote
1answer
41 views

How to enlarge this partition?

Inside vmware ESXI I have a CentOS virtual machine, and I resized the virtual disk from around 30 GB to 120 GB using vmware "edit" vm menu. Then I booted using a gparted bootable ISO and resized the ...
1
vote
1answer
80 views

How to change zram sector size?

I have cloned a disk into a sparse file that is about 80G but indeed requires only about 12G, even not compressed it fits on my memory, but in order to save some resources I want to use zram: sudo ...
1
vote
1answer
2k views

Change disk type from Microsoft Basic to Linux filesystem

I'm not clear where this is coming from and although it seems cosmetic I would like to change my disk type from Microsoft Basic to Linux filesystem WARNING: fdisk GPT support is currently new, ...
1
vote
1answer
62 views

Whole disk is a partition: can't shrink, can't create new one

When I set up arch linux, I created a partition with fdisk, and ran mkfs.ext4 on /dev/sda. Now, I want to partition /dev/sda to have 2 partitions, instead of just one. The problem is, that when I try ...
1
vote
1answer
509 views

Corrupted SD card is readonly and not mounting

I'm having issues trying to recover a corrupted micro-SD card (not the data, just the card). I think it was formated to be part of the internal storage of an Android phone when that was an option. # ...
1
vote
2answers
60 views

How to read the output from an interactive program without it scrolling off the screen?

I am running fdisk on a device and I'm trying to list the supported partition types. The problem is that it immediately scrolls off the screen and I can't see it. I was using the latest Fedora on ...
1
vote
2answers
3k views

Make parted start next partition after previous one - automatically?

I've inherited a shell script that pipes a list of 'random' characters to fdisk. What it is doing is partitioning a disk as follows: Set up the blank disk, partition table etc Create first partition ...
1
vote
1answer
128 views

executing parted triggers udev, fdisk does not

I'm in a server environment (RHEL 7.2 or thereabouts) and I noticed that my udev rules get invoked (creating my custom symlinks) when I run parted print, even if I'm just listing partitions. When I ...
1
vote
2answers
321 views

how to display and add partition in the SUN solaris OS?

how to display and add partition in the SUN solaris OS? Linux version is uname -a SunOS SMS 5.10 Generic_141414-02 sun4v sparc SUNW,Netra-T2000 #fdisk -l fdisk: illegal option -- l Usage: fdisk [ ...
1
vote
1answer
6k views

Can't format disk with mkfs command on CentOS 7

Followed this guide to add a new disk: https://www.tecmint.com/add-new-disk-to-an-existing-linux/ That's become /dev/sdb. After run fdisk /dev/sdb to do the partition. Check again: fdisk -l Disk /...
1
vote
1answer
805 views

fdisk -l + how to read output

what is the meaning of "*" from fdisk -l command , regarding sda1 ? fdisk -l | grep /dev | grep "*" /dev/sda1 * 1 4294967295 2147483647+ ee GPT /dev/sdb1 * 2048 1050623 ...
1
vote
1answer
106 views

FDisk Not Extending to Full Amount after LVM resize

I'm using VMWare vSphere 5.1.0 Client to extend this VM's hard drive size from 5GB to 10GB. I've done that in the client and it's shows up in vSphere: Fdisk does recognize the new hard drive size: ...
1
vote
1answer
2k views

Where to get information on failed disk?

I have a disk inside my server which has failed and I'm trying to figure out which one it is. I did not make a list of all serial numbers as I should have. I plan on doing this but in the meantime, ...
1
vote
2answers
671 views

I have killed my HDD

I have some trouble with my external USB 3.0 drive with 1Tb HDD. I had formatted it wrong way: I wrote /dev/sdb instead /dev/sdb1, and now I have no ability to use this drive. fdisk /dev/sdb fdisk: ...
1
vote
1answer
63 views

Mount all connected drives to their own respective mount points

How can I mount every single hard drive connected to a computer (preferably excluding flash drives and CDs) to it's own mount point. For example, if my connected drives looked like so: DISK ...
1
vote
1answer
942 views

How to renumber partitions

I've seen posts in the past that advise against changing the partition number but like Fox Mulder: " All the evidence to the contrary is not entirely dissuasive " I have an old MBR disk that I used ...
1
vote
2answers
372 views

LVM Drive partitions missing

I have a 4 drive LVM PV Group. I had one drive fail (Ok, I broke it installing it in a new case.) so I swapped it for another drive and recovered the remaining data. After a reboot I got stuck at a ...
1
vote
1answer
395 views

Partition system id FDISK

if I change a partition system id to FAT16 with fdisk and make another file system such as ext2 on that partition with mkfs what is problem? every thing is ok ! so what does (partition system id) do?
1
vote
1answer
123 views

Which raid drive is available to mount?

I have a Centos 7 system with 4 drives installed. They are setup in the bios as 2 mirrored pairs. When the system was installed, the default installation only saw one of the pairs and installed on it....
1
vote
1answer
12k views

can't see disk partition /dev/sdb in linux

I did a successful partition for a new volume /dev/sdb. After that I mounted it in /etc/fstab. The thing is that I can't see /dev/sdb volumes along with /dev/sda volumes using df -h command nor with ...
1
vote
3answers
3k views

My SD card has a partition but Linux doesn't create a device entry for the partition

OK, I don't know what's going on here, at first I thought it was a problem I remember having some time ago where I couldn't mount a vfat partition because it had some flag set that it had not been ...
1
vote
1answer
1k views

HDD Won't connect / system won't read it. Not sure what dmesg output means`

I have a hdd that I pulled from an old windows laptop, I don't think there's any information on it that I want to keep. I was going to format it to ext4 or something. Yesterday when I connected and ...
1
vote
1answer
304 views

Replacing a partition within a .img with another one

I have 2 .img files (embedded Linux images, each with 2 partitions- a boot partition and a rootfs). I need to replace the rootfs partition in one with the other's. How can I do this In the .imgs ...
1
vote
2answers
1k views

Cannot mount external USB drive

I'm on Debian Jessie and I have an external USB drive with NTFS. I plugged it into my Raspberry Pi, which then spontaneously restarted (probably the power consumption was too high for the adapter I'm ...
1
vote
1answer
109 views

Are partition tables always required? [duplicate]

So I have a home server with 4 hdds: hdd1: 60Gb (SSD - OS drive) hdd2: 4TB (data drive) hdd3: 2TB (data drive) hdd4: 1TB (data drive) So I intend installing ubuntu server onto hdd1 (ssd drive)...
1
vote
1answer
6k views

pvcreate error on partition

I can't create this partition, I'm getting this error shown below: Device /dev/mapper/vg_paperino-lv_rootp1 not found (or ignored by filtering) Below are the steps that I'm doing on CentOS: [root@...
1
vote
1answer
885 views

How to realign a disk on logical volume with minimum to zero down time

A system running un-align disk partition that needs to be aligned without loss of data on all the partition including mbr with the minimum to no down time.
1
vote
2answers
1k views

Fdisk partition alignment, NAND, not showing specified heads

I ran fdisk with these options, fdisk -H 32 -S 32 /dev/sdc Then I made a new label, and created an aligned first partition. Disk /dev/sdc: 7743 MB, 7743995904 bytes 32 heads, 32 sectors/track, ...
1
vote
1answer
2k views

Adding a populated existing disk device to a QEMU raw image

I have a raw QEMU image (vda.raw), and I would like to resize it and add an existing partition, using data I have in a file that contains a raw ext3 file system populated with data (vdb.raw). The two ...
1
vote
2answers
45 views

Mapping between EC2 volume and your mounted filesystem

I am running out of space on a particular filesystem. I know this with the following command df -H $ sudo df -H Filesystem Size Used Avail Use% Mounted on udev 4.1G ...
1
vote
1answer
728 views

Adding brick volume to gluster fails

I created a 2TB volume to increase space on home directory. I created the partition: $ parted /dev/xvdb mklabel gpt $ parted -s /dev/xvdb mkpart primary ext4 1 100% Formatted the partition: $ mkfs....
1
vote
0answers
412 views

Problem mounting and reading hard disk

I am trying to read the content of a 1Tb external disk. The device was part of an external nas (dlink 320) using raid 1. when I plug the hard disk using the usb port no partition is mounted. The ...
1
vote
0answers
274 views

Want to allocate space to centos-root folder

Below is my df -h output [root@dpnjsv2-centos7-base logs]# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/centos-root 12G 9.8G 1.6G 87% / devtmpfs 2....
1
vote
0answers
6k views

Inaccessible drive with the message: unknown filesystem type '(null)'

Short story: A disk with partitions sdb1-sdb4 and filetype ext4 now shows up as sdb with no file type. While trying to mount sdb I get the messages: mount: /dev/sdb is write-protected, mounting read-...
1
vote
2answers
3k views

FDISK doesn't show any partitions for a disk, trying to resize an LVM disk, running CentOS

This particular system is acting peculiar and i've not seen this before. System is running CentOS and is a VM on VMWare. I increased the space on the drive from 100GB to 130GB. When I went in to the ...
1
vote
0answers
30 views

Problem mounting NTFS disks

I had initially gotten good results in using /etc/fstab to specify mounting points for my hard disks. But after meddling around with folder permissions, my disks refused to mount. What I was doing: ...
1
vote
0answers
117 views

Arch Windows dualboot: fdisk only lists liveusb?

I'm trying to dual boot windows 10 (secureboot disabled, uefi enabled) with arch. I used the disk management utility in windows to set aside some space for linux, but when I boot the liveusb and run ...