mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-09-03 18:04:16 +00:00
runtime: remove wrong xfs options
"data=ordered" and "errors=remount-ro" are wrong options in xfs. (they are ext4 options) <https://manpages.ubuntu.com/manpages/focal/man5/xfs.5.html> Fixes: #11205 Signed-off-by: Shunsuke Kimura <pbrehpuum@gmail.com>
This commit is contained in:
@@ -150,7 +150,11 @@ func GetKernelRootParams(rootfstype string, disableNvdimm bool, dax bool) ([]Par
|
||||
kernelRootParams = append(kernelRootParams, Param{"rootflags", "ro"})
|
||||
}
|
||||
case XFS:
|
||||
fallthrough
|
||||
if dax {
|
||||
kernelRootParams = append(kernelRootParams, Param{"rootflags", "dax ro"})
|
||||
} else {
|
||||
kernelRootParams = append(kernelRootParams, Param{"rootflags", "ro"})
|
||||
}
|
||||
// EXT4 filesystem is used by default.
|
||||
case EXT4:
|
||||
if dax {
|
||||
|
@@ -64,7 +64,7 @@ func TestGetKernelRootParams(t *testing.T) {
|
||||
rootfstype: string(XFS),
|
||||
expected: []Param{
|
||||
{"root", string(Nvdimm)},
|
||||
{"rootflags", "data=ordered,errors=remount-ro ro"},
|
||||
{"rootflags", "ro"},
|
||||
{"rootfstype", string(XFS)},
|
||||
},
|
||||
disableNvdimm: false,
|
||||
@@ -75,7 +75,7 @@ func TestGetKernelRootParams(t *testing.T) {
|
||||
rootfstype: string(XFS),
|
||||
expected: []Param{
|
||||
{"root", string(Nvdimm)},
|
||||
{"rootflags", "dax,data=ordered,errors=remount-ro ro"},
|
||||
{"rootflags", "dax ro"},
|
||||
{"rootfstype", string(XFS)},
|
||||
},
|
||||
disableNvdimm: false,
|
||||
@@ -86,7 +86,7 @@ func TestGetKernelRootParams(t *testing.T) {
|
||||
rootfstype: string(XFS),
|
||||
expected: []Param{
|
||||
{"root", string(VirtioBlk)},
|
||||
{"rootflags", "data=ordered,errors=remount-ro ro"},
|
||||
{"rootflags", "ro"},
|
||||
{"rootfstype", string(XFS)},
|
||||
},
|
||||
disableNvdimm: true,
|
||||
|
Reference in New Issue
Block a user