Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [block-device]

Block devices are a specific type of Unix device node, typically representing storage devices such as hard drives, CD-ROMs, etc.

-1
votes
1answer
30 views

Find mount point by device UUID

I have device UUID like from blkid: /dev/sda1: UUID="5db99adc-11d3-482d-af80-1985dac704b1" TYPE="ext4" PARTUUID="000f2b58-01" I search a tool which I can give 5db99adc-11d3-482d-af80-1985dac704b1, ...
1
vote
1answer
38 views

Dont use /dev/sd* for removable device

Today I almost erased my system with dd because I was going to write on my internal HDD (/dev/sdb*) instead of the removable usb (/dev/sdc*). I want to make a udev rule to set any block usb under a ...
0
votes
1answer
24 views

Btrfs check repair give device busy. How to see what it keeps busy?

I am in a chicken-egg situation for my secondary harddrive (non boot): My BTRFS mount has gone readonly because no space left. btrfs filesystem resize only works on mounted volumes. I needed to ...
0
votes
0answers
25 views

Hard drive not visible during Linux Mint installation

I had successfully installed Linux Mint 19 on my new Dell laptop at work. It was working fine, in general, though it did not shut down properly. I'd seen somewhere a video driver might be responsible, ...
2
votes
1answer
41 views

Documented size of Linux kernel partition sector size in bytes

My primary question is to authoritatively see if the block size used in sector counts: /sys/block/<disk>/<partition>/size is in fact 512 B, or if this can vary. I thought this would be ...
0
votes
0answers
27 views

Does Linux offer any way to force-unmount or disable a file system or block device on I/O error?

I've just learned that ext4's errors=remount-ro doesn't remount the file system read-only on errors. It remounts on file system metadata errors. So it cannot be trusted to take the FS offline if there'...
0
votes
2answers
698 views

How to tell if linux disk is READ ONLY

I have a sata disk on module which has a hardware switch which can lock the disk from being written in a READ ONLY MODE. Is there a way to tell in software whether or not that switch has been switched ...
2
votes
1answer
913 views

Why is there both character device and block device for nvme?

I am trying to understand the configuration of nvme. But I do not understand why there are two devices: nvme block and nvme character device: crw------- 1 root root 243, 0 Dec 12 16:09 /dev/nvme0 ...
0
votes
1answer
55 views

Cannot format a drive once used in a ZFS pool

I have created a ZFS test pool with a drive - now I have pulled thet drive out and want to format it to EXT4 and use it outside of ZFS. I think the pool wasn't properly destroyed. Now when I plug the ...
0
votes
1answer
97 views

Why is dmsetup failing when I try to create a snapshot?

I would like to create a COW device for an existing block device using dmsetup. The block device is: # blockdev --getsz /dev/loop0 3534848 I am trying to use a 256M ramdisk as the backing store: # ...
0
votes
0answers
100 views

why list of disks not printed with order from sfdisk or fdisk commands

we notice about this problem in last few days on one redhat machine ( version 7.2 ) we notice that order of the disks isn't according to the right order note - sda is the OS instead to get the ...
1
vote
2answers
98 views

Understanding stat, du and ls -l output on my nfs mount

