同事在两节点的RAC上打oneoff patch,在其中一个节点上运行opatch apply,按理应该会自动检测并且分发到另外一个节点,进行patch,但是在分发到第二个节点的时候遇到了PRKC-1002的报错,此时,如果在另外一个节点运行opatch lsinventory也会报错,检测不到原来打过哪些patch了。
我先开启opatch的debug,来查看为什么在节点2上无法运行lsinventory了:
au11qapa70tels2>$ORACLE_HOME/OPatch/opatch lsinventory
...
parserXMLFile : start
PatchObject(oracleHomePath,patchID)
PatchObject::PatchObject looks for the actions file /ora/product/10.2.0/db_1/inventory/oneoffs/6920066/etc/config/actions.xml
PatchObject::PatchObject looks for the inventory file /ora/product/10.2.0/db_1/inventory/oneoffs/6920066/etc/config/inventory.xml
parserXMLFile : start
parserXMLFile : start
PatchObject(oracleHomePath,patchID)
PatchObject::PatchObject looks for the actions file /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/actions.xml
PatchObject::PatchObject looks for the inventory file /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/inventory.xml
PatchObject::PatchObject now looks for the actions file /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/actions
PatchObject::PatchObject now looks for the inventory file /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/inventory
Loading the information from inventory/filemap.
Inventory load failed... OPatch cannot load inventory for the given Oracle Home.
Locker::release()
OUISessionManager::unRegister()
Un-Registering the caller : OPatch
LsInventory::getInstance() returns
LsInventorySession failed: Unable to create patchObject
Cleaning up the directory : "/ora/product/10.2.0/db_1/.patch_storage/patch_unzip"...
OPatch failed with error code 73
au11qapa70tels2>
我们看到,是因为缺少了一些文件,如 /ora/product/10.2.0/db_1/inventory/oneoffs/6920066/etc/config/actions.xml等等。
/ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/actions.xml: No such file or directory
au11qapa70tels2>ls -l /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/inventory.xml
/ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/inventory.xml: No such file or directory
au11qapa70tels2>ls -l /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/
/ora/product/10.2.0/db_1/inventory/oneoffs/8350262/: No such file or directory
可以看到,整个/ora/product/10.2.0/db_1/inventory/oneoffs/8350262/路径都不存在。
那么,为什么在部署这个patch的时候,这个路径会在node2上没有呢?我们来看看部署patch时完整的log:
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>cat opatch2011-11-17_15-42-59PM.log
- SEVERE:OPatch invoked as follows: 'lsinventory '
- INFO:
- Oracle Home : /ora/product/10.2.0/db_1
- Central Inventory : /ora/admin/oraInventory
- from : /var/opt/oracle/oraInst.loc
- OPatch version : 10.2.0.4.3
- OUI version : 10.2.0.4.0
- OUI location : /ora/product/10.2.0/db_1/oui
- Log file location : /ora/product/10.2.0/db_1/cfgtoollogs/opatch/opatch2011-11-17_15-42-59PM.log
- INFO:Starting LsInventorySession at Thu Nov 17 15:43:02 EST 2011
- INFO:Lsinventory Output file location : /ora/product/10.2.0/db_1/cfgtoollogs/opatch/lsinv/lsinventory2011-11-17_15-42-59PM.txt
- INFO:--------------------------------------------------------------------------------
- INFO:Installed Top-level Products (4):
- INFO:Oracle Database 10g 10.2.0.1.0
- INFO:Oracle Database 10g Release 2 Patch Set 2 10.2.0.3.0
- INFO:Oracle Database 10g Release 2 Patch Set 3 10.2.0.4.0
- INFO:Oracle Database Vault 10.2.0.4.0
- INFO:There are 4 products installed in this Oracle Home.
- INFO:
- INFO:Interim patches (4) :
- INFO:Patch 6672979 : applied on Tue Nov 30 20:14:18 EST 2010
- Created on 11 Aug 2008, 07:06:04 hrs PST8PDT
- Bugs fixed:
- 6672979
- INFO:Patch 5945060 : applied on Tue Nov 30 19:19:13 EST 2010
- Created on 22 Mar 2009, 22:52:01 hrs US/Pacific
- Bugs fixed:
- 5945060
- INFO:Patch 6920066 : applied on Tue Nov 30 18:22:45 EST 2010
- Created on 26 Jun 2008, 07:29:30 hrs US/Pacific
- Bugs fixed:
- 6920066
- INFO:Patch 8208643 : applied on Tue Nov 30 18:20:16 EST 2010
- Created on 23 Mar 2009, 01:12:32 hrs US/Pacific
- Bugs fixed:
- 7505535, 7688543, 7319691, 8208643, 7489862
- INFO:
- INFO:
- INFO:Rac system comprising of multiple nodes
- INFO: Local node = au11qapa50tels2
- Remote node = au11qapa70tels2
- INFO:--------------------------------------------------------------------------------
- INFO:Finishing LsInventorySession at Thu Nov 17 15:43:09 EST 2011
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>cat opatch2011-11-17_16-05-54PM.log
- SEVERE:OPatch invoked as follows: 'apply '
- INFO:
- Oracle Home : /ora/product/10.2.0/db_1
- Central Inventory : /ora/admin/oraInventory
- from : /var/opt/oracle/oraInst.loc
- OPatch version : 10.2.0.4.3
- OUI version : 10.2.0.4.0
- OUI location : /ora/product/10.2.0/db_1/oui
- Log file location : /ora/product/10.2.0/db_1/cfgtoollogs/opatch/opatch2011-11-17_16-05-54PM.log
- INFO:Starting ApplySession at Thu Nov 17 16:05:57 EST 2011
- INFO:Starting Apply Session at Thu Nov 17 16:05:57 EST 2011
- INFO:ApplySession applying interim patch '8350262' to OH '/ora/product/10.2.0/db_1'
- INFO:Starting to apply patch to local system at Thu Nov 17 16:05:58 EST 2011
- INFO:Start the Apply initScript at Thu Nov 17 16:05:58 EST 2011
- INFO:Finish the Apply initScript at Thu Nov 17 16:05:58 EST 2011
- INFO:Patch 8350262 has no conflicts/superset wiht any other patch processed till now
- INFO:Checking conflicts for patch: 8350262
- INFO:Checking conflicts/supersets for patch: 8350262 with patch:8350262
- INFO:Checking conflicts/supersets for patch: 8350262 with patch:6672979
- INFO:Checking conflicts/supersets for patch: 8350262 with patch:5945060
- INFO:Checking conflicts/supersets for patch: 8350262 with patch:6920066
- INFO:Checking conflicts/supersets for patch: 8350262 with patch:8208643
- INFO:
- Running prerequisite checks...
- INFO:Space Needed : 249742
- INFO:Prereq checkPatchApplicableOnCurrentPlatform Passed on patch :8350262
- INFO:
- OPatch detected the node list and the local node from the inventory. OPatch will patch the local system then propagate the patch to the remote nodes.
- INFO:Start saving patch at Thu Nov 17 16:06:08 EST 2011
- INFO:Finish saving patch at Thu Nov 17 16:06:08 EST 2011
- INFO:Start backing up system for restore at Thu Nov 17 16:06:08 EST 2011
- INFO:Backing up files and inventory (not for auto-rollback) for the Oracle Home
- INFO:Backing up files affected by the patch '8350262' for restore. This might take a while...
- INFO:Finish backing up system for restore at Thu Nov 17 16:06:09 EST 2011
- INFO:Current working directory is : /ora/product/10.2.0/db_1/OPatch
- INFO:This is a platform specific OPatch that has ocm.zip
- INFO:The ocm location is /ora/product/10.2.0/db_1/OPatch/ocm/ocm.zip
- INFO:
- The Oracle Configuration Manager is installed previously in the Oracle Home.
- INFO:
- The Oracle Configuration Manager is already configured. OPatch does nothing.
- INFO:Start backing up system for rollback at Thu Nov 17 16:06:10 EST 2011
- INFO:Backing up files affected by the patch '8350262' for rollback. This might take a while...
- INFO:Finish backing up system for rollback at Thu Nov 17 16:06:28 EST 2011
- INFO:Start modifying the system at Thu Nov 17 16:06:28 EST 2011
- INFO:
- Patching component oracle.sysman.agent.core, 10.2.0.4.0a...
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emCORE.jar" with "/sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/fsc/FSWalletUtil.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emCORE.jar" with "/sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/rep/RepWalletUtil.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emCORE.jar" with "/sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/util/RootCert.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emCORE.jar" with "/sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/util/SecConstants.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emd_java.jar" with "/sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/fsc/FSWalletUtil.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emd_java.jar" with "/sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/rep/RepWalletUtil.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emd_java.jar" with "/sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/util/RootCert.class"
- INFO:Updating jar file "/ora/product/10.2.0/db_1/sysman/jlib/emd_java.jar" with "/sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/util/SecConstants.class"
- INFO:Finish modifying the system at Thu Nov 17 16:08:49 EST 2011
- INFO:ApplySession adding interim patch '8350262' to inventory
- INFO:Start saving patch to inventory at Thu Nov 17 16:08:49 EST 2011
- INFO:Registered Encoding value is : ISO8859-1 for the file /ora/product/10.2.0/db_1/inventory/oneoffs/8350262/etc/config/actions.xml
- INFO:Finish saving patch to inventory at Thu Nov 17 16:09:04 EST 2011
- INFO:
- Verifying the update...
- INFO:Inventory check OK: Patch ID 8350262 is registered in Oracle Home inventory with proper meta-data.
- INFO: verifying 8 jar files.
- INFO:Verify top-level entry oracle/sysman/eml/sec/fsc/FSWalletUtil.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/FSWalletUtil.class and /ora/admin/patch/8350262/files//sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/fsc/FSWalletUtil.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/rep/RepWalletUtil.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/RepWalletUtil.class and /ora/admin/patch/8350262/files//sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/rep/RepWalletUtil.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/util/RootCert.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/RootCert.class and /ora/admin/patch/8350262/files//sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/util/RootCert.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/util/SecConstants.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/SecConstants.class and /ora/admin/patch/8350262/files//sysman/jlib/emCORE.jar/oracle/sysman/eml/sec/util/SecConstants.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/fsc/FSWalletUtil.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/FSWalletUtil.class and /ora/admin/patch/8350262/files//sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/fsc/FSWalletUtil.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/rep/RepWalletUtil.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/RepWalletUtil.class and /ora/admin/patch/8350262/files//sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/rep/RepWalletUtil.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/util/RootCert.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/RootCert.class and /ora/admin/patch/8350262/files//sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/util/RootCert.class
- INFO:Verify top-level entry oracle/sysman/eml/sec/util/SecConstants.class using file /ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/scratch/work/SecConstants.class and /ora/admin/patch/8350262/files//sysman/jlib/emd_java.jar/oracle/sysman/eml/sec/util/SecConstants.class
- INFO:Files check OK: Files from Patch ID 8350262 are present in Oracle Home.
- INFO:Finish applying patch to local system at Thu Nov 17 16:09:18 EST 2011
- INFO:Starting to apply patch to remote nodes 'au11qapa70tels2' at Thu Nov 17 16:09:18 EST 2011
- INFO:
- Patching in rolling mode.
- INFO:Updating nodes 'au11qapa70tels2'
- INFO: Apply-related files are:
- FP = "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_files.txt"
- DP = "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_dirs.txt"
- MP = "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/make_cmds.txt"
- RC = "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/remote_cmds.txt"
- INFO:Instantiating the file "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_files.txt.instantiated" by replacing $ORACLE_HOME in "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_files.txt" with actual path.
- INFO:Propagating files to remote nodes...
- INFO:Instantiating the file "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_dirs.txt.instantiated" by replacing $ORACLE_HOME in "/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_dirs.txt" with actual path.
- INFO:Propagating directories to remote nodes...
- WARNING:OUI-67188:
- OPatch failed to copy directories to remote nodes 'au11qapa70tels2' . Detail: Error occurred on nodes:
- All-node error message = Error while copying files inside directory '/ora/product/10.2.0/db_1' based on listed file '/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_dirs.txt.instantiated' with excludeListFile 'null' to nodes 'au11qapa70tels2'. [PRKC-1002 : All the submitted commands did not execute successfully]
- ----------------------------------------------------------------------------------
- au11qapa70tels2:
- ###################################################################
- # This system is for the use of authorized users only. #
- # Individuals using this computer system without authority, or in #
- # excess of their authority, are subject to having all of their #
- # activities on this system monitored and recorded by system #
- # personnel. #
- # #
- # In the course of monitoring individuals improperly using this #
- # system, or in the course of system maintenance, the activities #
- # of authorized users may also be monitored. #
- # #
- # Anyone using this system expressly consents to such monitoring #
- # and is advised that if such monitoring reveals possible #
- # evidence of criminal activity, system personnel may provide the #
- # evidence of such monitoring to law enforcement officials. #
- ###################################################################
- WARNING: Access to this computer system is limited to authorised users only.
- Unauthorised users may be subject to prosecution under the Crimes
- Act or State legislation.
- Please note, ALL CUSTOMER DETAILS are confidential and must not be
- disclosed.
- ----------------------------------------------------------------------------------
- INFO:
- OPatch failed to copy directories to remote nodes 'au11qapa70tels2' .
- Do you want to proceed? [y|n]
- INFO:Start to wait for user-input at Thu Nov 17 16:09:22 EST 2011
- INFO:Finish waiting for user-input at Thu Nov 17 16:10:04 EST 2011
- INFO:User Responded with: Y
- INFO:Finish applying patch to remote nodes at Thu Nov 17 16:10:04 EST 2011
- INFO:--------------------------------------------------------------------------------
- INFO:The following warnings have occurred during OPatch execution:
- INFO:1) OUI-67188:
- OPatch failed to copy directories to remote nodes 'au11qapa70tels2' . Detail: Error occurred on nodes:
- All-node error message = Error while copying files inside directory '/ora/product/10.2.0/db_1' based on listed file '/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_dirs.txt.instantiated' with excludeListFile 'null' to nodes 'au11qapa70tels2'. [PRKC-1002 : All the submitted commands did not execute successfully]
- ----------------------------------------------------------------------------------
- au11qapa70tels2:
- ###################################################################
- # This system is for the use of authorized users only. #
- # Individuals using this computer system without authority, or in #
- # excess of their authority, are subject to having all of their #
- # activities on this system monitored and recorded by system #
- # personnel. #
- # #
- # In the course of monitoring individuals improperly using this #
- # system, or in the course of system maintenance, the activities #
- # of authorized users may also be monitored. #
- # #
- # Anyone using this system expressly consents to such monitoring #
- # and is advised that if such monitoring reveals possible #
- # evidence of criminal activity, system personnel may provide the #
- # evidence of such monitoring to law enforcement officials. #
- ###################################################################
- WARNING: Access to this computer system is limited to authorised users only.
- Unauthorised users may be subject to prosecution under the Crimes
- Act or State legislation.
- Please note, ALL CUSTOMER DETAILS are confidential and must not be
- disclosed.
- ----------------------------------------------------------------------------------
- INFO:--------------------------------------------------------------------------------
- SEVERE:OUI-67204:OPatch Session completed with warnings.
- INFO:Finishing ApplySession at Thu Nov 17 16:10:04 EST 2011
- INFO:Total time spent waiting for user-input is 42 seconds. Finish at Thu Nov 17 16:10:04 EST 2011
- au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/cfgtoollogs/opatch>
请注意,在140行之前的log是说明在node1上的patch过程,到140行为止,说明在node1上patch是成功的。在140行之后是在node2上的patch的log。
到153行为止,在node2上分发文件的过程是没有问题的,而且在node2上检查
在/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44/rac/copy_files.txt.instantiated中所示的3个文件都是存在的:
/ora/product/10.2.0/db_1/sysman/jlib/emd_java.jar
/ora/product/10.2.0/db_1/inventory/ContentsXML/comps.xml
在158行,开始报错了,以下的文件夹在node2上无法建立:
/ora/product/10.2.0/db_1/.patch_storage/8350262_Sep_14_2010_04_59_44
该2个文件夹无法建立,所以我们在node2上运行lsinventory也会报错找不到上述文件夹中的文件。
因此,从log中我们看到,那些patch的jar 文件,只是拷贝到了node2上,连编译都还没编译(因为编译需要将执行语句从node1分发到node2上的/oneoffs/8350262目录下)。在node上,该patch是部署失败的。
那么是什么原因造成了PRKC-1002?我们在metalink上找到了一些线索:
=========================================
Cause
This is because the date on the local node is higher than the date on the remote node(s).
Solution
To fix this, set the times of the nodes to be the same. You can do this with "ntpupdate < nodename > " to sync the dates.
难道是时间不一致?分别在2台机器上运行date看时间,似乎没有差异。我们再试试在同一台机器上运行date:
Thursday, 17 November 2011 9:29:47 PM EST
###################################################################
# This system is for the use of authorized users only. #
# Individuals using this computer system without authority, or in #
# excess of their authority, are subject to having all of their #
# activities on this system monitored and recorded by system #
# personnel. #
# #
# In the course of monitoring individuals improperly using this #
# system, or in the course of system maintenance, the activities #
# of authorized users may also be monitored. #
# #
# Anyone using this system expressly consents to such monitoring #
# and is advised that if such monitoring reveals possible #
# evidence of criminal activity, system personnel may provide the #
# evidence of such monitoring to law enforcement officials. #
###################################################################
WARNING: Access to this computer system is limited to authorised users only.
Unauthorised users may be subject to prosecution under the Crimes
Act or State legislation.
Please note, ALL CUSTOMER DETAILS are confidential and must not be
disclosed.
Thursday, 17 November 2011 9:29:48 PM EST
au11qapa50tels2:TSPRD1:/ora/product/10.2.0/db_1/.patch_storage/6672979_Aug_11_2008_07_06_04/rac>
看出什么问题来了吗?是不是多了很多内容?平时运行date的时候,只有2行,而现在,你却看到了node2上的ssh banner?!
在metalink上还找到了两篇相关的文章:
=============================
Cause
SSH banner was enabled on RAC setup, due to this agent installation fails while copying files to one of the cluster node.
"$ssh node2" from node1 was returning banner right after the connection.
Solution
Disable the banner on both the RAC nodes and re-try the agent installation.
Once the SSH banner is disabled agent install should be successful.
and the banner can be enabled after the installation is complete on both the nodes.
=============
Disable banner (/etc/banner) on all cluster nodes when you
run clusterverify (cluvfy, runcluvfy)
install software
patch the system
因此,问题就出在这边了,由于设置了node的ssh banner,我估计在分发或者创建文件的时候,会通过ssh获取节点间的时间,如果有ssh banner,获取不到第一行显示的时间,因此出现上述报错。如果你搜索metelink,还会发现ssh banner会造成很多类似的问题,如gc agent无法push,cluvfy也会失败。
找到问题后,解决问题就比较简单了。而且还有不同的解决方式。
方法二,也是推荐的方法,回滚之后,在node2上用opatch apply -local的方式进行patch。
总体来说,如果节点不是很多,不嫌麻烦的话,还是用-local的方式一个节点一个节点的手工部署过去来的安全。方式为:
如果部署多个patch: