CN115586866A - Data writing method and device for mechanical hard disk and computing equipment - Google Patents

Data writing method and device for mechanical hard disk and computing equipment Download PDF

Info

Publication number
CN115586866A
CN115586866A CN202211104719.0A CN202211104719A CN115586866A CN 115586866 A CN115586866 A CN 115586866A CN 202211104719 A CN202211104719 A CN 202211104719A CN 115586866 A CN115586866 A CN 115586866A
Authority
CN
China
Prior art keywords
storage
data
hard disk
writing
mechanical hard
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211104719.0A
Other languages
Chinese (zh)
Inventor
李舒
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba China Co Ltd
Original Assignee
Alibaba China Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba China Co Ltd filed Critical Alibaba China Co Ltd
Priority to CN202211104719.0A priority Critical patent/CN115586866A/en
Publication of CN115586866A publication Critical patent/CN115586866A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • G06F3/0607Improving or facilitating administration, e.g. storage management by facilitating the process of upgrading existing storage systems, e.g. for improving compatibility between host and storage device
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0674Disk device
    • G06F3/0676Magnetic disk device

Abstract

The application provides a data writing method and device for a mechanical hard disk and computing equipment, and relates to the technical field of data storage. The method comprises the following steps: determining a plurality of storage objects from data to be stored, and writing the plurality of storage objects into the mechanical hard disk respectively according to a magnetic tile stacking mode, wherein the plurality of storage objects are isolated by a spatial distance to realize data updating according to the storage objects as a unit, so that the independence of read-write operation among different storage objects can be realized while the storage density is improved, and the performance loss, power consumption expense and data crosstalk caused by write amplification and read amplification are inhibited; in addition, the use of the physical space of the mechanical hard disk is realized by taking the storage object as the granularity, so that the efficiency and the flexibility of data processing are improved.

Description

