CN107665129A - Information processing method and storage device - Google Patents

Information processing method and storage device Download PDF

Info

Publication number
CN107665129A
CN107665129A CN201610619978.5A CN201610619978A CN107665129A CN 107665129 A CN107665129 A CN 107665129A CN 201610619978 A CN201610619978 A CN 201610619978A CN 107665129 A CN107665129 A CN 107665129A
Authority
CN
China
Prior art keywords
boot variable
storage
subregion
variable
storage medium
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
CN201610619978.5A
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.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing 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 Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN201610619978.5A priority Critical patent/CN107665129A/en
Priority to US15/664,038 priority patent/US20180032351A1/en
Publication of CN107665129A publication Critical patent/CN107665129A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the invention discloses a kind of information processing method and electronic equipment, methods described includes:First operating system is installed;Obtain the store path of the guidance code of first operating system and the systematic name of first operating system;According to the store path and the systematic name, boot variable is generated;The boot variable and the guidance code are stored in the first storage medium simultaneously.

Description

Information processing method and storage device
Technical field
The present invention relates to areas of information technology, more particularly to a kind of information processing method and storage device.
Background technology
Some operating systems (such as Extensible Firmware Interface (Unified Extensible Firmware Interface, UEFI) operating system) after installing, a UEFI guiding can will be generated in UEFI flash memory flash Variable come record UEFI operating systems to bootstrap store path.The UEFI boot variables can also record operation system simultaneously The title of system.
Because UEFI boot variables are stored in UEFI flash, if being stored with the operating system code and guiding generation When the storage medium of code is moved in another electronic equipment (such as electronic equipment A), electronic equipment A UEFI flash In do not store the UEFI boot variables, therefore the guidance code that can not find UEFI operating systems carries out UEFI operating systems Guiding.
The content of the invention
In view of this, the embodiment of the present invention it is expected to provide a kind of information processing method and electronic equipment, at least partly solves Above mentioned problem.
To reach above-mentioned purpose, the technical proposal of the invention is realized in this way:
First aspect of the embodiment of the present invention provides a kind of information processing method, including:
First operating system is installed;
Obtain the store path of the guidance code of first operating system and the systematic name of first operating system;
According to the store path and the systematic name, boot variable is generated;
The boot variable and the guidance code are stored in the first storage medium simultaneously.
It is described to store the boot variable and the guidance code simultaneously in the first storage medium based on such scheme, Including:
The storage of the boot variable will be write in the subregion entry field of n-th subregion of first storage medium Location;
In the storage location corresponding to the storage address of n-th subregion, the boot variable is write.
Based on such scheme, in the subregion entry field of n-th subregion by first storage medium described in write-in The storage address of boot variable, including:
The sector configured information of the boot variable storage is write in the subregion entry field of n-th subregion;
The storage location corresponding to the storage address in n-th subregion, the boot variable is write, wrapped Include:
The boot variable is write in the sector that n-th subregion corresponds to sector configured information instruction.
Based on such scheme, in the subregion entry field of n-th subregion by first storage medium described in write-in The storage address of boot variable, including:
In the attribute byte of the subregion entry field of n-th subregion, the sector configured information is write.
Based on such scheme, guiding entry field is provided with n-th subregion;
The guiding entry field includes store path byte and systematic name byte;
The storage location corresponding to the storage address in n-th subregion, the boot variable is write, wrapped Include:
The store path is stored in the store path byte;
The systematic name is stored in the systematic name byte.
Based on such scheme, the guiding entry field includes store path length byte and systematic name length byte;
Methods described also includes:
Byte number needed for the storage variable storage is stored in the store path length byte;
Byte number needed for the systematic name storage is stored in the systematic name length byte.
Based on such scheme, the guiding entry field includes origin identification byte and check byte;
Methods described also includes:
Origin identification is stored in the origin identification byte;
The check code of data storage in the guiding entry field is stored in the check byte.
Based on such scheme, methods described also includes:
When starting first operating system, the first boot variable is read from first storage medium;
Read the second boot variable in the second storage medium of first operating system;
Judge whether first boot variable and second boot variable are consistent;
When first boot variable and inconsistent second boot variable, read according to first boot variable The guidance code of first operating system.
It is described when first boot variable and inconsistent second boot variable based on such scheme, according to institute The guidance code that the first boot variable reads first operating system is stated, including:
When first boot variable and inconsistent second boot variable, first boot variable is replaced into institute State the second boot variable in the second storage medium;
Based on second boot variable after replacement, the guidance code of reading first operating system.
Based on such scheme, methods described also includes:
When first boot variable is consistent with second boot variable, institute is read according to second boot variable State guidance code.
Second aspect of the embodiment of the present invention provides a kind of electronic equipment, including processor and is connected with the processor At least one memory;The memory includes multiple storage mediums;
The processor, for installing the first operating system;Obtain the storage of the guidance code of first operating system Path and the systematic name of first operating system;According to the store path and the systematic name, boot variable is generated;
The processor, it is additionally operable to store the boot variable and guidance code storage simultaneously to depositing described in same In storage media.
Based on such scheme, the storage medium for storing the boot variable and the guidance code is the first storage medium; First storage medium includes N number of subregion;Wherein, the N is the integer not less than 1;
The processor, specifically for institute will be write in the subregion entry field of the n-th subregion of first storage medium State the storage address of boot variable;In the storage location corresponding to the storage address of n-th subregion, the guiding is write Variable;Wherein, the n is the positive integer no more than the N.
Based on such scheme, first storage medium is also stored with partition table;
The processor, specifically for the subregion of the n-th subregion described in the partition table in first storage medium The sector configured information of the boot variable storage is write in entry field;And refer in n-th subregion corresponding to the sector Show in the sector of information instruction and write the boot variable.
Based on such scheme, the processor, specifically for the subregion of n-th subregion in first storage medium In the attribute byte of entry field, the sector configured information is write.
Based on such scheme, guiding entry field is provided with n-th subregion;
The guiding entry field includes store path byte and systematic name byte;
The processor, specifically for described in storage in the store path byte that is stored in first storage medium The systematic name is stored in store path and the systematic name byte.
Based on such scheme, the guiding entry field includes store path length byte and systematic name length byte;
The processor, it is additionally operable to store institute in the store path length byte of first storage medium storage State and byte needed for the systematic name storage is stored in byte number needed for storage variable storage and the systematic name length byte Number.
Based on such scheme, the guiding entry field includes origin identification byte and check byte;
The processor, it is additionally operable to the storage starting mark in the origin identification byte of first storage medium storage The check code of data storage in the guiding entry field is stored in knowledge and the check byte.
Based on such scheme, the memory also includes second storage medium different from first storage medium;Institute Processor is stated to be connected with second storage medium;
The processor, specifically for when starting first operating system, being read from first storage medium First boot variable;The second boot variable is read from second storage medium;Judge first boot variable and described Whether two boot variables are consistent;When first boot variable and inconsistent second boot variable, according to described first Boot variable reads the guidance code of first operating system.
Based on such scheme, the processor, specifically for when first boot variable and second boot variable When inconsistent, first boot variable is replaced into the second boot variable in second storage medium;After replacement Second boot variable, read the guidance code of first operating system.
Based on such scheme, the processor, it is additionally operable to work as first boot variable and second boot variable one During cause, the guidance code is read according to second boot variable.
The third aspect of the embodiment of the present invention provides a kind of electronic equipment, including:
Installation unit, for installing the first operating system;
Acquiring unit, the store path and described first of the guidance code for obtaining first operating system operate system The systematic name of system;
Generation unit, for according to the store path and the systematic name, generating boot variable;
Memory cell, for storing the boot variable and the guidance code simultaneously in the first storage medium.
Information processing method and electronic equipment provided in an embodiment of the present invention, boot variable and guidance code storage can be arrived In same storage medium, when so the storage medium migrates, boot variable and guidance code synchronous migration, like this, no Can lead to not because boot variable and guidance code not migrate together according to boot variable, read guidance code and then Caused the problem of can not guiding the first operating system;Also include the systematic name of the first operating system in boot variable simultaneously, Therefore the correctness of the systematic name of the first operating system is ensure that simultaneously.
Brief description of the drawings
Fig. 1 is the schematic flow sheet of the first information processing method provided in an embodiment of the present invention;
Fig. 2 is the schematic flow sheet of second of information processing method provided in an embodiment of the present invention;
Fig. 3 is the subregion schematic diagram of a kind of first storage medium provided in an embodiment of the present invention or the first storage medium;
Fig. 4 is the third information processing method schematic flow sheet provided in an embodiment of the present invention;
Fig. 5 is the structural representation of the first electronic equipment provided in an embodiment of the present invention;
Fig. 6 is the structural representation of second of electronic equipment provided in an embodiment of the present invention;
Fig. 7 is the schematic flow sheet of the third information processing method provided in an embodiment of the present invention.
Embodiment
Technical scheme is further elaborated below in conjunction with Figure of description and specific embodiment.
Embodiment one:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
Described in the present embodiment information processing processing method can apply in various electronic equipments, such as, desktop computer, The various electronic equipments such as notebook computer, tablet personal computer or server.
The step S110 installs the first operating system, and the operating system can be various types of operating systems, such as Common Windows systems etc.;First operating system can also be UEFI systems etc. in the present embodiment.Installing described the After one operating system, the operation code of first operating system is storable in first storage medium.
The guidance code can be referred to as bootstrap again, to guide the code of first os starting.
The boot variable can be stored in the position beyond any storage boot variable, example in the present embodiment Such as, it is storable in protection MBR (the Protective Master Boot of the 1st sector of first storage medium Record, PMBR) reserve bytes in.For example, first storage medium is magnetic disc contingency table (GUID Partition Table, GPT) form storage medium.The boot variable can be then stored in the first storage medium of the GPT forms In PMBR reserve bytes.By boot variable storage into the reservation variable, on the one hand realize the guiding and become The storage of amount, on the other hand also achieve it is maximum compatible with prior art, avoid influence boot variable in the first storage medium On storage influence other information storage.Certainly, it should be noted that:The boot variable is not limited to be stored in described In the reserve bytes in the subregion head of form portion of 1 sector.The Chinese of the GUID is GUID, to should be Globally Unique Identifier abbreviation.
The store path and systematic name of the guidance code of first operating system will be obtained in the present embodiment, can be with By electronic equipment by performing preset program code, automatically according to the storage location of bootstrap, generate the store path and Systematic name;Electronic equipment automatically generates, and has the characteristics of error rate is low.
Boot variable will be generated according to store path and systematic name in step s 130.In the prior art, generally Guidance code is in storage hard disk, and the bootstrap is stored in BIOS, facilitates BIOS performing the guidance code, root According to the boot variable being stored in BIOS, the corresponding storage location to hard disk reads the bootstrap, to complete operating system The bootup process of startup.But in the present embodiment, the boot variable and the guidance code can be stored in same deposit Storage media, the storage medium are referred to as the first storage medium in the present embodiment.Like this, when the first storage medium is from an electricity Sub- equipment, when moving in another electronic equipment, electronic equipment can still can drawing in first storage medium Variable is led, obtains the storage location of the boot variable, and can accurately be obtained according to the boot variable and be located at described first The systematic name of the first operating system in storage medium.Obviously, the boot variable and guidance code one are led to and are stored in together In one storage medium, easy solve that boot variable caused by storage medium migration in the prior art is lost or mistake is asked Topic.
Embodiment two:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
As described in Figure 2, the step S140 may include:
Step S141:The boot variable will be write in the subregion entry field of n-th subregion of first storage medium Storage address;
Step S142:In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount.
First storage medium can be divided into N number of subregion in the present embodiment;Each described subregion both corresponds to one Individual subregion entry field.The subregion entry field stores first storage medium and specially hewed out for indicating each subregion Storage region.The N is the positive integer not less than the n.
The storage address of the boot variable is write in the subregion entry field of n-th subregion in the present embodiment, So electronic equipment subsequently when scanning first storage medium, can by scanning and parsing the subregion entry field, Determine which subregion the boot variable is stored in.
The information of electronic equipment is read for convenience in the present embodiment, when the boot variable is stored in the n-th subregion, The storage address of boot variable is just write in the subregion entry field of the n-th subregion, such electronic equipment arrives in the n-th subarea-scanning The storage address of boot variable, the boot variable is just read to the n-th subregion correspondence position according to the storage address.Utilize, profit The boot variable is stored with subregion, and guides in subregion entry field the mode of the instruction of the storage address of variable, It is same that there is realization simplicity, the compatible big feature with prior art.
It is illustrated in figure 3 the GPT format layout schematic diagrames of first storage medium;First storage medium includes master Subregion form area, backup subregion form area and each subregion.
PMBR and subregion form (Partition Table Header, PTH) are stored with the Zhu Fen forms area.Institute State and carry on the back anti-subregion form area and be stored with subregion form for backup.
Include the subregion entry field of subregion gauge outfit and each subregion in the subregion form.N-th of cutting entrance Field at least may be used to indicate the original position and final position of n-th of subregion.In figure 3, the LBA is logical blocks Location, it is Logical Bloock Address;LBA0 represents the 1st logical block addresses 0, and LBA1 represents logical block addresses 1, LBAm represents logical blocks m.One logical block addresses corresponds to a logical blocks.
Table 1 is the description of the subregion entry field:
Table 1
Embodiment three:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
The step S140 may include:
As described in Figure 2, the step S140 may include:
Step S141:The boot variable will be write in the subregion entry field of n-th subregion of first storage medium Storage address;
Step S142:In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount.
The step S141 may include:
The sector configured information of the boot variable storage is write in the subregion entry field of n-th subregion;One The subregion may include multiple sectors, be written to the subregion entry field (Partition Entry, PE) in the present embodiment In storage address be the sector configured information such as sector mark of instruction storage sector, so facilitate electronic equipment to need reading to draw When leading variable, by scanning the corresponding sector of the n-th subregion, the boot variable of acquisition.
It is described to may include in step S142:In the sector that n-th subregion corresponds to sector configured information instruction Write the boot variable.
The usual boot variable can be stored in any one sector of the n-th subregion, electric for convenience in this embodiment The information of sub- equipment is read, and the sector for preferably storing the boot variable is the first sector of the n-th subregion or last fan Area.So, the original position for the n-th subregion that electronic equipment can be directly in subregion entry field orients first sector, Or last sector is positioned according to final position, the easy reading of the boot variable is completed, lifts reading efficiency.
Example IV:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
The step S140 may include:
As described in Figure 2, the step S140 may include:
Step S141:The boot variable will be write in the subregion entry field of n-th subregion of first storage medium Storage address;
Step S142:In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount.
The step S141 may include:The boot variable storage is write in the subregion entry field of n-th subregion Sector configured information, for example, in the attribute byte of the subregion entry field of n-th subregion, write the sector instruction Information.
It is described to may include in step S142:In the sector that n-th subregion corresponds to sector configured information instruction Write the boot variable.
Include attribute byte in the subregion entry field of the n-th subregion.Attribute byte is reserved byte in the prior art, Currently without content is defined, the sector configured information of the boot variable is write in attribute byte in the present embodiment, can be with It is compatible with prior art well, avoid influenceing the distribution of existing subregion entry field other guide;With the strong spy of compatibility Point.
Table 2 is the description of each bit Bit in attribute byte:
Bits Description
Bit0 ……
Bit1
Bits2-47 Reservation bit, default value 0 ...
Bits48-63 Reserve bytes for GUID specific uses
Table 2
It can be used for the storage that one or more bits in Bits2-47 record the boot variable in the present embodiment Location.For example, in the present embodiment can be such as table 3 below after the attribute byte modification:
Bits Description
Bit0 ……
Bit1
Bit2 Indicate the storage address of storage boot variable
Bits3-47 Reservation bit, default value 0 ...
Bits48-63 Reserve bytes for GUID specific uses
Table 3
Specifically such as, being specifically defined for the Bit2 of the attribute byte can be such as table 4 below:
Bits Content
Bit2 Originate LBA or terminate LBA
Table 4
If the Bit2 of attribute byte content is as shown in table 4, then it represents that is deposited in the starting LBA or termination LBA of n-th of subregion Store up the storage address of the boot variable.
Embodiment five:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
The step S140 may include:
As described in Figure 2, the step S140 may include:
Step S141:The boot variable will be write in the subregion entry field of n-th subregion of first storage medium Storage address;
Step S142:In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount.
Guiding entry field is provided with n-th subregion.In the present embodiment in the subregion of write-in boot variable A new field is introduced, referred to as described guiding entry field;It is described guiding entry field include store path byte with And systematic name byte.
Described 142 may include:
The store path is stored in the store path byte;
The systematic name is stored in the systematic name byte.
Guiding entry field comprises at least store path byte and systematic name byte in the present embodiment.In store path Store path in byte;The storage system title in systematic name byte, like this, electronic equipment are reading boot variable When, corresponding byte can be arrived and read the systematic name and the store path;Convenient can be read according to store path guides Code, and read systematic name.
Embodiment six:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
The step S140 may include:
As described in Figure 2, the step S140 may include:
Step S141:The boot variable will be write in the subregion entry field of n-th subregion of first storage medium Storage address;
Step S142:In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount.
Guiding entry field is provided with n-th subregion.
Described 142 may include:
The store path is stored in the store path byte;
The systematic name is stored in the systematic name byte.
The guiding entry field includes store path length byte and systematic name length byte;
Methods described also includes:
Byte number needed for the storage variable storage is stored in the store path length byte;
Byte number needed for the systematic name storage is stored in the systematic name length byte.
In order to facilitate the reading of Subsequent electronic equipment, in the present embodiment also in the booting operating system entry field Also include store path length byte and systematic name length byte, have recorded store path in storage boot variable respectively and be Byte number needed for title of uniting, so facilitates reading of the Subsequent electronic equipment by the byte number, determines shared by storage address Byte number shared by byte number and systematic name, so as to simplify the read operation of electronic equipment.
Embodiment seven:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
The step S140 may include:
As described in Figure 2, the step S140 may include:
Step S141:The boot variable will be write in the subregion entry field of n-th subregion of first storage medium Storage address;
Step S142:In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount.
Guiding entry field is provided with n-th subregion.
Described 142 may include:
The store path is stored in the store path byte;
The systematic name is stored in the systematic name byte.
Methods described also includes:
Byte number needed for the storage variable storage is stored in the store path length byte;
Byte number needed for the systematic name storage is stored in the systematic name length byte.
In the present embodiment, the guiding entry field includes origin identification byte and check byte;
Methods described also includes:
Origin identification is stored in the origin identification byte;
The check code of data storage in the guiding entry field is stored in the check byte.
Origin identification is stored by origin identification byte in the present embodiment, so facilitates electronic equipment to pass through origin identification Scanning or reading, simplicity confirms to have had been enter into the reading of boot variable at present.
In addition, in order to ensure the correctness of information, check byte is also introduced in this embodiment, and school is stored in check byte Code is tested, the check code can be used for verifying the other information in guiding entry field, if verification is correct, then it is assumed that work as leading The boot variable stored in introducing port byte is correct, and otherwise it is believed that there is mistake, to prevent the phenomenon illegally distorted, lifting is drawn Lead the memory reliability of variable.
Table 5 is a kind of definition of the guiding entry field:
Table 5
Embodiment eight:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
As shown in figure 4, methods described also includes:
Step S210:When starting first operating system, the first guiding is read from first storage medium and is become Amount;
Step S220:Read the second boot variable in the second storage medium of first operating system;
Step S230:Judge whether first boot variable and second boot variable are consistent;
Step S240:When first boot variable and inconsistent second boot variable, draw according to described first Lead the guidance code that variable reads first operating system.
The first operating system is starting in the present embodiment, usual basic input output system (Basic Input Output System, BIOS) the second storage medium in may be stored with the second boot variable;In the present embodiment will storage Boot variable in first storage medium is the first boot variable.But the phenomenon of hard disk migration is there may be, therefore In the present embodiment when reading boot variable, the first boot variable can be read from the first storage medium, then deposit with the second of BIOS The second boot variable in storage media is compared.Second storage medium obviously stores with described first in the present embodiment Medium is not same storage medium, and is the operation code for not storing the boot variable and first operating system It is storage medium.
When first boot variable and second boot variable are inconsistent, i.e. the first boot variable and the second guiding Variable is different, then can be defined by the first boot variable, directly reads guidance code according to the first boot variable;Obviously so solve Guidance code caused by hard disk migration can not correctly be read, caused by entering can not normal boot operating system the problem of.
It is worth noting that:The present embodiment is the further improvement on the basis of any one foregoing embodiment, described Specific storage location and specific storage mode of one boot variable in first storage medium, may refer to embodiment two to Implement seven, be not just repeated herein.
Implement nine:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
As shown in figure 4, methods described also includes:
Step S210:When starting first operating system, the first guiding is read from first storage medium and is become Amount;
Step S220:Read the second boot variable in the second storage medium of first operating system;
Step S230:Judge whether first boot variable and second boot variable are consistent;
Step S240:When first boot variable and inconsistent second boot variable, draw according to described first Lead the guidance code that variable reads first operating system.
The step S240 may include:
When first boot variable and inconsistent second boot variable, first boot variable is replaced into institute State the second boot variable in the second storage medium;
Based on second boot variable after replacement, the guidance code of reading first operating system.
First boot variable is replaced into the second boot variable in the second storage medium, in the present embodiment on the one hand In order to facilitate the BIOS currently readings to guidance code;On the other hand reading of the BIOS next times to boot variable can be facilitated.
Embodiment ten:
As shown in figure 1, the present embodiment provides a kind of information processing method, including:
Step S110:First operating system is installed;
Step S120:Obtain the store path of the guidance code of first operating system and first operating system Systematic name;
Step S130:According to the store path and the systematic name, boot variable is generated;
Step S140:The boot variable and the guidance code are stored in the first storage medium simultaneously.
As shown in figure 4, methods described also includes:
Step S210:When starting first operating system, the first guiding is read from first storage medium and is become Amount;
Step S220:Read the second boot variable in the second storage medium of first operating system;
Step S230:Judge whether first boot variable and second boot variable are consistent;
Step S240:When first boot variable and inconsistent second boot variable, draw according to described first Lead the guidance code that variable reads first operating system.
Methods described also includes:
When first boot variable is consistent with second boot variable, institute is read according to second boot variable State guidance code.
When first boot variable is consistent with second boot variable in the present embodiment, show that being stored in second deposits Boot variable in storage media is correct, therefore directly can read the guidance code by the second boot variable.
Embodiment 11:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
Processor 110 described in the present embodiment may correspond to various process chips or process circuit, specifically may include center Processor CPU, Micro-processor MCV, digital signal processor DSP, application processor AP, programmable array PLC or special are integrated Circuit ASIC etc..The processor 110 can complete above-mentioned first operating system by performing predetermined code in the present embodiment Installation, the operation such as generation of boot variable.
The memory 120 can be various storage mediums, the memory that preferably non-moment storage medium is formed, for example, The memory formed by flash memory flash.
The processor 110 and memory 120 are detachably connected, such after memory is dismantled, with other processing Device connection after, due in same memory, be both stored with the first operating system to operation code, guidance code and The boot variable, other processors are facilitated directly according to the boot variable being stored in the memory, to determine guidance code Storage location, determine the systematic name of the first operating system;Solve in the prior art, electronic equipment is by guidance code and guiding Variable storage is in different memories, after a memory migrates, causes electronic equipment can not find guiding generation Code, the problem of the first operating system can not be guided.
The bus 130 for connecting the processor 110 and the memory 120 is also shown in Figure 5.Here bus can For various types of buses, information exchange can be carried out, for example, can be pci bus or IIS buses.Here memory 120 can By the detachable interface in the buses such as pci bus or IIS, to be connected with the processor 110.
Embodiment 12:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The storage medium for storing the boot variable and the guidance code is the first storage medium 121;Described first deposits Storage media 121 includes N number of subregion;Wherein, the N is the integer not less than 1;
The processor 110, specifically for will be write in the subregion entry field of the n-th subregion of first storage medium The storage address of the boot variable;In the storage location corresponding to the storage address of n-th subregion, draw described in write-in Lead variable;Wherein, the n is the positive integer no more than the N.
The first storage medium 121 can be divided N number of area by the processor 110 in the present embodiment.Institute in the present embodiment The n-th subregion can be stored in by guidance code by stating processor 110;Boot variable can be stored in the subregion entrance of the n-th subregion simultaneously In field.Here the associated description of subregion entry field may refer in previous embodiment.
Guidance code is stored in which subregion of the first storage medium 121 in the present embodiment, just by corresponding guiding Variable storage is into the subregion entry field of the subregion, the follow-up reading of convenient processor 110.
Embodiment 13:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The storage medium for storing the boot variable and the guidance code is the first storage medium 121;Described first deposits Storage media 121 includes N number of subregion;Wherein, the N is the integer not less than 1;
The processor 110, specifically for will be write in the subregion entry field of the n-th subregion of first storage medium The storage address of the boot variable;In the storage location corresponding to the storage address of n-th subregion, draw described in write-in Lead variable;Wherein, the n is the positive integer no more than the N.
First storage medium 121 is also stored with partition table.The associated description of the partition table may refer to foregoing right The embodiment of the method answered.
The processor 110, specifically for the n-th subregion described in the partition table in first storage medium 121 Subregion entry field in write the sector configured information of boot variable storage;And correspond in n-th subregion described The boot variable is write in the sector of sector configured information instruction.
The processor 110 in the present embodiment, by the subregion entry field of the n-th subregion of the first storage medium 121 Sector configured information is write, the sector of generally described sector configured information instruction, can be only used for storing boot variable.So, after Continue the processor 110 to read the guidance code directly according to the boot variable read from the sector, realize easy.
Embodiment 14:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The storage medium for storing the boot variable and the guidance code is the first storage medium 121;Described first deposits Storage media 121 includes N number of subregion;Wherein, the N is the integer not less than 1;
The processor 110, specifically for will be write in the subregion entry field of the n-th subregion of first storage medium The storage address of the boot variable;In the storage location corresponding to the storage address of n-th subregion, draw described in write-in Lead variable;Wherein, the n is the positive integer no more than the N.
First storage medium 121 is also stored with partition table;
The processor 110, specifically for the n-th subregion described in the partition table in first storage medium 121 Subregion entry field in write the sector configured information of boot variable storage;And correspond in n-th subregion described The boot variable is write in the sector of sector configured information instruction.
The processor 110, specifically for the subregion entry field of n-th subregion in first storage medium In attribute byte, the sector configured information is write.
In specific application, the processor 110 can write sector and refer in the attribute byte of the subregion entrance byte Show information;And attribute byte is reserve bytes, the byte for being reserved to UEFI systems generally can be.
The sector configured information is stored in the attribute byte of reservation, have with prior art compatibility it is strong the characteristics of.
Embodiment 15:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The storage medium for storing the boot variable and the guidance code is the first storage medium 121;Described first deposits Storage media 121 includes N number of subregion;Wherein, the N is the integer not less than 1;
The processor 110, specifically for will be write in the subregion entry field of the n-th subregion of first storage medium The storage address of the boot variable;In the storage location corresponding to the storage address of n-th subregion, draw described in write-in Lead variable;Wherein, the n is the positive integer no more than the N.
First storage medium 121 is also stored with partition table;
The processor 110, specifically for the n-th subregion described in the partition table in first storage medium 121 Subregion entry field in write the sector configured information of boot variable storage;And correspond in n-th subregion described The boot variable is write in the sector of sector configured information instruction.
The processor 110, specifically for the subregion entry field of n-th subregion in first storage medium In attribute byte, the sector configured information is write.
Guiding entry field is provided with n-th subregion;
The guiding entry field includes store path byte and systematic name byte;
The processor 110, specifically for being deposited in the store path byte that is stored in first storage medium 121 Store up in the store path and the systematic name byte and store the systematic name.
The guiding entry field comprises at least store path byte and systematic name byte, Ke Yifen in the present embodiment Not Xie Ru store path and systematic name, so have realize the characteristics of easy.
Embodiment 16:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The storage medium for storing the boot variable and the guidance code is the first storage medium 121;Described first deposits Storage media 121 includes N number of subregion;Wherein, the N is the integer not less than 1;
The processor 110, specifically for will be write in the subregion entry field of the n-th subregion of first storage medium The storage address of the boot variable;In the storage location corresponding to the storage address of n-th subregion, draw described in write-in Lead variable;Wherein, the n is the positive integer no more than the N.
First storage medium 121 is also stored with partition table;
The processor 110, specifically for the n-th subregion described in the partition table in first storage medium 121 Subregion entry field in write the sector configured information of boot variable storage;And correspond in n-th subregion described The boot variable is write in the sector of sector configured information instruction.
The processor 110, specifically for the subregion entry field of n-th subregion in first storage medium In attribute byte, the sector configured information is write.
Guiding entry field is provided with n-th subregion;
The guiding entry field includes store path byte and systematic name byte;
The processor 110, specifically for being deposited in the store path byte that is stored in first storage medium 121 Store up in the store path and the systematic name byte and store the systematic name.
The guiding entry field includes store path length byte and systematic name length byte;
The processor 110, it is additionally operable in the store path length byte of first storage medium 121 storage Store in byte number needed for the storage variable storage and the systematic name length byte and store the systematic name storage institute Need byte number.
In the present embodiment, the processor 110, it is additionally operable to the store path length in the storage of the first storage medium 121 Byte and systematic name byte, the byte number needed for write-in store path and systematic name, facilitate subsequent processor according to storage Required byte number, read store path and systematic name.
In another scheme of the present embodiment, the guiding entry field includes origin identification byte and check word Section;The processor 110, it is additionally operable to store origin identification in the origin identification byte of first storage medium storage And the check code of data storage in the guiding entry field is stored in the check byte.Introducing and school by start byte The storage of check code in byte is tested, a side facilitates reading of the electronic equipment to boot variable, on the other hand can also utilize school Test code and carry out Information Authentication, it is ensured that the accuracy of boot variable storage.
Embodiment 17:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The memory 120 also includes the second storage medium 122;First storage medium 121 and second storage Medium 122 is different storage medium.Second storage medium 122 may include and BIOS in electronic equipment is integrally disposed deposits Storage media.Being established between the processor 110 and second storage medium 122 has connection, and the connection, which can be, to be detachably connected, Can also be non-be detachably connected.
The processor 110, specifically for when starting first operating system, from first storage medium 121 The first boot variable of middle reading;The second boot variable is read from second storage medium 122;Judge first boot variable It is whether consistent with second boot variable;When first boot variable and inconsistent second boot variable, foundation First boot variable reads the guidance code of first operating system.In the present embodiment can be to be located at guidance code Guidance code in same memory is defined, and carries out the reading of the guidance code.The processor 110 can pass through predetermined generation The execution of code, read the first boot variable from the first storage medium 121 and the second storage medium 122 respectively and the second guiding becomes Amount, and compare the first boot variable and the second boot variable, when determining the first boot variable and the second boot variable difference, with First boot variable, which is defined, reads the guidance code, it is possible to reduce guidance code reads less than or can not guide the first operation system The phenomenon of system.
As further improvement of this embodiment, the processor 110, it is additionally operable to when first boot variable and described When second boot variable is consistent, the guidance code is read according to second boot variable.The processing in the present embodiment When device 110 determines the first boot variable and consistent the second boot variable, guidance code is directly read according to the second boot variable, Display is feasible, and is that reading efficiency is high.
Embodiment 18:
As shown in figure 5, second aspect of the embodiment of the present invention provide a kind of electronic equipment, including processor 110 and with institute State at least one memory 120 that processor 110 is detachably connected;The memory includes multiple storage mediums;
The processor 110, for installing the first operating system;Obtain depositing for the guidance code of first operating system Store up the systematic name of path and first operating system;According to the store path and the systematic name, generation guiding becomes Amount;
The processor 110, it is additionally operable to store the boot variable simultaneously and same institute is arrived in guidance code storage State in storage medium.
The memory 120 also includes and the first storage medium 121 and the second storage medium 122;The memory 120 is also Including the second storage medium 122;First storage medium 121 and second storage medium 122 are different storage mediums. Being established between the processor 110 and second storage medium 122 has connection.
The processor 110, specifically for when starting first operating system, from first storage medium 121 The first boot variable of middle reading;The second boot variable is read from second storage medium 122;Judge first boot variable It is whether consistent with second boot variable;When first boot variable and inconsistent second boot variable, foundation First boot variable reads the guidance code of first operating system.
The processor 110, will specifically for when first boot variable and inconsistent second boot variable First boot variable replaces the second boot variable in second storage medium;Based on second guiding after replacement Variable, read the guidance code of first operating system.
If there is the first boot variable in the present embodiment and the second boot variable is inconsistent, in the present embodiment the place The second boot variable in second storage medium can be replaced with first boot variable by reason device 110, so conveniently next time Quickly read the boot variable.
Embodiment 19:
As shown in fig. 6, the embodiment of the present invention also provides a kind of electronic equipment, including:
Installation unit 210, for installing the first operating system;
Acquiring unit 220, the store path and described first of the guidance code for obtaining first operating system are grasped Make the systematic name of system;
Generation unit 230, for according to the store path and the systematic name, generating boot variable;
Memory cell 240, for storing the boot variable and the guidance code simultaneously in the first storage medium.
The electronic equipment can be the device corresponding to any one foregoing embodiment of the method in the present embodiment.The peace Dress unit 210, acquiring unit 220 and generation unit 230 can all correspond to processor or process circuit, the processor or processing Circuit may refer to associated description in previous embodiment, just not be repeated again.The memory cell 240 can in the present embodiment Corresponding to various storage chips, boot variable and guidance code can be stored simultaneously in the first storage medium, avoid storage from being situated between The problem of guidance code caused by matter migration can not read and can not guide the first operating system.
In certain embodiments, the memory cell 240, can be specifically used for the n-th subregion of first storage medium Subregion entry field in write the storage address of the boot variable;Correspond to the storage address in n-th subregion Storage location, write the boot variable.
In certain embodiments, the memory cell 240, the subregion entry field in n-th subregion can be specifically used for The sector configured information of the middle write-in boot variable storage;Indicated in n-th subregion corresponding to the sector configured information Sector in write the boot variable.For example, the memory cell 240, specifically for the subregion entrance in n-th subregion In the attribute byte of field, the sector configured information is write.
In certain embodiments, it is provided with guiding entry field in n-th subregion;The guiding entry field includes Store path byte and systematic name byte;The memory cell 240, institute is stored available in the store path byte State store path;The systematic name is stored in the systematic name byte.
In certain embodiments, the guiding entry field includes store path length byte and systematic name length word Section.The memory cell 240, it is additionally operable to store byte needed for the storage variable storage in the store path length byte Number;Byte number needed for the systematic name storage is stored in the systematic name length byte.
In addition, the guiding entry field includes origin identification byte and check byte;The memory cell 240 may be used also For storing origin identification in the origin identification byte;Store in the check byte and deposited in the guiding entry field Store up the check code of data.
In certain embodiments, the electronic equipment also includes processing unit, and the processing unit may correspond to aforementioned processing Device or process circuit.The processing unit, specifically for when starting first operating system, from first storage medium The first boot variable of middle reading;Read the second boot variable in the second storage medium of first operating system;Judge institute State the first boot variable and whether second boot variable is consistent;When first boot variable and second boot variable When inconsistent, the guidance code of first operating system is read according to first boot variable.For example, the processing is single Member, specifically for described when first boot variable and inconsistent second boot variable, the described first guiding is become Amount replaces the second boot variable in second storage medium;Based on second boot variable after replacement, described in reading The guidance code of first operating system.
In some another outer embodiments, the processing unit, it may also be used for when first boot variable and described the When two boot variables are consistent, the guidance code is read according to second boot variable.
Below in conjunction with above-described embodiment, there is provided a specific example:
As shown in fig. 7, this example, which provides a kind of information processing method, includes two stages:
First stage:Original system where storage medium
Step S1:Operating system OS installation procedures start;
Step S2:Create hard disk GPT partition tables;
Step S3:UEFI operating systems are installed;
Step S4:By the special section of boot variable write-in storage medium.During concrete implementation, here special Sector can be any one sector of memory., can also be by the boot variable in order to facilitate the reading of Subsequent electronic equipment Storage address, write in the subregion entry field of the subregion.Here special section can be any one sector of corresponding subregion, The preferably first sector or last sector of the subregion, can so facilitate the boot variable of electronic equipment to read.
Second stage:System after storage medium movement;
Step S6:Operating system power-up starts;
Step S7:Detect the guiding entry field of the special section of storage medium;
Step S8:Judging to detect from the boot variable that BIOS is read and the boot variable in the guiding entry field is It is no consistentIf into step S10, if not into step S9.
Step S9:Rebuild UEFI OS boot variables.Here establishment, by drawing in the guiding entry field of special section Variable is led to be written in BIOS storage memory.
Step S10:UEFI operating systems are guided using bootstrap.Here bootstrap is foregoing guiding generation Code.
In several embodiments provided herein, it should be understood that disclosed apparatus and method, it can be passed through Its mode is realized.Apparatus embodiments described above are only schematical, for example, the division of the unit, is only A kind of division of logic function, there can be other dividing mode when actually realizing, such as:Multiple units or component can combine, or Another system is desirably integrated into, or some features can be ignored, or do not perform.In addition, shown or discussed each composition portion Point mutual coupling or direct-coupling or communication connection can be the INDIRECT COUPLINGs by some interfaces, equipment or unit Or communication connection, can be electrical, mechanical or other forms.
The above-mentioned unit illustrated as separating component can be or may not be physically separate, show as unit The part shown can be or may not be physical location, you can positioned at a place, can also be distributed to multiple network lists In member;Partly or entirely unit therein can be selected to realize the purpose of this embodiment scheme according to the actual needs.
In addition, each functional unit in various embodiments of the present invention can be fully integrated into a processing module, also may be used To be each unit individually as a unit, can also two or more units it is integrated in a unit;It is above-mentioned Integrated unit can both be realized in the form of hardware, can also be realized in the form of hardware adds SFU software functional unit.
One of ordinary skill in the art will appreciate that:Realizing all or part of step of above method embodiment can pass through Programmed instruction related hardware is completed, and foregoing program can be stored in a computer read/write memory medium, the program Upon execution, the step of execution includes above method embodiment;And foregoing storage medium includes:It is movable storage device, read-only Memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disc or Person's CD etc. is various can be with the medium of store program codes.
The foregoing is only a specific embodiment of the invention, but protection scope of the present invention is not limited thereto, any Those familiar with the art the invention discloses technical scope in, change or replacement can be readily occurred in, should all be contained Cover within protection scope of the present invention.Therefore, protection scope of the present invention should be based on the protection scope of the described claims.