ls -l f.txt -rwxrwxr-x 1 abc abc 1161 Sep 1 02:02 f.txt stat f.txt File: `f.txt' Size: 1161 Blocks: 34 IO Block: 524288 regular file Device: 38h/56d Inode: 6448956669 Links: 1 ...
0
votes
2answers
485 views

Read Ahead value automatically getting updated at boot

OS version: CentOS Linux release 7.2.1511 (Core) I have the following commands in my rc.local file: /usr/sbin/blockdev --report > /root/test_boot /usr/sbin/blockdev --setra 256 /dev/vdb /usr/sbin/...
2
votes
1answer
130 views

How to know if some data already exists on a device disk?

The simple way to check if disk include filesystem is to do: mount /grid/sdb /mnt and if sdb or other /dev/sdx have file-system then mount will be succeeded, if not. Probably file system exists! ...
-4
votes
1answer
958 views

cat /dev/zero | pv > /dev/null [closed]

cat /dev/zero | pv > /dev/null What exactly happens here and what determines the speed of this process. Even on low end hardware you get a couple of GB/s transfer speeds like this.
0
votes
2answers
142 views

GCE Persistent Disk block sized writes data integrity

The block size for a SSD Persistent Disk appears to be 4096 bytes. If I write aligned blocks of 4096 bytes directly to the block device (/dev/sdb with O_DIRECT and posix_memalign), are these writes ...
0
votes
2answers
3k views

USB Mass Storage recognized, but SCSI block-device not showing up

The block-device of a USB mass storage does not show up in Ubuntu 16.04, while I positively can see it in Ubuntu 14.04. Question: How can I make it show up in Ubuntu 16.04? NOTES: Both machines are ...
4
votes
2answers
437 views

Tool to visualize linux block devices (partitions, LVM PVs, LVs, mdadm devices…)

I'm looking for a tool that will scan my GUI-less server and create an easy to digest rough overview of all the block devices and their relationship (disk partitions, mdadm devices, LVM PVs & LVs ...
2
votes
2answers
820 views

How to query DRBD device size?

To write Ansible script to setup DRBD device and file systems, I face the following issue: # blockdev --report /dev/drbd0 RO RA SSZ BSZ StartSec Size Device blockdev: cannot ...
0
votes
1answer
954 views

Give a VM access to a whole disk with the least overhead with qemu-kvm

I'm moving a Windows 10 install from dedicated hardware to a KVM VM. The disk (SSD) is being physically moved from the current machine to the VM host machine. Is there a way to just pass the entire ...
1
vote
1answer
130 views

Why is an EC2 AWS instance showing an extra block device?

I'm using aws cli's autoscaling to create EC2 instances. Despite only having two device mappings in my launch config, the resulting instances have an additional device. The pertinent map Json: "...
0
votes
0answers
39 views

No w/s in iostat output even though wMB/s is high

I am trying to format a 2 TB SAN based block device (/dev/mapper/mpathb). Even though, mke2fs has been running since over one hour without completing, iostat -z -x -m 10 output in a separate terminal ...
3
votes
1answer
1k views

Units for size in /proc/partitions don't make sense

I have a Seagate 750GB drive. Parted shows the drive as 750GB parted /dev/sdc print Model: ST375064 0AS (scsi) Disk /dev/sdc: 750GB Sector size (logical/physical): 512B/512B Partition Table: gpt ...
-1
votes
1answer
40 views

Is there a standard file extension for block device image files

Block device image files are just a large contiguous set of blocks for the device they are emulating. I realize that file extensions are more for the user and that generally on Linux operating systems ...
0
votes
1answer
402 views

Where does blkid get its information from? (/dev/block/ showing up in blkid output)

I have a CentOS 7 box that is acting very strangely. On first boot, typing "blkid" produces: [BurnC7 (2015-12-17 22:00:25) ~]# blkid /dev/block/8:3: UUID="c83f7479-4bc1-44e5-84ae-e38a83e75219" TYPE="...
1
vote
2answers
1k views

How to tell mdadm to use a partition as/instead of a block-device?

I have four 500GB disks which were set up as a Linux Software-RAID 5 volume during the Debian install (next to the system drive which is a SSD). One of the drives (sda) went bad and now I am trying to ...
1
vote
1answer
467 views

Proper way to identify member devices in mdadm.conf

My current mdadm.conf looks like: $ cat /etc/mdadm/mdadm.conf DEVICE /dev/sdb1 /dev/sdc1 ARRAY /dev/md0 metadata=1.2 spares=0 UUID=357ff7cc:55e78d18:9fc7917b:f5b253f2 MAILADDR me@example.com Since ...
1
vote
2answers
411 views

Is there a way of relating the raid units with the os devices in 3ware?

I got a linux server recently with a 3ware raid. It has several volumes (/c4/u*/v*) that are seen by the OS as devices (/dev/sd*) I can roughly relate those units with the devices because of their ...
0
votes
1answer
441 views

How to have automatic file system checks for Linux Software Raid?

In a Linux Software raid, what is the best practice for periodically having the filesystems checked? With single drive or hardware raid, tune2fs -c 5 -i 1w /dev/sda1 means check the filesystem every ...
4
votes
1answer
234 views

Why is my HDD partition a character special device?

I have a bunch of old 1T disks with an mdadm array on them. They had been out of commission for awhile, but yesterday I slotted them into a server running an up to date Debian Jessie. Eventually I ...
4
votes
2answers
7k views

Readahead for /var/lib/mongo is set to 4096KB

I'm trying to set the readahead for mongo 256 or less as recommended, I looked at the documentation for any guidance and I found this: Ensure that readahead settings for the block devices that ...
6
votes
1answer
654 views

Is it possible to calculate where is, physically, a bad block located on a hard disk?

I dd_rescue'd a hard drive, and I know where the bad blocks are. I still have the drive with me, so I can get any information needed from SMART or fdisk. I would like to know if it is possible to see,...
1
vote
2answers
1k views

XenServer move VM Failed

We currently are running our XenServer virtual machines off of an over extended Drobo unit and wanted to migrate a particular 600+GB VM off of the Drobo onto a newer Drobo, so I attached a storage ...
4
votes
1answer
21k views

Whole block device named xvda1, xvda2 instead of xvda, xvdb

I am working on a VM that was set up for me in a public cloud. It's running under the Xen hypervisor in paravirtualized mode and has two virtual disks. So I expect the virtual disk block devices to be ...
0
votes
1answer
888 views

How to auto mount 2nd drive on boot in Windows Azure on linux?

I'm currently programming a website and it's connecting to Ubuntu 12.04 linux VM on Windows Azure for database connections. The issue I'm having is that if the VM is restarted the attached disk I ...
2
votes
0answers
277 views

Partition block size different from device's and stacked LVM volumes ones

I have a pair of HP ML350 G6 servers with LSI MegaRAID 9266-4i+CacheVault driving Supermicro CSE836E16 enclosures via SAS bracket, filled with WD RE 3TB SATA drives. On these are configured a RAID10 ...
2
votes
1answer
333 views

Linux device names: What other non-standard storage device names are there apart from /dev/cciss

This is a question about Linux storage device names on RHEL5 and RHEL6 Most storage devices are accessible using device names /dev/sda, /dev/sdb, etc. By storage device I mean a device that could be ...
0
votes
1answer
138 views

Copy tape device files

I've just exchanged tape drives between machines (both Unix Tru64). The device files aren't working now, and I have to do some work with them (will generate a different question). I created a ...
2
votes
1answer
1k views

Multi-Generation Snapshots using Device Mapper (Linux)

LVM is an amazingly useful tool, however, it seems to still lack support for snapshotting a drive that is already a snapshot. I made a script to handle this automatically but ran into some troubles. ...
40
votes
5answers
8k views

Intentionally cause an I/O error in Linux?

Is there anyway, with Linux, to purposely cause a block device to report an I/O error, or possibly simulate one for testing purposes?
2
votes
1answer
105 views

Are blocks that are read from LVM kept in Linux's block cache?

Does Linux keep blocks that are read from an LVM logical volume in the block cache as it does with blocks read from a "regular" block device or is the IO direct? Also, do the usual buffering ...
1
vote
3answers
5k views

Possible to set size of ram disk?

When I do yum install MAKEDEV MAKEDEV ram fdisk -l /dev/ram I get the that it is 16MB. I am using MAKEDEV to get a block-device instead of tmpfs. Question Is it possible to set it to e.g. 1GB?
1
vote
2answers
3k views

Scanning for new disks attached using virtio?

I can successfully attach disks to a running KVM instance using virsh attach-disk... virsh attach-disk node-1 /dev/vg_lunsr/lun1 vdb Disk attached successfully ...but these new devices aren't seen ...
6
votes
2answers
214 views

Accessing the partitions on an LVM volume

Suppose you have an LVM volume /dev/vg0/mylv. You have presented this as a virtual disk to a virtualised or emulated guest system. During installation the guest system sees it as /dev/sda and ...
6
votes
1answer
2k views

What effect does RAID stripe size have on read-ahead settings?

I'm trying to figure out the correct read-ahead values to set on a RAID10 array, and I'm wondering if the RAID stripe size should factor into my considerations. I've heard conflicting information ...
26
votes
3answers
18k views

Readahead Settings for LVM, Device-Mapper, Software Raid and Block Devices - what wins?

I've been trying to find a straight answer on this one, and it has proved elusive. This question and its answer is close, but does not really give me the specifics I would like. Let's start with ...
3
votes
1answer
1k views

Making NFS behave like a block device

We're currently working on a virtualization setup, and because of features like being able to grow volumes on our filers rather than having to go through the process resizing block devices etc. we'd ...
12
votes
5answers
13k views

Is DRBD the only viable block replication solution for Linux?

I've found myself needing redundant storage at a block level. File-level replication (Gluster, GFS, etc) does not work for my use case. It looks like DRBD is the go-to solution for block replication....
8
votes
1answer
4k views

Xen 4.1 host (dom0) with blktap disks (“tap:aio:”) not connecting

Problem using blktap with xen-4.1 running Ubuntu Precise stock kernel with dom0 xen-4.1. I get: [ 5.580106] XENBUS: Waiting for devices to initialise: 295s...290s. ... [ 300.580288] XENBUS: ...
6
votes
3answers
2k views

Seeking distributed, fault-tolerant, networked block storage [closed]

I'm looking for a distributed, fault-tolerant network storage system which exposes block devices (not filesystems) on the clients. A client's block device should write simultaneously to several ...