CN112905120A - Lock disc upgrading method and device, electronic equipment and storage medium - Google Patents

Lock disc upgrading method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112905120A
CN112905120A CN202110189213.3A CN202110189213A CN112905120A CN 112905120 A CN112905120 A CN 112905120A CN 202110189213 A CN202110189213 A CN 202110189213A CN 112905120 A CN112905120 A CN 112905120A
Authority
CN
China
Prior art keywords
disk
written
disks
storage system
upgrading
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.)
Granted
Application number
CN202110189213.3A
Other languages
Chinese (zh)
Other versions
CN112905120B (en
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.)
Shandong Yingxin Computer Technology Co Ltd
Original Assignee
Shandong Yingxin Computer Technology 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 Shandong Yingxin Computer Technology Co Ltd filed Critical Shandong Yingxin Computer Technology Co Ltd
Priority to CN202110189213.3A priority Critical patent/CN112905120B/en
Publication of CN112905120A publication Critical patent/CN112905120A/en
Application granted granted Critical
Publication of CN112905120B publication Critical patent/CN112905120B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/062Securing storage systems
    • 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
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application provides a lock disc upgrading method, a lock disc upgrading device, electronic equipment and a medium, wherein the method comprises the following steps: acquiring disk identifications of all disks of a storage system; determining a disk to be written in from all disks according to the disk identification, and writing encrypted data in the disk to be written; when the locking disc version is upgraded, decrypting the encrypted data of the disc in the upgraded storage system; when the decryption is successful, the disk which is successfully decrypted is online; and if the decryption fails, the off-line decryption fails. According to the method and the device, the disk identification of each disk of the storage system is obtained before upgrading, the disk to be written is determined according to the disk identification, the disk to be written is not encrypted and is an old disk, the encrypted data is injected into the old disk, and the encrypted data of the disk is decrypted after upgrading is completed, so that the old disk originally inserted in the system can be continuously used, the compatibility of the disks is realized, the upgrading is guaranteed to be smoothly carried out, and the user experience is improved.

Description

