{"id":419,"date":"2017-09-18T10:45:24","date_gmt":"2017-09-18T02:45:24","guid":{"rendered":"https:\/\/blog.jsjs.org\/?p=419"},"modified":"2017-09-18T10:45:24","modified_gmt":"2017-09-18T02:45:24","slug":"%e5%85%b3%e4%ba%8erpm%e7%9a%84config%e5%92%8cnoreplace","status":"publish","type":"post","link":"https:\/\/blog.jsjs.org\/?p=419","title":{"rendered":"\u5173\u4e8eRPM\u7684%config\u548c(noreplace)"},"content":{"rendered":"<p>\u8fd9\u7bc7\u6587\u7ae0\u7ffb\u8bd1\u81ea<a href=\"http:\/\/www-uxsup.csx.cam.ac.uk\/~jw35\/docs\/rpm_config.html\">\u8fd9\u91cc<\/a>\uff0c \u662f\u4e00\u7bc7\u5173\u4e8e\u5236\u4f5cRPM\u5305\u4e2d\u7684\u4e00\u4e2a\u6bd4\u8f83\u96be\u4e8e\u7406\u89e3\u7684\u5730\u65b9\u3002 \u4e0d\u505a\u5f00\u53d1\u7684\u540c\u5b66\u5c31\u4e0d\u8981\u770b\u4e86\u3002<\/p>\n<p>RPM spec\u6587\u4ef6\u6709\u4e2a\u540d\u4e3a %config \u7684\u5b8f\uff0c\u5b83\u53ef\u4ee5\u6807\u8bc6\u914d\u7f6e\u6587\u4ef6\uff0c \u8fd9\u6837\u5728\u5347\u7ea7\u65f6\u7528\u6237\u5bf9\u914d\u7f6e\u6587\u4ef6\u505a\u8fc7\u7684\u4fee\u6539\u5c31\u4e0d\u4f1a\u4e22\u5931\u3002 \u6ca1\u6709\u5b83\uff0c\u7528\u6237\u5343\u8f9b\u4e07\u82e6\u4fee\u6539\u8fc7\u7684\u914d\u7f6e\u6587\u4ef6\u4f1a\u5728\u5347\u7ea7\u8fc7\u7a0b\u4e2d\u88ab\u8986\u76d6\u3002<\/p>\n<p>%config\u4e5f\u53ef\u4ee5\u5199\u6210%config(noreplace)\uff0c\u4e0d\u8fc7\u7f51\u4e0a\u5173\u4e8e\u5b83\u7684\u8bf4\u660e\u5374\u5c48\u6307\u53ef\u6570\u3002 \u4e0b\u9762\u662f\u5173\u4e8e\u8fd9\u4e24\u8005\u7684\u4e00\u4e9b\u5b9e\u9a8c\uff0c\u90fd\u662f\u5728RedHat 9\u7684RPM(rpm-4.2-0.69)\u4e0a\u8fdb\u884c\u7684\uff0c \u5176\u4ed6\u7248\u672c\u6709\u53ef\u80fd\u4e0d\u540c\u3002<\/p>\n<p>RPM\u4e2d\u7684\u6587\u4ef6\u7684\u5236\u7ea6\u6761\u4ef6\u6709\u4e09\u4e2a\uff1a1. \u8be5\u6587\u4ef6\u5728spec\u4e2d\u5982\u4f55\u6807\u8bc6\uff08\u9ed8\u8ba4\uff0c%config\u6216\u8005%config(noreplace)\uff09\uff1b 2. \u5728rpm\u5347\u7ea7\u5305\u4e2d\u8be5\u6587\u4ef6\u662f\u5426\u88ab\u66f4\u65b0\uff1b3. \u8be5\u6587\u4ef6\u662f\u5426\u88ab\u7528\u6237\u7f16\u8f91\u8fc7\u3002<\/p>\n<p>\u4e0b\u8868\u5c31\u662f\u5404\u4e2a\u6761\u4ef6\u7684\u7ec4\u5408\u7ed3\u679c\u3002<\/p>\n<table>\n<tbody>\n<tr>\n<td>\u6587\u4ef6\u6807\u8bc6<\/td>\n<td>\u5728RPM\u5347\u7ea7\u5305\u4e2d\u662f\u5426\u66f4\u65b0\u4e86\uff1f<\/td>\n<td>\u65e7\u7248\u672c\u6587\u4ef6\u672a\u88ab\u7528\u6237\u7f16\u8f91\u8fc7<\/td>\n<td>\u65e7\u7248\u672c\u6587\u4ef6\u88ab\u7528\u6237\u7f16\u8f91\u8fc7<\/td>\n<\/tr>\n<tr>\n<td>\u9ed8\u8ba4<\/td>\n<td>No<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<\/tr>\n<tr>\n<td>~<\/td>\n<td>Yes<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<\/tr>\n<tr>\n<td>%config<\/td>\n<td>No<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<td>\u4fdd\u6301\u65e7\u6587\u4ef6<\/td>\n<\/tr>\n<tr>\n<td>~<\/td>\n<td>Yes<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<td>\u65e7\u6587\u4ef6\u6539\u540d\u4e3a.rpmsave\u5e76\u590d\u5236\u65b0\u6587\u4ef6<\/td>\n<\/tr>\n<tr>\n<td>%config(noreplace)<\/td>\n<td>No<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<td>\u4fdd\u6301\u65e7\u6587\u4ef6<\/td>\n<\/tr>\n<tr>\n<td>~<\/td>\n<td>Yes<\/td>\n<td>\u7528\u65b0\u6587\u4ef6\u8986\u76d6<\/td>\n<td>\u4fdd\u6301\u65e7\u6587\u4ef6\uff0c\u65b0\u6587\u4ef6\u5b89\u88c5\u4e3a.rpmnew<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u5176\u4e2d(noreplace)\u6709\u6548\u7684\u4e24\u79cd\u60c5\u51b5\u4e0a\u5b58\u5728\u4ee5\u4e0b\u7684\u95ee\u9898\uff1a\u5f53spec\u6587\u4ef6\u4e2d\u7684\u5b9a\u4e49\u6539\u53d8\u65f6\u4f1a\u53d1\u751f\u4ec0\u4e48\uff1f\u7ed3\u8bba\u5982\u4e0b\uff1a<\/p>\n<table>\n<tbody>\n<tr>\n<td>\u6587\u4ef6\u6807\u8bc6<\/td>\n<td>\u5728RPM\u5347\u7ea7\u5305\u4e2d\u662f\u5426\u66f4\u65b0\u4e86\uff1f<\/td>\n<td>\u65e7\u7248\u672c\u6587\u4ef6\u88ab\u7528\u6237\u7f16\u8f91\u8fc7<\/td>\n<\/tr>\n<tr>\n<td>\u7531%config(noreplace)\u6539\u4e3a%config<\/td>\n<td>Yes<\/td>\n<td>\u65e7\u6587\u4ef6\u6539\u540d\u4e3a.rpmsave\u5e76\u5b89\u88c5\u65b0\u6587\u4ef6<\/td>\n<\/tr>\n<tr>\n<td>\u7531%config\u6539\u4e3a%config(noreplace)<\/td>\n<td>Yes<\/td>\n<td>\u4fdd\u6301\u65e7\u6587\u4ef6\uff0c\u65b0\u6587\u4ef6\u5b89\u88c5\u4e3a.rpmnew<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u7ed3\u8bba\uff1a\u975e\u914d\u7f6e\u6587\u4ef6\u6216\u662f\u4e0a\u6b21\u5b89\u88c5\u540e\u6ca1\u6709\u88ab\u4fee\u6539\u7684\u6587\u4ef6\u4f1a\u88abRPM\u5305\u5185\u7684\u65b0\u6587\u4ef6\u8986\u76d6\u3002 \u5982\u679c\u914d\u7f6e\u6587\u4ef6\u88ab\u4fee\u6539\u8fc7\uff0c\u4f46\u5728\u65b0\u7684RPM\u5305\u4e2d\u672a\u4f5c\u66f4\u65b0\uff0c\u5219\u4fee\u6539\u8fc7\u7684\u6587\u4ef6\u4fdd\u7559\u3002 \u4ec5\u5f53\u914d\u7f6e\u6587\u4ef6\u88ab\u4fee\u6539\u5e76\u4e14\u5728\u65b0\u7684RPM\u5305\u4e2d\u88ab\u66f4\u65b0\u65f6\uff0c\u5177\u4f53\u52a8\u4f5c\u53d6\u51b3\u4e8e(noreplace)\u3002 %config\u4f7f\u5f97\u65e7\u6587\u4ef6\u88ab\u6539\u540d\u4e3a.rpmsave\u5e76\u5b89\u88c5\u65b0\u6587\u4ef6\uff0c\u800c%config(noreplace)\u5c06\u4fdd\u6301\u65e7\u6587\u4ef6 \u5e76\u5c06\u65b0\u6587\u4ef6\u5b89\u88c5\u4e3a.rpmnew\u3002<\/p>\n<p>\u5efa\u8bae\u4e00\u822c\u914d\u7f6e\u6587\u4ef6\u90fd\u6807\u8bc6\u4e3a(noreplace)\uff0c\u9664\u975e\u5347\u7ea7\u6240\u5e26\u6765\u7684\u914d\u7f6e\u6587\u4ef6\u53d8\u52a8\u975e\u5e38\u91cd\u8981\uff0c \u4f7f\u7528\u4e0a\u4e00\u7248\u672c\u7684\u914d\u7f6e\u6587\u4ef6\u65e0\u6cd5\u6b63\u5e38\u5de5\u4f5c\u65f6\u624d\u4f7f\u7528%config\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u8fd9\u7bc7\u6587\u7ae0\u7ffb\u8bd1\u81ea\u8fd9\u91cc\uff0c \u662f\u4e00\u7bc7\u5173\u4e8e\u5236\u4f5cRPM\u5305\u4e2d\u7684\u4e00\u4e2a\u6bd4\u8f83\u96be\u4e8e\u7406\u89e3\u7684\u5730\u65b9\u3002 \u4e0d\u505a\u5f00\u53d1\u7684\u540c\u5b66\u5c31\u4e0d\u8981\u770b\u4e86\u3002 RPM spec\u6587\u4ef6\u6709\u4e2a\u540d\u4e3a %config \u7684\u5b8f\uff0c\u5b83\u53ef\u4ee5\u6807\u8bc6\u914d\u7f6e\u6587\u4ef6\uff0c \u8fd9\u6837\u5728\u5347\u7ea7\u65f6\u7528\u6237\u5bf9\u914d\u7f6e\u6587\u4ef6\u505a\u8fc7\u7684\u4fee\u6539\u5c31\u4e0d\u4f1a\u4e22\u5931\u3002 \u6ca1\u6709\u5b83\uff0c\u7528\u6237\u5343\u8f9b\u4e07\u82e6\u4fee\u6539\u8fc7\u7684\u914d\u7f6e\u6587\u4ef6\u4f1a\u5728\u5347\u7ea7\u8fc7\u7a0b\u4e2d\u88ab\u8986\u76d6\u3002 %config\u4e5f\u53ef\u4ee5\u5199\u6210%config(noreplace)\uff0c\u4e0d\u8fc7\u7f51\u4e0a\u5173\u4e8e\u5b83\u7684\u8bf4\u660e\u5374\u5c48\u6307\u53ef\u6570\u3002 \u4e0b\u9762\u662f\u5173\u4e8e\u8fd9\u4e24\u8005\u7684\u4e00\u4e9b\u5b9e\u9a8c\uff0c\u90fd\u662f\u5728RedHat 9\u7684RPM(rpm-4.2-0.69)\u4e0a\u8fdb\u884c\u7684\uff0c \u5176\u4ed6\u7248\u672c\u6709\u53ef\u80fd\u4e0d\u540c\u3002 RPM\u4e2d\u7684\u6587\u4ef6\u7684\u5236\u7ea6\u6761\u4ef6\u6709\u4e09\u4e2a\uff1a1. \u8be5\u6587\u4ef6\u5728spec\u4e2d\u5982\u4f55\u6807\u8bc6\uff08\u9ed8\u8ba4\uff0c%config\u6216\u8005%config(noreplace)\uff09\uff1b 2. \u5728rpm\u5347\u7ea7\u5305\u4e2d\u8be5\u6587\u4ef6\u662f\u5426\u88ab\u66f4\u65b0\uff1b3. \u8be5\u6587\u4ef6\u662f\u5426\u88ab\u7528\u6237\u7f16\u8f91\u8fc7\u3002 \u4e0b\u8868\u5c31\u662f\u5404\u4e2a\u6761\u4ef6\u7684\u7ec4\u5408\u7ed3\u679c\u3002 \u6587\u4ef6\u6807\u8bc6 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[1],"tags":[],"class_list":["post-419","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=\/wp\/v2\/posts\/419","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=419"}],"version-history":[{"count":0,"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=\/wp\/v2\/posts\/419\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=419"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=419"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.jsjs.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=419"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}