Data writing method and device for mechanical hard disk and computing equipment
Technical Field
The present application relates to the field of data storage technologies, and in particular, to a data writing method and apparatus for a mechanical hard disk, and a computing device.
Background
The information age has brought forth explosive growth of mass data, and has generated strong demand for data storage. A mechanical Hard Disk (HDD) is widely used as a data storage medium.
The leading and scalable mechanical hard disk storage technology currently used in the industry is the Shingle Magnetic Recording (SMR) mechanical hard disk. The SMR HDD lead-in area (zone) concept divides a mechanical hard disk into a plurality of zones, and adjacent tracks may overlap each other within one zone, so that more tracks may be provided on the same disk (player) compared to a Conventional Magnetic Recording (SMR) mechanical hard disk, thereby increasing the amount of data stored per unit area. However, any data modification and update within the same zone of the SMR HDD needs to read the data of the entire zone, and the data modification and update is performed in units of zones, which may increase read amplification, write amplification, and power consumption, and thus, the flexibility is poor, and it is not favorable for data recovery.
Disclosure of Invention
The embodiment of the application provides a data writing method, a data writing device and computing equipment for a mechanical hard disk, which can realize the independence of read-write operation among different storage objects, and inhibit performance loss, power consumption expense and data crosstalk caused by write amplification and read amplification; in addition, the use of the physical space of the mechanical hard disk is realized by taking the storage object as the granularity, so that the efficiency and the flexibility of data processing are improved.
In a first aspect, an embodiment of the present application provides a data writing method for a mechanical hard disk, which is applied to a computing device, where the computing device includes the mechanical hard disk, and the method includes:
determining a plurality of storage objects from data to be stored;
and writing the plurality of storage objects into the mechanical hard disk respectively according to a magnetic tile stacking mode, wherein the plurality of storage objects are isolated through space distance so as to realize data updating according to the storage objects as a unit.
In a second aspect, an embodiment of the present application provides a data writing device for a mechanical hard disk, including:
the determining module is used for determining a plurality of storage objects from the data to be stored;
and the writing module is used for writing the plurality of storage objects into the mechanical hard disk respectively in a magnetic tile stacking mode, and the plurality of storage objects are isolated by space distance so as to realize data updating by taking the storage objects as a unit.
In a third aspect, an embodiment of the present application provides a computing device, including a mechanical hard disk and a driver in any one of the methods described above, where the driver executes any one of the methods described above.
In a fourth aspect, the present application provides a computer-readable storage medium, in which a computer program is stored, and when the computer program is executed by a processor, the computer program implements the method of any one of the above.
Compared with the prior art, the method has the following advantages:
according to the data writing method, the data writing device and the computing equipment for the mechanical hard disk, a plurality of storage objects are determined from data to be stored, and the storage objects are written into the mechanical hard disk respectively in a magnetic tile stacking mode, wherein the storage objects are isolated through space distances, so that data updating is achieved by taking the storage objects as units, the storage density is improved, the independence of reading and writing operations among different storage objects can be achieved, and performance loss, power consumption overhead and data crosstalk caused by writing amplification and reading amplification are inhibited; in addition, the use of the physical space of the mechanical hard disk is realized by taking the storage object as the granularity, so that the efficiency and the flexibility of data processing are improved.
The foregoing description is only an overview of the technical solutions of the present application, and the following detailed description of the present application is given to enable the technical means of the present application to be more clearly understood and to enable the above and other objects, features, and advantages of the present application to be more clearly understood.
Drawings
In the drawings, like reference numerals refer to the same or similar parts or elements throughout the several views unless otherwise specified. The figures are not necessarily to scale. It is appreciated that these drawings depict only some embodiments in accordance with the disclosure and are not to be considered limiting of its scope.
FIG. 1 is a schematic diagram of a data storage of a mechanical hard disk in the related art;
FIG. 2 is a flowchart illustrating a data writing method for a mechanical hard disk according to an embodiment of the present disclosure;
FIG. 3 is a schematic diagram of a mechanical hard disk with a multi-disk configuration according to an embodiment of the present application;
FIG. 4 is a diagram illustrating independent storage of multiple storage objects according to an embodiment of the present application;
FIG. 5 is a diagram illustrating independent storage of multiple data units according to an embodiment of the present application;
FIG. 6 is a diagram illustrating data update of a storage object according to an embodiment of the present application;
FIG. 7 is a block diagram of a data writing apparatus for a mechanical hard disk according to an embodiment of the present application; and
FIG. 8 is a block diagram of an electronic device used to implement embodiments of the present application.
Detailed Description
In the following, only certain exemplary embodiments are briefly described. As those skilled in the art will recognize, the described embodiments may be modified in various different ways, without departing from the spirit or scope of the present application. Accordingly, the drawings and description are to be regarded as illustrative in nature, and not as restrictive.
In order to facilitate understanding of the technical solutions of the embodiments of the present application, the following description is made of related art of the embodiments of the present application. The following related arts as alternatives can be arbitrarily combined with the technical solutions of the embodiments of the present application, and all of them belong to the scope of the embodiments of the present application.
For mass data generated in the information era, except for partial hot spot data, most data have not strict requirements on access delay and throughput, so that after the cost is comprehensively considered, a mechanical hard disk is widely used as a data storage medium, and the capacity increment and the storage amount of the mechanical hard disk are still superior to those of a solid state hard disk. How to deeply dig the potential of the mechanical hard disk, improve the storage density, reduce the storage cost, improve the stability, reduce the power consumption, reduce the failure rate and the like becomes the problem to be solved.
In the related art, the scalable HDD storage technology is SMR HDD. The technology adopts a magnetic shoe stacking mode, reduces the magnetic track spacing, improves the storage density and reduces the storage cost on the basis of partial magnetization overlapping of storage bits. FIG. 1 is a schematic diagram of data storage of a conventional magnetic recording machine hard disk and a tile magnetic recording machine hard disk in the related art. As shown in fig. 1, in a conventional magnetic recording mechanical hard disk, data is stored in separate tracks. In a tile magnetic recording mechanical hard disk, adjacent tracks within a zone overlap and data storage is performed in a tile stack. The magnetic shoe stacking mode includes stacking multiple tracks for storing data in the hard disk, so that more data can be stored in the same storage space. . For example, in one embodiment, adjacent tracks of the plurality of tracks are partially overlapped, in a roof-tile like arrangement, with the overlapping plurality of tracks being used to store data. However, any data modification and update in the same zone needs to read the data of the whole zone, and write the data of the whole zone back after the corresponding data modification and update. While the data size of one zone is large (e.g., 256 MB), a relatively large amount of data needs to be read and written in order to modify a small amount of data, and there is a significant optimization space for the resulting read amplification, write amplification, power consumption, and the like. Furthermore, the zones are fixed size and independent from each other, lacking configuration flexibility, lacking scheduling capability between different zones. Data recovery of one zone needs to copy the valid data in the zone to other zones, the copying process includes reading and writing of a large amount of data, and for a mechanical type device like an HDD, the recovery operation has obvious influence on the occupancy rate of a magnetic head and increases the power consumption.
In order to solve the above problem, in this embodiment, the mechanical hard disk is controlled, the data storage manner of the mechanical hard disk is changed, the original isolation ring and fixed zone arrangement in the mechanical hard disk is removed, and the plurality of storage objects are written into the mechanical hard disk respectively according to the magnetic tile stacking manner, so that the storage density can be improved. Moreover, a plurality of storage objects are isolated through space distance, data writing is carried out by taking the storage objects as units, and data placement, isolation, updating, deleting and necessary data recovery work can be flexibly arranged. The memory density is improved, the read-write operation independence among different memory objects can be realized, and the performance loss, power consumption expense and data crosstalk caused by write amplification and read amplification are inhibited; in addition, the use of the physical space of the mechanical hard disk is realized by taking the storage object as the granularity, so that the efficiency and the flexibility of data processing are improved.
An embodiment of the present application provides a data writing method for a mechanical hard disk, and fig. 2 is a flowchart of the data writing method for a mechanical hard disk according to an embodiment of the present application, where the method is applied to a computing device, the computing device may be a server, a user device, and the like, the computing device includes a mechanical hard disk and a driver, and the driver may include a driver stored outside the mechanical hard disk and a firmware stored inside the mechanical hard disk, and the method includes:
in step S201, a plurality of storage objects are determined from data to be stored.
The computing equipment receives the data to be stored, and determines a plurality of storage objects according to the characteristic information of the storage objects in the data to be stored. The storage object may be various types of objects that need to be stored, and may include at least one of the following: video, audio, images, logs, tables, files, and the like. The characteristic information of the storage object may include at least one of: length, compressibility, format, repetition, etc. of the binary string.
Step S202, writing a plurality of storage objects into the mechanical hard disk respectively according to a magnetic tile stacking mode, and isolating the plurality of storage objects through space distance so as to realize data updating according to the storage objects as a unit.
The magnetic tile stacking mode comprises the step of stacking a plurality of magnetic tracks for storing data in the hard disk, so that more data can be stored in the storage space with the same size. For example, in one embodiment, adjacent tracks of the plurality of tracks are partially overlapped, in a roof-tile like arrangement, with the overlapping plurality of tracks being used to store data. Optionally, the plurality of storage objects are sequentially written into the magnetic tracks of the mechanical hard disk according to the sequence in which the storage objects are received by the computing device.
For any storage object, the data of the storage object is written into the magnetic tracks of the mechanical hard disk in a magnetic tile stacking mode, a plurality of magnetic tracks of the same storage object are stored, and the adjacent magnetic tracks are overlapped, so that more data can be stored. Different storage objects are isolated through space distance, and data crosstalk cannot occur among the storage objects. When data update operations such as data reading and data deletion are performed, the operations are performed on a storage object basis.
The storage area and the isolation area of the storage object can be set irregularly, and the size and the shape of the storage area and the isolation area can be flexibly adjusted according to the storage object. The shape of the isolation region is not limited, and only the storage objects can be independently read without influencing the storage objects of the adjacent tracks, so that the influence of medium magnetization of the adjacent space is avoided. The storage density is improved and the cost is reduced in the same storage object, and a magnetic shoe stacking mode can be adopted to reduce the storage space occupation.
Illustratively, fig. 3 shows a mechanical hard disk drive of a multiple disk (platter) configuration with multiple parallel heads in lockstep to form a cylindrical data write. One storage object is based on the disk number average data of the mechanical hard disk and is written into the corresponding sector of the corresponding disk.
The data writing method for the mechanical hard disk, provided by the embodiment of the application, determines a plurality of storage objects from data to be stored, and writes the plurality of storage objects into the mechanical hard disk respectively according to a magnetic tile stacking manner, wherein the plurality of storage objects are isolated by a spatial distance, so that data updating is realized by taking the storage objects as a unit, the storage density is improved, the independence of reading and writing operations among different storage objects can be realized, and the performance loss, power consumption overhead and data crosstalk caused by writing amplification and reading amplification are inhibited; in addition, the use of the physical space of the mechanical hard disk is realized by taking the storage object as granularity, so that the efficiency and the flexibility of data processing are improved.
In one possible implementation, the isolation between the plurality of storage objects by the spatial distance is implemented by: by controlling the write head of the mechanical hard disk, a spatial distance is set between the write completion position of one storage object and the write start position of another storage object.
The storage objects can be unstructured data, and the users are served in an object storage mode to have natural affinity and high efficiency. The isolation between different storage objects can be realized by controlling the write head to the write completion position and the write start position of different storage objects. As shown in fig. 4, three graphs represent three storage objects, the three storage objects are converted into binary strings, and then are sequentially stored in the mechanical hard disk according to the magnetic shoe stacking manner, each storage object is written into a magnetic track, the later written magnetic track is covered on the previously written magnetic track, and the storage objects are independent from each other and keep a spatial distance.
The SMR HDD in the related art is characterized by a plurality of large-capacity zones (for example, 256 MB) regularly divided on a magnetic disk or the like, and the zones are divided by a separation ring. The setting mode is fixed and cannot be adjusted according to the storage objects, and thousands of storage objects are placed in one zone. When any one memory object is updated, other memory objects of the same zone are affected. When reading a storage object, in order to remove the inter-track interference, other storage objects adjacent to each track also need to be read, which increases the reading delay and also causes the reading interference. The data-landing manner in this embodiment realizes write/read granularity as fine as one storage object. The whole HDD can be regarded as a whole, binary strings of storage objects are written according to requirements, space distances are kept among different storage objects, and crosstalk is avoided. On one hand, the space overhead occupied by the fixed isolation ring is saved, and on the other hand, due to the independence among the storage objects, when one storage object is updated, other storage objects cannot be influenced, the write amplification is avoided, and the read amplification and the power consumption increase caused by the read amplification are reduced.
In one possible implementation, writing a plurality of storage objects to a mechanical hard disk in a tile stack manner, respectively, includes: dividing a storage object into a plurality of data units, wherein the data units are isolated by space distance; and respectively writing the data units into the mechanical hard disk according to the magnetic shoe stacking mode.
In practical applications, different types of storage objects are different in size, for example, a piece of speech 250kB, a picture 1.8MB, a pdf file 50kB, and so on. The storage object can be divided into a plurality of data segments, namely data units according to the size of the storage object, the specific length of each data unit can be set according to needs, and each data unit is respectively written into a sector of the mechanical hard disk according to a magnetic tile stacking mode. As shown in fig. 5, each data unit is represented by a pattern filling, and each data unit is sequentially written into a track, and the track written later is overlaid on the track written earlier, so as to improve the storage density and reduce the storage cost. The data units are isolated by space distance, and when data is read, the data is sequentially read out and Inter-Track Interference (ITI) is removed according to an SMR decoding mode, so that the stored data can be restored.
In one possible implementation, the method further includes: if the first data unit of the storage object is interrupted in writing, controlling a second data unit of the storage object to start writing at a first space distance from the writing interruption position of the first data unit; and when the writing of the second data unit is completed, continuing to write the first data unit at a second space distance from the writing completion position of the second data unit.
In practical applications, as shown in fig. 5, when one storage object is divided into a plurality of data units for data writing, when one data unit is temporarily interrupted from writing, and another data unit is written, the data writing middle position between two data units is controlled, and a spatial distance is maintained between the positions for rewriting, the first spatial distance and the second spatial distance may be the same or different, and the spatial distance may be preset according to specific needs. The tracks may overlap during storage for the same data element, with a spatial distance maintained between different data elements. The storage density is improved, and the data reading between different data units is not influenced.
How to control the writing and interruption of a data unit is shown in the following embodiments:
in a possible implementation manner, the method further comprises the steps of controlling a write head to write data through a high level of a write enable signal; and controlling the write head to stop data writing through the low level of the write enable signal.
In practical applications, the writing interruption of a data unit is controlled by a write enable signal (write gate), and different data units are not overlapped with each other and do not affect each other. As shown in fig. 5, the start and interruption of data writing are controlled by the high level and the low level of the write enable signal, respectively. When reading data, control is performed by a corresponding read enable signal (read gate). Thus, although the read head continuously sweeps over discrete tracks, which data elements are retained and which data elements are discarded may be selected by the read enable signal. For example, the corresponding pick-up signal at a high level of the retention enable signal may be performed by a binary and logic operation.
In one possible implementation, the method further includes: deleting a first storage object in the plurality of storage objects in the mechanical hard disk to release a first storage space of the first storage object; and storing the second storage object through the first storage space, and if the second storage space of the second storage object is smaller than the first storage space, storing verification data by using the residual storage space, wherein the verification data is used for verifying the second storage object.
In practical application, the written data is updated and deleted by taking the storage objects as units, and the read-write independence between the storage objects is ensured while the storage density is satisfied. As shown in fig. 6, after a storage object is deleted, the released storage space can be reused locally, thereby reducing the influence caused by the recovery of a large-capacity zone and improving the data stability. If the residual storage space exists after multiplexing, the residual storage space can be used for storing the check data, and the check data can be used for checking the data stored in the released storage space, so that the consistency of the data is improved.
For example, if the deleted storage object occupies N sectors of 4KB and the storage space remaining after the storage space multiplexing can accommodate one sector, when the N sectors of the red object are sequentially written, parity data (parity data) of the red object is generated by accumulating in a RAID (Redundant Arrays of Independent Disks) manner and is written into the remaining sectors. When one sector in the N +1 sectors has errors, the data can be restored in a RAID mode, and the data stability is improved.
In one possible implementation, the method further includes: when the version of a third storage object stored in the mechanical hard disk is updated, deleting the third storage object to release the storage space of the third storage object for storing a fourth storage object; and storing the updated third storage object in the current available storage space.
In practical application, if the stored object has a new version, the new version is written into the current available storage space in an additional writing manner, and the space distance between the new version and the adjacent storage object is kept, as shown in fig. 6, the original version is marked as expired and can be deleted, and the storage space occupied by the storage object of the expired version can be recycled and used for writing other storage objects with proper length.
Corresponding to the application scenario and the method of the method provided by the embodiment of the application, the embodiment of the application further provides a data writing device for a mechanical hard disk. Fig. 7 is a block diagram of a data writing device for a mechanical hard disk according to an embodiment of the present application, where the data writing device for a mechanical hard disk may include:
a determining module 701, configured to determine a plurality of storage objects from data to be stored.
The writing module 702 is configured to write a plurality of storage objects into the mechanical hard disk in a magnetic tile stacking manner, where the storage objects are separated by a spatial distance, so as to implement data updating according to the storage objects as a unit.
The data writing device for the mechanical hard disk determines a plurality of storage objects from data to be stored, and writes the plurality of storage objects into the mechanical hard disk respectively according to a magnetic tile stacking manner, wherein the plurality of storage objects are isolated by a spatial distance, so that data updating is performed by taking the storage objects as a unit, the storage density is improved, the independence of reading and writing operations among different storage objects can be realized, and performance loss, power consumption overhead and data crosstalk caused by writing amplification and reading amplification are suppressed; in addition, the use of the physical space of the mechanical hard disk is realized by taking the storage object as granularity, so that the efficiency and the flexibility of data processing are improved.
In one possible implementation, the writing module 702 is configured to: dividing a storage object into a plurality of data units, wherein the data units are isolated by space distance; and respectively writing the data units into the mechanical hard disk according to the magnetic tile stacking mode.
In one possible implementation, the isolation between the plurality of storage objects by the spatial distance is implemented by: by controlling the write head of the mechanical hard disk, a spatial distance is set between the write completion position of one storage object and the write start position of another storage object.
In a possible implementation manner, the writing module 702 is further configured to: if the first data unit of the storage object is interrupted in writing, controlling a second data unit of the storage object to start writing at a first space distance from the writing interruption position of the first data unit; and when the writing of the second data unit is completed, continuing to write the first data unit at a second space distance from the writing completion position of the second data unit.
In a possible implementation mode, the device also comprises a control module, a data reading module and a data reading module, wherein the control module is used for controlling the data reading of the writing magnetic head through the high level of the writing enabling signal; and controlling the write head to stop data writing through the low level of the write enable signal.
In one possible implementation manner, the apparatus further includes a first updating module configured to:
deleting a first storage object in the plurality of storage objects in the mechanical hard disk to release a first storage space of the first storage object; and storing the second storage object through the first storage space, and if the second storage space of the second storage object is smaller than the first storage space, storing verification data by using the residual storage space, wherein the verification data is used for verifying the second storage object.
In a possible implementation manner, the apparatus further includes a second updating module, configured to: when the version of a third storage object stored in the mechanical hard disk is updated, deleting the third storage object to release the storage space of the third storage object for storing a fourth storage object; and storing the updated third storage object in the current available storage space.
The functions of each module in each device in the embodiment of the present application can be referred to the corresponding description in the above method, and have corresponding beneficial effects, which are not described herein again.
Corresponding to an application scenario and a method of the method provided by the embodiment of the present application, the embodiment of the present application provides a computing device, which includes the mechanical hard disk and the driver in any of the embodiments, and the driver executes the method in any of the embodiments.
An electronic device is provided in an embodiment of the present application, and fig. 8 is a block diagram of an electronic device for implementing an embodiment of the present application. As shown in fig. 8, the electronic apparatus includes: a memory 810 and a processor 820, the memory 810 having stored therein computer programs operable on the processor 820. The processor 820, when executing the computer program, implements the methods in the embodiments described above. The number of the memory 810 and the processor 820 may be one or more.
The electronic device further includes:
and a communication interface 830, configured to communicate with an external device, and perform data interactive transmission.
If the memory 810, the processor 820 and the communication interface 830 are implemented independently, the memory 810, the processor 820 and the communication interface 830 may be connected to each other through a bus and perform communication with each other. The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended ISA (EISA) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in FIG. 8, but this is not intended to represent only one bus or type of bus.
Optionally, in an implementation, if the memory 810, the processor 820 and the communication interface 830 are integrated on a chip, the memory 810, the processor 820 and the communication interface 830 may complete communication with each other through an internal interface.
Embodiments of the present application provide a computer-readable storage medium, which stores a computer program, and when the program is executed by a processor, the computer program implements the method provided in the embodiments of the present application.
The embodiment of the present application further provides a chip, where the chip includes a processor, and is configured to call and run an instruction stored in a memory from the memory, so that a communication device in which the chip is installed executes the method provided in the embodiment of the present application.
An embodiment of the present application further provides a chip, including: the system comprises an input interface, an output interface, a processor and a memory, wherein the input interface, the output interface, the processor and the memory are connected through an internal connection path, the processor is used for executing codes in the memory, and when the codes are executed, the processor is used for executing the method provided by the embodiment of the application.
It should be understood that the Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. The general purpose processor may be a microprocessor or any conventional processor or the like. It is noted that the processor may be a processor supporting an Advanced reduced instruction set machine (ARM) architecture.
Further, optionally, the memory may include a read-only memory and a random access memory. The memory may be either volatile memory or nonvolatile memory, or may include both volatile and nonvolatile memory. The non-volatile Memory may include a Read-Only Memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an Electrically Erasable PROM (EEPROM), or a flash Memory. Volatile Memory can include Random Access Memory (RAM), which acts as external cache Memory. By way of example, and not limitation, many forms of RAM are available. For example, static Random Access Memory (Static RAM, SRAM), dynamic Random Access Memory (DRAM), synchronous Dynamic Random Access Memory (SDRAM), double Data Rate Synchronous Dynamic Random Access Memory (DDR SDRAM), enhanced SDRAM (ESDRAM), SLDRAM (SLDRAM), and Direct Rambus RAM (DR RAM).
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. The procedures or functions according to the present application are all or partially generated when the computer program instructions are loaded and executed on a computer. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium.
In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, "a plurality" means two or more unless specifically limited otherwise.
Any process or method described in a flow diagram or otherwise herein may be understood as representing a module, segment, or portion of code, which includes one or more executable instructions for implementing specific logical functions or steps of the process. And the scope of the preferred embodiments of the present application includes other implementations in which functions may be performed out of the order shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved.
The logic and/or steps described in the flowcharts or otherwise described herein, such as an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions.
It should be understood that portions of the present application may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. All or part of the steps of the method of the above embodiments may be implemented by hardware that is configured to be instructed to perform the relevant steps by a program, which may be stored in a computer-readable storage medium, and which, when executed, includes one or a combination of the steps of the method embodiments.
In addition, functional units in the embodiments of the present application may be integrated into one processing module, or each unit may exist alone physically, or two or more units are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module may also be stored in a computer-readable storage medium if it is implemented in the form of a software functional module and sold or used as a separate product. The storage medium may be a read-only memory, a magnetic or optical disk, or the like.
The above description is only an exemplary embodiment of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive various changes or substitutions within the technical scope described in the present application, and these should be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (10)

