{"id":2377,"date":"2018-10-24T10:51:19","date_gmt":"2018-10-24T02:51:19","guid":{"rendered":"https:\/\/www.aoisnow.net\/blog\/?p=2377"},"modified":"2018-10-24T10:51:19","modified_gmt":"2018-10-24T02:51:19","slug":"tont-41483-%e4%b8%8d%e5%ae%89%e5%85%a8%e7%9a%84%e8%ae%be%e5%a4%87%e5%88%a0%e9%99%a4%e5%af%b9%e8%af%9d%e6%a1%86","status":"publish","type":"post","link":"https:\/\/www.aoisnow.net\/blog\/archives\/2377","title":{"rendered":"TONT 41483 \u4e0d\u5b89\u5168\u7684\u8bbe\u5907\u5220\u9664\u5bf9\u8bdd\u6846"},"content":{"rendered":"<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-2378\" src=\"https:\/\/www.aoisnow.net\/blog\/wp-content\/uploads\/2018\/10\/windows2000_unsafe_device_removal_dialog.png\" alt=\"\" width=\"390\" height=\"400\" \/><\/p>\n<p>\u7b97\u4e86\u7b97\u4e86\uff0c\u6211\u4e0d\u7ba1\u4f60\u4e86\u3002<\/p>\n<p><!--more--><\/p>\n<p>\u539f\u6587\u94fe\u63a5\uff1a<a href=\"https:\/\/blogs.msdn.microsoft.com\/oldnewthing\/20031216-00\/?p=41483\" target=\"_blank\" rel=\"noopener\">https:\/\/blogs.msdn.microsoft.com\/oldnewthing\/20031216-00\/?p=41483<\/a><\/p>\n<p>In a comment, somebody asked what the deal was with the unsafe device removal dialog in Windows 2000 and why it&#8217;s gone in Windows XP.<\/p>\n<p>\u5728\u67d0\u5219\u8bc4\u8bba\u4e2d\uff0c\u6709\u4eba\u63d0\u95eeWindows 2000\u4e2d\u7684\u300e\u4e0d\u5b89\u5168\u8bbe\u5907\u5220\u9664\u300f\u5bf9\u8bdd\u6846\u76f8\u5173\u7684\u4e8b\u60c5\uff0c\u4ee5\u53ca\u4e3a\u4ec0\u4e48\u5230\u4e86Windows XP\u8fd9\u4e2a\u5bf9\u8bdd\u6846\u53c8\u88ab\u79fb\u9664\u4e86\u3002<\/p>\n<p>I wasn&#8217;t involved with that dialog, but here&#8217;s what I remember: The device was indeed removed unsafely. If it was a USB storage device, for example, there may have been unflushed I\/O buffers. If it were a printer, there may have been an active print job. The USB stack doesn&#8217;t know for sure (those are concepts at a higher layer that the stack doesn&#8217;t know about) &#8211; all it knows is that it had an active channel with the device and now the device is gone, so it gets upset and yells at you.<\/p>\n<p>\u6211\u6ca1\u6709\u53c2\u4e0e\u90a3\u4e2a\u5bf9\u8bdd\u6846\u7684\u8bbe\u8ba1\u5de5\u4f5c\uff0c\u4e0d\u8fc7\u6211\u6240\u8bb0\u5f97\u7684\u662f\uff1a\u76f8\u5173\u8bbe\u5907\u7684\u786e\u88ab\u4ee5\u4e0d\u5b89\u5168\u7684\u65b9\u5f0f\u79fb\u9664\u4e86\u3002\u4f8b\u5982\uff0c\u5982\u679c\u662f\u4e00\u4e2aUSB\u5b58\u50a8\u8bbe\u5907\uff0c\u53ef\u80fdI\/O\u7f13\u5b58\u4e2d\u8fd8\u5b58\u5728\u5c1a\u672a\u5b8c\u6210\u5904\u7406\u7684\u6570\u636e\uff1b\u5982\u679c\u662f\u53f0\u6253\u5370\u673a\uff0c\u53ef\u80fd\u6709\u6b63\u5728\u8fdb\u884c\u7684\u6253\u5370\u4efb\u52a1\u3002USB\u534f\u8bae\u6808\u5bf9\u6b64\u5e76\u4e0d\u786e\u5207\u660e\u4e86\uff08\u8fd9\u4e9b\u76f8\u5173\u7684\u4fe1\u606f\u662f\u7531\u66f4\u9ad8\u5c42\u6b21\u7684\u673a\u5236\u5904\u7406\u7684\uff0c\u534f\u8bae\u6808\u5e76\u4e0d\u4e86\u89e3\uff09\u2014\u2014\u534f\u8bae\u6808\u6240\u77e5\u7684\u53ea\u662f\u521a\u521a\u4e0e\u8fd9\u53f0\u8bbe\u5907\u8fd8\u6709\u4e2a\u6d3b\u52a8\u7684\u6570\u636e\u901a\u9053\uff0c\u7136\u540e\u73b0\u5728\u8bbe\u5907\u5374\u4e0d\u89c1\u4e86\uff0c\u6240\u4ee5\u5b83\u4f1a\u6025\u5f97\u8df3\u8d77\u811a\u6765\uff0c\u5bf9\u7528\u6237\u5927\u558a\u5927\u53eb\u3002<\/p>\n<p>In Windows XP, it still gets upset but it now keeps its mouth shut. You&#8217;re now on your honor not to rip out your USB drive before waiting two seconds for all I\/O to flush, not to unplug your printer while a job is printing, etc. If you do, then your drive gets corrupted \/ print job is lost \/ etc. and you&#8217;re on your own.<\/p>\n<p>\u800c\u5728Windows XP\u4e2d\uff0c\u534f\u8bae\u6808\u4ecd\u7136\u4f1a\u5bf9\u6b64\u6df1\u8868\u4e0d\u6ee1\uff0c\u4f46\u4f1a\u9009\u62e9\u4e00\u8a00\u4e0d\u53d1\u3002\u73b0\u5728\u4f60\u5fc5\u987b\u81ea\u884c\u627f\u62c5\u4e0d\u7b49\u6700\u540e\u4e24\u79d2\u949f\u3001\u8ba9\u7f13\u51b2\u533a\u91cc\u7684\u6570\u636e\u88ab\u5904\u7406\u5b8c\u4e4b\u524d\u4e0d\u8981\u62d4\u6389\u4f60\u7684U\u76d8\uff0c\u6216\u8005\u6b63\u5728\u6253\u5370\u65f6\u4e0d\u8981\u628a\u6253\u5370\u673a\u626f\u6389\u4e4b\u7c7b\u7684\u4e8b\u60c5\u7684\u540e\u679c\u3002\u771f\u8981\u662f\u8fd9\u4e48\u505a\u4e86\uff0c\u90a3\u4e48\u4f60\u5c31\u8981\u9762\u5bf9\u7684U\u76d8\u5c31\u4f1a\u574f\u6389\u3001\u6253\u5370\u4efb\u52a1\u4e22\u5931\u4e4b\u7c7b\u7684\u4e8b\u60c5\uff0c\u5e76\u81ea\u884c\u627f\u62c5\u76f8\u5e94\u7684\u540e\u679c\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7b97\u4e86\u7b97\u4e86\uff0c\u6211\u4e0d\u7ba1\u4f60\u4e86\u3002<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[],"class_list":["post-2377","post","type-post","status-publish","format-standard","hentry","category-tont_history"],"_links":{"self":[{"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/posts\/2377","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/comments?post=2377"}],"version-history":[{"count":0,"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/posts\/2377\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/media?parent=2377"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/categories?post=2377"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.aoisnow.net\/blog\/wp-json\/wp\/v2\/tags?post=2377"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}