Hot answers tagged

7 votes

Are hard links for directories possible on ext2/3/4 filesystems?

Directories do have hard links... every time you mkdir a new directory then the .. entry is a link to the same inode as the parent directory. eg $ ls -lid . 23855134 drwxr-xr-x 2 sweh sweh 4096 ...
Stephen Harris's user avatar
7 votes
Accepted

mkfs ext2 ignore number-of-inodes

The number hasn't been ignored, it's been rounded up. It looks like space for inodes are allocated in groups. See in your output: Inodes per group: 1632 When you request 99,000 inodes, that'...
Philip Couling's user avatar
6 votes

Are hard links for directories possible on ext2/3/4 filesystems?

Technically, you can do it, quite easily too: debugfs has a ln command which can create directory hard links. Doing this produces a working file system with multiple directories pointing at the same ...
Stephen Kitt's user avatar
6 votes

How do I know if a partition is ext2, ext3, or ext4?

use -T option to print file system type [root@centos6 ~]# df -T Filesystem Type 1K-blocks Used Available Use% Mounted on /dev/mapper/VolGroup-lv_root ext4 ...
LawrenceLi's user avatar
5 votes
Accepted

what is this “first inode” reported by dumpe2fs?

#11 is the first "non-special" inode, that can be used for the first regularly created file or directory (usually used for lost+found). The number of that inode is saved in the filesystem ...
cg909's user avatar
  • 7,072
4 votes
Accepted

Embedded device, log partition, what file system is more resilient and uses less reads/writes?

You could safely use ext3 with noatime option: then only actual file writes would touch your flash device in write mode. The ext3fs journal is a good thing in case of embedded system that may get ...
Serge's user avatar
  • 8,531
4 votes
Accepted

Why does creating a file need at least five separate disk I/Os in Unix FFS?

Prof. Remzi Arpaci-Dusseau's book Operating Systems: Three Easy Pieces has an aside about file creation: As an example, think about what data structures must be updated when a file is created; ...
muru's user avatar
  • 72.2k
4 votes
Accepted

How exactly is ext2 upwards-compatible?

This depends heavily on how the ext4 filesystem was formatted. Some newer ext4 features (e.g. extents or 64bit) cannot be understood by older ext2 drivers, and the kernel would refuse to mount the ...
LustreOne's user avatar
  • 1,728
4 votes

Is it safe to fsck on critical disk data partition?

Why OS is asking to run fsck? As some point in the past the filesystem was not unmounted cleanly. The system needs you to run fsck to clear up the inconsistencies. What I'm doing wrong? I use ...
Chris Davies's user avatar
3 votes

Making bit identical ext2 filesystems

IMHO this all seems to be made overly complicated. When tar alone seems like the obvious solution. tar can create just about any file system, including cdfs (--options cd9660:*). It will also allow ...
somebody's user avatar
  • 343
3 votes

Embedded device, log partition, what file system is more resilient and uses less reads/writes?

Ext4 wasn't designed for flash media. It can work, and it's a safe value due to the extremely wide usage it gets, but it isn't necessarily the best choice, especially on flash media that doesn't do ...
Gilles 'SO- stop being evil''s user avatar
3 votes
Accepted

"write-once archive": ext2 vs ext4^has_journal vs

I don't agree with the squashfs recommendations. You don't usually write a squashfs to a raw block device; think of it as an easily-readable tar archive. That means you would still need an underlaying ...
Wouter Verhelst's user avatar
3 votes

What is the difference between "inode size" and "Bytes per inode"

Extremely rough filesystem schematic: |_|__inodes__|_______________________DATA_________________________________| inode-ratio/bytes-per-inode = amount of inodes for the DATA area inode-size = size ...
sjas's user avatar
  • 545
3 votes

what is this “first inode” reported by dumpe2fs?

Inode #1 -> #10 are "Reserved". From that reserved block #2 is the "root" directory of the filesystem So #11 is typically the first real inode allocated... and that is probably ...
Stephen Harris's user avatar
2 votes

Ext2 filesystem for /boot partition