1. A data writing method for a mechanical hard disk, wherein the method is applied to a computing device, the computing device comprises the mechanical hard disk, and the method comprises the following steps:
determining a plurality of storage objects from data to be stored;
and writing the plurality of storage objects into the mechanical hard disk respectively according to a magnetic tile stacking mode, wherein the plurality of storage objects are isolated through space distance so as to realize data updating according to the storage objects as a unit.
2. The method of claim 1, wherein writing the plurality of storage objects to the mechanical hard disk in a tile-stacked manner comprises:
dividing the storage object into a plurality of data units, wherein the data units are isolated by space distance;
and respectively writing the data units into the mechanical hard disk according to a magnetic tile stacking mode.
3. The method of claim 1, wherein the isolation between the plurality of storage objects by spatial distance is achieved by:
and setting a spatial distance between a write completion position of one storage object and a write start position of another storage object by controlling a write head of the mechanical hard disk.
4. The method according to any one of claims 1-3, further comprising:
if the writing of the first data unit of the storage object is interrupted, controlling a second data unit of the storage object to start writing at a first space distance from the writing interruption position of the first data unit;
and when the writing of the second data unit is completed, continuing to write the first data unit at a second space distance from the writing completion position of the second data unit.
5. The method of claim 4, further comprising:
controlling a write magnetic head to write data through the high level of the write enable signal;
and controlling the write head to stop data writing through the low level of the write enable signal.
6. The method according to any one of claims 1-3, further comprising:
deleting a first storage object in the plurality of storage objects in the mechanical hard disk to release a first storage space of the first storage object;
and storing a second storage object through the first storage space, and if the second storage space of the second storage object is smaller than the first storage space, storing check data by using the residual storage space, wherein the check data is used for checking the second storage object.
7. The method according to any one of claims 1-3, further comprising:
when the version of a third storage object stored in the mechanical hard disk is updated, deleting the third storage object to release the storage space of the third storage object for storing a fourth storage object;
and storing the updated third storage object in the current available storage space.
8. A data writing apparatus for a mechanical hard disk, comprising:
the device comprises a determining module, a storage module and a storage module, wherein the determining module is used for determining a plurality of storage objects from data to be stored;
and the writing module is used for writing the plurality of storage objects into the mechanical hard disk respectively in a magnetic tile stacking mode, and the plurality of storage objects are isolated by space distance so as to realize data updating by taking the storage objects as a unit.
9. A computing device comprising the mechanical hard disk of any one of claims 1-7 and a driver to perform the method of any one of claims 1-7.
10. A computer-readable storage medium, having stored therein a computer program which, when executed by a processor, implements the method of any one of claims 1-7.
CN202211104719.0A 2022-09-09 2022-09-09 Data writing method and device for mechanical hard disk and computing equipment Pending CN115586866A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211104719.0A CN115586866A (en) 2022-09-09 2022-09-09 Data writing method and device for mechanical hard disk and computing equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211104719.0A CN115586866A (en) 2022-09-09 2022-09-09 Data writing method and device for mechanical hard disk and computing equipment