Lock disc upgrading method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of storage technologies, and in particular, to a method and an apparatus for upgrading a lock disk, an electronic device, and a computer-readable storage medium.
Background
The locking disk is to restrict all disks from being used on the storage system, only those disks passing through the disk locking restriction function can be used on the storage device, and the disks not passing through are not identified and cannot be used. The existing storage equipment has the problem of compatibility of an old disk when the version of a locked disk is upgraded. Since the old disk does not support the acquisition of some commands or some contents and there is no encrypted data on the old disk, the problem arises after the upgrade.
Therefore, how to provide a solution to the above technical problem is a problem that needs to be solved by those skilled in the art.
Disclosure of Invention
The application aims to provide a lock disc upgrading method, a lock disc upgrading device, electronic equipment and a computer readable storage medium, which can be compatible with an old disc without encrypted data. The specific scheme is as follows:
the application provides a lock disc upgrading method, which comprises the following steps:
acquiring disk identifications of all disks of a storage system;
determining a disk to be written in from all the disks according to the disk identification, and writing encrypted data in the disk to be written;
when the locking disc version is upgraded, decrypting the encrypted data of the disc in the upgraded storage system;
when the decryption is successful, the disk which is successfully decrypted is online; and if the decryption fails, the off-line decryption fails.
Preferably, when the disk identifier is a production date, the obtaining disk identifiers of all disks of the storage system includes:
acquiring the production dates of all the disks of the storage system;
correspondingly, the determining a disk to be written in from all the disks according to the disk identifier includes:
and taking the first target disk with the production date between preset dates as the disk to be written.
Preferably, the method further comprises the following steps:
and determining a second target disk which does not acquire the production date as the disk to be written.
Preferably, the obtaining the production dates of all the disks of the storage system includes:
issuing a date acquisition instruction to each disk to obtain feedback information of each disk;
judging whether the byte length of the feedback information is greater than or equal to a preset length or not;
and if the length is larger than or equal to the preset length, acquiring the production date.
Preferably, when the disk identifier is a supported command, the obtaining the disk identifiers of all the disks of the storage system includes:
acquiring the supported commands of each disk;
correspondingly, the determining a disk to be written in from all the disks according to the disk identifier includes:
and determining the disk of which the supported command comprises a preset command as the disk to be written.
Preferably, when the disk identifier is the set ID, the obtaining the disk identifiers of all the disks of the storage system includes:
acquiring the set ID of each disk;
correspondingly, the determining a disk to be written in from all the disks according to the disk identifier includes:
and taking the third target disk with the set ID in the target ID range as the disk to be written.
Preferably, the disk in the storage system after being upgraded includes a disk before being upgraded and a newly inserted disk.
The application provides a lock dish upgrading device includes:
the acquisition module is used for acquiring the disk identifiers of all the disks of the storage system;
the encrypted data writing module is used for determining a disk to be written from all the disks according to the disk identification and writing encrypted data into the disk to be written;
the decryption module is used for decrypting the encrypted data of the disk in the storage system after upgrading the version of the locking disk;
the disk processing module is used for online decrypting the successful disk after decryption is successful; and if the decryption fails, the off-line decryption fails.
The application provides an electronic device, including:
a memory for storing a computer program;
and the processor is used for realizing the steps of the lock disc upgrading method when the computer program is executed.
The present application provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the lock disc upgrading method as described above.
The application provides a lock disc upgrading method, which comprises the following steps: acquiring disk identifications of all disks of a storage system; determining a disk to be written in from all disks according to the disk identification, and writing encrypted data in the disk to be written; when the locking disc version is upgraded, decrypting the encrypted data of the disc in the upgraded storage system; when the decryption is successful, the disk which is successfully decrypted is online; and if the decryption fails, the off-line decryption fails.
Therefore, the disk identification of each disk of the storage system is obtained before upgrading, the disk to be written is determined according to the disk identification, the disk to be written is not encrypted and is an old disk, the encrypted data is injected into the old disk, and the encrypted data of the disk is decrypted after upgrading is completed, so that the old disk originally inserted into the system can be continuously used, the compatibility of the disks is realized, the upgrading is ensured to be smoothly carried out, and the user experience is improved.
This application still provides a lock dish upgrading device, electronic equipment and medium simultaneously, all has above-mentioned beneficial effect, no longer gives unnecessary details here.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a method for upgrading a lock dial according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of a lock disc upgrading device provided in an embodiment of the present application;
fig. 3 is a block diagram of an electronic device according to an embodiment of the present disclosure;
fig. 4 is a block diagram of another electronic device provided in the embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The locking disk is to restrict all disks from being used on the storage system, only those disks passing through the disk locking restriction function can be used on the storage device, and the disks not passing through are not identified and cannot be used. The existing storage equipment has the problem of compatibility of an old disk when the version of a locked disk is upgraded. Since the old disk does not support the acquisition of some commands or some contents and there is no encrypted data on the old disk, the problem arises after the upgrade.
Based on the above technical problem, this embodiment provides a method for upgrading a locking disk, including obtaining disk identifiers of all disks of a storage system;
determining a disk to be written in from all disks according to the disk identification, and writing encrypted data in the disk to be written;
when the locking disc version is upgraded, decrypting the encrypted data of the disc in the upgraded storage system;
when the decryption is successful, the disk which is successfully decrypted is online; and if the decryption fails, the off-line decryption fails.
Therefore, the disk identification of each disk of the storage system is obtained before upgrading, the disk to be written is determined according to the disk identification, the disk to be written is not encrypted and is an old disk, the encrypted data is injected into the old disk, and the encrypted data of the disk is decrypted after upgrading is completed, so that the old disk originally inserted into the system can be continuously used, the compatibility of the disks is realized, the upgrading is ensured to be smoothly carried out, and the user experience is improved.
Referring to fig. 1 specifically, fig. 1 is a flowchart of a lock disc upgrading method provided in an embodiment of the present application, which specifically includes:
s101, acquiring disk identifications of all disks of a storage system;
the storage system comprises a plurality of magnetic disks, and the plurality of magnetic disks can be all old disks; all are new discs; a part of old disc and a part of new disc; wherein, the new disc refers to a magnetic disc capable of supporting the setting function, and the old disc cannot support the setting function. Wherein the disk identification includes, but is not limited to, a date of manufacture or a functional parameter or disk ID.
S102, determining a disk to be written in from all disks according to the disk identification, and writing encrypted data in the disk to be written in;
in this embodiment, the disk to be written is determined from all the disks according to the disk identifier, and it can be understood that different disk identifiers are determined in different manners. After the disk to be written is determined, a section of blank sector is reserved on the disk to be written, and encryption processing is performed on the disk to be written, namely, encrypted data is injected into a fixed position of the disk to be written.
In an implementation manner, the first target disk of the production log before the preset date is an old disk, that is, a disk to be written, and there is no encrypted data in the disk to be written, and at this time, the production date is used as a disk identifier, and it can be understood that the newer the production date is, the more complete the function of the disk is. Wherein the preset date is the date of the upgraded version of the lock disc.
In another implementation, the first target disk without the setting function is an old disk, that is, a disk to be written, where there is no encrypted data in the disk to be written, and at this time, the disk identifier is a function parameter of the disk, that is, a supported command, for example, the disk 1 has a function a; the magnetic disk 2 has functions a, b; the magnetic disk 3 has a function a; the disk 4 has functions a, b; when the functions are set as functions a and b, the magnetic disk 1 and the magnetic disk 3 are old disks, namely, magnetic disks to be written, and the magnetic disk 2 and the magnetic disk 4 are new disks. The function parameter is the function parameter of the disk of the date corresponding to the lock disk upgrading version.
In another implementation, the disk identifier may also be a set ID, and when the ID is set, the setting may be performed according to a production sequence, that is, the disk with the set ID within the target ID range is used as a legacy disk, that is, a disk to be written, where there is no encrypted data in the disk to be written; for example, the ID of disk 1 is 1, and the ID of disk 2 is 2; the ID of the disk n is n. The set ID is the ID corresponding to the lock disc upgrading version.
Of course, other forms may also exist, the present embodiment is not limited, and as long as the purpose of the present embodiment can be achieved, the user may customize the setting.
In this embodiment, after the disk to be written is determined, since the new disk supports some commands, some contents are acquired, and there is encrypted data, the disk to be written does not support some commands, some contents are acquired, and there is no encrypted data in the old disk, if the disk locking upgrade is directly performed, the problem of an upgrade failure may occur.
S103, after the version of the locking disk is upgraded, decrypting the encrypted data of the disk in the upgraded storage system;
and after upgrading the lock disk version, decrypting the disk in the storage system.
Further, the disks in the upgraded storage system include a disk before upgrading and a newly inserted disk.
At this time, the disk in the storage system after being upgraded has two situations, the first situation is that the disk before being upgraded is on the storage system, and the second situation is that the disk newly inserted is on the storage system, and the newly inserted disk may be a new disk or an old disk.
After the version of the lock disk is upgraded, the encrypted data exists in the new disk, and the encrypted data is written into the disk to be written, so that the encrypted data of the new disk and the encrypted data of the disk to be written can be decrypted.
But when there is a newly inserted disk, if the newly inserted disk is a new disk, the new disk itself has encrypted data, and therefore decryption of the encrypted data of the newly inserted disk can be performed; if the newly inserted disk is an old disk, when the encrypted data is written in the old disk, decrypting the encrypted data of the newly inserted disk can be executed; if the newly inserted disk is a legacy disk, the decryption cannot be performed when the legacy disk is not written with encrypted data.
S104, when the decryption is successful, the disk which is successfully decrypted is online; and if the decryption fails, the off-line decryption fails.
After decryption succeeds, the successfully decrypted disk can be normally used, and therefore the successfully decrypted disk is on-line; and if the decryption fails, the disk with the decryption failure cannot be used, and the disk is kicked.
Based on the technical scheme, the disk identification of each disk of the storage system is obtained before the upgrade, the disk to be written is determined according to the disk identification, the disk to be written is not an old disk, the encrypted data is injected into the old disk at the moment, and the encrypted data of the disk is decrypted after the upgrade is completed, so that the old disk originally inserted in the system can be continuously used, the compatibility of the disks is realized, the upgrade is ensured to be smoothly carried out, and the user experience is improved.
In an implementation manner, in order to quickly determine the disk to be written, in this embodiment, the disk identifier is set to a production date, and specifically, when the disk identifier is the production date, acquiring the disk identifiers of all the disks of the storage system includes:
acquiring production dates of all disks of the storage system;
correspondingly, determining the disk to be written in from all the disks according to the disk identifier, including:
and taking the first target disk with the production date between the preset dates as the disk to be written.
In this embodiment, a first target disk of a production log before a preset date is an old disk, that is, a disk to be written, and the disk to be written does not have encrypted data.
Therefore, the method and the device can quickly determine the disk to be written by taking the production date as the disk identifier, and improve the determination efficiency of the disk to be written.
Further, after the disk to be written is determined, whether the disk to be written has the encrypted data or not is judged, if yes, the encrypted data is not written again, and if not, the encrypted data is written, so that the situations of resource waste and complex operation caused by repeated writing are ensured.
Further, there may be a second target disk that cannot acquire a disk identifier, and in this embodiment, the disk is also used as a disk to be written, so that the occurrence of missing determination by an old disk is avoided, and specifically, the method further includes: and determining the second target disk which does not acquire the production date as the disk to be written.
In this embodiment, the second target disk of the production date that is not obtained is also used as the disk to be written, and at this time, the disk to be written includes: a first target disk and a second target disk.
Therefore, in the embodiment, the disk which does not acquire the production date is also used as the disk to be written, so that the situation that the old disk is determined to be missing is avoided.
Further, this embodiment may further include: after the first target disk and the second target disk are determined, whether the first target disk and the second target disk have the encrypted data or not is judged, if the first target disk and/or the second target disk have the encrypted data, the encrypted data is not written again, and if the first target disk and/or the second target disk do not have the encrypted data, the encrypted data is written, so that the situation that repeated writing is not performed, resource waste is caused, and the operation is complicated is ensured.
Further, the obtaining of the production date is further explained, wherein the obtaining of the production dates of all the disks of the storage system comprises:
issuing a date acquisition instruction to each disk to obtain feedback information of each disk;
judging whether the byte length of the feedback information is greater than or equal to a preset length or not;
and if the length is larger than or equal to the preset length, acquiring the production date.
Specifically, the code implements a lock disk upgrade module that is executed first when the upgrade is initiated.
In an implementation real-time manner, the date acquisition command inquiry std may be issued to all the disks to obtain feedback information of each disk, and whether the length of the response (feedback information) is greater than or equal to a preset length (e.g. 106 bytes) is determined, and if the length is greater than or equal to the preset length, the production date is acquired from 102 bytes and 106 bytes.
Further, if the length is smaller than the preset length, the disc can be determined as an old disc; or if the length is smaller than the preset length, a log sense command can be issued, the command is used for acquiring the production date, whether the command is supported by the state given by the response message is judged, and if the command is not supported, the disk is identified as an old disk.
In another real-time implementation mode, a log sense command is issued, the command is used for acquiring the production date, whether the state given by the response message supports the command is judged, and if not, the disk is identified as an old disk.
Further, when the disk identifier is a supported command, acquiring disk identifiers of all disks of the storage system, including:
acquiring a command supported by each disk;
correspondingly, determining the disk to be written in from all the disks according to the disk identifier, including:
and determining the disk of the supported commands, which comprises the preset commands, as the disk to be written.
Further, when the disk identifier is the set ID, acquiring the disk identifiers of all the disks of the storage system includes:
acquiring a set ID of each disk;
correspondingly, determining the disk to be written in from all the disks according to the disk identifier, including:
and taking the third target disk with the set ID in the target ID range as the disk to be written.
The disk identification can also be a set ID, and the ID can be set according to the production sequence when being set, namely, the disk with the set ID in the target ID range is used as a master disk, namely, the disk to be written, and the disk to be written has no encrypted data; for example, the ID of disk 1 is 1, and the ID of disk 2 is 2; the ID of the disk n is n.
Based on any embodiment, the invention realizes an implementation mode of the lock disk upgrading function on the storage system, is compatible with all the old disks originally inserted into the storage system, and does not support the old disks to be replaced by other old disks. Restricting them from buying new encrypted discs. The embodiment provides a specific locking disc method, which comprises the following steps:
1. the code implements a lock disk upgrade module that is executed first at the beginning of the upgrade. And for all the disks, issuing a date acquisition instruction inquiry std, judging whether the response length of the feedback information of each disk is 106 bytes, and if so, acquiring the production date from 102 and 106 bytes. Otherwise, sending log sense command, judging whether the state given by the response message supports the command, if not, marking the disk as a disk to be written, namely an old disk.
2. On the storage system, an encryption module is added before upgrading, all the old disks are traversed, a section of blank sectors is reserved on the old disks, encryption processing is carried out on the old disks, and encryption data are injected into fixed positions of the old disks.
3. After upgrading, when the lock disc is processed, the decryption is directly carried out, and if the decryption fails, the lock disc is kicked. The decryption is successful and the disc is made online and available.
In summary, before upgrading, production dates are acquired for all disks on the storage system, if the production dates are not acquired, encrypted data are injected into the disks, or when the disks are determined to be old disks according to the production dates, the encrypted data are injected; after upgrading, when the disc is locked, if the production date does not exist (the disc is a old disc), the disc is directly decrypted, and the old disc can be used after the decryption is successful. The specific implementation is that before upgrading, a command for locking disks is issued to all disks on a storage system, the production date is obtained, and if some old disks are not obtained, encrypted data are injected into the disks. After upgrading, when the lock disc is judged, if the production date does not exist, the decryption is directly carried out, and because the encrypted data is injected previously, the decryption is successful, and the old disc can be used. After upgrading, for other old discs inserted by the user, the user cannot use the old discs because the user does not acquire the production date and fails to decrypt because the user does not inject the encrypted data in advance. This limits the user to use all the old disks inserted in the storage system at that time, or to buy new encrypted disks, and not to insert other old disks.
Referring to fig. 2, fig. 2 is a schematic structural diagram of a lock disc upgrading device provided in an embodiment of the present application, and includes:
an obtaining module 201, configured to obtain disk identifiers of all disks of a storage system;
an encrypted data writing module 202, configured to determine a disk to be written in from all disks according to the disk identifier, and write encrypted data in the disk to be written;
the decryption module 203 is used for decrypting the encrypted data of the disk in the updated storage system after the version of the lock disk is updated;
the disk processing module 204 is used for online decrypting the successful disk after the decryption is successful; and if the decryption fails, the off-line decryption fails.
Preferably, when the disk identifier is a production date, the obtaining module 201 includes:
a production date acquisition unit for acquiring production dates of all disks of the storage system;
correspondingly, the encrypted data writing module 202 includes:
and the first disk-to-be-written determining unit is used for taking the first target disk with the production date between the preset dates as the disk to be written.
Preferably, the encrypted data writing module 202 further includes:
and the second disk-to-be-written determining unit is used for determining a second target disk which does not acquire the production date as a disk-to-be-written.
Preferably, the production date acquiring unit is configured to:
issuing a date acquisition instruction to each disk to obtain feedback information of each disk;
judging whether the byte length of the feedback information is greater than or equal to a preset length or not;
and if the length is larger than or equal to the preset length, acquiring the production date.
Preferably, when the disk identifier is a supported command, the obtaining module 201 includes:
a supported command acquiring unit for acquiring supported commands of each disk;
correspondingly, the encrypted data writing module 202 further includes:
and the third disk-to-be-written determining unit is used for determining the disk which contains the preset command in the supported commands as the disk to be written.
Preferably, when the disk identifier is a production date, the obtaining module 201 includes:
a setting ID acquisition unit for acquiring a setting ID of each disk;
correspondingly, the encrypted data writing module 202 includes:
and the fourth disk-to-be-written determining unit is used for taking the third target disk with the set ID in the target ID range as the disk-to-be-written.
Preferably, the disks in the upgraded storage system include a disk before upgrading and a newly inserted disk.
Since the embodiments of the apparatus portion and the method portion correspond to each other, please refer to the description of the embodiments of the method portion for the embodiments of the apparatus portion, which is not repeated here.
In the following, an electronic device provided by the embodiment of the present application is introduced, and the electronic device described below and the lock disk upgrading method described above may be referred to correspondingly.
Referring to fig. 3, fig. 3 is a structural diagram of an electronic device according to an embodiment of the present application, including:
a memory 100 for storing a computer program;
a processor 200 for implementing the steps of the above-mentioned lock-tray upgrade method when executing the computer program.
The memory 100 includes a nonvolatile storage medium, an internal memory. The non-volatile storage medium stores an operating system and computer-readable instructions, and the internal memory provides an environment for the operating system and the computer-readable instructions in the non-volatile storage medium to run. The processor 200 provides the computing and control capabilities for the electronic device to execute the computer programs stored in the memory 100.
On the basis of the foregoing embodiment, as a preferred implementation, referring to fig. 4, fig. 4 is a structural diagram of another electronic device provided in an embodiment of the present application, where the electronic device further includes:
and an input interface 300 connected to the processor 200, for acquiring computer programs, parameters and instructions imported from the outside, and storing the computer programs, parameters and instructions into the memory 100 under the control of the processor 200. The input interface 300 may be connected to an input device for receiving parameters or instructions manually input by a user. The input device may be a touch layer covered on a display screen, or a button, a track ball or a touch pad arranged on a terminal shell, or a keyboard, a touch pad or a mouse, etc.
And a display unit 400 connected to the processor 200 for displaying data transmitted by the processor 200. The display unit 400 may be a display screen on a PC, a liquid crystal display screen, or an electronic ink display screen.
And a network port 500 connected to the processor 200 for performing communication connection with each external terminal device. The communication technology adopted by the communication connection can be a wired communication technology or a wireless communication technology, such as a mobile high definition link (MHL) technology, a Universal Serial Bus (USB), a High Definition Multimedia Interface (HDMI), a wireless fidelity (WiFi), a bluetooth communication technology, a low power consumption bluetooth communication technology, an ieee802.11 s-based communication technology, and the like.
Since the embodiment of the electronic device portion corresponds to the embodiment of the lock disk upgrading method portion, please refer to the description of the embodiment of the lock disk upgrading method portion for the embodiment of the electronic device portion, and details are not repeated here.
The following describes a computer-readable storage medium provided by embodiments of the present application, and the computer-readable storage medium described below and the method described above may be referred to correspondingly.
The present embodiment provides a computer-readable storage medium, on which a computer program is stored, and when being executed by a processor, the computer program implements the steps of the above-mentioned lock disc upgrading method.
Since the embodiment of the computer-readable storage medium portion and the embodiment of the method portion correspond to each other, please refer to the description of the embodiment of the method portion for the embodiment of the computer-readable storage medium portion, which is not repeated here.
The embodiments are described in a progressive manner in the specification, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The above provides a method and an apparatus for upgrading a lock dial, an electronic device, and a computer-readable storage medium. The principles and embodiments of the present application are explained herein using specific examples, which are provided only to help understand the method and the core idea of the present application. It should be noted that, for those skilled in the art, it is possible to make several improvements and modifications to the present application without departing from the principle of the present application, and such improvements and modifications also fall within the scope of the claims of the present application.

