3
votes
1answer
21 views

How do I change the OS block size

I am using SUSE 11SP3 and formatted the devices with a block size of 4KB using mkfs.ext3. /sys/block/sda/queue/logical_block_size and /sys/block/sda/queue/physical_block_size show the OS is using 512 ...
1
vote
1answer
33 views

The libblkid library: any way to use it with blocks in the core memory?

I know how to use the libblkid library to analyze existing block devices. I'd like to use it to analyze a memory extent before I write it to the block device. Something like that: char block[4096]; ...
2
votes
1answer
52 views

The libblkid library: what is the 'blkid_superblocks_get_name' function for?

I'm trying to use the libblkid library to analyze various filesystems on a block device from a C/C++ program, and it works well. However I'm confused with the blkid_superblocks_get_name function from ...
0
votes
1answer
98 views

What disk is a file / directory stored on? [duplicate]

From the command line (bash) I would like to know what disk a given file is stored in. E.G.: $ [what filesystem is this file in command] /tmp/example/file /dev/sda1
3
votes
1answer
636 views

Finding all partitions with filesystems

I'm writing a script that will copy all of the files on a device to a directory. The problem is that some of the devices have multiple partitions and some of the partitions don't have filesystems to ...
8
votes
1answer
193 views

How to re-size partitions in a complete hard drive image?

I have taken a complete image of a hard drive using: dd if=/dev/sda of=/home/user/harddriveimg bs=4M It would seem to me, that I should be able to re-size the partitions within it after suitably ...
7
votes
2answers
2k views

Find filesystem of an unmounted partition from a script

I'm writing a custom automated install using AIF (Arch Installation Framework), and I need to find the filesystem on a partition given a partition. So far I have this: grok_partitions () { local ...
9
votes
4answers
1k views

Is there a way to sync only one partition?

Is there a way to sync only one partition instead of all partitions? Something like "sync /dev/sdc1".