Publications (1)

Publication Number Publication Date
CN115586866A true CN115586866A (en) 2023-01-10

Family

ID=84771785

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211104719.0A Pending CN115586866A (en) 2022-09-09 2022-09-09 Data writing method and device for mechanical hard disk and computing equipment

Country Status (1)

Country Link
CN (1) CN115586866A (en)

Similar Documents

Publication Publication Date Title
KR101086857B1 (en) Control Method of Solid State Storage System for Data Merging
US7958331B2 (en) Storage device with opportunistic address space
US7490212B2 (en) System and method for writing data to dedicated bands of a hard disk drive
US7281089B2 (en) System and method for reorganizing data in a raid storage system
KR101910840B1 (en) Dynamic granule-based intermediate storage
CN111506251B (en) Data processing method and device, SMR storage system and storage medium
US7818524B2 (en) Data migration systems and methods for independent storage device expansion and adaptation
JP2008204041A (en) Storage device and data arrangement control method
US20200090705A1 (en) Shingled magnetic recording storage system
US7188299B2 (en) Data-recording/reproduction apparatus and data-recording/reproduction method
WO2018188618A1 (en) Solid-state disk access
JPWO2011118114A1 (en) Nonvolatile storage device and memory controller
US9235352B2 (en) Datastore for non-overwriting storage devices
CN112420080B (en) Magnetic disk device
Anderson You Don’t Know Jack about Disks: Whatever happened to cylinders and tracks?
CN115586866A (en) Data writing method and device for mechanical hard disk and computing equipment
JP2008077782A (en) Memory data processor, memory, and memory data processing program
US20100218038A1 (en) Storage control device, storage control method, and storage control program
JP2005078378A (en) Data storage device and data writing method in non-volatile memory
US20170229141A1 (en) Managing read and write errors under external vibration
US20090187719A1 (en) Data backup method for logical volume manager
US7715133B2 (en) Method for duplicating data
JP2000513129A (en) Method of tracking incomplete writes in a disk array, and disk storage system performing such a method
JP4365509B2 (en) Data management apparatus, data management method, and recording medium recording data management procedure
US20230325119A1 (en) System and method for performing data read-write operations in zoned storage devices

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination