Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Boot file system mounting method and apparatus

A file system and boot file technology, applied in the computer field, can solve the problems of occupying large flash memory, running memory, and resource consumption, etc.

Inactive Publication Date: 2018-01-09
BOWEI TECH
View PDF2 Cites 10 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The present invention provides a method and device for mounting a boot file system, which is used to solve the technical problem of large resource consumption due to the need to occupy a large flash memory and running memory in the prior art method

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Boot file system mounting method and apparatus
  • Boot file system mounting method and apparatus
  • Boot file system mounting method and apparatus

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0054] This embodiment provides a method for mounting the boot file system, please refer to figure 1 , the method includes:

[0055] Step S101: Create a first file system, the first file system includes a readable and writable directory;

[0056] Step S102: Create a second file system, the second file system is a SquashFS file system, and generate an entire image that includes the first image file of the first file system and the second image file of the SquashFS file system;

[0057] Step S103: extracting the second image file from the entire image, and constructing a first association between the second image file and the pre-created loopback device of the first file system;

[0058] Step S104: According to the first association, mount the image file into the readable and writable directory, and construct a second association between the readable and writable directory and the loopback device;

[0059] Step S105: According to the second association, convert the readable an...

Embodiment 2

[0078] This embodiment provides a device for mounting a boot file system, please refer to image 3 , the device consists of:

[0079] Creating module 201, configured to create a first file system, the first file system includes a readable and writable directory;

[0080] The generation module 202 is used to create a second file system, the second file system is a SquashFS file system, and generates the entire image file containing the first image file of the first file system and the second image file of the SquashFS file system mirror image;

[0081] An extraction module 203, configured to extract the second image file from the entire image, and construct a first association between the second image file and the pre-created loopback device of the first file system;

[0082] Mounting module 204, configured to mount the loopback device into the readable and writable directory according to the first association, and construct a second association between the readable and writa...

Embodiment 3

[0092] See Figure 4 , the embodiment of the present invention provides a computer-readable storage medium 300, on which a computer program 311 is stored, and when the program is executed by a processor, the following steps are implemented:

[0093] Create a first file system, the first file system includes a readable and writable directory;

[0094] Create a second file system, the second file system is a SquashFS file system, and generate a whole image that includes the first image file of the first file system and the second image file of the SquashFS file system;

[0095] Extracting the second image file from the entire image, and constructing a first association between the second image file and the pre-created loopback device of the first file system;

[0096] According to the first association, mount the loopback device into the readable and writable directory, and construct a second association between the readable and writable directory and the loopback device;

[0...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a boot file system mounting method and apparatus. The method comprises the steps of creating a first file system; creating a second file system, and generating a whole mirror image; extracting a second mirror image file from the whole mirror image, and establishing a first correlation between the second mirror image file and a pre-created loopback device of the first file system; according to the first correlation, mounting the loopback device to a read-write directory, and establishing a second correlation between the read-write directory and the loopback device; and according to the second correlation, converting the read-write directory into a root directory of a preset running environment, and based on the root directory of the preset running environment, booting a startup script. The technical problem of relatively high resource consumption due to occupation of relatively large flash memory and running memory in a method in the prior art is solved.

Description

technical field [0001] The invention belongs to the technical field of computers, and in particular relates to a method and a device for mounting a boot file system. Background technique [0002] At present, in embedded devices, the Linux operating system and rootfs root file system are usually compressed into JFFS2 or UBIFS format images and stored in FLASH flash memory devices, such as NANDFLASH with non-linear macrocell mode and non-volatile flash memory technology. NOR FLASH, during the system startup process, the above image is directly mounted to the root file system. [0003] However, in the existing method, the rootfs root file system is compressed into a JFFS2 or UBIFS format mirror image. Since the root file system contains kernel code image files, the general capacity is relatively large. After being compressed into a mirror image, the capacity size is usually several hundred megabytes. , if the above image is directly mounted to the root file system, a larger fl...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/4401G06F9/50
Inventor 雷红章
Owner BOWEI TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products