A file access method, comprising: receiving a file access request from a process, wherein the file access request comprises a file identifier, and the file identifier is used to indicate a to-be-accessed object file; accessing first physical address space according to preset first virtual address space and a preset first mapping relationship between the first virtual address space and the first physical address space storing a file system, wherein the first virtual address space is a part of user space of an operating system, and the first physical address space is a part of memory space; obtaining, from the first physical address space, an index node of the object file according to the file identifier of the object file, wherein the index node comprises information about a file page table of the object file; obtaining the file page table of the object file according to the information that is about the file page table of the object file and comprised in the index node, wherein the file page table records second physical address space of a data page that is of the object file and stored in the first physical address space, and the data page of the object file is used to store file data; allocating second virtual address space to the object file, wherein the second virtual address space is a part of sharing space that is in the user space of the operating system and allocated to all processes, and the second virtual address space is continuous address space; establishing a second mapping relationship between the second physical address space and the second virtual address space; and accessing the object file in the second physical address space according to the second virtual address space and the second mapping relationship. receiving a file access request from a process, wherein the file access request comprises a file identifier, and the file identifier is used to indicate a to-be-accessed object file; accessing first physical address space according to preset first virtual address space and a preset first mapping relationship between the first virtual address space and the first physical address space storing a file system, wherein the first virtual address space is a part of user space of an operating system, and the first physical address space is a part of memory space; obtaining, from the first physical address space, an index node of the object file according to the file identifier of the object file, wherein the index node comprises information about a file page table of the object file; obtaining the file page table of the object file according to the information that is about the file page table of the object file and comprised in the index node, wherein the file page table records second physical address space of a data page that is of the object file and stored in the first physical address space, and the data page of the object file is used to store file data; allocating second virtual address space to the object file, wherein the second virtual address space is a part of sharing space that is in the user space of the operating system and allocated to all processes, and the second virtual address space is continuous address space; establishing a second mapping relationship between the second physical address space and the second virtual address space; and accessing the object file in the second physical address space according to the second virtual address space and the second mapping relationship.