Claims (21)

  1. A kind of 1. information processing method, it is characterised in that including:
    First operating system is installed;
    Obtain the store path of the guidance code of first operating system and the systematic name of first operating system;
    According to the store path and the systematic name, boot variable is generated;
    The boot variable and the guidance code are stored in the first storage medium simultaneously.
  2. 2. according to the method for claim 1, it is characterised in that
    It is described to store the boot variable and the guidance code simultaneously in the first storage medium, including:
    The storage address of the boot variable will be write in the subregion entry field of n-th subregion of first storage medium;
    In the storage location corresponding to the storage address of n-th subregion, the boot variable is write.
  3. 3. according to the method for claim 2, it is characterised in that
    The storage of the boot variable is write in the subregion entry field of n-th subregion by first storage medium Location, including:
    The sector configured information of the boot variable storage is write in the subregion entry field of n-th subregion;
    The storage location corresponding to the storage address in n-th subregion, the boot variable is write, including:
    The boot variable is write in the sector that n-th subregion corresponds to sector configured information instruction.
  4. 4. according to the method for claim 3, it is characterised in that
    The storage of the boot variable is write in the subregion entry field of n-th subregion by first storage medium Location, including:
    In the attribute byte of the subregion entry field of n-th subregion, the sector configured information is write.
  5. 5. according to the method for claim 2, it is characterised in that
    Guiding entry field is provided with n-th subregion;
    The guiding entry field includes store path byte and systematic name byte;
    The storage location corresponding to the storage address in n-th subregion, the boot variable is write, including:
    The store path is stored in the store path byte;
    The systematic name is stored in the systematic name byte.
  6. 6. according to the method for claim 5, it is characterised in that
    The guiding entry field includes store path length byte and systematic name length byte;
    Methods described also includes:
    Byte number needed for the storage variable storage is stored in the store path length byte;
    Byte number needed for the systematic name storage is stored in the systematic name length byte.
  7. 7. according to the method for claim 6, it is characterised in that
    The guiding entry field includes origin identification byte and check byte;
    Methods described also includes:
    Origin identification is stored in the origin identification byte;
    The check code of data storage in the guiding entry field is stored in the check byte.
  8. 8. according to the method described in any one of claim 1 to 7, it is characterised in that
    Methods described also includes:
    When starting first operating system, the first boot variable is read from first storage medium;
    Read the second boot variable in the second storage medium of first operating system;
    Judge whether first boot variable and second boot variable are consistent;
    When first boot variable and inconsistent second boot variable, according to described in first boot variable reading The guidance code of first operating system.
  9. 9. according to the method for claim 8, it is characterised in that
    It is described when first boot variable and inconsistent second boot variable, according to first boot variable read The guidance code of first operating system, including:
    When first boot variable and inconsistent second boot variable, first boot variable is replaced described the The second boot variable in two storage mediums;
    Based on second boot variable after replacement, the guidance code of reading first operating system.
  10. 10. according to the method for claim 6, it is characterised in that
    Methods described also includes:
    When first boot variable is consistent with second boot variable, draw according to being read second boot variable Lead code.
  11. 11. a kind of electronic equipment, it is characterised in that be detachably connected including processor and with the processor at least one Memory;The memory includes multiple storage mediums;
    The processor, for installing the first operating system;Obtain the store path of the guidance code of first operating system With the systematic name of first operating system;According to the store path and the systematic name, boot variable is generated;
    The processor, it is additionally operable to store the boot variable and guidance code storage simultaneously to same storage Jie In matter.
  12. 12. electronic equipment according to claim 11, it is characterised in that
    The storage medium for storing the boot variable and the guidance code is the first storage medium;The first storage medium bag Include N number of subregion;Wherein, the N is the integer not less than 1;
    The processor, specifically for will draw described in write-in in the subregion entry field of the n-th subregion of first storage medium Lead the storage address of variable;In the storage location corresponding to the storage address of n-th subregion, write the guiding and become Amount;Wherein, the n is the positive integer no more than the N.
  13. 13. electronic equipment according to claim 12, it is characterised in that
    First storage medium is also stored with partition table;
    The processor, specifically for the subregion entrance of the n-th subregion described in the partition table in first storage medium The sector configured information of the boot variable storage is write in field;And correspond to sector instruction letter in n-th subregion Cease in the sector of instruction and write the boot variable.
  14. 14. electronic equipment according to claim 13, it is characterised in that
    The processor, specifically for the attribute word of the subregion entry field of n-th subregion in first storage medium In section, the sector configured information is write.
  15. 15. electronic equipment according to claim 12, it is characterised in that
    Guiding entry field is provided with n-th subregion;
    The guiding entry field includes store path byte and systematic name byte;
    The processor, specifically for storing the storage in the store path byte that is stored in first storage medium The systematic name is stored in path and the systematic name byte.
  16. 16. electronic equipment according to claim 15, it is characterised in that
    The guiding entry field includes store path length byte and systematic name length byte;
    The processor, it is additionally operable to deposit described in storage in the store path length byte of first storage medium storage Byte number needed for the systematic name storage is stored in byte number needed for storage variable storage and the systematic name length byte.
  17. 17. electronic equipment according to claim 16, it is characterised in that
    The guiding entry field includes origin identification byte and check byte;
    The processor, be additionally operable to first storage medium storage the origin identification byte in store origin identification and The check code of data storage in the guiding entry field is stored in the check byte.
  18. 18. according to the electronic equipment described in any one of claim 11 to 17, it is characterised in that
    The memory also includes second storage medium different from first storage medium;The processor and described second Storage medium connects;
    The processor, specifically for when starting first operating system, first is read from first storage medium Boot variable;The second boot variable is read from second storage medium;Judge that first boot variable and described second draws Whether consistent lead variable;When first boot variable and inconsistent second boot variable, according to the described first guiding Variable reads the guidance code of first operating system.
  19. 19. electronic equipment according to claim 18, it is characterised in that
    The processor, specifically for when first boot variable and inconsistent second boot variable, by described One boot variable replaces the second boot variable in second storage medium;Based on second boot variable after replacement, Read the guidance code of first operating system.
  20. 20. electronic equipment according to claim 16, it is characterised in that
    The processor, it is additionally operable to when first boot variable is consistent with second boot variable, according to described second Boot variable reads the guidance code.
  21. 21. a kind of electronic equipment, it is characterised in that including:
    Installation unit, for installing the first operating system;
    Acquiring unit, store path and first operating system for the guidance code that obtains first operating system Systematic name;
    Generation unit, for according to the store path and the systematic name, generating boot variable;
    Memory cell, for storing the boot variable and the guidance code simultaneously in the first storage medium.
