[晕事]今天做了件晕事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 分钟前
计算机网络:套接字
linux·服务器·计算机网络
YuanDaima20489 分钟前
WSL2 与 Ubuntu 22.04 基础环境部署指南
linux·运维·服务器·人工智能·ubuntu·docker
万邦科技Lafite10 分钟前
API接口一键获取商品评论,根据商品评论分析客户画像
linux·服务器·数据库·windows·microsoft·电商开放平台
其实防守也摸鱼36 分钟前
DVWA--Brute Force (暴力破解)通关指南
服务器·网络·安全·靶场·教程·工具·dvwa
sulikey1 小时前
操作系统磁盘 I/O:为何选择“块“而非“扇区“?
linux·操作系统·io·磁盘·磁盘io
一个人旅程~1 小时前
如何永久关闭bitlocker并防止出现更新后被强制加密?
linux·windows·经验分享·电脑
源远流长jerry1 小时前
TCP 三次握手深度解析:从内核源码到生产实践
linux·运维·网络·网络协议·tcp/ip
智象科技1 小时前
智能运维(AIOps),正在改变IT行业格局
运维·人工智能·运维开发·devops·智能运维
黄筱筱筱筱筱筱筱2 小时前
RHCE---web服务器①
linux·运维·服务器
上海云盾安全满满2 小时前
服务器被攻击了,更换IP是否有用吗
服务器·网络·tcp/ip