Claims (10)

1. A lock disc upgrading method is characterized by comprising the following steps:
acquiring disk identifications of all disks of a storage system;
determining a disk to be written in from all the disks according to the disk identification, and writing encrypted data in the disk to be written;
when the locking disc version is upgraded, decrypting the encrypted data of the disc in the upgraded storage system;
when the decryption is successful, the disk which is successfully decrypted is online; and if the decryption fails, the off-line decryption fails.
2. The lock disk upgrading method according to claim 1, wherein when the disk identifier is a production date, the obtaining disk identifiers of all disks of the storage system includes:
acquiring the production dates of all the disks of the storage system;
correspondingly, the determining a disk to be written in from all the disks according to the disk identifier includes:
and taking the first target disk with the production date between preset dates as the disk to be written.
3. The lock disc upgrading method according to claim 2, further comprising:
and determining a second target disk which does not acquire the production date as the disk to be written.
4. The lock disk upgrading method according to claim 2, wherein the obtaining the production dates of all the disks of the storage system comprises:
issuing a date acquisition instruction to each disk to obtain feedback information of each disk;
judging whether the byte length of the feedback information is greater than or equal to a preset length or not;
and if the length is larger than or equal to the preset length, acquiring the production date.
5. The method for upgrading a lock disk according to claim 1, wherein when the disk identifier is a supported command, the obtaining disk identifiers of all disks of the storage system includes:
acquiring the supported commands of each disk;
correspondingly, the determining a disk to be written in from all the disks according to the disk identifier includes:
and determining the disk of which the supported command comprises a preset command as the disk to be written.
6. The lock disk upgrading method according to claim 1, wherein when the disk identifier is a set ID, the obtaining disk identifiers of all disks of the storage system includes:
acquiring the set ID of each disk;
correspondingly, the determining a disk to be written in from all the disks according to the disk identifier includes:
and taking the third target disk with the set ID in the target ID range as the disk to be written.
7. The lock disc upgrading method according to claim 1, wherein the upgraded disks in the storage system include a disk before upgrading and a newly inserted disk.
8. A lock disc upgrading device, comprising:
the acquisition module is used for acquiring the disk identifiers of all the disks of the storage system;
the encrypted data writing module is used for determining a disk to be written from all the disks according to the disk identification and writing encrypted data into the disk to be written;
the decryption module is used for decrypting the encrypted data of the disk in the storage system after upgrading the version of the locking disk;
the disk processing module is used for online decrypting the successful disk after decryption is successful; and if the decryption fails, the off-line decryption fails.
9. An electronic device, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the lock disc upgrading method according to any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the lock disc upgrading method according to any one of claims 1 to 7.
CN202110189213.3A 2021-02-19 2021-02-19 Lock disc upgrading method and device, electronic equipment and storage medium Active CN112905120B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110189213.3A CN112905120B (en) 2021-02-19 2021-02-19 Lock disc upgrading method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110189213.3A CN112905120B (en) 2021-02-19 2021-02-19 Lock disc upgrading method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112905120A true CN112905120A (en) 2021-06-04
CN112905120B CN112905120B (en) 2023-08-04