CN201610619978.5A 2016-07-29 2016-07-29 Information processing method and storage device Pending CN107665129A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201610619978.5A CN107665129A (en) 2016-07-29 2016-07-29 Information processing method and storage device
US15/664,038 US20180032351A1 (en) 2016-07-29 2017-07-31 Information processing method and storage device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610619978.5A CN107665129A (en) 2016-07-29 2016-07-29 Information processing method and storage device

Publications (1)

Publication Number Publication Date
CN107665129A true CN107665129A (en) 2018-02-06

Family

ID=61122010

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610619978.5A Pending CN107665129A (en) 2016-07-29 2016-07-29 Information processing method and storage device

Country Status (1)

Country Link
CN (1) CN107665129A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110187843A (en) * 2019-06-04 2019-08-30 苏州浪潮智能科技有限公司 A kind of method that storage medium name order is constant, system, terminal and storage medium
CN112988248A (en) * 2021-03-09 2021-06-18 南昌黑鲨科技有限公司 Computer readable storage medium and method for starting intelligent terminal operating system from multiple storage media
CN113721837A (en) * 2021-07-14 2021-11-30 中国科学院信息工程研究所 BIOS-based storage medium information elimination method and device

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1898643A (en) * 2003-10-27 2007-01-17 美国能量变换公司 System and method for updating a software program
US20090013165A1 (en) * 2000-01-06 2009-01-08 Chow David Q Portable usb device that boots a computer as a server
CN101548265A (en) * 2006-12-31 2009-09-30 桑迪士克股份有限公司 Portable multi-platform booting systems and architectures
CN102043640A (en) * 2009-10-23 2011-05-04 富港电子(东莞)有限公司 Flash system and program updating method thereof
CN102200921A (en) * 2010-03-25 2011-09-28 微软公司 Intelligent boot device selection and recovery
JP2012043309A (en) * 2010-08-20 2012-03-01 Sharp Corp System module and electric equipment
CN103430147A (en) * 2011-03-18 2013-12-04 富士通株式会社 Information processing device and method for controlling information processing device
CN105282613A (en) * 2014-06-24 2016-01-27 日照海帝电器有限公司 Smart television software upgrading method and system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090013165A1 (en) * 2000-01-06 2009-01-08 Chow David Q Portable usb device that boots a computer as a server
CN1898643A (en) * 2003-10-27 2007-01-17 美国能量变换公司 System and method for updating a software program
CN101548265A (en) * 2006-12-31 2009-09-30 桑迪士克股份有限公司 Portable multi-platform booting systems and architectures
CN102043640A (en) * 2009-10-23 2011-05-04 富港电子(东莞)有限公司 Flash system and program updating method thereof
CN102200921A (en) * 2010-03-25 2011-09-28 微软公司 Intelligent boot device selection and recovery
JP2012043309A (en) * 2010-08-20 2012-03-01 Sharp Corp System module and electric equipment
CN103430147A (en) * 2011-03-18 2013-12-04 富士通株式会社 Information processing device and method for controlling information processing device
CN105282613A (en) * 2014-06-24 2016-01-27 日照海帝电器有限公司 Smart television software upgrading method and system

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110187843A (en) * 2019-06-04 2019-08-30 苏州浪潮智能科技有限公司 A kind of method that storage medium name order is constant, system, terminal and storage medium
CN112988248A (en) * 2021-03-09 2021-06-18 南昌黑鲨科技有限公司 Computer readable storage medium and method for starting intelligent terminal operating system from multiple storage media
CN112988248B (en) * 2021-03-09 2023-03-31 南昌黑鲨科技有限公司 Computer readable storage medium and method for starting intelligent terminal operating system from multiple storage media
CN113721837A (en) * 2021-07-14 2021-11-30 中国科学院信息工程研究所 BIOS-based storage medium information elimination method and device
CN113721837B (en) * 2021-07-14 2024-06-11 中国科学院信息工程研究所 Storage medium information elimination method and device based on BIOS

