[晕事]今天做了件晕事22;寻找99-sysctl.conf; systemd

这个文件,使用ls命令看不出来是一个链接。

然后满世界的找这个文件怎么来的,后来发现是systemd里的一个文件。

从systemd的源文件里也没找到相关的文件信息。

最后把这个rpm安装包下载下来,才找到这个文件原来是一个链接

#ll /etc/sysctl.d/99-sysctl.conf

lrwxrwxrwx. 1 root root 14 May 18 11:57 /etc/sysctl.d/99-sysctl.conf -> .../sysctl.conf

所以最好还是从意思里将ll作为列表文件的习惯命令;

ll='ls -la'

-l use a long listing format

-a, --all

do not ignore entries starting with .

这个-l命令可以使用长格式列表,将链接列出来。

那问题是为什么要做99-sysctl.conf,难道是为了确保/etc/sysctl.conf文件里的内容一定是生效的!下面是systemd里的解释:

The systemd-sysctl tool no longer natively reads the file /etc/sysctl.conf. If desired, the file should be symlinked from /etc/sysctl.d/99-sysctl.conf. Apart from providing legacy support by a symlink rather than built-in code, it also makes the otherwise hidden order of application of the different files visible. (Note that this partly reverts to a pre-198 application order of sysctl knobs!)

相关推荐
-今昭-7 小时前
MooseFS分布式文件系统
linux·服务器·网络
byte轻骑兵7 小时前
【BlueZ 】蓝牙 HCI 协议基础:与 BlueZ 源码的层面对应关系
linux·hci·电脑蓝牙·嵌入式蓝牙·buez
万联WANFLOW7 小时前
Meta开源了能本地跑的agent
运维·服务器·网络·人工智能·业界资讯
Brilliantwxx7 小时前
【Linux】 进程(1) 从冯诺依曼体系到进程核心概念
linux·运维·服务器
lengjingzju8 小时前
编译与调试完全指南—第12章 日志分析
linux
陈聪.8 小时前
Docker 核心知识整理:从入门到企业级应用
运维·docker·容器
城管不管8 小时前
重生——第十次面试之开源中国一面挂
java·linux·开发语言·算法·面试·职场和发展·开源
蜀道山老天师8 小时前
Zabbix监控Apache与Nginx应用实践完整指南
linux·运维·nginx·apache·zabbix
王志来137944730088 小时前
从分散到集成:工控服务器机箱采购如何实现“一站式”破局
运维·服务器·人工智能·python
暖核8 小时前
Linux实战入门:从零编写第一个Bash Shell脚本
linux·运维·bash