<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Ubuntu &#8211; 元几录</title>
	<atom:link href="https://blog.dpean.com/tag/ubuntu/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.dpean.com</link>
	<description></description>
	<lastBuildDate>Tue, 04 Nov 2025 12:06:00 +0000</lastBuildDate>
	<language>zh-Hans</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.8.3</generator>

<image>
	<url>https://blog.dpean.com/wp-content/uploads/2025/08/cropped-logo-1-150x150.png</url>
	<title>Ubuntu &#8211; 元几录</title>
	<link>https://blog.dpean.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Waydroid全屏显示</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/waydroid%e5%85%a8%e5%b1%8f%e6%98%be%e7%a4%ba/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Tue, 04 Nov 2025 12:05:59 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Waydroid]]></category>
		<guid isPermaLink="false">https://blog.dpean.com/?p=705</guid>

					<description><![CDATA[打开 设置 -> 查看及自定义快捷键 -> 窗口 -> 切换&#8230;]]></description>
										<content:encoded><![CDATA[
<p>打开 <strong>设置 -> 查看及自定义快捷键 -> 窗口 -> 切换全屏模式</strong> ，我这里设置的是<strong> Shift+F11</strong></p>



<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1024" height="539" src="https://blog.dpean.com/wp-content/uploads/2025/11/微信图片_2025-11-04_200250_178-1024x539.png" alt="" class="wp-image-708" srcset="https://blog.dpean.com/wp-content/uploads/2025/11/微信图片_2025-11-04_200250_178-1024x539.png 1024w, https://blog.dpean.com/wp-content/uploads/2025/11/微信图片_2025-11-04_200250_178-300x158.png 300w, https://blog.dpean.com/wp-content/uploads/2025/11/微信图片_2025-11-04_200250_178-768x405.png 768w, https://blog.dpean.com/wp-content/uploads/2025/11/微信图片_2025-11-04_200250_178.png 1530w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<h4 class="wp-block-heading">参考资料</h4>



<ol class="wp-block-list">
<li><a href="https://github.com/waydroid/waydroid/issues/1558#issuecomment-2349721653" target="_blank" rel="noreferrer noopener nofollow">force a specific app to launch in full screen/without top bar #1558 &#8211; github</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu安装：无法将grub安装到/dev/sda</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu%e5%ae%89%e8%a3%85bug%ef%bc%9a%e6%97%a0%e6%b3%95%e5%b0%86grub%e5%ae%89%e8%a3%85%e5%88%b0-dev-sda/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Mon, 03 Nov 2025 10:03:13 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[装机]]></category>
		<guid isPermaLink="false">https://blog.dpean.com/?p=673</guid>

					<description><![CDATA[问题描述：Ubuntu-24.04.3LTS使用UEFI安装&#8230;]]></description>
										<content:encoded><![CDATA[
<p><strong>问题描述：Ubuntu-24.04.3LTS</strong>使用<strong>UEFI</strong>安装时，会出现 <strong>无法将grub安装到/dev/sda</strong> Bug</p>



<p><strong>解决方案：</strong>我这里使用<strong>非UEFI</strong>装机就可以了（虽然很慢）</p>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="683" src="https://blog.dpean.com/wp-content/uploads/2025/11/IMG_8416-e1762164049464-1024x683.jpg" alt="" class="wp-image-674" srcset="https://blog.dpean.com/wp-content/uploads/2025/11/IMG_8416-e1762164049464-1024x683.jpg 1024w, https://blog.dpean.com/wp-content/uploads/2025/11/IMG_8416-e1762164049464-300x200.jpg 300w, https://blog.dpean.com/wp-content/uploads/2025/11/IMG_8416-e1762164049464-768x512.jpg 768w, https://blog.dpean.com/wp-content/uploads/2025/11/IMG_8416-e1762164049464.jpg 1440w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<h4 class="wp-block-heading">参考资料</h4>



<ol class="wp-block-list">
<li><a href="https://blog.csdn.net/weixin_52840162/article/details/136744217" target="_blank" rel="noreferrer noopener">ubuntu22.04安装单系统出错“无法将GURB安装到/dev/sda”的详细解决方案</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu设置定时任务</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu%e8%ae%be%e7%bd%ae%e5%ae%9a%e6%97%b6%e4%bb%bb%e5%8a%a1/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Mon, 08 Sep 2025 07:41:50 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://blog.dpean.com/?p=443</guid>

					<description><![CDATA[使用cron配置 例：飞牛配置每天03:02重启 在配置文件&#8230;]]></description>
										<content:encoded><![CDATA[
<p><strong>使用cron配置</strong></p>



<p>例：飞牛配置每天03:02重启</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>su #root登录
vi /etc/crontab</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">su</span><span style="color: #F6F6F4"> </span><span style="color: #7B7F8B">#root登录</span></span>
<span class="line"><span style="color: #62E884">vi</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/crontab</span></span></code></pre></div>



<p>在配置文件的最后一行添加：<em>2 3 * * * root reboot</em>，如下方代码所示</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly># /etc/crontab: system-wide crontab
# Unlike any other crontab you don't have to run the `crontab'
# command to install the new version when you edit this file
# and files in /etc/cron.d. These files also have username fields,
# that none of the other crontabs do.

SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

# Example of job definition:
# .---------------- minute (0 - 59)
# |  .------------- hour (0 - 23)
# |  |  .---------- day of month (1 - 31)
# |  |  |  .------- month (1 - 12) OR jan,feb,mar,apr ...
# |  |  |  |  .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat
# |  |  |  |  |
# *  *  *  *  * user-name command to be executed
17 *	* * *	root	cd / &amp;&amp; run-parts --report /etc/cron.hourly
25 6	* * *	root	test -x /usr/sbin/anacron || { cd / &amp;&amp; run-parts --report /etc/cron.daily; }
47 6	* * 7	root	test -x /usr/sbin/anacron || { cd / &amp;&amp; run-parts --report /etc/cron.weekly; }
52 6	1 * *	root	test -x /usr/sbin/anacron || { cd / &amp;&amp; run-parts --report /etc/cron.monthly; }
#
2 3	* * *	root	reboot #添加此行，上方"Example of job definition"有其对应的含义</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #7B7F8B"># /etc/crontab: system-wide crontab</span></span>
<span class="line"><span style="color: #7B7F8B"># Unlike any other crontab you don&#39;t have to run the `crontab&#39;</span></span>
<span class="line"><span style="color: #7B7F8B"># command to install the new version when you edit this file</span></span>
<span class="line"><span style="color: #7B7F8B"># and files in /etc/cron.d. These files also have username fields,</span></span>
<span class="line"><span style="color: #7B7F8B"># that none of the other crontabs do.</span></span>
<span class="line"></span>
<span class="line"><span style="color: #BF9EEE">SHELL</span><span style="color: #F286C4">=</span><span style="color: #E7EE98">/bin/sh</span></span>
<span class="line"><span style="color: #BF9EEE">PATH</span><span style="color: #F286C4">=</span><span style="color: #E7EE98">/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin</span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B"># Example of job definition:</span></span>
<span class="line"><span style="color: #7B7F8B"># .---------------- minute (0 - 59)</span></span>
<span class="line"><span style="color: #7B7F8B"># |  .------------- hour (0 - 23)</span></span>
<span class="line"><span style="color: #7B7F8B"># |  |  .---------- day of month (1 - 31)</span></span>
<span class="line"><span style="color: #7B7F8B"># |  |  |  .------- month (1 - 12) OR jan,feb,mar,apr ...</span></span>
<span class="line"><span style="color: #7B7F8B"># |  |  |  |  .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat</span></span>
<span class="line"><span style="color: #7B7F8B"># |  |  |  |  |</span></span>
<span class="line"><span style="color: #7B7F8B"># *  *  *  *  * user-name command to be executed</span></span>
<span class="line"><span style="color: #62E884">17</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4">	</span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">root</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">cd</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/</span><span style="color: #F6F6F4"> &amp;&amp; </span><span style="color: #62E884">run-parts</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">--report</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/cron.hourly</span></span>
<span class="line"><span style="color: #62E884">25</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">6</span><span style="color: #F6F6F4">	</span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">root</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">test</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-x</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/usr/sbin/anacron</span><span style="color: #F6F6F4"> </span><span style="color: #F286C4">||</span><span style="color: #F6F6F4"> { </span><span style="color: #97E1F1">cd</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/</span><span style="color: #F6F6F4"> &amp;&amp; </span><span style="color: #62E884">run-parts</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">--report</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/cron.daily</span><span style="color: #F6F6F4">; }</span></span>
<span class="line"><span style="color: #62E884">47</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">6</span><span style="color: #F6F6F4">	</span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">7</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">root</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">test</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-x</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/usr/sbin/anacron</span><span style="color: #F6F6F4"> </span><span style="color: #F286C4">||</span><span style="color: #F6F6F4"> { </span><span style="color: #97E1F1">cd</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/</span><span style="color: #F6F6F4"> &amp;&amp; </span><span style="color: #62E884">run-parts</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">--report</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/cron.weekly</span><span style="color: #F6F6F4">; }</span></span>
<span class="line"><span style="color: #62E884">52</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">6</span><span style="color: #F6F6F4">	</span><span style="color: #BF9EEE">1</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">root</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">test</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-x</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/usr/sbin/anacron</span><span style="color: #F6F6F4"> </span><span style="color: #F286C4">||</span><span style="color: #F6F6F4"> { </span><span style="color: #97E1F1">cd</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/</span><span style="color: #F6F6F4"> &amp;&amp; </span><span style="color: #62E884">run-parts</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">--report</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/cron.monthly</span><span style="color: #F6F6F4">; }</span></span>
<span class="line"><span style="color: #7B7F8B">#</span></span>
<span class="line"><span style="color: #62E884">2</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">3</span><span style="color: #F6F6F4">	</span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE; font-style: italic">*</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">root</span><span style="color: #F6F6F4">	</span><span style="color: #E7EE98">reboot</span><span style="color: #F6F6F4"> </span><span style="color: #7B7F8B">#添加此行，上方&quot;Example of job definition&quot;有其对应的含义</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>systemctl restart cron
systemctl status cron</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">systemctl</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">restart</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">cron</span></span>
<span class="line"><span style="color: #62E884">systemctl</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">status</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">cron</span></span></code></pre></div>



<p><strong>/etc中每个cron文件夹代表含义</strong></p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>/etc/cron.d/ #存放系统级别额外crontab配置
/etc/cron.hourly/
/etc/cron.daily/
/etc/cron.weekly/
/etc/cron.monthly/ #cron会分别每小时、每天、每周、每月自动运行这些目录中的脚本 /etc/crontab中有记录</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">/etc/cron.d/</span><span style="color: #F6F6F4"> </span><span style="color: #7B7F8B">#存放系统级别额外crontab配置</span></span>
<span class="line"><span style="color: #62E884">/etc/cron.hourly/</span></span>
<span class="line"><span style="color: #62E884">/etc/cron.daily/</span></span>
<span class="line"><span style="color: #62E884">/etc/cron.weekly/</span></span>
<span class="line"><span style="color: #62E884">/etc/cron.monthly/</span><span style="color: #F6F6F4"> </span><span style="color: #7B7F8B">#cron会分别每小时、每天、每周、每月自动运行这些目录中的脚本 /etc/crontab中有记录</span></span></code></pre></div>



<p><strong>参考资料</strong></p>



<ol class="wp-block-list">
<li><a href="https://www.cnblogs.com/lonmyblog/p/8006789.html" target="_blank" rel="noreferrer noopener">ubuntu 使用cron设置定时启动任务</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu22.04 设置静态IP</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu22-04-%e8%ae%be%e7%bd%ae%e9%9d%99%e6%80%81ip/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Fri, 11 Apr 2025 00:45:40 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://dpean.com/?p=250</guid>

					<description><![CDATA[安装net-tools、openvswitch-switch&#8230;]]></description>
										<content:encoded><![CDATA[
<p>安装net-tools、openvswitch-switch</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>su
apt install net-tools
apt install openvswitch-switch</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">su</span></span>
<span class="line"><span style="color: #62E884">apt</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">install</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">net-tools</span></span>
<span class="line"><span style="color: #62E884">apt</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">install</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">openvswitch-switch</span></span></code></pre></div>



<p>查看网卡名</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>ifconfig
#enp3s0: flags=4163&lt;UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
#        inet 192.168.50.3  netmask 255.255.255.0  broadcast 192.168.50.255
#        inet6 fe80::2e0:b4ff:fe1c:704b  prefixlen 64  scopeid 0x20&lt;link>
#        inet6 fdc2:8c5e:7c48:5348:2e0:b4ff:fe1c:704b  prefixlen 64  scopeid 0x0&lt;global>
#        ether 00:e0:b4:1c:70:4b  txqueuelen 1000  (Ethernet)
#        RX packets 26226  bytes 34068377 (34.0 MB)
#        RX errors 0  dropped 1196  overruns 0  frame 0
#        TX packets 2935  bytes 362905 (362.9 KB)
#        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
#        device memory 0xd0600000-d061ffff  

#lo: flags=73&lt;UP,LOOPBACK,RUNNING>  mtu 65536
#        inet 127.0.0.1  netmask 255.0.0.0
#        inet6 ::1  prefixlen 128  scopeid 0x10&lt;host>
#        loop  txqueuelen 1000  (Local Loopback)
#        RX packets 146  bytes 13595 (13.5 KB)
#        RX errors 0  dropped 0  overruns 0  frame 0
#        TX packets 146  bytes 13595 (13.5 KB)
#        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">ifconfig</span></span>
<span class="line"><span style="color: #7B7F8B">#enp3s0: flags=4163&lt;UP,BROADCAST,RUNNING,MULTICAST&gt;  mtu 1500</span></span>
<span class="line"><span style="color: #7B7F8B">#        inet 192.168.50.3  netmask 255.255.255.0  broadcast 192.168.50.255</span></span>
<span class="line"><span style="color: #7B7F8B">#        inet6 fe80::2e0:b4ff:fe1c:704b  prefixlen 64  scopeid 0x20&lt;link&gt;</span></span>
<span class="line"><span style="color: #7B7F8B">#        inet6 fdc2:8c5e:7c48:5348:2e0:b4ff:fe1c:704b  prefixlen 64  scopeid 0x0&lt;global&gt;</span></span>
<span class="line"><span style="color: #7B7F8B">#        ether 00:e0:b4:1c:70:4b  txqueuelen 1000  (Ethernet)</span></span>
<span class="line"><span style="color: #7B7F8B">#        RX packets 26226  bytes 34068377 (34.0 MB)</span></span>
<span class="line"><span style="color: #7B7F8B">#        RX errors 0  dropped 1196  overruns 0  frame 0</span></span>
<span class="line"><span style="color: #7B7F8B">#        TX packets 2935  bytes 362905 (362.9 KB)</span></span>
<span class="line"><span style="color: #7B7F8B">#        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0</span></span>
<span class="line"><span style="color: #7B7F8B">#        device memory 0xd0600000-d061ffff  </span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B">#lo: flags=73&lt;UP,LOOPBACK,RUNNING&gt;  mtu 65536</span></span>
<span class="line"><span style="color: #7B7F8B">#        inet 127.0.0.1  netmask 255.0.0.0</span></span>
<span class="line"><span style="color: #7B7F8B">#        inet6 ::1  prefixlen 128  scopeid 0x10&lt;host&gt;</span></span>
<span class="line"><span style="color: #7B7F8B">#        loop  txqueuelen 1000  (Local Loopback)</span></span>
<span class="line"><span style="color: #7B7F8B">#        RX packets 146  bytes 13595 (13.5 KB)</span></span>
<span class="line"><span style="color: #7B7F8B">#        RX errors 0  dropped 0  overruns 0  frame 0</span></span>
<span class="line"><span style="color: #7B7F8B">#        TX packets 146  bytes 13595 (13.5 KB)</span></span>
<span class="line"><span style="color: #7B7F8B">#        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0</span></span></code></pre></div>



<p>配置netplan</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>cd /etc/netplan
cp 50-cloud-init.yaml 50-cloud-init.yaml.bak
#文件名会有不同
vi 50-cloud-init.yaml</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #97E1F1">cd</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/netplan</span></span>
<span class="line"><span style="color: #62E884">cp</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">50</span><span style="color: #E7EE98">-cloud-init.yaml</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">50</span><span style="color: #E7EE98">-cloud-init.yaml.bak</span></span>
<span class="line"><span style="color: #7B7F8B">#文件名会有不同</span></span>
<span class="line"><span style="color: #62E884">vi</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">50</span><span style="color: #E7EE98">-cloud-init.yaml</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">YAML</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>network:
 version: 2
 renderer: networkd
 ethernets:
  enp3s0:
  #网卡名
   addresses:
    - 192.168.50.3/24
    #静态ip
   nameservers:
    addresses: &#91;8.8.8.8,114.114.114.114&#93;
    #dns
   routes:
    - to: default
      via: 192.168.50.1
      #网关</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #97E1F1">network</span><span style="color: #F286C4">:</span></span>
<span class="line"><span style="color: #F6F6F4"> </span><span style="color: #97E1F1">version</span><span style="color: #F286C4">:</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">2</span></span>
<span class="line"><span style="color: #F6F6F4"> </span><span style="color: #97E1F1">renderer</span><span style="color: #F286C4">:</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">networkd</span></span>
<span class="line"><span style="color: #F6F6F4"> </span><span style="color: #97E1F1">ethernets</span><span style="color: #F286C4">:</span></span>
<span class="line"><span style="color: #F6F6F4">  </span><span style="color: #97E1F1">enp3s0</span><span style="color: #F286C4">:</span></span>
<span class="line"><span style="color: #F6F6F4">  </span><span style="color: #7B7F8B">#网卡名</span></span>
<span class="line"><span style="color: #F6F6F4">   </span><span style="color: #97E1F1">addresses</span><span style="color: #F286C4">:</span></span>
<span class="line"><span style="color: #F6F6F4">    </span><span style="color: #F286C4">-</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">192.168.50.3/24</span></span>
<span class="line"><span style="color: #F6F6F4">    </span><span style="color: #7B7F8B">#静态ip</span></span>
<span class="line"><span style="color: #F6F6F4">   </span><span style="color: #97E1F1">nameservers</span><span style="color: #F286C4">:</span></span>
<span class="line"><span style="color: #F6F6F4">    </span><span style="color: #97E1F1">addresses</span><span style="color: #F286C4">:</span><span style="color: #F6F6F4"> &#91;</span><span style="color: #BF9EEE">8.8.8.8</span><span style="color: #F6F6F4">,</span><span style="color: #BF9EEE">114.114.114.114</span><span style="color: #F6F6F4">&#93;</span></span>
<span class="line"><span style="color: #F6F6F4">    </span><span style="color: #7B7F8B">#dns</span></span>
<span class="line"><span style="color: #F6F6F4">   </span><span style="color: #97E1F1">routes</span><span style="color: #F286C4">:</span></span>
<span class="line"><span style="color: #F6F6F4">    </span><span style="color: #F286C4">-</span><span style="color: #F6F6F4"> </span><span style="color: #97E1F1">to</span><span style="color: #F286C4">:</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">default</span></span>
<span class="line"><span style="color: #F6F6F4">      </span><span style="color: #97E1F1">via</span><span style="color: #F286C4">:</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">192.168.50.1</span></span>
<span class="line"><span style="color: #F6F6F4">      </span><span style="color: #7B7F8B">#网关</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>netplan apply</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">netplan</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">apply</span></span></code></pre></div>



<p>禁止Ubuntu默认云覆盖</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>vi /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">vi</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/cloud/cloud.cfg.d/99-disable-network-config.cfg</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">JSON</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>network: {config: disabled} //将此行代码取消注释</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #F6F6F4">network: {</span><span style="color: #EE6666; font-style: italic; text-decoration: underline">config</span><span style="color: #F286C4">:</span><span style="color: #F6F6F4"> </span><span style="color: #EE6666; font-style: italic; text-decoration: underline">disabled</span><span style="color: #F6F6F4">} </span><span style="color: #7B7F8B">//将此行代码取消注释</span></span></code></pre></div>



<p><strong>参考资料</strong></p>



<ol class="wp-block-list">
<li><a href="https://www.51cto.com/article/721393.html">如何在 Ubuntu 服务器 22.04 上设置静态 IP 地址</a></li>



<li><a href="https://blog.csdn.net/hjl_and_djj/article/details/144293107">Ubuntu Server 22.04.5 LTS重启后IP被重置问题</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu装机：那些熟悉的 “老伙计”</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/%e5%b7%a7%e5%90%88%e7%9a%84%e6%8e%a8%e8%8d%90/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Fri, 11 Apr 2025 00:22:17 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://dpean.com/?p=241</guid>

					<description><![CDATA[刚上手新系统，一番探索竟有意外惊喜—装机推荐列表里，藏着好几&#8230;]]></description>
										<content:encoded><![CDATA[
<div class="wp-block-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex">
<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow" style="flex-basis:66.66%">
<p>刚上手新系统，一番探索竟有意外惊喜—装机推荐列表里，藏着好几位曾朝夕相伴的 “老伙计”。</p>



<p>从服务部署与运维角度看，Docker 作为容器化核心工具，可实现应用环境的标准化封装与快速迁移，新系统预装该工具，能大幅缩短后续项目的环境搭建周期，降低因环境差异导致的部署故障风险；Keepalived 作为高可用解决方案的关键组件，其预装为服务稳定性保障提供了基础支持，有助于提前构建业务系统的冗余架构，减少后期高可用改造的复杂度。​</p>



<p>在数据管理与自动化操作层面，PGSQL 作为成熟的关系型数据库，在处理结构化业务数据时具备稳定的性能与完善的功能，其被纳入推荐列表，为需要构建数据存储系统的工作场景提供了可靠选择，避免了从零选型与部署数据库的成本；PowerShell 则凭借强大的脚本编写与系统管理能力，能够满足自动化运维、批量任务处理等需求，预装该工具可快速启动自动化工作流程，提升系统管理效率。​</p>



<p>而 Mosquitto 作为轻量级 MQTT 协议代理工具，在物联网设备通信、分布式系统消息传递等场景中应用广泛，新系统对其的支持，意味着针对物联网相关的开发或运维工作可快速开展，无需额外投入资源进行工具部署与环境配置。​</p>
</div>



<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow" style="flex-basis:40%">
<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="1024" src="https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834-1024x1024.jpg" alt="" class="wp-image-242" srcset="https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834-1024x1024.jpg 1024w, https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834-300x300.jpg 300w, https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834-150x150.jpg 150w, https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834-768x768.jpg 768w, https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834-1536x1536.jpg 1536w, https://blog.dpean.com/wp-content/uploads/2025/04/微信图片_20250411082030-scaled-e1744331034834.jpg 1920w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>
</div>
</div>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu22.04 修改时区</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu22-04-%e4%bf%ae%e6%94%b9%e6%97%b6%e5%8c%ba/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Fri, 11 Apr 2025 00:14:33 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://dpean.com/?p=237</guid>

					<description><![CDATA[查看当前时间及时区 运行tzselect，依次选择Asia &#8230;]]></description>
										<content:encoded><![CDATA[
<p>查看当前时间及时区</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>date -R
#Fri, 11 Apr 2025 00:05:08 +0000</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">date</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-R</span></span>
<span class="line"><span style="color: #7B7F8B">#Fri, 11 Apr 2025 00:05:08 +0000</span></span></code></pre></div>



<p>运行tzselect，依次选择Asia &#8211; China &#8211; Beijing</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>tzselect
#Please identify a location so that time zone rules can be set correctly.
#Please select a continent, ocean, "coord", or "TZ".
#1) Africa                                                            7) Europe
#2) Americas                                                          8) Indian Ocean
#3) Antarctica                                                        9) Pacific Ocean
#4) Asia                                                             10) coord - I want to use geographical coordinates.
#5) Atlantic Ocean                                                   11) TZ - I want to specify the timezone using the Posix TZ format.
#6) Australia
? 4
#Please select a country whose clocks agree with yours.
# 1) Afghanistan              13) Cocos (Keeling) Islands  25) Jordan                   37) Nepal                    49) Syria
# 2) Antarctica               14) Cyprus                   26) Kazakhstan               38) Oman                     50) Taiwan
# 3) Armenia                  15) East Timor               27) Korea (North)            39) Pakistan                 51) Tajikistan
# 4) Australia                16) French S. Terr.          28) Korea (South)            40) Palestine                52) Thailand
# 5) Azerbaijan               17) Georgia                  29) Kuwait                   41) Philippines              53) Turkmenistan
# 6) Bahrain                  18) Hong Kong                30) Kyrgyzstan               42) Qatar                    54) United Arab Emirates
# 7) Bangladesh               19) India                    31) Laos                     43) Réunion                  55) Uzbekistan
# 8) Bhutan                   20) Indonesia                32) Lebanon                  44) Russia                   56) Vietnam
# 9) Brunei                   21) Iran                     33) Macau                    45) Saudi Arabia             57) Yemen
#10) Cambodia                 22) Iraq                     34) Malaysia                 46) Seychelles
#11) China                    23) Israel                   35) Mongolia                 47) Singapore
#12) Christmas Island         24) Japan                    36) Myanmar (Burma)          48) Sri Lanka
? 11
#Please select one of the following timezones.
#1) Beijing Time
#2) Xinjiang Time
? 1

#The following information has been given:

#        China
#        Beijing Time

#Therefore TZ='Asia/Shanghai' will be used.
#Selected time is now:   Fri Apr 11 08:05:54 CST 2025.
#Universal Time is now:  Fri Apr 11 00:05:54 UTC 2025.
#Is the above information OK?
#1) Yes
#2) No
? 1

#You can make this change permanent for yourself by appending the line
#        TZ='Asia/Shanghai'; export TZ
#to the file '.profile' in your home directory; then log out and log in again.

#Here is that TZ value again, this time on standard output so that you
#can use the /usr/bin/tzselect command in shell scripts:
#Asia/Shanghai</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">tzselect</span></span>
<span class="line"><span style="color: #7B7F8B">#Please identify a location so that time zone rules can be set correctly.</span></span>
<span class="line"><span style="color: #7B7F8B">#Please select a continent, ocean, &quot;coord&quot;, or &quot;TZ&quot;.</span></span>
<span class="line"><span style="color: #7B7F8B">#1) Africa                                                            7) Europe</span></span>
<span class="line"><span style="color: #7B7F8B">#2) Americas                                                          8) Indian Ocean</span></span>
<span class="line"><span style="color: #7B7F8B">#3) Antarctica                                                        9) Pacific Ocean</span></span>
<span class="line"><span style="color: #7B7F8B">#4) Asia                                                             10) coord - I want to use geographical coordinates.</span></span>
<span class="line"><span style="color: #7B7F8B">#5) Atlantic Ocean                                                   11) TZ - I want to specify the timezone using the Posix TZ format.</span></span>
<span class="line"><span style="color: #7B7F8B">#6) Australia</span></span>
<span class="line"><span style="color: #F286C4">?</span><span style="color: #F6F6F4"> 4</span></span>
<span class="line"><span style="color: #7B7F8B">#Please select a country whose clocks agree with yours.</span></span>
<span class="line"><span style="color: #7B7F8B"># 1) Afghanistan              13) Cocos (Keeling) Islands  25) Jordan                   37) Nepal                    49) Syria</span></span>
<span class="line"><span style="color: #7B7F8B"># 2) Antarctica               14) Cyprus                   26) Kazakhstan               38) Oman                     50) Taiwan</span></span>
<span class="line"><span style="color: #7B7F8B"># 3) Armenia                  15) East Timor               27) Korea (North)            39) Pakistan                 51) Tajikistan</span></span>
<span class="line"><span style="color: #7B7F8B"># 4) Australia                16) French S. Terr.          28) Korea (South)            40) Palestine                52) Thailand</span></span>
<span class="line"><span style="color: #7B7F8B"># 5) Azerbaijan               17) Georgia                  29) Kuwait                   41) Philippines              53) Turkmenistan</span></span>
<span class="line"><span style="color: #7B7F8B"># 6) Bahrain                  18) Hong Kong                30) Kyrgyzstan               42) Qatar                    54) United Arab Emirates</span></span>
<span class="line"><span style="color: #7B7F8B"># 7) Bangladesh               19) India                    31) Laos                     43) Réunion                  55) Uzbekistan</span></span>
<span class="line"><span style="color: #7B7F8B"># 8) Bhutan                   20) Indonesia                32) Lebanon                  44) Russia                   56) Vietnam</span></span>
<span class="line"><span style="color: #7B7F8B"># 9) Brunei                   21) Iran                     33) Macau                    45) Saudi Arabia             57) Yemen</span></span>
<span class="line"><span style="color: #7B7F8B">#10) Cambodia                 22) Iraq                     34) Malaysia                 46) Seychelles</span></span>
<span class="line"><span style="color: #7B7F8B">#11) China                    23) Israel                   35) Mongolia                 47) Singapore</span></span>
<span class="line"><span style="color: #7B7F8B">#12) Christmas Island         24) Japan                    36) Myanmar (Burma)          48) Sri Lanka</span></span>
<span class="line"><span style="color: #F286C4">?</span><span style="color: #F6F6F4"> 11</span></span>
<span class="line"><span style="color: #7B7F8B">#Please select one of the following timezones.</span></span>
<span class="line"><span style="color: #7B7F8B">#1) Beijing Time</span></span>
<span class="line"><span style="color: #7B7F8B">#2) Xinjiang Time</span></span>
<span class="line"><span style="color: #F286C4">?</span><span style="color: #F6F6F4"> 1</span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B">#The following information has been given:</span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B">#        China</span></span>
<span class="line"><span style="color: #7B7F8B">#        Beijing Time</span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B">#Therefore TZ=&#39;Asia/Shanghai&#39; will be used.</span></span>
<span class="line"><span style="color: #7B7F8B">#Selected time is now:   Fri Apr 11 08:05:54 CST 2025.</span></span>
<span class="line"><span style="color: #7B7F8B">#Universal Time is now:  Fri Apr 11 00:05:54 UTC 2025.</span></span>
<span class="line"><span style="color: #7B7F8B">#Is the above information OK?</span></span>
<span class="line"><span style="color: #7B7F8B">#1) Yes</span></span>
<span class="line"><span style="color: #7B7F8B">#2) No</span></span>
<span class="line"><span style="color: #F286C4">?</span><span style="color: #F6F6F4"> 1</span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B">#You can make this change permanent for yourself by appending the line</span></span>
<span class="line"><span style="color: #7B7F8B">#        TZ=&#39;Asia/Shanghai&#39;; export TZ</span></span>
<span class="line"><span style="color: #7B7F8B">#to the file &#39;.profile&#39; in your home directory; then log out and log in again.</span></span>
<span class="line"></span>
<span class="line"><span style="color: #7B7F8B">#Here is that TZ value again, this time on standard output so that you</span></span>
<span class="line"><span style="color: #7B7F8B">#can use the /usr/bin/tzselect command in shell scripts:</span></span>
<span class="line"><span style="color: #7B7F8B">#Asia/Shanghai</span></span></code></pre></div>



<p>复制文件至etc</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>cp /usr/share/zoneinfo/Asia/Shanghai  /etc/localtime</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">cp</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/usr/share/zoneinfo/Asia/Shanghai</span><span style="color: #F6F6F4">  </span><span style="color: #E7EE98">/etc/localtime</span></span></code></pre></div>



<p>检查</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>date -R
#Fri, 11 Apr 2025 08:06:12 +0800</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">date</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-R</span></span>
<span class="line"><span style="color: #7B7F8B">#Fri, 11 Apr 2025 08:06:12 +0800</span></span></code></pre></div>



<p><strong>参考资料</strong></p>



<ol class="wp-block-list">
<li><a href="https://blog.csdn.net/zhengchaooo/article/details/79500032">Ubuntu修改时区和更新时间</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu 22.04 查看版本信息</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu%e6%9f%a5%e7%9c%8b%e7%89%88%e6%9c%ac%e4%bf%a1%e6%81%af/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Tue, 01 Apr 2025 21:07:34 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://dpean.com/?p=216</guid>

					<description><![CDATA[参考资料]]></description>
										<content:encoded><![CDATA[
<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>cat /proc/version
#显示：Linux version 5.15.0-106-generic (buildd@lcy02-amd64-017) (gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0, GNU ld (GNU Binutils for Ubuntu) 2.38) #116-Ubuntu SMP Wed Apr 17 09:17:56 UTC 2024</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">cat</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/proc/version</span></span>
<span class="line"><span style="color: #7B7F8B">#显示：Linux version 5.15.0-106-generic (buildd@lcy02-amd64-017) (gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0, GNU ld (GNU Binutils for Ubuntu) 2.38) #116-Ubuntu SMP Wed Apr 17 09:17:56 UTC 2024</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>uname -a
#显示：Linux jp 5.15.0-106-generic #116-Ubuntu SMP Wed Apr 17 09:17:56 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">uname</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-a</span></span>
<span class="line"><span style="color: #7B7F8B">#显示：Linux jp 5.15.0-106-generic #116-Ubuntu SMP Wed Apr 17 09:17:56 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>lsb_release -a
#显示：LSB Version:    core-11.1.0ubuntu4-noarch:security-11.1.0ubuntu4-noarch
#Distributor ID: Ubuntu
#Description:    Ubuntu 22.04.4 LTS
#Release:        22.04
#Codename:       jammy</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">lsb_release</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">-a</span></span>
<span class="line"><span style="color: #7B7F8B">#显示：LSB Version:    core-11.1.0ubuntu4-noarch:security-11.1.0ubuntu4-noarch</span></span>
<span class="line"><span style="color: #7B7F8B">#Distributor ID: Ubuntu</span></span>
<span class="line"><span style="color: #7B7F8B">#Description:    Ubuntu 22.04.4 LTS</span></span>
<span class="line"><span style="color: #7B7F8B">#Release:        22.04</span></span>
<span class="line"><span style="color: #7B7F8B">#Codename:       jammy</span></span></code></pre></div>



<p class="eplus-wrapper"><strong>参考资料</strong></p>



<ol class="wp-block-list">
<li><a href="https://blog.csdn.net/icanflyingg/article/details/123330930" target="_blank" rel="noreferrer noopener">ubuntu查看系统版本</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu 22.04 查看系统架构</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu22-04%e6%9f%a5%e7%9c%8b%e7%b3%bb%e7%bb%9f%e6%9e%b6%e6%9e%84/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Tue, 01 Apr 2025 21:02:39 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://dpean.com/?p=214</guid>

					<description><![CDATA[参考资料]]></description>
										<content:encoded><![CDATA[
<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>arch
#显示：x86_64</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">arch</span></span>
<span class="line"><span style="color: #7B7F8B">#显示：x86_64</span></span></code></pre></div>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>dpkg --print-architecture
#显示：amd64</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">dpkg</span><span style="color: #F6F6F4"> </span><span style="color: #BF9EEE">--print-architecture</span></span>
<span class="line"><span style="color: #7B7F8B">#显示：amd64</span></span></code></pre></div>



<p class="eplus-wrapper"><strong>参考资料</strong></p>



<ol class="wp-block-list">
<li><a href="https://blog.csdn.net/qq_29761395/article/details/123006510" target="_blank" rel="noreferrer noopener">Ubuntu 20.04 &#8211; 查看操作系统架构</a></li>
</ol>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Ubuntu 修改主机名</title>
		<link>https://blog.dpean.com/%e7%9f%a5%e8%af%86/ubuntu%e4%bf%ae%e6%94%b9%e4%b8%bb%e6%9c%ba%e5%90%8d/</link>
		
		<dc:creator><![CDATA[dpecain]]></dc:creator>
		<pubDate>Mon, 10 Mar 2025 05:54:43 +0000</pubDate>
				<category><![CDATA[知识]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://dpean.com/?p=149</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[
<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:clamp(14px, .875rem, 21px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#f6f6f4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:clamp(20px, 1.25rem, 30px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:10px 0px 0 16px;font-size:0.8em;width:100%;text-align:left;background-color:#282A36;font-style:italic;color:#f6f6f4"><span style="border-bottom:1px solid rgba(251, 251, 239, 0.2)">Bash</span></span><span role="button" tabindex="0" data-code="hostname server #临时修改，重启服务器后不生效
vi /etc/hostname #永久修改" style="color:#f6f6f4;display:none" aria-label="复制" class="code-block-pro-copy-button"><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dracula-soft" style="background-color: #282A36" tabindex="0"><code><span class="line"><span style="color: #62E884">hostname</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">server</span><span style="color: #F6F6F4"> </span><span style="color: #7B7F8B">#临时修改，重启服务器后不生效</span></span>
<span class="line"><span style="color: #62E884">vi</span><span style="color: #F6F6F4"> </span><span style="color: #E7EE98">/etc/hostname</span><span style="color: #F6F6F4"> </span><span style="color: #7B7F8B">#永久修改</span></span></code></pre></div>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
