1 Star 0 Fork 16

gaohongmei/dracut

forked from src-anolis-os/dracut 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0113.patch 1.25 KB
一键复制 编辑 原始数据 按行查看 历史
From f9c068e999cc76eaa318cc0773ef9133ea986131 Mon Sep 17 00:00:00 2001
From: Sebastian Mitterle <smitterl@redhat.com>
Date: Thu, 19 Mar 2020 12:12:50 +0100
Subject: [PATCH] dasd: only install /etc/dasd.conf if present
`dasd.conf` needn't be present on system even if modules have been loaded.
Check if file exists to avoid error message during kernel update
```bash
dracut-install: ERROR: installing '/etc/dasd.conf'
dracut: FAILED: /usr/lib/dracut/dracut-install -D /var/tmp/dracut.YvVRx5/initramfs -H /etc/dasd.conf
```
(cherry picked from commit defb1611c771d9f05780aebb101baefde2f66874)
Resolves: #1815043
---
modules.d/95dasd/module-setup.sh | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/modules.d/95dasd/module-setup.sh b/modules.d/95dasd/module-setup.sh
index 0da61309..ec33a9e0 100755
--- a/modules.d/95dasd/module-setup.sh
+++ b/modules.d/95dasd/module-setup.sh
@@ -18,8 +18,9 @@ depends() {
install() {
inst_hook cmdline 30 "$moddir/parse-dasd.sh"
inst_multiple dasdinfo dasdconf.sh normalize_dasd_arg
- if [[ $hostonly ]]; then
- inst -H /etc/dasd.conf
+ conf=/etc/dasd.conf
+ if [[ $hostonly && -f $conf ]] ; then
+ inst -H $conf
fi
inst_rules 56-dasd.rules
inst_rules 59-dasd.rules
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/gaohongmei/dracut.git
git@gitee.com:gaohongmei/dracut.git
gaohongmei
dracut
dracut
a8

搜索帮助