summary: ext2 is a bad choice for /boot, since (unless I'm missing something or am very unlucky) it appears to prevent "normal" update of GRUB2. details: Today I was updating a 2010-vintage laptop ...
TomRoche's user avatar
  • 1,275
2 votes

"write-once archive": ext2 vs ext4^has_journal vs

SquashFS is a compressible read-only filesystem that fits your requirements well, has been in the kernel for a few years, and is already widely used (e.g., in LiveCDs). The latest documentation for ...
Vincent Yu's user avatar
2 votes

Mount iSCSI ext2 Linux Partition on FreeBSD 10.2

The ext2fs file system is optional on FreeBSD and needs to be loaded. Add the following line to /boot/loader.conf to have it loaded at boot time: ext2fs_load="YES"
Richard Smith's user avatar
2 votes

Are there two inode tables used in locating the inode of a file in ext2?

The text you quoted is, arguably, sloppily worded.  The master, authoritative inodes for a filesystem are stored in the filesystem.  So, for a filesystem that’s on a disk (in a disk partition), the ...
G-Man Says 'Reinstate Monica''s user avatar
2 votes

Is it safe to fsck on critical disk data partition?

a) Why OS is asking for fsck run. What I'm doing wrong? fsck stands for "file system consistency check". On most systems, fsck is run at boot time if certain conditions are detected. Usually, these ...
Hunter.S.Thompson's user avatar
2 votes
Accepted

Can I use a Linux boot stick to check a windows system?

1: Can I use a Linux boot stick to check the desktop windows partition for viruses and/or rootkits? Yes, you can. Examples include Bitdefender, AntiVirus Live, and numerous others. 2: How is a ...
K7AAY's user avatar
  • 3,796
2 votes

How to format a usb flash drive to Ext2?

There are two steps. First you have to create the partition, then you have to build the filesystem on it. From the CLI as root, the following commands will format, and build a ext2 filesystem on a USB ...
James Aanderson's user avatar
2 votes

why can gnome disks not format ext2 or ext3?

You'd have to ask the gnome developers to be sure, but the gnome project has a general policy of reducing complexity (and choice paralysis) by eliminating choices. My guess is that the reasoning is ...
cas's user avatar
  • 78.3k
2 votes

Making bit identical ext2 filesystems

The answer to your original question is a tool called genext2fs. If you supply the -f switch, then it will create bit-by-bit identical output, given the same input. This is either proven by its own ...
josch's user avatar
  • 355
2 votes
Accepted

Unix ext2 superblock - file system creation date

You are correct writing that the original ext2 superblock specification does not make provision for storing the file system creation date. But leaves 788 bytes Unused starting from offset 236. Unused ...
MC68020's user avatar
  • 7,624
2 votes
Accepted

How are block devices physically addressed in a file system

Do the pointers that are part of the inodes comprise of logical block indices or actual physical addresses? Logical, relative to beginning of the block device that contains the filesystem. then ...
telcoM's user avatar
  • 94.5k
1 vote

Making bit identical ext2 filesystems

You could also try e2image: The e2image program will save critical ext2, ext3, or ext4 filesystem metadata located on device to a file. Despite that by default e2image saves metadata only, it's able ...
Alexey Suslov's user avatar
1 vote

Making bit identical ext2 filesystems

Note: This will not be a full answer; just a partial one, or, at least, a hint I need to be able to run my script that creates the image and have the output be bit-for-bit identical each time. ...
alsjflalasjf.dev's user avatar
1 vote
Accepted

Can files survive partition table and file system recreation?

Yes it's possible if you delete and re-create your partition from the exact same sector. The system does not a "full format" when you create your file system. By the way, you can do the same to extend ...
darxmurf's user avatar
  • 1,132
1 vote

How to calculate the "Inode blocks per group" on ext2 file system?

The inodes are just packed in blocks, both have sizes that are powers of two, so they fit exactly. From these numbers: Block size: 1024 Inodes per group: 1976 Inode size: 128 We get 1024 B/block --...
ilkkachu's user avatar
  • 138k
1 vote
Accepted

What is the most recent technique to implement quotas?

Is the quota approach still in use? Yes it is. Since disks have grown in size, quotas might not be of much worth to common users, but still find their usage in multi-user environment e.g. on servers. ...
Irfan Latif's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible