<?xml version="1.0" encoding="utf-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><title>张大伟博客</title><link>https://zdw.vip/</link><description>Good Luck To You!</description><item><title>emlog夜色视频主题</title><link>https://zdw.vip/?id=44</link><description>&lt;h3 style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin-top: 20px; margin-bottom: 10px; font-size: 16px; padding: 10px 0px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;emlog是一款国人开发的优秀的知名php博客程序，通过今天这款emlog夜色视频主题，即可轻松打造一个视频网站，视频站的用户粘度加emlog博客程序的SEO优势，应该有不错的效益。&lt;/h3&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;这款emlog夜色主题是简单从素材网扒下来的视频模板，带两种首页展示模式，两种列表展示模式 搭配分集视频播放器效果最佳，当然也可以自行插入Video标签。&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;演示站http://su1018.top&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;图片&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;a class=&quot;alignnone size-full wp-image-18129&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2022/01/9fa99a67f2a3a4c.jpg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px; margin: 0px auto;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607032107178077366731363.jpeg&quot;&gt;&lt;/a&gt;&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;这款模板目前免费发布在emlog官方应用商店里，可以免费使用。&lt;a title=&quot;点此进入emlog官方主题页面查看&quot; href=&quot;https://www.emlog.net/template/detail/992&quot; target=&quot;_blank&quot; rel=&quot;noopener noreferrer nofollow&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;点此进入emlog官方主题页面查看&lt;/a&gt;&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:20:55 +0800</pubDate></item><item><title>EmlogPro简约蓝BULE博客主题 v2.2</title><link>https://zdw.vip/?id=43</link><description>&lt;div id=&quot;attachment_19565&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 1249px;&quot;&gt;&lt;a class=&quot;size-full wp-image-19565&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2022/06/cfcd208495d565e-4.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607032007178077360766589.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-19565&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word; color: var(--theme-color);&quot;&gt;EmlogPro简约蓝BULE博客主题 v2.2&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;主题需要安装模板设置插件！该主题适配EMLOG-PRO，其他版本另行测试。之前是收费的现在免费分享出来吧！&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;1、首页幻灯片可设置获取哪一篇文章内容，也可以自定义幻灯片。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;2、首页图文板块可设置展示多个分类内容。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;3、首页带文章CMS板块，可开关。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;4、模板带公告弹窗，可在模板设置插件中设置。 5、模板全面支持PRO，轻便小巧。&lt;/p&gt;&lt;h3 style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin-top: 20px; margin-bottom: 10px; font-size: 16px; padding: 10px 0px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;2020-05-27 v2.2更新：&lt;/h3&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;1、修复首页CMS板块标题过长不省略bug。&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;2、修复标签不显示bug。&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;3、文章页优化。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;非常简洁的博客主题，适合个人博客、咨询站、图文站！&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:19:10 +0800</pubDate></item><item><title>安装和使用Strapi时一些令人抓狂的问题</title><link>https://zdw.vip/?id=42</link><description>&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;96&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;不知道大伙在安装strapi时有没有遇到这种情况：&lt;/p&gt;&lt;p&gt;&lt;figure class=&quot;wp-block-image size-large is-resized text-reveal&quot; data-sr-id=&quot;97&quot; style=&quot;box-sizing: border-box; margin: 0px 0px 20px; overflow: hidden; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_20646&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 1290px;&quot;&gt;&lt;a class=&quot;size-full wp-image-20646&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/c4ca4238a0b9238-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031631178077339134623.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-20646&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;安装和使用Strapi时一些令人抓狂的问题&lt;/p&gt;&lt;/div&gt;&lt;/figure&gt;&lt;/p&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;98&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;报错信息：error Error: https://registry.npmjs.org/@strapi%2fstrapi: tunneling socket could not be established, cause=getaddrinfo ENOTFOUND 10809&lt;/p&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;99&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;当然你换成淘宝镜像依然会有此报错信息：&lt;/p&gt;&lt;p&gt;&lt;figure class=&quot;wp-block-image size-large text-reveal&quot; data-sr-id=&quot;100&quot; style=&quot;box-sizing: border-box; margin: 0px 0px 20px; overflow: hidden; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_20647&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 1290px;&quot;&gt;&lt;a class=&quot;size-full wp-image-20647&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/c81e728d9d4c2f6-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031631178077339175769.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-20647&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;安装和使用Strapi时一些令人抓狂的问题&lt;/p&gt;&lt;/div&gt;&lt;/figure&gt;&lt;/p&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;101&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;这看似好像是一个网络的问题，但是换成淘宝镜像还是会安装失败。但是与之报错脱不了干系的一定有10809端口，大伙看着这个端口是不是很熟悉呢？没错，他就是v2的端口。v2在本地占用了2个默认端口，10808(socks) 和 10809(http)。&lt;/p&gt;&lt;p&gt;&lt;figure class=&quot;wp-block-image size-large text-reveal&quot; data-sr-id=&quot;102&quot; style=&quot;box-sizing: border-box; margin: 0px 0px 20px; overflow: hidden; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_20648&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 363px;&quot;&gt;&lt;a class=&quot;size-full wp-image-20648&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/eccbc87e4b5ce2f-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031632178077339213721.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-20648&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;安装和使用Strapi时一些令人抓狂的问题&lt;/p&gt;&lt;/div&gt;&lt;/figure&gt;&lt;/p&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;103&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;这一下就能说通了，好像就是10809端口的代理连接不上？于是打开了v2的代理再次尝试。依然以10809端口无法建立隧道套接字的报错结束。后来上网一查，咦，原来npm也可以在cmd里设置代理！&lt;/p&gt;&lt;p id=&quot;6&quot; class=&quot;text-reveal&quot; data-sr-id=&quot;104&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;设置代理的代码如下：&lt;/p&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;pre class=&quot;wp-block-code text-reveal language-cpp prettyprint&quot; tabindex=&quot;0&quot; data-sr-id=&quot;105&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;npm&amp;nbsp;config&amp;nbsp;set&amp;nbsp;proxy&amp;nbsp;http://127.0.0.1:10809npm&amp;nbsp;config&amp;nbsp;set&amp;nbsp;https-proxy&amp;nbsp;http://127.0.0.1:10809&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;/div&gt;&amp;nbsp;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;106&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;清除代理：&lt;/p&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;pre class=&quot;wp-block-code text-reveal language-bash prettyprint&quot; tabindex=&quot;0&quot; data-sr-id=&quot;107&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;npm&amp;nbsp;config&amp;nbsp;rm&amp;nbsp;proxy
npm&amp;nbsp;config&amp;nbsp;rm&amp;nbsp;https-proxy&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;/div&gt;&amp;nbsp;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;shortcode-tip info text-reveal&quot; data-sr-id=&quot;108&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&amp;nbsp;更多代理配置yarn也会存在这个问题，所以我把相关代理放到这里：&lt;a href=&quot;https://note.onll.cn/note/npm.html#%E9%85%8D%E7%BD%AE%E4%BB%A3%E7%90%86&quot; target=&quot;_blank&quot; rel=&quot;noopener&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;查看笔记&lt;/a&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;h2 id=&quot;title-2&quot; class=&quot;wp-block-heading text-reveal&quot; data-sr-id=&quot;109&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;运行时页面无法打开&lt;/h2&gt;&lt;div class=&quot;shortcode-tip danger text-reveal&quot; data-sr-id=&quot;110&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&amp;nbsp;提示使用1337端口运行时页面无法打开并提示426错误码&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;111&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;当我们安装好strapi后会自动启动strapi服务，默认端口为1337，大伙有没有遇到打开提示http 426的错误。当遇到426错误代码时我也是很头疼啊，当初我以为是代理问题，我关闭了代理，又改了hosts，依然没有解决。然后查找了全网（ChatGPT、百度、必应、谷歌，报错github里的issue），都没有找到解决办法。&lt;/p&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;112&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;既然在本地用1337端口打不开，那我换个端口试试？我将端口换到了3000，重启后发现正常运行了。没错，1337端口被占用了。那么巧了，什么程序会默认占用1337端口呢？它就是Razer，雷蛇驱动：雷云，这是我通过资源管理器查找到的。所以当你存在razer服务时就需要更换strapi的运行端口。&lt;/p&gt;&lt;p class=&quot;text-reveal&quot; data-sr-id=&quot;113&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;更换端口时需要将config.js和.env的端口一并更换，否则也不行。&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:16:16 +0800</pubDate></item><item><title>WordPress 启用对象缓存Redis</title><link>https://zdw.vip/?id=41</link><description>&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;Redis的对象缓存，可以使用WordPress.org上提供的免费插件Redis Object Cache。它支持Predis、PhpRedis（PECL）、HHVM、复制、群集和WP-CLI。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;使用此插件之前，您需要检查您的站点是否正在使用具有所需&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;PHP Redis&lt;/code&gt;扩展名和正常工作的Redis服务器的PHP环境，宝塔可以安装下图在PHP管理里安装 redis 扩展，使用自编译环境的大神请自行解决。&lt;/p&gt;&lt;div id=&quot;attachment_21972&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 955px;&quot;&gt;&lt;a class=&quot;size-full wp-image-21972&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/b55423923492838.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031211178077313136603.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-21972&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;如果一切就绪，则此插件的安装非常简单-只需激活该插件，转到&lt;/span&gt;&lt;span style=&quot;text-align: justify; box-sizing: border-box; font-weight: 700;&quot;&gt;“设置”&amp;gt;“ Redis”&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;，然后单击“启用对象缓存”即可。&lt;/span&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;div id=&quot;attachment_21973&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 1290px;&quot;&gt;&lt;a class=&quot;size-full wp-image-21973&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/686c1d1a524671f.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px; outline: 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031212178077313287456.png&quot;&gt;&lt;/a&gt;&lt;/div&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:11:51 +0800</pubDate></item><item><title>WordPress网站免插件，一行代码实现：上传图片自动转为WebP格式</title><link>https://zdw.vip/?id=40</link><description>&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;用一段php代码，免插件的方式，实现图片上传WordPress网站，自动将JPEG、PNG、GIF等转换为WebP格式图片。大大提高网站文章编辑的效率。之前我在写文章的时候，上传图片到网站的流程是先手动把本地的图片到一些站点，比如Squoosh、TinyPNG，进行WebP格式转化压缩，之后再手动上传到网站。这个过程实际上非常耗时，且机械重复没什么技术含量。一直想着有什么方法可以上传图片到网站的过程中自动就把这些活干了，省时省力。以前也尝试过一些插件，要么免费额度太少，要么过多的插件影响网站速度。&lt;/p&gt;&lt;div id=&quot;attachment_22443&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 685px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22443&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/c4f3374d133df0c-1.jpg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031132178077309251709.jpeg&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22443&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;WordPress网站免插件，一行代码实现：上传图片自动转为WebP格式&lt;/p&gt;&lt;/div&gt;&lt;h2 id=&quot;wznav_1&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;为什么要使用WebP格式的图片&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;WebP格式图片是由 Google 推出的一种现代图像格式，用来替代传统的图像格式如 JPEG、PNG、GIF 等。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;相比 JPEG、PNG和GIF，WebP 通常可以提供更小的文件大小，同时保持相似或更好的图像质量。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;较小的图片体积让网页加载更快，能够提高用户体验。快速加载的网页对 SEO（搜索引擎优化） 更好，提升网站在 Google、百度 等搜索引擎中的排名。&lt;/p&gt;&lt;h2 id=&quot;wznav_2&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;自动转化WebP代码&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;代码功能说明：&lt;/p&gt;&lt;ul class=&quot;wp-block-list list-paddingleft-2&quot; style=&quot;box-sizing: border-box; margin-bottom: 18px; margin-left: 30px; padding: 0px; list-style-position: initial; list-style-image: initial; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;li&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;&lt;/li&gt;&lt;ul class=&quot;wp-block-list list-paddingleft-2&quot; style=&quot;list-style-type: square;&quot;&gt;&lt;li&gt;&lt;p&gt;自动识别并将上传的图片jpeg、png、gif格式的图片转换为WebP格式&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/ul&gt;&lt;ul class=&quot;wp-block-list list-paddingleft-2&quot; style=&quot;box-sizing: border-box; margin-bottom: 18px; margin-left: 30px; padding: 0px; list-style-position: initial; list-style-image: initial; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;li&gt;&lt;p&gt;图像质量为80%（如果要设置其他值，可更改代码中的 $quality = 80，建议值 70-90% ）&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;不保留原文件（如果要保留，删除或注释这个代码&lt;span style=&quot;box-sizing: border-box; font-weight: 700; font-size: 14px; color: #4E585A;&quot;&gt;@unlink($file_path);&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;/**&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;* Convert Uploaded Images to WebP Format with Custom Quality&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;*/&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;add_filter(&amp;#39;wp_handle_upload&amp;#39;, &amp;#39;wpturbo_handle_upload_convert_to_webp&amp;#39;);&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;function wpturbo_handle_upload_convert_to_webp($upload) {&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;if (in_array($upload[&amp;#39;type&amp;#39;], [&amp;#39;image/jpeg&amp;#39;, &amp;#39;image/png&amp;#39;, &amp;#39;image/gif&amp;#39;])) {&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$file_path = $upload[&amp;#39;file&amp;#39;];&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;if (extension_loaded(&amp;#39;imagick&amp;#39;) || extension_loaded(&amp;#39;gd&amp;#39;)) {&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$image_editor = wp_get_image_editor($file_path);&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;if (!is_wp_error($image_editor)) {&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;// Set WebP quality (adjust as needed)&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$quality = 80; // Adjust between 0 (low) to 100 (high)&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;$image_editor-&amp;gt;set_quality($quality); // Set quality for WebP conversion&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;$file_info = pathinfo($file_path);&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$dirname = $file_info[&amp;#39;dirname&amp;#39;];&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$filename = $file_info[&amp;#39;filename&amp;#39;];&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$def_filename = wp_unique_filename($dirname, $filename . &amp;#39;.webp&amp;#39;);&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$new_file_path = $dirname . &amp;#39;/&amp;#39; . $def_filename;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;$saved_image = $image_editor-&amp;gt;save($new_file_path, &amp;#39;image/webp&amp;#39;);&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;if (!is_wp_error($saved_image) &amp;amp;&amp;amp; file_exists($saved_image[&amp;#39;path&amp;#39;])) {&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;// Update the upload data to use the WebP image&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$upload[&amp;#39;file&amp;#39;] = $saved_image[&amp;#39;path&amp;#39;];&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$upload[&amp;#39;url&amp;#39;] = str_replace(basename($upload[&amp;#39;url&amp;#39;]), basename($saved_image[&amp;#39;path&amp;#39;]), $upload[&amp;#39;url&amp;#39;]);&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;$upload[&amp;#39;type&amp;#39;] = &amp;#39;image/webp&amp;#39;;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;// Optionally delete the original file&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;@unlink($file_path);&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;}&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;}&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;}&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;}&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;return $upload;&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;}&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;建议代码用Code Snippets、WPCode等插件进行统一管理。&lt;/p&gt;&lt;div id=&quot;attachment_22444&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 863px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22444&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/58b3d72022fa298-1.jpg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031133178077309367412.jpeg&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22444&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;WordPress网站免插件，一行代码实现：上传图片自动转为WebP格式&lt;/p&gt;&lt;/div&gt;&lt;h2 id=&quot;wznav_3&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;实际测试&lt;/h2&gt;&lt;div id=&quot;attachment_22445&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 726px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22445&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/12597dc1fdeceb9-1.jpg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031133178077309395200.jpeg&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22445&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;WordPress网站免插件，一行代码实现：上传图片自动转为WebP格式&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;上传后格式自动为WebP，大小为22kb，变化极其明显&lt;/p&gt;&lt;div id=&quot;attachment_22446&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 809px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22446&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/334593070dc462b-1.jpg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px; outline: 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607031133178077309337054.jpeg&quot;&gt;&lt;/a&gt;&lt;/div&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:10:55 +0800</pubDate></item><item><title>linux执行命令权限不够怎么办？如何获取权限？</title><link>https://zdw.vip/?id=39</link><description>&lt;p data-track=&quot;2&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;Linux 系统管理中，用户权限分配与安全控制是信息安全的核心环节。直接使用 root 账户进行日常操作存在极高风险，一旦密码泄露或误操作，可能导致系统失控、数据泄露或恶意攻击。此外，普通用户权限过度开放或受限不足，也会引发权限滥用或业务受阻。本案例针对企业或&lt;span class=&quot;wpcom_keyword_link&quot; style=&quot;box-sizing: border-box;&quot;&gt;服务器&lt;/span&gt;环境中常见的多用户协作场景，通过精细化用户权限管理，平衡安全性与操作便利性，防止未授权访问和权限滥用，确保系统稳定运行。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21904&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 720px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21904&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/4372d3bfb21f3f2-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030505178077270591210.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p data-track=&quot;4&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;本案例基于 Linux 系统（如 CentOS），演示如何通过用户创建、权限分配及登录安全设置构建多层次权限管理体系。核心步骤包括：&lt;/p&gt;&lt;ol start=&quot;1&quot; style=&quot;box-sizing: border-box; margin-bottom: 18px; margin-left: 30px; padding: 0px; list-style-position: initial; list-style-image: initial; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot; class=&quot; list-paddingleft-2&quot;&gt;&lt;li&gt;&lt;p&gt;用户创建与基础配置：使用useradd创建普通用户user1，通过passwd设置强密码，并验证账户登录功能，避免直接使用 root 账户。&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;sudo 权限精细化管理：编辑/etc/sudoers文件，允许user1执行特定管理命令（如创建用户useradd、修改普通用户密码passwd），但禁止修改 root 密码（通过!/usr/bin/passwd root规则），实现 “最小权限原则”。测试显示，user1可成功创建user2并设置密码，但尝试修改 root 密码时被拒绝。&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;登录安全强化：禁止 root 远程登录（修改sshd_config中PermitRootLogin no），设置用户会话超时时间（TMOUT=180秒无操作自动注销），并通过附加组（如 wheel 组）灵活扩展用户权限。&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;案例实现了普通用户与管理员账户的权限隔离，降低了 root 账户暴露风险，同时确保普通用户在授权范围内高效操作，为企业级 Linux 系统权限管理提供了可复用的安全模板。&lt;/p&gt;&lt;h1 class=&quot;pgc-h-arrow-right&quot; style=&quot;box-sizing: border-box; margin: 20px 0px 10px; font-size: 36px; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; color: rgb(51, 51, 51); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span id=&quot;311_25E52588259B25E525BB25BA25E7259425A825E6258825B725E525B925B625E625B5258B25E825AF259525E7259925BB25E525BD2595&quot; class=&quot;ez-toc-section&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;3.1.1 创建用户并测试登录&lt;/h1&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（1）创建新用户：执行useradd user1创建一个普通用户，为后续权限分配做准备，避免直接使用高权限的root用户进行日常操作，降低安全风险。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21905&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 901px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21905&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/aa8e6d62e9f0cce-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030506178077270647149.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（2）设置用户密码：执行passwd user1设置登录密码，强密码能有效防止暴力破解，提升账户安全性。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21906&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 862px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21906&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/6b5360e4e33c511-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030506178077270671512.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（3）确认账户可正常登录：使用新创建的user1账户尝试登录系统。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21907&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 975px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21907&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/a51c7861611e4eb-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030506178077270612444.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;h1 class=&quot;pgc-h-arrow-right&quot; style=&quot;box-sizing: border-box; margin: 20px 0px 10px; font-size: 36px; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-weight: 500; line-height: 1.1; color: rgb(51, 51, 51); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span id=&quot;312_25E425BF25AE25E6259425B925E7259425A825E6258825B725E6259D258325E925992590&quot; class=&quot;ez-toc-section&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;3.1.2 修改用户权限&lt;/h1&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（1）为新用户添加 sudo 权限：编辑/etc/sudoers文件，添加nuser1 ALL=(ALL) ALL。允许user1在无需密码的情况下执行sudo命令，方便进行管理操作，同时保持了一定的权限控制。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21908&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 831px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21908&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/a7b379743f560df-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030507178077270732154.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（2）在 /etc/sudoers 文件中授予普通用户执行所有命令的权限后，该用户并不能直接使用 su – 或 su – root 命令切换到 root 用户，而必须要使用 sudo su – 或 sudo su – root 命令。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21909&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 869px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21909&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/5dc102ee2aea84b-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030507178077270727507.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（3）授予普通用户创建用户，并修改用户密码的权限，但是禁止该用户修改 root 用户密码，在 /etc/sudoers 文件中将nuser1 ALL=(ALL) ALL修改为user1 ALL=(ALL) /usr/sbin/useradd, /usr/bin/passwd, !/usr/bin/passwd “”, !/usr/bin/passwd root。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;命令选项与参数说明：&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;/usr/bin/useradd：允许 user1 用户执行 useradd USER 命令创建普通用户。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;/usr/bin/passwd：允许 user1 用户执行 passwd USER 命令修改用户密码。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;!/usr/bin/passwd root：禁止 user1 用户执行 passwd root 命令修改 root 用户密码。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;!/usr/bin/passwd “”：禁止 user1 用户执行 passwd 命令修改 root 用户密码，因为 passwd 命令后边为空则默认为 root 用户。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;a class=&quot;j-wpcom-lightbox&quot; href=&quot;https://www.zun.com/zx/wp-content/uploads/2025/07/8b17ebb0381418518c3dd21b550fd9f3.jpeg&quot; data-fancybox=&quot;images&quot; data-group=&quot;0&quot; data-id=&quot;6&quot; data-index=&quot;6&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;/a&gt;&lt;a class=&quot;syl-page-img j-lazy&quot; href=&quot;https://www.zun.com/zx/wp-content/uploads/2025/07/8b17ebb0381418518c3dd21b550fd9f3.jpeg&quot; alt=&quot;linux执行命令权限不够怎么办？如何获取权限？&quot; data-original=&quot;https://www.zun.com/zx/wp-content/uploads/2025/07/8b17ebb0381418518c3dd21b550fd9f3.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030508178077270833756.jpeg&quot;&gt;&lt;/a&gt;&amp;nbsp;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（4）测试创建普通用户和设置用户密码效果&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21910&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 950px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21910&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/79b6df24c193cb8-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030509178077270975738.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（5）测试修改root用户密码和修改当前用户密码效果&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21911&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 895px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21911&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/e866687c9c408f5-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030509178077270990367.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;3.1.3 用户登录安全设置&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（1）禁止 root 远程登录：打开/etc/ssh/sshd_config文件，找到PermitRootLogin项，将其值设置为no，完成后重启ssh服务生效配置，减少因root账户被入侵导致系统完全失控的风险。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;a class=&quot;j-wpcom-lightbox&quot; href=&quot;https://www.zun.com/zx/wp-content/uploads/2025/07/75b551b831e79990fede83840a28455a.jpeg&quot; data-fancybox=&quot;images&quot; data-group=&quot;0&quot; data-id=&quot;9&quot; data-index=&quot;9&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;/a&gt;&lt;a class=&quot;syl-page-img j-lazy&quot; href=&quot;https://www.zun.com/zx/wp-content/uploads/2025/07/75b551b831e79990fede83840a28455a.jpeg&quot; alt=&quot;linux执行命令权限不够怎么办？如何获取权限？&quot; data-original=&quot;https://www.zun.com/zx/wp-content/uploads/2025/07/75b551b831e79990fede83840a28455a.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030510178077271087552.jpeg&quot;&gt;&lt;/a&gt;&amp;nbsp;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;在宿主机上打开命令提示符窗口，使用root用户远程链接测试是否能登录。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21912&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 1165px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21912&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/0d0046ff8b1c79f-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030510178077271015358.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（2）设置用户登录超时时间：编辑/etc/profile文件，添加TMOUT=180，表示用户在 3 分钟（180 秒）无操作后自动注销登录。这可避免因用户离开但会话仍保持活跃而带来的安全隐患。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21913&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 887px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21913&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/50c9d5aa5d69bcb-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030510178077271028246.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;background-color: #FFFFFF; text-align: justify;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p class=&quot;pgc-img-caption&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;（3）为用户添加附加组：运行usermod -a -G wheel newuser，将newuser添加到wheel组，wheel组通常具有较高权限，添加到该组可根据需要赋予用户更多管理权限，与在/etc/sudoers文件，添加nuser1 ALL=(ALL) ALL配置类似，可选择使用其中一种方法即可。&lt;/p&gt;&lt;div class=&quot;pgc-img&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div id=&quot;attachment_21914&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; width: 830px;&quot;&gt;&lt;span style=&quot;background-image: initial; background-position: 0px 0px; background-size: initial; background-repeat: initial; background-attachment: initial; background-origin: initial; background-clip: initial; border-style: initial; border-color: initial; border-image: initial; height: auto;&quot;&gt;&lt;a class=&quot;size-full wp-image-21914&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/cb82c84f21e89f0-2.jpeg&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030511178077271195086.jpeg&quot;&gt;&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</description><pubDate>Sun, 07 Jun 2026 03:04:03 +0800</pubDate></item><item><title>Debian 双栈网络时开启 IPv4 优先</title><link>https://zdw.vip/?id=38</link><description>&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;双协议栈技术就是指在一台设备上同时启用 IPv4 协议栈和 IPv6 协议栈，这样就可以同时使用 IPv4 和 IPv6 的网络。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;现代操作系统和浏览器通常会优先使用 IPv6，只有当 IPv6 无法访问时，才会回退到 IPv4。但在某些特定的应用或场景中，我们可能更希望系统优先使用 IPv4，这时就需要通过配置文件进行调整。&lt;/p&gt;&lt;h2 id=&quot;xiu-gai-etc-gai-conf&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;修改 /etc/gai.conf&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;在 Debian 等 Linux 系统下，有一个&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;/etc/gai.conf&lt;/code&gt;&amp;nbsp;文件，用于系统的&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;getaddrinfo&lt;/code&gt;&amp;nbsp;调用，默认情况下，它会使用 IPv6 优先，如果您安装了&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;curl&lt;/code&gt;&amp;nbsp;并且本地支持 IPv6，那么可以使用&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;curl ip.sb&lt;/code&gt;&amp;nbsp;测试：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;root@debian&amp;nbsp;~&amp;nbsp;#&amp;nbsp;curl&amp;nbsp;ip.sb2001:db8::2&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;结果与&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;curl ip.sb -6&lt;/code&gt;&amp;nbsp;等效。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;从 Debian 13 开始，curl (8.14.1) 默认强制使用 IPv6。因此，如果希望测试本地出口公网 IP，可以改用&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;wget&lt;/code&gt;：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;root@debian&amp;nbsp;~&amp;nbsp;#&amp;nbsp;wget&amp;nbsp;-qO-&amp;nbsp;http://ip.sb2001:db8::2&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;效果等同于&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;wget -qO- http://ip.sb -6&lt;/code&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;如果你不想使用 IPv6 优先，可以在这个文件中找到：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;#precedence&amp;nbsp;::ffff:0:0/96&amp;nbsp;&amp;nbsp;100&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;取消注释，修改为：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;precedence&amp;nbsp;::ffff:0:0/96&amp;nbsp;&amp;nbsp;100&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;一行命令修改：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;sed&amp;nbsp;-i&amp;nbsp;&amp;#39;s/#precedence&amp;nbsp;::ffff:0:0\/96&amp;nbsp;&amp;nbsp;100/precedence&amp;nbsp;::ffff:0:0\/96&amp;nbsp;&amp;nbsp;100/&amp;#39;&amp;nbsp;/etc/gai.conf&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;此时再次执行&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;curl ip.sb&lt;/code&gt;&amp;nbsp;测试：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;root@debian&amp;nbsp;~&amp;nbsp;#&amp;nbsp;curl&amp;nbsp;ip.sb192.0.2.2&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;效果等同于&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;curl ip.sb -4&lt;/code&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;从 Debian 13 开始的 curl (8.14.1) 会强制 IPv6 优先，所以我们可以使用&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;wget&lt;/code&gt;&amp;nbsp;命令：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;root@debian&amp;nbsp;~&amp;nbsp;#&amp;nbsp;wget&amp;nbsp;-qO-&amp;nbsp;http://ip.sb192.0.2.2&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;效果等同于&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;wget -qO- http://ip.sb -4&lt;/code&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;某些情况下，你可能又需要强制启用 IPv6 优先（是的，有些系统和用户的需求确实有点奇怪😅），因为目前 IANA 分配的公网 IPv6 还未进行到&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;3000:0000::/4&lt;/code&gt;，所以我们只要把这段之前的 IPv6 加到优先级列表即可，加入这两行&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;label&lt;/code&gt;&amp;nbsp;的优先级：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;label&amp;nbsp;2002::/16&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1
label&amp;nbsp;2001:0::/32&amp;nbsp;&amp;nbsp;&amp;nbsp;1&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;h2 id=&quot;jin-yong-ipv6&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;禁用 IPv6&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;有一些极端情况下，我们可能需要禁止系统的 IPv6 功能，这时候就需要添加或修改&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;/etc/sysctl.d/local.conf&lt;/code&gt;&amp;nbsp;文件，首先找到你的网卡名称，这里以&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;eth0&lt;/code&gt;&amp;nbsp;为例，然后加入如下内容：&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;net.ipv6.conf.all.autoconf&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.default.autoconf&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.all.accept_ra&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.default.accept_ra&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.all.disable_ipv6&amp;nbsp;=&amp;nbsp;1net.ipv6.conf.default.disable_ipv6&amp;nbsp;=&amp;nbsp;1net.ipv6.conf.lo.disable_ipv6&amp;nbsp;=&amp;nbsp;1net.ipv6.conf.eth0.disable_ipv6&amp;nbsp;=&amp;nbsp;1&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;若需对其他网卡禁用 IPv6，只需将&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;eth0&lt;/code&gt;&amp;nbsp;替换为对应网卡名称即可。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;一句话命令&lt;/p&gt;&lt;div class=&quot;relative group cs-animate-2&quot; style=&quot;box-sizing: border-box; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative;&quot;&gt;&lt;pre class=&quot;border-[#33393f] border-[1px] relative transition language-bash prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; transition: all 0.3s ease 0s; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;cat&amp;nbsp;&amp;gt;&amp;gt;&amp;nbsp;/etc/sysctl.d/local.conf&amp;nbsp;&amp;lt;&amp;lt;&amp;nbsp;EOF
net.ipv6.conf.all.autoconf&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.default.autoconf&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.all.accept_ra&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.default.accept_ra&amp;nbsp;=&amp;nbsp;0net.ipv6.conf.all.disable_ipv6&amp;nbsp;=&amp;nbsp;1net.ipv6.conf.default.disable_ipv6&amp;nbsp;=&amp;nbsp;1net.ipv6.conf.lo.disable_ipv6&amp;nbsp;=&amp;nbsp;1net.ipv6.conf.eth0.disable_ipv6&amp;nbsp;=&amp;nbsp;1EOF&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Bash&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word;&quot;&gt;&lt;button class=&quot;opacity-0 absolute right-2 top-2 cursor-pointer z-10 bg-[#36415391] hover:bg-[#364153] rounded-[6px] outline-0 text-[#c9d1d9] px-2 py-1 transition-all duration-200&quot; style=&quot;margin: 0px; font: inherit; overflow: visible; appearance: button; cursor: pointer;&quot;&gt;&lt;/button&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;注意：&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;cat&lt;/code&gt;&amp;nbsp;命令中的&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;&amp;gt;&amp;gt;&lt;/code&gt;&amp;nbsp;表示追加内容；若使用&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;&amp;gt;&lt;/code&gt;，则会覆盖原有内容。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;然后执行&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;sysctl --system&lt;/code&gt;&amp;nbsp;重新加载配置文件。此时查看&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;ip a&lt;/code&gt;，即可发现 IPv6 已被禁用。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;下图为修改前后的对比示例：&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;使用前，我们可以看到无论是本地还是公网网卡都有&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;inet6&lt;/code&gt;，即都有 IPv6 地址：&lt;/p&gt;&lt;div id=&quot;attachment_22021&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 584px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22021&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/8fd3b33b30b014b.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030312178077259263078.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22021&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;自动草稿&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;使用后，无论本地还是公网网卡均无 IPv6 地址：&lt;/p&gt;&lt;div id=&quot;attachment_22022&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 590px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22022&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/7599f7c6c259070.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030312178077259255352.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22022&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;自动草稿&lt;/p&gt;&lt;/div&gt;&lt;h2 id=&quot;qi-ta-xi-tong-he-ruan-jian&quot; style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;其他系统和软件&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;Windows 系统可参考这篇回答&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;Firefox 下打开&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;about:config&lt;/code&gt;&amp;nbsp;然后把&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;network.dns.disableIPv6&lt;/code&gt;&amp;nbsp;改成&amp;nbsp;&lt;code style=&quot;box-sizing: border-box; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: 13.5px; padding: 2px 4px; color: rgb(199, 37, 78); background-color: rgb(249, 242, 244); border-radius: 4px;&quot;&gt;true&lt;/code&gt;&amp;nbsp;即可禁止 Firefox 请求 IPv6&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:02:53 +0800</pubDate></item><item><title>Ubuntu 24.04.2 LTS 以桌面应用为主的Linux发行版操作系统 中文名【乌班图】免费开源</title><link>https://zdw.vip/?id=37</link><description>&lt;p class=&quot;u-no-padding--top&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;为全球数百万台PC和笔记本电脑提供支持的开源桌面操作系统&lt;/p&gt;&lt;p class=&quot;u-no-padding--top&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;桌面PC和笔记本精心打造的Ubuntu长期支持(&lt;abbr title=&quot;Long-term support&quot; style=&quot;box-sizing: border-box; border-bottom: 1px dotted rgb(119, 119, 119); cursor: help;&quot;&gt;LTS&lt;/abbr&gt;)版本。LTS意为“长期支持”，一般为5年。LTS版本将提供免费安全和维护更新至 2029年4月。&lt;/p&gt;&lt;p class=&quot;u-no-padding--top&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;推荐的系统配置要求：&lt;/p&gt;&lt;ul class=&quot;p-list is-split list-paddingleft-2&quot; style=&quot;box-sizing: border-box; margin-bottom: 18px; margin-left: 30px; padding: 0px; list-style-position: initial; list-style-image: initial; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;li&gt;&lt;p&gt;双核2 GHz处理器或更高&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;4 GB系统内存&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;25 GB磁盘存储空间&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;可访问的互联网&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;光驱或USB安装介质&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;a class=&quot;alignnone size-full wp-image-22329&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/11/c4ca4238a0b9238-7.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px; outline: 0px; margin: 0px auto;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030224178077254483784.png&quot;&gt;&lt;/a&gt;&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 03:01:24 +0800</pubDate></item><item><title>Linux下使用tcpdump监听DNS查询</title><link>https://zdw.vip/?id=36</link><description>&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;准备在新服务器上部署一些镜像，便于提供workspace。这就难免要使用到docker pull来拉取镜像。&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;结果问题来了，需要用到的这个镜像不知道什么原因，各大镜像站中均无数据&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;起初不断配置registry mirrors来加速，但是始终没有效果&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;总是出现如下故障&lt;/p&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;pre class=&quot;language-shell-session prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;read&amp;nbsp;tcp&amp;nbsp;172.16.11.202:42874-＞104.18.125.25:443:&amp;nbsp;read:&amp;nbsp;connection&amp;nbsp;reset&amp;nbsp;by&amp;nbsp;peer&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Shell session&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;h2 style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;解决过程&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;简单查询，发现104.18.125.25是Cloudflare的节点ip，于是想到能否查询一下docker的子域名，看看有没有指向cf的，如果有，直接hosts替换一下说不定就好了&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;结果通过itdog查询，发现docker.io所有子域名都没有指向Cloudflare服务的&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;这就奇了怪了&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;尝试先拉取一个镜像，另外一个shellsession使用ss查询一下连接是否来自dockerd进程&lt;/p&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;pre class=&quot;language-shell-session prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;ss&amp;nbsp;-tnp&amp;nbsp;state&amp;nbsp;connected&amp;nbsp;|&amp;nbsp;grep&amp;nbsp;docker&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Shell session&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22377&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 793px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22377&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/cd2932ee10c0a30-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030013178077241322207.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22377&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux下使用tcpdump监听DNS查询&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;看起来是的没错了，那我要怎么寻找这个被解析的未知域名呢&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;用tcpdump监听&lt;/p&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;pre class=&quot;language-shell-session prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;&amp;nbsp;tcpdump&amp;nbsp;-i&amp;nbsp;ens17&amp;nbsp;-nt&amp;nbsp;-s&amp;nbsp;500&amp;nbsp;port&amp;nbsp;domain&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Shell session&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;ens17是网卡接口名称&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;port domain用来过滤数据包，表示只抓取使用domain（域名）服务的数据包，即DNS查询和应答报文。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;那么，新开一个终端，尝试请求，并且开始监听&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22378&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 635px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22378&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/6454112953144b0-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030013178077241376389.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22378&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux下使用tcpdump监听DNS查询&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;抓取到了&lt;br style=&quot;box-sizing: border-box;&quot;/&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22379&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 1290px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22379&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/3207c8048e48c33-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030014178077241450428.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22379&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux下使用tcpdump监听DNS查询&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;可以看到，docker在尝试请求mirrors gs9tpsud.mirror.aliyuncs.com，拉取失败了，然后开始进行auth请求，向官方库production.cloudflare.docker.com获取数据&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22380&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 1290px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22380&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/5944f4b9b2b4a04-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607030015178077241578968.png&quot;&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22380&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux下使用tcpdump监听DNS查询&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;两个数据包都是IP数据报，第一个数据报表示10.0.17.2（本地）向223.5.5.5（DNS服务器）查询production.cloudflare.docker.com的IP地址，53是DNS服务的端口号，“+”表示启用递归查询标志，“A?”表示使用A类型的查询方式，61是该报文的长度（字节）。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;第二个数据报表示223.5.5.5向10.0.17.2发送DNS应答报文，2/0/0表示该报文中包含2个应答资源记录，0个授权资源记录和0个额外信息记录，A表示紧随其后的记录是IP地址。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;同理，后面还有AAAA请求数据报&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;到此，查询到了未知的域名，进行hosts临时转发后，成功拉取镜像&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 02:59:53 +0800</pubDate></item><item><title>Linux终端的使用</title><link>https://zdw.vip/?id=35</link><description>&lt;h2 style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;一、终端的作用&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;要了解终端，就要了解一下计算机方面的历史，早期的计算机都属于大中型计算机，是个庞然大物，占用很大的空间，属于公用产品。不像现在的电脑，可以人手一部，直接操作。那如何对这些计算机进行控制与操作呢。那就搞个终端设备来操作。因此一台计算机上有很多种不同的终端设备也和正常。也就是说终端就是为主机提供了人机接口，每个人都通过终端使用主机的资源。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;终端有字符终端和图形终端两种模式。在linux的图形环境下，我们可以通过鼠标点击来完成所有的管理任务，这是图形界面终端，另外一种就是文本界面的终端，在这个界面的终端下我们可以使用linux命令来控制系统完成响应的工作，而这个文本终端也是服务器常用的模式。&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;用一句话来说终端就是存在于用户和计算机之间沟通的桥梁，通过终端，用户可以控制计算机完成响应的工作，也可以获得到计算机的反馈&lt;/p&gt;&lt;h2 style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;二、打开终端的几种方法&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;第一种，我们登录系统之后就已经打开了图形终端，在图形终端中也给我们提供了一个可以用linux命令控制系统的工具，我们点击屏幕左上角的“活动”就可以找到这个它&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22387&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 810px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22387&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/1f13c273661cf33-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607025825178077230575217.png&quot;/&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22387&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux终端的使用&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;打开之后我们会看到linux的命令行，在这里面我们可以输入linux命令来进行操作&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22388&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 810px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22388&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/cc8595c533f5691-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607025825178077230567643.png&quot;/&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22388&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux终端的使用&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;第二种 打开文本终端，这个需要键盘上的组合键[Ctrl] + [Alt] + [F1] - [F6] ，其中F1和F2是两个可供登录的图形终端，F3-F6为文本终端，现在我们使用[Ctrl] + [Alt] + [F3]打开文本终端，然后使用root用户登录&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22389&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 810px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22389&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/7fc91c7cc4ae684-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607025826178077230684702.png&quot;/&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22389&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux终端的使用&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;这就是在linux中终端的打开方式，那我们接下来看一下有哪些快捷键&lt;/p&gt;&lt;h2 style=&quot;box-sizing: border-box; font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; line-height: 1.1; color: rgb(51, 51, 51); margin: 18px 0px; font-size: 18px; padding: 10px 0px; border-bottom: 1px solid var(--theme-border-color); text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;三、常用快捷键&lt;/h2&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;1、图形界面下通过点击屏幕右上角的“活动”按钮打开的终端&lt;/p&gt;&lt;div class=&quot;code-toolbar&quot; style=&quot;box-sizing: border-box; position: relative; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;pre class=&quot;language-cli prettyprint&quot; tabindex=&quot;0&quot; style=&quot;box-sizing: border-box; overflow: auto; font-variant-numeric: normal; font-variant-east-asian: normal; font-variant-alternates: normal; font-kerning: auto; font-optical-sizing: auto; font-feature-settings: normal; font-variation-settings: normal; font-stretch: normal; font-size: 1em; line-height: 1.5; font-family: Consolas, Monaco, &amp;quot;Andale Mono&amp;quot;, &amp;quot;Ubuntu Mono&amp;quot;, monospace; padding: 1em; color: rgb(248, 248, 242); word-break: normal; overflow-wrap: normal; background-color: rgb(39, 40, 34); border: none; border-radius: 0.3em; text-shadow: rgba(0, 0, 0, 0.3) 0px 1px; text-align: left; word-spacing: normal; tab-size: 4; hyphens: none;&quot;&gt;[Shift]+[Ctrl]+t&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以标签的形式打开一个新的终端[Shift]+[Ctrl]+n&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以窗口的形式打开一个新的终端[Shift]+[Ctrl]+w&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;关闭标签页[Shift]+[Ctrl]+q&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;关闭窗口&lt;/pre&gt;&lt;div class=&quot;toolbar&quot; style=&quot;box-sizing: border-box; position: absolute; z-index: 10; top: 0.3em; right: 0.2em; transition: opacity 0.3s ease-in-out 0s; opacity: 0;&quot;&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;span style=&quot;box-sizing: border-box; color: #BBBBBB; font-size: 0.8em; padding: 0px 0.5em; background: rgba(224, 224, 224, 0.2); box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;Cli&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;toolbar-item&quot; style=&quot;box-sizing: border-box; display: inline-block;&quot;&gt;&lt;button class=&quot;copy-to-clipboard-button&quot; type=&quot;button&quot; data-copy-state=&quot;copy&quot; style=&quot;margin: 0px; font-style: inherit; font-variant: inherit; font-weight: inherit; font-stretch: inherit; font-size: 0.8em; font-family: inherit; font-optical-sizing: inherit; font-kerning: inherit; font-feature-settings: inherit; font-variation-settings: inherit; color: rgb(187, 187, 187); overflow: visible; appearance: button; cursor: pointer; background: rgba(224, 224, 224, 0.2); border-width: 0px; border-style: initial; border-color: initial; padding: 0px 0.5em; user-select: none; box-shadow: rgba(0, 0, 0, 0.2) 0px 2px 0px 0px; border-radius: 0.5em;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;复制&lt;/span&gt;&lt;/button&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;如果你想知道额外的快捷键，点击终端上方的文字按钮，会有对应快捷键的提示&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;span data-fancybox=&quot;Joe&quot; style=&quot;box-sizing: border-box;&quot;&gt;&lt;/span&gt;&lt;/p&gt;&lt;div id=&quot;attachment_22390&quot; class=&quot;wp-caption aligncenter&quot; style=&quot;box-sizing: border-box; margin: 0px auto 18px; text-align: center; background-color: rgb(246, 246, 246); padding: 10px 10px 1px; max-width: 100%; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-wrap: wrap; width: 810px;&quot;&gt;&lt;a class=&quot;size-full wp-image-22390&quot; href=&quot;https://www.llin.cn/wp-content/uploads/2025/12/a17a164376f8aaa-1.png&quot; data-fancybox=&quot;images&quot; style=&quot;box-sizing: border-box; background: 0px 0px;&quot;&gt;&lt;img src=&quot;https://zdw.vip/zb_users/upload/2026/06/20260607025826178077230659815.png&quot;/&gt;&lt;/a&gt;&lt;p id=&quot;caption-attachment-22390&quot; class=&quot;wp-caption-text&quot; style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 10px; overflow-wrap: break-word;&quot;&gt;Linux终端的使用&lt;/p&gt;&lt;/div&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;&lt;br/&gt;&lt;/p&gt;&lt;p style=&quot;box-sizing: border-box; margin-top: 0px; margin-bottom: 18px; overflow-wrap: break-word; color: rgb(51, 51, 51); font-family: &amp;quot;Microsoft Yahei&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 15px; text-align: justify; text-wrap: wrap; background-color: rgb(255, 255, 255);&quot;&gt;2、通用快捷键&lt;/p&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;&lt;p&gt;Ctrl+r:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 实现快速检索使用过的历史命令.&lt;/p&gt;&lt;p&gt;Ctrl+a:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 光标回到命令行首。&amp;nbsp;&lt;/p&gt;&lt;p&gt;Ctrl+e:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 光标回到命令行尾。&amp;nbsp;&lt;/p&gt;&lt;p&gt;ctrl+w:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 移除光标前的一个单词&lt;/p&gt;&lt;p&gt;Ctrl+k:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 删除光标处到行尾的字符。&lt;/p&gt;&lt;p&gt;Ctrl+u:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 删除整个命令行文本字符。&lt;/p&gt;&lt;p&gt;Ctrl+y:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 粘贴Ctrl+u，Ctrl+k，Ctrl+w删除的文本。&lt;/p&gt;&lt;p&gt;Ctrl+d:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 删除提示符所在出的一个字符，在空命令行的情况下可以退出终端。&lt;/p&gt;&lt;p&gt;esc+. :&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 上一个命令的后面的参数&lt;/p&gt;&lt;p&gt;Ctrl+b:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 光标向行首移动一个字符。&lt;/p&gt;&lt;p&gt;Ctrl+f:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 光标向行尾移动一个字符。&lt;/p&gt;&lt;p&gt;Ctrl+h:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 向行首删除一个字符。&lt;/p&gt;&lt;p&gt;Ctrl+i:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 相当于Tab键。&lt;/p&gt;&lt;p&gt;Ctrl+L:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 清屏&lt;/p&gt;&lt;p&gt;Ctrl+s:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 使终端发呆，静止，可以使快速输出的终端屏幕停下来。&lt;/p&gt;&lt;p&gt;Ctrl+q:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 退出Ctrl+s引起的发呆。&lt;/p&gt;&lt;p&gt;Ctrl+z:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 使正在运行在终端的任务，运行于后台。 （可用fg恢复）&lt;/p&gt;&lt;p&gt;Ctrl+c:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 中断终端中正在执行的任务。&lt;/p&gt;&lt;p&gt;Tab键:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 命令、文件名等自动补全功能。&lt;/p&gt;</description><pubDate>Sun, 07 Jun 2026 02:58:10 +0800</pubDate></item></channel></rss>