Results 1 to 2 of 2
Hi All,
I am using NetBSD-5.1.
1. I wanted to know what happens internally when we create a file in linux. ( In general )?
The header file STDIO.H present ...
- 01-17-2011 #1Just Joined!
- Join Date
- Sep 2009
- Posts
- 5
What happens internally when we create a file in Linux
Hi All,
I am using NetBSD-5.1.
1. I wanted to know what happens internally when we create a file in linux. ( In general )?
The header file STDIO.H present in "src/include/stdio.h" contains a "FILE" structure with various members like _p, _cookie, etc.
2. I wanted to know how does internally memory gets allocated for them.?
Thanks,
Niks
Bangalore, India
- 01-17-2011 #2
BSD is not Linux but anyway...
I'm not an expert but can give you some direction. The application you are using makes a request to your VFS Virtual File System to save the data.The VFS has a log or table that tells it where the data will fit well. The VFS then makes a request to your hard drive to store it.Linux and maybe BSD do not defragment so there is an application that is run before the data is saved to disk. It checks ahead of time. Part of the O.S updates an inode table that is most likely part of VFS. The part that a user looks at to navagate using the GUI is also updated. I think the two popular Linux File Managers are Dolphin and Nautilus. This is the GUI part that includes paths and menus for the mouse to click on, what the user sees. This is a very vague and non technical view but gives you an out line of how to think of it and what to investigate on your own.
I hope this helps!


Reply With Quote