<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" 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:media="http://search.yahoo.com/mrss/"><channel><title>systemd on Shaowen Chen's Website</title><link>https://www.chenshaowen.com/en/tags/systemd/</link><description>Recent content in systemd on Shaowen Chen's Website</description><generator>Hugo -- gohugo.io</generator><language>en</language><copyright>&amp;copy;2016 - {year}, All Rights Reserved.</copyright><lastBuildDate>Thu, 26 May 2022 00:00:00 +0000</lastBuildDate><sy:updatePeriod>weekly</sy:updatePeriod><atom:link href="https://www.chenshaowen.com/en/tags/systemd/atom.xml" rel="self" type="application/rss+xml"/><item><title>Configure Scheduled Tasks with systemd timer</title><link>https://www.chenshaowen.com/en/blog/how-to-configure-scheduled-task-using-systemd-timer.html</link><pubDate>Thu, 26 May 2022 00:00:00 +0000</pubDate><atom:modified>Thu, 26 May 2022 00:00:00 +0000</atom:modified><guid>https://www.chenshaowen.com/en/blog/how-to-configure-scheduled-task-using-systemd-timer.html</guid><description>1. Preparing the Scheduled Script If it is a Bash script, the first line needs to specify the interpreter.
1 2 mkdir -p /root/scripts vim /root/scripts/quick-clear.sh 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 #!/bin/sh /usr/local/bin/kubectl --kubeconfig /root/.kube/config get pods --all-namespaces -o wide | grep Evicted | awk &amp;#39;{print $1,$2}&amp;#39; | xargs --no-run-if-empty -L1 /usr/local/bin/kubectl --kubeconfig /root/.</description><dc:creator>WeChat Official Account</dc:creator><category>Linux</category><category>systemd</category><category>Scheduled Tasks</category><category>Operations</category><category>Learning</category><category>cron</category><category>Automation</category><category>Best Practices</category></item><item><title>How to Change Kubelet Startup Parameters</title><link>https://www.chenshaowen.com/en/blog/how-to-change-kubelet-config.html</link><pubDate>Wed, 23 Jun 2021 00:00:00 +0000</pubDate><atom:modified>Wed, 23 Jun 2021 00:00:00 +0000</atom:modified><guid>https://www.chenshaowen.com/en/blog/how-to-change-kubelet-config.html</guid><description>1. Edit the Kubelet Configuration File 1 vim /etc/systemd/system/kubelet.service.d/10-kubeadm.conf Modify the relevant Kubelet parameters
ExecStart=/usr/local/bin/kubelet $KUBELET_KUBECONFIG_ARGS $KUBELET_CONFIG_ARGS $KUBELET_KUBEADM_ARGS $KUBELET_EXTRA_ARGS You can list the available parameters with the following command:
1 kubelet --help For example, if you need to change --sync-frequency in KUBELET_KUBECONFIG_ARGS, the period for syncing container configuration, the default value is 1 min.</description><dc:creator>WeChat Official Account</dc:creator><category>Kubernetes</category><category>Kubelet</category><category>Configuration</category><category>Operations</category><category>Learning</category><category>Node</category><category>systemd</category><category>Troubleshooting</category></item></channel></rss>