Family

ID=76123826

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110189213.3A Active CN112905120B (en) 2021-02-19 2021-02-19 Lock disc upgrading method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112905120B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114356233A (en) * 2021-12-30 2022-04-15 广东浪潮智慧计算技术有限公司 NVME disk locking realization method, device, equipment and medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105138477A (en) * 2015-07-21 2015-12-09 浪潮电子信息产业股份有限公司 Method for protecting hard disk data
US9798534B1 (en) * 2015-07-01 2017-10-24 EMC IP Holding Company LLC Method and system to perform non-intrusive online disk firmware upgrades
CN108898005A (en) * 2018-07-09 2018-11-27 郑州云海信息技术有限公司 A kind of hard disk knows method for distinguishing, system, equipment and computer readable storage medium
CN109002309A (en) * 2018-07-25 2018-12-14 郑州云海信息技术有限公司 A kind of HardwareUpgring method and relevant apparatus
CN109409112A (en) * 2018-10-19 2019-03-01 郑州云海信息技术有限公司 A kind of disk binding method and device
CN109407971A (en) * 2018-09-13 2019-03-01 新华三云计算技术有限公司 The method and device of staging disk lock
CN109522757A (en) * 2018-10-22 2019-03-26 郑州云海信息技术有限公司 A kind of server data disk lock collar device, method and server
CN110633585A (en) * 2019-08-08 2019-12-31 北京盛赞科技有限公司 Hard disk locking and unlocking method, device, equipment and readable storage medium
CN111695166A (en) * 2020-06-11 2020-09-22 北京百度网讯科技有限公司 Disk encryption protection method and device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9798534B1 (en) * 2015-07-01 2017-10-24 EMC IP Holding Company LLC Method and system to perform non-intrusive online disk firmware upgrades
CN105138477A (en) * 2015-07-21 2015-12-09 浪潮电子信息产业股份有限公司 Method for protecting hard disk data
CN108898005A (en) * 2018-07-09 2018-11-27 郑州云海信息技术有限公司 A kind of hard disk knows method for distinguishing, system, equipment and computer readable storage medium
CN109002309A (en) * 2018-07-25 2018-12-14 郑州云海信息技术有限公司 A kind of HardwareUpgring method and relevant apparatus
CN109407971A (en) * 2018-09-13 2019-03-01 新华三云计算技术有限公司 The method and device of staging disk lock
CN109409112A (en) * 2018-10-19 2019-03-01 郑州云海信息技术有限公司 A kind of disk binding method and device
CN109522757A (en) * 2018-10-22 2019-03-26 郑州云海信息技术有限公司 A kind of server data disk lock collar device, method and server
CN110633585A (en) * 2019-08-08 2019-12-31 北京盛赞科技有限公司 Hard disk locking and unlocking method, device, equipment and readable storage medium
CN111695166A (en) * 2020-06-11 2020-09-22 北京百度网讯科技有限公司 Disk encryption protection method and device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114356233A (en) * 2021-12-30 2022-04-15 广东浪潮智慧计算技术有限公司 NVME disk locking realization method, device, equipment and medium

Also Published As

Publication number Publication date
CN112905120B (en) 2023-08-04

Similar Documents

Publication Publication Date Title
JP5576983B2 (en) Secure boot and configuration of subsystems from non-local storage
CN106843978B (en) SDK access method and system
CN110022558B (en) Method for encrypting and decrypting upgrade package, electronic device and storage medium
JP2012150772A (en) Information processing apparatus and removable medium management method
CN106066803B (en) application program operation control method and device
CN107526608B (en) OTA upgrade package upgrading method and device
CN112905120A (en) Lock disc upgrading method and device, electronic equipment and storage medium
CN103793644A (en) Method for information safety device to achieve multiple applications, and information safety device and system
CN110764813A (en) Upgrading method of system software and running method thereof
US9275209B2 (en) Information processing device, control method therefor, program, and information storage medium
CN112579138A (en) Page display method and device, electronic equipment and storage medium
JP6390696B2 (en) License information management apparatus, license information management method, and program
CN109274656B (en) Interface parameter decryption method and device, computer equipment and storage medium
JP4940031B2 (en) Information processing apparatus and firmware update method
JP6393171B2 (en) Information processing terminal and control program for information processing terminal
CN108628619B (en) Program updating method and device
CN115543386A (en) Firmware encryption method, decryption method, processing device and medium
CN104615941A (en) Fast encryption method and device for Android user partition and terminal equipment
JP2023157072A (en) Program, computer, system, and method
CN110995462B (en) Cloud host function expansion method, system, equipment and computer storage medium
CN110045929B (en) Mounting point management method and related device
US20090187898A1 (en) Method for securely updating an autorun program and portable electronic entity executing it
CN112817622A (en) BIOS refreshing method and device, electronic equipment and storage medium
CN106775881B (en) System upgrading method and device
US20110099383A1 (en) Method for transmitting data and preventing unauthorized data duplication for human-machine interface device using mass storage class operating on universal serial bus

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
GR01 Patent grant
GR01 Patent grant