Summary of the invention
Embodiments of the invention provide a kind of VTL backup method and VTL node, can improve the availability of VTL node link.
For achieving the above object, embodiments of the invention adopt following technical scheme:
First aspect, disclose a kind of VTL backup method, comprising:
When non-working port being detected, the access cluster file system obtains the normal port on the VTL node of described non-working port place, the virtual unit information of moving in session session connections corresponding to the global unique port name WWPN of described non-working port and described WWPN; In described cluster file system, storing the WWPN of the port of each VTL node in standby system and corresponding session thereof connects, the virtual unit information of operation and the status indicator of port in the session connection, described status indicator is normal port or non-working port for identifying port;
The WWPN of described non-working port is floated to described normal port;
According to the WWPN that floats to described normal port, set up described normal port and be connected with the session session between the backup server port;
According to the virtual unit information under described non-working port, virtual unit under described non-working port is distributed to described session to be connected, and connect the virtual unit under described non-working port is mounted on described backup server by described session, so that described backup server carries out data backup by the described virtual unit of described session attended operation.
In conjunction with first aspect, in the possible implementation of the first, described access cluster file system obtains the normal port on the VTL node of described non-working port place, specifically comprises:
The access cluster file system obtains the minimum normal port of virtual unit on the VTL node of described non-working port place, that move in session connections.
In conjunction with the possible implementation of the first of first aspect and first aspect, in the possible implementation of the second, create new virtual unit, the session that the access cluster file system obtains on idle port connects, the session that described new virtual unit is distributed on described idle port connects, and the session on described idle port connects the minimum session of virtual unit moved in the session connection of each port in each VTL node that comprises described standby system and connects; Session connection by described idle port is mounted to the virtual unit under described idle port on described backup server, it is the WWPN according to described idle port that the session of described idle port connects, and the described idle port of foundation is connected with the session between described backup server port.
In conjunction with first or two kind of possible implementation of first aspect and first aspect, in the third possible implementation, described idle port is the port on other VTL nodes except described new virtual unit place VTL node.
In conjunction with first or two or three kind of possible implementation of first aspect and first aspect, in the 4th kind of possible implementation, if do not have normal port on the VTL node of described non-working port place,, described method also comprises:
When non-working port being detected, the access cluster file system obtains the normal port on other VTL nodes except the VTL node of described non-working port place in described standby system.
Second aspect, disclose a kind of VTL VTL node, comprising:
The port access administration module, for when non-working port being detected, the access cluster file system obtains the normal port on the VTL node of described non-working port place, the virtual unit information of moving in session session connections corresponding to the global unique port name WWPN of described non-working port and described WWPN; In described cluster file system, storing the WWPN of the port of each VTL node in standby system and corresponding session thereof connects, the virtual unit information of operation and the status indicator of port in the session connection, described status indicator is normal port or non-working port for identifying port;
Driver module, for according to described port access administration module, floating to the WWPN of described normal port, set up described normal port and be connected with the session session between the backup server port;
Processing module, for the virtual unit information under the non-working port obtained according to described port access administration module, virtual unit under described non-working port is distributed to the session connection that described driver module is set up, and connect the virtual unit under described non-working port is mounted on described backup server by described session, so that described backup server carries out data backup by the described virtual unit of described session attended operation.
In conjunction with second aspect, in the possible implementation of the first, described port access administration module, specifically obtain the minimum normal port of virtual unit on the VTL node of described non-working port place, that move in session connections be used to accessing cluster file system.
In conjunction with the possible implementation of the first of second aspect or second aspect, in the possible implementation of the second, comprising:
Described port access administration module, also for after creating new virtual unit, the session that the access cluster file system obtains on idle port connects, the session that described new virtual unit is distributed on described idle port connects, and the session on described idle port connects the minimum session of virtual unit moved in the session connection of each port in each VTL node that comprises described standby system and connects;
Described processing module, also for the session by described idle port, connect the virtual unit under described idle port is mounted to described backup server, it is the WWPN according to described idle port that the session of described idle port connects, and the described idle port of foundation is connected with the session between described backup server port.
In conjunction with first or two kind of possible implementation of second aspect or second aspect, in the third possible implementation, described idle port is the port on other VTL nodes except described new virtual unit place VTL node.
First and second or three kinds of possible implementations in conjunction with second aspect or second aspect, in the 4th kind of possible implementation, described port access administration module, in the situation that do not have normal port on the VTL node of described non-working port place, also for when non-working port being detected, the access cluster file system obtains the normal port on other VTL nodes except the VTL node of described non-working port place in described standby system.
The VTL backup method that the embodiment of the present invention provides is the VTL node, the application cluster file system, when non-working port being detected, the WWPN of non-working port can be floated to the normal port on the VTL node of described non-working port place, by the link of normal port, taken over the link traffic of this non-working port, like this by the link traffic of the normal port link taking over fault port of same VTL node, rather than of the prior art by the business on all of the port link on other VTL node taking over fault port place VTL nodes, this has just improved the link availability of VTL node, and the regular traffic on described normal port link is not subjected to the impact of non-working port yet, compared with prior art, can make described VTL node have higher link availability.
In addition, when creating new virtual unit, can the application cluster file system be that the new virtual unit created is selected the minimum port of virtual unit under port, avoid the virtual unit under the port had too much, this port link is busy, under some ports, there is no virtual unit, this port link idle, can guarantee the harmony of each port link of accesses virtual equipment to a certain extent.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the present invention's part embodiment, rather than whole embodiment.Based on the embodiment in the present invention, those of ordinary skills, not making under the creative work prerequisite the every other embodiment obtained, belong to the scope of protection of the invention.
Embodiment 1:
The embodiment of the present invention provides a kind of VTL backup method, as shown in Figure 2, said method comprising the steps of:
201, the VTL node is when non-working port being detected, the access cluster file system obtains the normal port on the VTL node of described non-working port place, the virtual unit information of moving in session session connections corresponding to the global unique port name WWPN of described non-working port and described WWPN.
In each VTL node that the embodiment of the present invention provides, all applied cluster file system, described file group system can be supported the data sharing between each VTL node, while being the cluster file system of certain this node of VTL node visit, just can obtain the data of other VTL node storages.In described cluster file system in the embodiment of the present invention in each VTL node, storing the WWPN of the port of each VTL node in standby system and corresponding session thereof connects, the virtual unit information of operation and the status indicator of port in the session connection, described status indicator is normal port or non-working port for identifying port.Like this, each VTL node in described standby system is cluster management, and the virtual unit under each node is also cluster management.
Fault described here not only comprises the fault of originating port, also comprises the fault of the link generation that port is corresponding.When on certain VTL node, a non-working port occurring, all VTL nodes in standby system, also comprise that the node broken down can detect described non-working port; The VTL node that described non-working port detected just can be accessed the cluster file system of this node, according to the status indicator of described port, obtain the normal port on the VTL node of described non-working port place, can also obtain the virtual unit information of operation in the session session connection that the WWPN of described non-working port and described WWPN are corresponding, virtual unit information described here comprises which the virtual unit under described non-working port has.
202, the described VTL node that fault detected floats to described normal port by the WWPN of described non-working port.
Drift described here refers to the WWPN of non-working port is arranged on described normal port, and described so normal port is just local WWPN to two WWPN-mono-should be arranged, and one is the WWPN that drift comes.
203, the described VTL node that fault detected, according to the WWPN that floats to described normal port, is set up described normal port and is connected with the session between the backup server port.
When the VTL node detected self ports having and is connected with the ports physical of described backup server, the session that described VTL node will be set up according to the WWPN of described port between the port of described port and described backup server was connected.
Described normal port self has the WWPN an of this locality, the WWPN of described normal port this locality is to there being a session to connect, when described normal port drifts about a WWPN, the WWPN come according to drift also wants described normal port of correspondence establishment to be connected with the session between the backup server port, namely a WWPN is to there being a session to connect, when port had a plurality of WWPN, described port will connect a plurality of session should be arranged.
Cluster management pattern due to each VTL node in standby system, even the VTL node that fault detected described is not the VTL node at described normal port place, and the described VTL node that fault detected also can be set up a described normal port at described normal port according to the WWPN that floats to described normal port and be connected with the session between the backup server port.
204, the described VTL node of fault that detects is according to the virtual unit information under described non-working port, virtual unit under described non-working port is distributed to described session to be connected, and connect the virtual unit under described non-working port is mounted on described backup server by described session, so that described backup server carries out data backup by the described virtual unit of described session attended operation.
The described VTL node that fault detected can, according to the virtual unit information under described non-working port, be distributed to session that set up in step 202, corresponding with the next WWPN that drifts about to the virtual unit under described non-working port and connect.Then, by described session, connect the virtual unit under described non-working port is mounted on described backup server.
From the above, the address of setting up session connection use between backup server and VTL node is WWPN, after completing WWPN and drifting about and re-establish session and connect, because WWPN does not change, so backup server can think that this is that the session disconnected before connects recovery connection again.The scsi address of virtual unit on backup server that now is loaded in backup server by this session connection suspension do not change, and backup server can think that this is that session connects and temporarily disconnects and again recover so.Backup software on described like this backup server just again the virtual unit under the operating trouble node carried out data backup.
The VTL backup method that the embodiment of the present invention provides, by the application cluster file system, when non-working port being detected, access obtains the normal port on the VTL node of described non-working port place, the WWPN of described non-working port is floated to described normal port, according to the WWPN that floats to described normal port, setting up described normal port is connected with the session between the backup server port, and according to the virtual unit information under described non-working port, virtual unit under described non-working port is distributed to described session to be connected, then by described session, connect the virtual unit under described non-working port is mounted on described backup server, so that described backup server carries out data backup by the described virtual unit of described session attended operation, even a non-working port on the VTL node, occurred like this, on this VTL node, the link of other normal ports is still available, compared with prior art, can make described VTL node have higher link availability.In addition, the method that the embodiment of the present invention provides does not need to rebuild the virtual unit under non-working port, has so just saved port and has taken over the time.
Embodiment 2,
The embodiment of the present invention provides a kind of VTL backup method, as shown in Figure 3, said method comprising the steps of:
301, the VTL node creates new virtual unit, and the session that the access cluster file system obtains on idle port connects, and the session that described new virtual unit is distributed on described idle port connects.
Session on described idle port connects the minimum session of virtual unit moved in the session connection of each port in each VTL node that comprises described standby system and connects.
Because the VTL node in standby system has been applied cluster file system, each VTL node data is shared, in described cluster file system, store the WWPN of the port of each VTL node in standby system, virtual unit under port and the status indicator of port, described status indicator is normal port or non-working port for identifying port.
Session on the idle port that the access cluster file system obtains connects minimum the getting final product of virtual unit of operation in the session connection that only need to meet this port, the session that can be both the port on described new virtual unit place VTL node connects, and can be also the session connection of the port on other VTL nodes of described new virtual unit place VTL node.
As shown in Figure 1, VTL node A131 creates new virtual unit virtual disk machine B, and described VTL node A131 just can access the cluster file system in VTL node A131, and the session obtained on idle port connects.If do not move virtual unit in certain the session connection on the port T2 on described VTL node A131, this session that just virtual disk machine B can be distributed on port T2 connects.Certainly, if connecting, the session on upper each port of VTL node A131 all moved virtual unit, and certain session connection on the port T3 on VTL Node B 132 does not move virtual unit, this session that just virtual disk machine B can be distributed on port T3 connects.Like this, on VTL node A131, create a virtual tape machine A, after having created, virtual tape machine A may be also operation in certain session connection of the port of VTL Node B, has realized the cluster management of virtual unit on a plurality of VTL nodes.
Like this, in the session of each port of each VTL node of whole standby system connects, for the new virtual unit created, selecting the session of the minimum port of the virtual unit moved in the session connection connects, avoid the upper virtual unit moved of session of the port had too much, the port link is busy, on the session of some ports, do not move virtual unit, the port link idle, can guarantee the harmony of each port session link of accesses virtual equipment to a certain extent.
302, the session of the VTL node that creates described new virtual unit by described idle port connects described new virtual unit is mounted on described backup server.
When the VTL node detected self ports having and is connected with the ports physical of described backup server, the session that described VTL node will be set up according to the WWPN of described port between the port of described port and described backup server was connected.The session of described idle port connect be at idle port with after described backup server ports physical is communicated with, according to the WWPN of described idle port, the described idle port of foundation is connected with the session between described backup server port.
After the session connection of described new virtual unit being distributed on described idle port, when backup server scans the new virtual unit under this idle port, due to the cluster management pattern of each VTL node in standby system, the VTL node that creates described new virtual unit just can connect the virtual unit under described idle port is mounted on described backup server by the session of described idle port.Described backup server can be that described virtual unit distributes a scsi address according to the WWPN of idle port corresponding to described virtual unit.Like this, when having Backup Data to come, the backup software on backup server just can, according to scsi address, be specified described Backup Data is write in the RAID of VTL node connection by the operation virtual unit.
303, the VTL node is when non-working port being detected, the access cluster file system obtains the normal port on the VTL node of described non-working port place, the virtual unit information of moving in session connections corresponding to the global unique port name WWPN of described non-working port and described WWPN.
When on certain VTL node, a non-working port occurring, all VTL nodes in standby system, also comprise that the node broken down can detect described non-working port; The VTL node that described non-working port detected just can be accessed the cluster file system of this node, according to the status indicator of described port, obtain the normal port on the VTL node of described non-working port place, and the virtual unit information of operation in the WWPN of described non-working port and session connection corresponding to described WWPN, virtual unit information described here comprises which the virtual unit under described non-working port has.
Preferably, described normal port is that the access cluster file system obtains the minimum normal port of virtual unit on the VTL node of described non-working port place, that move in session connections.So just guaranteed the harmony of VTL node link.
If do not have normal port on the VTL node of described non-working port place,, the VTL node is when non-working port being detected, and the access cluster file system can obtain the normal port on other VTL nodes except the VTL node of described non-working port place in described standby system.
Supposing has a virtual unit-virtual tape machine A under the port T1 of the VTL node A131 in Fig. 1, port T1 is to there being WWPN1, port T2 is to there being WWPN1, when port T1 breaks down or the link T1-S1 of port T1 while breaking down, VTL node A131 or VTL Node B 132 can detect non-working port T1, after if VTL node A131 detects non-working port T1, VTL node A131 can access the file group system of VTL node A131, obtains the normal port T2 on VTL node A131.
If the port T2 on VTL node A131 is also non-working port, in VTL node A131, there is no normal port, after the file group system of described VTL node A131 access VTL node A131, acquisition be exactly the normal port on VTL Node B 132.
304, the described VTL node that fault detected floats to described normal port by the WWPN of described non-working port.
Drift described here refers to that the WWPN of non-working port is arranged on described normal port, and described so normal port is just local WWPN to two WWPN-mono-should be arranged, and one is the WWPN that drift comes.
305, the described VTL node that fault detected, according to the WWPN that floats to described normal port, is set up described normal port and is connected with the session between the backup server port.
When the VTL node detected self ports having and is connected with the ports physical of described backup server, the session that described VTL node will be set up according to the WWPN of described port between the port of described port and described backup server was connected.
Described normal port self has the WWPN an of this locality, the WWPN of described normal port this locality is to there being a session to connect, when described normal port drifts about a WWPN, the WWPN come according to drift also wants described normal port of correspondence establishment to be connected with the session between the backup server port, namely a WWPN is to there being a session to connect, when port had a plurality of WWPN, described port will connect a plurality of session should be arranged.As shown in Figure 1, suppose the WWPN1 on non-working port T1 is floated to normal port T2, two WWPN are arranged is WWPN1 and WWPN2 to normal port T2, between the port of described so normal port T2 and described backup server 11 just to there being two session to be connected.
Cluster management pattern due to each VTL node in standby system, even the VTL node that fault detected described is not the VTL node at described normal port place, and the described VTL node that fault detected also can be set up a described normal port at described normal port according to the WWPN that floats to described normal port and be connected with the session between the backup server port.
306, the described VTL node of fault that detects is according to the virtual unit information under described non-working port, virtual unit under described non-working port is distributed to described session to be connected, and connect the virtual unit under described non-working port is mounted on described backup server by described session, so that described backup server carries out data backup by the described virtual unit of described session attended operation.
According to the above, after WWPN1 on non-working port T1 is floated to the normal port T2 on VTL node A131, VTL node A131 just can be according to the virtual unit information under non-working port T1, virtual unit under non-working port T1 (virtual tape machine A) is distributed to described normal port T2 and according to the session that described WWPN1 sets up, connect, and connect the virtual unit under described non-working port is mounted on described backup server by described session.
Like this, on normal port T2, just can move simultaneously virtual tape machine A and virtual tape machine B, standby system can connect by two session corresponding to described normal port T2, drives respectively described virtual tape machine A and virtual tape machine B carries out backup traffic.
Because the address of setting up session connection use between backup server and VTL node is WWPN, after completing WWPN and drifting about and re-establish session and connect, because WWPN does not change, so backup server can think that this disconnects session connection recovery connection again before being.The scsi address of virtual unit on backup server that now is loaded in backup server by this session connection suspension do not change, and backup server can think that this is that session connects and temporarily disconnects and again recover so.Backup software on described like this backup server just again the virtual unit under the operating trouble node carried out data backup.
And, the method that the embodiment of the present invention provides does not need to rebuild the virtual unit under non-working port, so just save port and taken over the time, in the situation that backup software is supported, when carrying out a data backup, session disconnects also again the time of recovery in the overtime scope of backup software Backup Data, and backup software can a data for this backup resend so, and need not again back up whole data set, the backup traffic that realizes that can minimum particle size is recovered automatically.
The method that the embodiment of the present invention provides, the application cluster file system, when non-working port being detected, the WWPN of non-working port can be floated to the normal port on the VTL node of described non-working port place, by the link of normal port, taken over the link traffic of this non-working port, like this by the link traffic of the normal port link taking over fault port of same VTL node, rather than of the prior art by the business on all of the port link on other VTL node taking over fault port place VTL nodes, this has just improved the link availability of VTL node, and the regular traffic on described normal port link is not subjected to the impact of non-working port yet.
In addition, when creating new virtual unit, can the application cluster file system be that the new virtual unit created is selected the minimum port of virtual unit under port, avoid the virtual unit under the port had too much, this port link is busy, under some ports, there is no virtual unit, this port link idle, can guarantee the harmony of each port link of accesses virtual equipment to a certain extent.
The embodiment of the present invention also provides a kind of VTL node, and as shown in Figure 4, described VTL node comprises: port access administration module 401, driver module 402 and processing module 403.
Port access administration module 401, for when non-working port being detected, the access cluster file system obtains the normal port on the VTL node of described non-working port place, the virtual unit information of moving in session session connections corresponding to the global unique port name WWPN of described non-working port and described WWPN; In described cluster file system, storing the WWPN of the port of each VTL node in standby system and corresponding session thereof connects, the virtual unit information of operation and the status indicator of port in the session connection, described status indicator is normal port or non-working port for identifying port.Preferably, described port access administration module, specifically obtain the minimum normal port of virtual unit on the VTL node of described non-working port place, that move in session connections be used to accessing cluster file system.
Described port access administration module 401, also float to described normal port for the WWPN by described non-working port.
Driver module 402, for according to described port access administration module, floating to the WWPN of described normal port, set up described normal port and be connected with the session session between the backup server port.
Processing module 403, for the virtual unit information under the non-working port obtained according to described port access administration module, virtual unit under described non-working port is distributed to the session connection that described driver module is set up, and connect the virtual unit under described non-working port is mounted on described backup server by described session, so that described backup server carries out data backup by the described virtual unit of described session attended operation.
Further, when creating new virtual unit, described port access administration module 401, also for after creating new virtual unit, the session that the access cluster file system obtains on idle port connects, the session that described new virtual unit is distributed on described idle port connects, and the session on described idle port connects the minimum session of virtual unit moved in the session connection of each port in each VTL node that comprises described standby system and connects.
Described processing module 403, also for the session by described idle port, connect the virtual unit under described idle port is mounted to described backup server, it is the WWPN according to described idle port that the session of described idle port connects, and the described idle port of foundation is connected with the session between described backup server port.
Optionally, described idle port can be the port on other VTL nodes except described new virtual unit place VTL node.
Optionally, described port access administration module, in the situation that do not have normal port on the VTL node of described non-working port place, also for when non-working port being detected, the access cluster file system obtains the normal port on other VTL nodes except the VTL node of described non-working port place in described standby system.
One of ordinary skill in the art will appreciate that: all or part of step that realizes said method embodiment can complete by the hardware that program command is correlated with, aforesaid program can be stored in a computer read/write memory medium, this program, when carrying out, is carried out the step that comprises said method embodiment; And aforesaid storage medium comprises: various media that can be program code stored such as ROM, RAM, magnetic disc or CDs.
The above; be only the specific embodiment of the present invention, but protection scope of the present invention is not limited to this, anyly is familiar with those skilled in the art in the technical scope that the present invention discloses; can expect easily changing or replacing, within all should being encompassed in protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion by described protection range with claim.