I think I am finish with policies implementation. See test results.
in Test 1 - rpt1
I create patch base with 12 patches wit dependencies
In first call - nonrecursive patchadd refuses to install 200001-02 because
required patch is not specified.
Second call - recursive patching with "pick latest" policy it installs:
200004-03 200002-03 200003-03 200001-03
because 200001-02 is obsoleted by higher revision 200001-02, which
require 200003-01 obsoleted by higher revision 200003-03
and
require 200002-01 obsoleted by higher revision 200002-03 which also
require 200004-01 obsoleted by higher revision 200004-03
in result 4 patches will be installed
Third call - recursive patching with "pick earliest" policy it installs only:
200002-01 200001-02
Because 200001-02 requires only 200002-01 which does not require anything else.
in Test 2 - rpt2
It tests complex obsoletion for this cases. when 200001-02 and 200003-02 was
requested to be installed and 200002-01 required by 200001-02 is obsoleted by
higher revision 200002-02 required by 200003-02. Pdo successfully ignore
200002-01 as you may see from the test.
vassun
-----------------------------Test 1-------------------------------
#cat rpt1
echo + Regular patching +
echo ++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -R /d2/pdo/S10 -M /d2/pdo/rptest1 200001-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with latest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -R /d2/pdo/S10 -M /d2/pdo/rptest1 200001-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with Earliest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -E -R /d2/pdo/S10 -M /d2/pdo/rptest1 200001-02
# ./rpt1
++++++++++++++++++++
+ Regular patching +
++++++++++++++++++++
Validating patches...
Loading patches installed on the system...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Done!
Loading patches requested to install.
Done!
Checking patches that you specified for installation.
Done!
The following requested patches will not be installed because
no patches required by the patch are installed on this system.
0 For patch 200001-02, required patch 200002-01 does not exist.
No patches to install.
++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Recursive patching with latest patch choise policy +
++++++++++++++++++++++++++++++++++++++++++++++++++++++
Validating patches...
Analyzing current system patch context at /d2/pdo/S10...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Analyzing patch base /d2/pdo/rptest1...
Analyzing requested patch 200001-02...
200001-02 requires 200002-01O
Patch 200001-02 obsoleted by another patch which will be installed instead
The following requested patches will not be installed because
they have been made obsolete by other patches already
installed on the system or by patches you have specified for installation.
1 Patch 200004-02 has a higher revision, 200004-03, which is also
requested to be installed.
2 Patch 200004-01 has a higher revision, 200004-02, which is obsoleted.
3 Patch 200002-01 has a higher revision, 200002-02, which is obsoleted.
5 Patch 200001-02 has a higher revision, 200001-03, which is also
requested to be installed.
6 Patch 200003-02 has a higher revision, 200003-03, which is also
requested to be installed.
7 Patch 200002-02 has a higher revision, 200002-03, which is also
requested to be installed.
Approved patches will be installed in this order:
200004-03 200002-03 200003-03 200001-03
zone detected z1
zone detected z2
Preparing checklist for non-global zone check...
Checking non-global zones...
Summary for zones:
Zone z1
Rejected patches:
200001-01 200003-01 200004-02 200004-01 200002-01 200002-02 200003-02 200001-02
Patches that passed the dependency check:
200004-03 200002-03 200003-03 200001-03
Zone z2
Rejected patches:
200001-01 200003-01 200004-02 200004-01 200002-01 200002-02 200003-02 200001-02
Patches that passed the dependency check:
200004-03 200002-03 200003-03 200001-03
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Recursive patching with Earliest patch choise policy +
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Validating patches...
Analyzing current system patch context at /d2/pdo/S10...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Analyzing patch base /d2/pdo/rptest1...
Analyzing requested patch 200001-02...
200001-02 requires 200002-01 - available
Patch 200001-02 approved to install
The following requested patches will not be installed because
they have been made obsolete by other patches already
installed on the system or by patches you have specified for installation.
Approved patches will be installed in this order:
200002-01 200001-02
zone detected z1
zone detected z2
Preparing checklist for non-global zone check...
Checking non-global zones...
Summary for zones:
Zone z1
Rejected patches:
200001-01
Patches that passed the dependency check:
200002-01 200001-02
Zone z2
Rejected patches:
200001-01
Patches that passed the dependency check:
200002-01 200001-02
#
------------------------Test 2---------------------------------
echo ++++++++++++++++++++
echo + Regular patching +
echo ++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -R /d2/pdo/S10 -M /d2/pdo/rptest1 200001-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with latest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -R /d2/pdo/S10 -M /d2/pdo/rptest1 200001-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with Earliest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# cat rpt2
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with latest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -R /d2/pdo/S10 -M /d2/pdo/rptest2 200001-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with Earliest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -E -R /d2/pdo/S10 -M /d2/pdo/rptest2 200001-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with latest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -R /d2/pdo/S10 -M /d2/pdo/rptest2 200001-02
200003-02
echo
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
echo + Recursive patching with Earliest patch choise policy +
echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
/d2/pdo/bin/pdo patchadd -a -D -E -R /d2/pdo/S10 -M /d2/pdo/rptest2 200001-02
200003-02
# ./rpt2
++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Recursive patching with latest patch choise policy +
++++++++++++++++++++++++++++++++++++++++++++++++++++++
Validating patches...
Analyzing current system patch context at /d2/pdo/S10...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Analyzing patch base /d2/pdo/rptest2...
Analyzing requested patch 200001-02...
200001-02 requires 200002-01O
Patch 200001-02 obsoleted by another patch which will be installed instead
The following requested patches will not be installed because
they have been made obsolete by other patches already
installed on the system or by patches you have specified for installation.
1 Patch 200002-01 has a higher revision, 200002-02, which is obsoleted.
2 Patch 200001-02 has a higher revision, 200001-03, which is also
requested to be installed.
3 Patch 200002-02 has a higher revision, 200002-03, which is also
requested to be installed.
4 Patch 200004-01 has a higher revision, 200004-02, which is obsoleted.
5 Patch 200004-02 has a higher revision, 200004-03, which is also
requested to be installed.
Approved patches will be installed in this order:
200004-03 200002-03 200001-03
zone detected z1
zone detected z2
Preparing checklist for non-global zone check...
Checking non-global zones...
Summary for zones:
Zone z1
Rejected patches:
200001-01 200002-02 200002-01 200004-01 200004-02 200001-02
Patches that passed the dependency check:
200004-03 200002-03 200001-03
Zone z2
Rejected patches:
200001-01 200002-02 200002-01 200004-01 200004-02 200001-02
Patches that passed the dependency check:
200004-03 200002-03 200001-03
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Recursive patching with Earliest patch choise policy +
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Validating patches...
Analyzing current system patch context at /d2/pdo/S10...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Analyzing patch base /d2/pdo/rptest2...
Analyzing requested patch 200001-02...
200001-02 requires 200002-01 - available
Patch 200001-02 approved to install
The following requested patches will not be installed because
they have been made obsolete by other patches already
installed on the system or by patches you have specified for installation.
Approved patches will be installed in this order:
200002-01 200001-02
zone detected z1
zone detected z2
Preparing checklist for non-global zone check...
Checking non-global zones...
Summary for zones:
Zone z1
Rejected patches:
200001-01
Patches that passed the dependency check:
200002-01 200001-02
Zone z2
Rejected patches:
200001-01
Patches that passed the dependency check:
200002-01 200001-02
++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Recursive patching with latest patch choise policy +
++++++++++++++++++++++++++++++++++++++++++++++++++++++
Validating patches...
Analyzing current system patch context at /d2/pdo/S10...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Analyzing patch base /d2/pdo/rptest2...
Analyzing requested patch 200001-02...
200001-02 requires 200002-01O
Patch 200001-02 obsoleted by another patch which will be installed instead
Analyzing requested patch 200003-02...
200003-02 requires 200002-02O
Patch 200003-02 obsoleted by another patch which will be installed instead
The following requested patches will not be installed because
they have been made obsolete by other patches already
installed on the system or by patches you have specified for installation.
1 Patch 200002-01 has a higher revision, 200002-02, which is obsoleted.
3 Patch 200001-02 has a higher revision, 200001-03, which is also
requested to be installed.
4 Patch 200002-02 has a higher revision, 200002-03, which is also
requested to be installed.
5 Patch 200004-01 has a higher revision, 200004-02, which is obsoleted.
6 Patch 200003-02 has a higher revision, 200003-03, which is also
requested to be installed.
7 Patch 200004-02 has a higher revision, 200004-03, which is also
requested to be installed.
Approved patches will be installed in this order:
200003-03 200004-03 200002-03 200001-03
zone detected z1
zone detected z2
Preparing checklist for non-global zone check...
Checking non-global zones...
Summary for zones:
Zone z1
Rejected patches:
200001-01 200003-01 200003-02 200002-02 200002-01 200004-01 200004-02 200001-02
Patches that passed the dependency check:
200003-03 200004-03 200002-03 200001-03
Zone z2
Rejected patches:
200001-01 200003-01 200003-02 200002-02 200002-01 200004-01 200004-02 200001-02
Patches that passed the dependency check:
200003-03 200004-03 200002-03 200001-03
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+ Recursive patching with Earliest patch choise policy +
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Validating patches...
Analyzing current system patch context at /d2/pdo/S10...
System patches
116298-08 116302-02 113886-27 116352-01 113887-27
Analyzing patch base /d2/pdo/rptest2...
Analyzing requested patch 200001-02...
200001-02 requires 200002-01 - available
Patch 200001-02 approved to install
Analyzing requested patch 200003-02...
200003-02 requires 200002-02 - available
Patch 200003-02 approved to install
The following requested patches will not be installed because
they have been made obsolete by other patches already
installed on the system or by patches you have specified for installation.
Approved patches will be installed in this order:
200002-02 200001-02 200003-02
zone detected z1
zone detected z2
Preparing checklist for non-global zone check...
Checking non-global zones...
Summary for zones:
Zone z1
Rejected patches:
200001-01 200003-01 200002-01
Patches that passed the dependency check:
200002-02 200001-02 200003-02
Zone z2
Rejected patches:
200001-01 200003-01 200002-01
Patches that passed the dependency check:
200002-02 200001-02 200003-02
#
This message posted from opensolaris.org