linux系统的4个部分,以下是Linux文件系统的4个相关的结构定义中的一部分: Struct i..._考试资料网...
問答題為了實現文件的共享,辦法之一是把文件目錄分成基本文件目錄和符號文件目錄。現設目錄文件存放在磁盤上,盤塊長度為1024B,每個文件說明占48B。其中,文件符號名占6B,內部標識符ID占2B,請回答下列問題:以下是Linux文件系統的4個相關的結構定義中的一部分:
Struct inode{
struct list_head i_hash;
struct list_head i_denty;
unsiqned long 0 i_ino;
unsigned int i_count;
kdev_t i_dev;
umode_t i_mode;
off_t i_size;
time_t i_atime;
time_t i_mtime;
time_t i_ctime;
unsigned long i_blksize;
unsigned long i_blocks;
union{
struct ext2_inode_info ext2_i;
}u;
};
struct ext2_inode_info{
_u32i_data[15];
_u32i_flags;
};
struct denty{
int d_count;
struct inode *d_inode;
/*where the name belongs to-NULL is negative*/
struct dentry *d_parent; /*parent directory*/
struct list_head d_hash; /*lookup hash list*/
unsigned char d_iname{DNAME_INLINE_LEN}; /*small name*/
};
Struct 1ist_head{
struct list_head*next, *prev;
};
1)請描述這些結構的作用和相互關系。
2)根據這些結構,請描述文件的物理結構。
3)基于這些結構,請設計至少4條有關文件系統功能調用的實現。
總結
以上是生活随笔為你收集整理的linux系统的4个部分,以下是Linux文件系统的4个相关的结构定义中的一部分: Struct i..._考试资料网...的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Android获取LAUNCHER,An
- 下一篇: diff命令两个服务器文件,linux