Similar Documents

Publication Publication Date Title
CN106990958A (en) A kind of extension element, electronic equipment and startup method
CN104317694B (en) Whole machine testing method and device
US20130185484A1 (en) File programming method and associated device for nand flash
CN106155589B (en) A kind of virtual dynamic partition image file generation method and system
CN107665129A (en) Information processing method and storage device
CN109960678B (en) Naming processing method and computer processing device
CN107526687B (en) Multi-configuration memory system and operating method thereof
US10768852B2 (en) Batch automatic test method for solid state disks and batch automatic test device for solid state disks
CN110765032A (en) Method for reading and writing I2C memory based on system management bus interface
CN106776105A (en) A kind of verification of System startup files and Compilation Method
CN106293708A (en) Information processing method and storage device
CN109445691A (en) A kind of method and device improving FTL algorithm development and verification efficiency
CN110209349B (en) Data processing method and terminal equipment
CN114706533A (en) Multi-file multi-stage starting and loading method and device based on GPT partition table
CN103761202B (en) A kind of data storage node hard disk position identification method and system
CN103150281A (en) Integrating method and device and authentication method and device for bus interconnecting module
US20180032351A1 (en) Information processing method and storage device
CN110737577B (en) Test defect data storage method and device
CN113065315B (en) Conversion control method for describing file of register
CN111831224B (en) Method, system and equipment for erasing residual space of exFAT partition file
US20140052902A1 (en) Electronic device and method of generating virtual universal serial bus flash device
CN105353983A (en) Method and apparatus for identifying disk information in RAID
CN103268296B (en) The information write-in method of E-token dynamic password card group
JP2004145964A (en) Semiconductor memory, semiconductor memory manufacturing method, memory card, and method of controlling semiconductor memory
CN109656580B (en) Serial-port NAND FLASH data zero clearing processing method and system

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