Questions tagged [vfs]
38 questions
7
votes
2 answers
Linux cache evictions
Looking at how the VFS cache on my Linux machine behaves, I can see that even when effectively idle (crond and most other daemons stopped, interfaces down) the amount of free memory gradually increases implying that items are being evicted from the…
symcbean
- 5,008
- 2
- 25
- 37
5
votes
3 answers
confused about dd write speed and VFS page cache
After reading some articles on the Linux VFS page cache and the tunable parameters like dirty_ratio i was under the impression that page cache would operate as both read and write caching layer.
But using the simple test below it works well to…
Flo Woo
- 233
- 1
- 3
- 7
5
votes
1 answer
How do I temporarily extract a flash drive or HDD in Linux?
Suppose I mounted a disk in this way:
mount /dev/sdb /mnt/tmp
I have some files opened on this filesystem and don't want to unmount it. However I want to temporarily extract the device, then reattach it later. I want all reads and writes to this…
Vi.
- 5,528
- 7
- 34
- 68
4
votes
2 answers
Is file creation totally ordered?
On Linux, the openat syscall can be used to create files and to test for their existence. Speaking in terms of the C/C++ memory model, creating a file and verifying its existence creates a synchronizes-with relationship. What I need to know is…
Kaz Wesley
- 51
- 4
4
votes
0 answers
How does Linux resolve pathnames with the help of the dentry cache?
While dealing with the Virtual Filesystem of Linux I have come across a little problem of understanding how pathnames are resolved if they are already cached as dentries in the dentry cache.
I know that the different dentries are organized in a hash…
idlmn89
- 225
- 1
- 5
3
votes
0 answers
Tool for dumping Linux VFS superblock
From the dumpe2fs man page:
dumpe2fs prints the super block and blocks group information for the filesystem present on device.
So dumpe2fs will dump the filesystem superblock. Is there any such tool to dump the Linux VFS superblock (i.e. in-memory…
Suku
- 163
- 5
2
votes
1 answer
Usage and role of s_pins field in the VFS superblock
I study with details the structure of the VFS superblock and I noticed the field
struct hlist_head s_pins;
Even though I made an extensive search it was not possible to find info about this. I only found that this is defined and used in fs_pins.c…
Athanasios Margaris
- 129
- 6
2
votes
0 answers
How Linux system knows what files/subdirectories are under one directory
I'm reading the book "Linux Kernel Development", and there are some important points:
inode doesn't include filename.
filenames are stored in directory entry(dentry).
but dentry is not stored on disk, it's dynamic generated.
Unlike the previous…
Ethan Xu
- 121
- 4
2
votes
2 answers
Where does the file size comes from, i.e. , how does ls and cp know the file size?
Recently I had a file that reported a file size of 33P bytes in my 500GB SSD, more details here. That was through ls and cp would report that there was no enough space.
In my short knowledge and poor understanding of VFS, I would believe that the…
user3325563
- 41
- 3
2
votes
2 answers
How do I run the usermode linux kernel?
I followed the steps here and compiled the kernel successfully in usermode:
https://btrfs.wiki.kernel.org/index.php/Debugging_Btrfs_with_GDB
But when I start ./linux in various ways it always gives me a very similar error:…
Blub
- 165
- 1
- 6
2
votes
0 answers
Which subsystem caches file reads?
I am trying to understand how exactly file reads are served from Page Cache. This will be useful when I will be implementing my own filesystem in the kernel.
Is file content cached by VFS or filesystem or block device?
Where in kernel source…
ArekBulski
- 443
- 2
- 15
2
votes
0 answers
New inode when mounting new file system
Does kernel really create any new inode when some file system gets mounted on some directory of root file system? I don't expect it to create as there is no new files are being created. Is there some soft link being created? I've read that…
Vishal Sahu
- 273
- 1
- 7
2
votes
1 answer
Docker in Crouton - VFS consuming astronomical amounts of space
I'm attempting to help out a roommate who has installed Kubuntu on his Chromebook using Crouton (it's basically just a fancy chroot run within ChromeOS).
I helped him get the Docker daemon running, using some advice from this issue on the Docker…
Wieschie
- 123
- 4
2
votes
1 answer
How do I merge (without copying) two directories?
I have:
$ find 1 2 -printf '%i %p\n'
40011805 1
40011450 1/t
40011923 1/a
40014006 1/a/e
40011217 1/a/q
40011806 2
40011458 2/y
40011924 2/a
40013989 2/a/e
40013945 2/a/w
I want:
any 2
40011450 2/t
40011458 2/y
any …
Vi.
- 5,528
- 7
- 34
- 68
1
vote
0 answers
Limiting the total size of samba's vfs_recycle by pruning oldest deleted files first
Running SerNet Samba 4.0.9 on CentOS 6.4 serving as an AD DC and fileshare for XP clients.
Added recycler per the example here.
My concern is that the recycle dir will eventually grow large. vfs_recycle's docs mention a parameter for limiting…
Kev
- 1,729
- 4
- 27
- 47