Are partition and filesystem specified and identified in the same ways?
How is a filesystem identified or specified? Some commands such as resize2fs
expect a filesystem as an argument. The mount directory of a file system doesn't work.
Does name such as /dev/sda3
identify/specify a partition or a filesystem? I thought that /dev/sda3
specifies/identifies a partition (as seen in the output of fdisk -l
), instead of a filesystem, but it works as a filesystem argument to resize2fs
.
Generally, are partition and filesystem specified and identified in the same ways?
Thanks.
$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.9G 0 3.9G 0% /dev
tmpfs 788M 1.5M 786M 1% /run
/dev/sda3 260G 16G 231G 7% /
tmpfs 3.9G 542M 3.4G 14% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/sda4 550G 323G 199G 62% /home
tmpfs 788M 52K 788M 1% /run/user/1000
tmpfs 788M 4.0K 788M 1% /run/user/1001
$ sudo fdisk -l
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 31254527 31250432 14.9G Linux swap
/dev/sda3 1398441984 1953523711 555081728 264.7G Linux filesystem
/dev/sda4 226566144 1398441983 1171875840 558.8G Linux filesystem
Partition table entries are not in disk order.
$ sudo parted -l
Model: ATA ST1000LM014-1EJ1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 1049kB 2097kB 1049kB bios_grub
2 2097kB 16.0GB 16.0GB linux-swap(v1)
4 116GB 716GB 600GB ext4
3 716GB 1000GB 284GB ext4
filesystems partition
add a comment |
How is a filesystem identified or specified? Some commands such as resize2fs
expect a filesystem as an argument. The mount directory of a file system doesn't work.
Does name such as /dev/sda3
identify/specify a partition or a filesystem? I thought that /dev/sda3
specifies/identifies a partition (as seen in the output of fdisk -l
), instead of a filesystem, but it works as a filesystem argument to resize2fs
.
Generally, are partition and filesystem specified and identified in the same ways?
Thanks.
$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.9G 0 3.9G 0% /dev
tmpfs 788M 1.5M 786M 1% /run
/dev/sda3 260G 16G 231G 7% /
tmpfs 3.9G 542M 3.4G 14% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/sda4 550G 323G 199G 62% /home
tmpfs 788M 52K 788M 1% /run/user/1000
tmpfs 788M 4.0K 788M 1% /run/user/1001
$ sudo fdisk -l
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 31254527 31250432 14.9G Linux swap
/dev/sda3 1398441984 1953523711 555081728 264.7G Linux filesystem
/dev/sda4 226566144 1398441983 1171875840 558.8G Linux filesystem
Partition table entries are not in disk order.
$ sudo parted -l
Model: ATA ST1000LM014-1EJ1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 1049kB 2097kB 1049kB bios_grub
2 2097kB 16.0GB 16.0GB linux-swap(v1)
4 116GB 716GB 600GB ext4
3 716GB 1000GB 284GB ext4
filesystems partition
resize2fs
expects a device as an argument, not a filesystem;Usage: resize2fs [-d debug_flags] [-f] [-F] [-M] [-P] [-p] device [new_size]
– Stephen Harris
Feb 20 at 22:56
Actually, you can't specify a not-mounted filesystem in any way. They're block devices happens to contain a filesystem. Usually people would like to have a partition contain no filesystem (like swap or bios_grub or whatever) or one filesystem of exactly the same size. But… Linux always provides you the way to screw all the laws, right?
– 炸鱼薯条德里克
Feb 21 at 7:34
@炸 Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition? For a mounted filesystem, can we specify it by either specifying its underlying partition or its mount point?
– Tim
Feb 21 at 19:20
add a comment |
How is a filesystem identified or specified? Some commands such as resize2fs
expect a filesystem as an argument. The mount directory of a file system doesn't work.
Does name such as /dev/sda3
identify/specify a partition or a filesystem? I thought that /dev/sda3
specifies/identifies a partition (as seen in the output of fdisk -l
), instead of a filesystem, but it works as a filesystem argument to resize2fs
.
Generally, are partition and filesystem specified and identified in the same ways?
Thanks.
$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.9G 0 3.9G 0% /dev
tmpfs 788M 1.5M 786M 1% /run
/dev/sda3 260G 16G 231G 7% /
tmpfs 3.9G 542M 3.4G 14% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/sda4 550G 323G 199G 62% /home
tmpfs 788M 52K 788M 1% /run/user/1000
tmpfs 788M 4.0K 788M 1% /run/user/1001
$ sudo fdisk -l
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 31254527 31250432 14.9G Linux swap
/dev/sda3 1398441984 1953523711 555081728 264.7G Linux filesystem
/dev/sda4 226566144 1398441983 1171875840 558.8G Linux filesystem
Partition table entries are not in disk order.
$ sudo parted -l
Model: ATA ST1000LM014-1EJ1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 1049kB 2097kB 1049kB bios_grub
2 2097kB 16.0GB 16.0GB linux-swap(v1)
4 116GB 716GB 600GB ext4
3 716GB 1000GB 284GB ext4
filesystems partition
How is a filesystem identified or specified? Some commands such as resize2fs
expect a filesystem as an argument. The mount directory of a file system doesn't work.
Does name such as /dev/sda3
identify/specify a partition or a filesystem? I thought that /dev/sda3
specifies/identifies a partition (as seen in the output of fdisk -l
), instead of a filesystem, but it works as a filesystem argument to resize2fs
.
Generally, are partition and filesystem specified and identified in the same ways?
Thanks.
$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.9G 0 3.9G 0% /dev
tmpfs 788M 1.5M 786M 1% /run
/dev/sda3 260G 16G 231G 7% /
tmpfs 3.9G 542M 3.4G 14% /dev/shm
tmpfs 5.0M 4.0K 5.0M 1% /run/lock
tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/sda4 550G 323G 199G 62% /home
tmpfs 788M 52K 788M 1% /run/user/1000
tmpfs 788M 4.0K 788M 1% /run/user/1001
$ sudo fdisk -l
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 31254527 31250432 14.9G Linux swap
/dev/sda3 1398441984 1953523711 555081728 264.7G Linux filesystem
/dev/sda4 226566144 1398441983 1171875840 558.8G Linux filesystem
Partition table entries are not in disk order.
$ sudo parted -l
Model: ATA ST1000LM014-1EJ1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 1049kB 2097kB 1049kB bios_grub
2 2097kB 16.0GB 16.0GB linux-swap(v1)
4 116GB 716GB 600GB ext4
3 716GB 1000GB 284GB ext4
filesystems partition
filesystems partition
asked Feb 20 at 22:26
TimTim
27.6k78264477
27.6k78264477
resize2fs
expects a device as an argument, not a filesystem;Usage: resize2fs [-d debug_flags] [-f] [-F] [-M] [-P] [-p] device [new_size]
– Stephen Harris
Feb 20 at 22:56
Actually, you can't specify a not-mounted filesystem in any way. They're block devices happens to contain a filesystem. Usually people would like to have a partition contain no filesystem (like swap or bios_grub or whatever) or one filesystem of exactly the same size. But… Linux always provides you the way to screw all the laws, right?
– 炸鱼薯条德里克
Feb 21 at 7:34
@炸 Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition? For a mounted filesystem, can we specify it by either specifying its underlying partition or its mount point?
– Tim
Feb 21 at 19:20
add a comment |
resize2fs
expects a device as an argument, not a filesystem;Usage: resize2fs [-d debug_flags] [-f] [-F] [-M] [-P] [-p] device [new_size]
– Stephen Harris
Feb 20 at 22:56
Actually, you can't specify a not-mounted filesystem in any way. They're block devices happens to contain a filesystem. Usually people would like to have a partition contain no filesystem (like swap or bios_grub or whatever) or one filesystem of exactly the same size. But… Linux always provides you the way to screw all the laws, right?
– 炸鱼薯条德里克
Feb 21 at 7:34
@炸 Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition? For a mounted filesystem, can we specify it by either specifying its underlying partition or its mount point?
– Tim
Feb 21 at 19:20
resize2fs
expects a device as an argument, not a filesystem; Usage: resize2fs [-d debug_flags] [-f] [-F] [-M] [-P] [-p] device [new_size]
– Stephen Harris
Feb 20 at 22:56
resize2fs
expects a device as an argument, not a filesystem; Usage: resize2fs [-d debug_flags] [-f] [-F] [-M] [-P] [-p] device [new_size]
– Stephen Harris
Feb 20 at 22:56
Actually, you can't specify a not-mounted filesystem in any way. They're block devices happens to contain a filesystem. Usually people would like to have a partition contain no filesystem (like swap or bios_grub or whatever) or one filesystem of exactly the same size. But… Linux always provides you the way to screw all the laws, right?
– 炸鱼薯条德里克
Feb 21 at 7:34
Actually, you can't specify a not-mounted filesystem in any way. They're block devices happens to contain a filesystem. Usually people would like to have a partition contain no filesystem (like swap or bios_grub or whatever) or one filesystem of exactly the same size. But… Linux always provides you the way to screw all the laws, right?
– 炸鱼薯条德里克
Feb 21 at 7:34
@炸 Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition? For a mounted filesystem, can we specify it by either specifying its underlying partition or its mount point?
– Tim
Feb 21 at 19:20
@炸 Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition? For a mounted filesystem, can we specify it by either specifying its underlying partition or its mount point?
– Tim
Feb 21 at 19:20
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f501972%2fare-partition-and-filesystem-specified-and-identified-in-the-same-ways%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f501972%2fare-partition-and-filesystem-specified-and-identified-in-the-same-ways%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
resize2fs
expects a device as an argument, not a filesystem;Usage: resize2fs [-d debug_flags] [-f] [-F] [-M] [-P] [-p] device [new_size]
– Stephen Harris
Feb 20 at 22:56
Actually, you can't specify a not-mounted filesystem in any way. They're block devices happens to contain a filesystem. Usually people would like to have a partition contain no filesystem (like swap or bios_grub or whatever) or one filesystem of exactly the same size. But… Linux always provides you the way to screw all the laws, right?
– 炸鱼薯条德里克
Feb 21 at 7:34
@炸 Is it correct that for an umounted filesystem, the only way to specify it is to specify its underlying partition? For a mounted filesystem, can we specify it by either specifying its underlying partition or its mount point?
– Tim
Feb 21 at 19:20