요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
.. SPDX-License-Identifier: GPL-2.0
================
OCFS2 filesystem
================
OCFS2 is a general purpose extent based shared disk cluster file
system with many similarities to ext3. It supports 64 bit inode
numbers, and has automatically extending metadata groups which may
also make it attractive for non-clustered use.
You'll want to install the ocfs2-tools package in order to at least
get "mount.ocfs2" and "ocfs2_hb_ctl".
Project web page: http://ocfs2.wiki.kernel.org
Tools git tree: https://github.com/markfasheh/ocfs2-tools
OCFS2 mailing lists: https://subspace.kernel.org/lists.linux.dev.html
All code copyright 2005 Oracle except when otherwise noted.
Credits
=======
Lots of code taken from ext3 and other projects.
Authors in alphabetical order:
- Joel Becker <[email protected]>
- Zach Brown <[email protected]>
- Mark Fasheh <[email protected]>
- Kurt Hackel <[email protected]>
- Tao Ma <[email protected]>
- Sunil Mushran <[email protected]>
- Manish Singh <[email protected]>
- Tiger Yang <[email protected]>
Caveats
=======
Features which OCFS2 does not support yet:
- Directory change notification (F_NOTIFY)
- Distributed Caching (F_SETLEASE/F_GETLEASE/break_lease)
Mount options
=============
OCFS2 supports the following mount options:
(*) == default
======================= ========================================================
barrier=1 This enables/disables barriers. barrier=0 disables it,
barrier=1 enables it.
errors=remount-ro(*) Remount the filesystem read-only on an error.
errors=panic Panic and halt the machine if an error occurs.
intr (*) Allow signals to interrupt cluster operations.
nointr Do not allow signals to interrupt cluster
operations.
noatime Do not update access time.
relatime(*) Update atime if the previous atime is older than
mtime or ctime
strictatime Always update atime, but the minimum update interval
is specified by atime_quantum.
atime_quantum=60(*) OCFS2 will not update atime unless this number
of seconds has passed since the last update.
Set to zero to always update atime. This option need
work with strictatime.
data=ordered (*) All data are forced directly out to the main file
system prior to its metadata being committed to the
journal.
data=writeback Data ordering is not preserved, data may be written
into the main file system after its metadata has been
committed to the journal.
preferred_slot=0(*) During mount, try to use this filesystem slot first. If
it is in use by another node, the first empty one found
will be chosen. Invalid values will be ignored.
commit=nrsec (*) Ocfs2 can be told to sync all its data and metadata
every 'nrsec' seconds. The default value is 5 seconds.
This means that if you lose your power, you will lose
as much as the latest 5 seconds of work (your
filesystem will not be damaged though, thanks to the
journaling). This default value (or any low value)
will hurt performance, but it's good for data-safety.
Setting it to 0 will have the same effect as leaving
it at the default (5 seconds).
Setting it to very large values will improve
performance.
localalloc=8(*) Allows custom localalloc size in MB. If the value is too
large, the fs will silently revert it to the default.
localflocks This disables cluster aware flock.
inode64 Indicates that Ocfs2 is allowed to create inodes at
any location in the filesystem, including those which
will result in inode numbers occupying more than 32
bits of significance.
user_xattr (*) Enables Extended User Attributes.
nouser_xattr Disables Extended User Attributes.
acl Enables POSIX Access Control Lists support.
noacl (*) Disables POSIX Access Control Lists support.
resv_level=2 (*) Set how aggressive allocation reservations will be.
Valid values are between 0 (reservations off) to 8
(maximum space for reservations).
dir_resv_level= (*) By default, directory reservations will scale with file
reservations - users should rarely need to change this
value. If allocation reservations are turned off, this
option will have no effect.
coherency=full (*) Disallow concurrent O_DIRECT writes, cluster inode
lock will be taken to force other nodes drop cache,
therefore full cluster coherency is guaranteed even
for O_DIRECT writes.
coherency=buffered Allow concurrent O_DIRECT writes without EX lock among
nodes, which gains high performance at risk of getting
stale data on other nodes.
journal_async_commit Commit block can be written to disk without waiting
for descriptor blocks. If enabled older kernels cannot
mount the device. This will enable 'journal_checksum'
internally.
======================= ========================================================
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
OCFS2 개요, 도구와 기여자
1-36OCFS2는 ext3와 여러 특성이 비슷한 범용 extent 기반 공유 디스크 클러스터 파일시스템입니다. 64비트 inode 번호를 지원하고 메타데이터 그룹을 자동으로 확장하므로, 클러스터가 아닌 환경에서도 선택할 만한 특성이 있습니다.
최소한 `mount.ocfs2`와 `ocfs2_hb_ctl`을 사용하려면 `ocfs2-tools` 패키지를 설치해야 합니다. 원문은 프로젝트 웹 페이지, 도구 Git 트리, OCFS2 메일링 리스트 주소를 제공합니다. 별도 표기가 없는 코드는 2005년 Oracle 저작권이며, ext3와 다른 프로젝트에서 가져온 코드가 많이 사용되었습니다.
기여자는 알파벳 순으로 Joel Becker, Zach Brown, Mark Fasheh, Kurt Hackel, Tao Ma, Sunil Mushran, Manish Singh, Tiger Yang입니다. 이름과 전자우편 주소는 아래 보존된 원문에서 그대로 확인할 수 있습니다.
공유 디스크 클러스터 파일시스템의 핵심 특성과 운영 도구입니다.
.. SPDX-License-Identifier: GPL-2.0
================
OCFS2 filesystem
================
OCFS2 is a general purpose extent based shared disk cluster file
system with many similarities to ext3. It supports 64 bit inode
numbers, and has automatically extending metadata groups which may
also make it attractive for non-clustered use.
You'll want to install the ocfs2-tools package in order to at least
get "mount.ocfs2" and "ocfs2_hb_ctl".
Project web page: http://ocfs2.wiki.kernel.org
Tools git tree: https://github.com/markfasheh/ocfs2-tools
OCFS2 mailing lists: https://subspace.kernel.org/lists.linux.dev.html
All code copyright 2005 Oracle except when otherwise noted.
Credits
=======
Lots of code taken from ext3 and other projects.
Authors in alphabetical order:
- Joel Becker <[email protected]>
- Zach Brown <[email protected]>
- Mark Fasheh <[email protected]>
- Kurt Hackel <[email protected]>
- Tao Ma <[email protected]>
- Sunil Mushran <[email protected]>
- Manish Singh <[email protected]>
- Tiger Yang <[email protected]>
미지원 기능과 옵션 표기
37-50현재 OCFS2가 지원하지 않는 기능은 디렉터리 변경 알림 `F_NOTIFY`와 분산 캐싱에 관련된 `F_SETLEASE`, `F_GETLEASE`, `break_lease`입니다. 해당 인터페이스에 의존하는 애플리케이션을 배치하기 전에 이 제한을 확인해야 합니다.
이후 표는 OCFS2 마운트 옵션을 설명하며 `(*)` 표시는 기본값을 뜻합니다. 옵션 이름, 수치 범위, 기본값, 데이터 안전성과 클러스터 일관성에 미치는 영향을 함께 검토해야 합니다.
애플리케이션 호환성 검토가 필요한 기능입니다.
Caveats
=======
Features which OCFS2 does not support yet:
- Directory change notification (F_NOTIFY)
- Distributed Caching (F_SETLEASE/F_GETLEASE/break_lease)
Mount options
=============
OCFS2 supports the following mount options:
(*) == default
장벽, 오류, atime과 데이터 순서
51-76`barrier=1`은 쓰기 장벽을 활성화하고 `barrier=0`은 비활성화합니다. 오류 정책은 기본 `errors=remount-ro`가 오류 시 읽기 전용으로 다시 마운트하며, `errors=panic`은 시스템을 panic 상태로 만들고 정지시킵니다.
기본 `intr`은 신호가 클러스터 작업을 중단할 수 있게 하며 `nointr`은 이를 허용하지 않습니다. `noatime`은 접근 시각을 갱신하지 않습니다. 기본 `relatime`은 기존 atime이 mtime 또는 ctime보다 오래되었을 때 atime을 갱신합니다.
`strictatime`은 atime을 항상 갱신하되 최소 갱신 간격을 `atime_quantum`으로 정합니다. 기본 `atime_quantum=60`은 마지막 갱신 후 60초가 지나야 갱신하며, 0은 항상 갱신한다는 뜻입니다. 이 옵션은 `strictatime`과 함께 사용해야 합니다.
기본 `data=ordered`는 저널에 메타데이터를 커밋하기 전에 모든 데이터를 주 파일시스템으로 내보냅니다. `data=writeback`은 데이터 순서를 보존하지 않으므로 메타데이터 커밋 뒤에 데이터가 주 파일시스템에 기록될 수 있습니다.
기본 `preferred_slot=0`은 마운트할 때 지정 슬롯을 먼저 시도하고 다른 노드가 사용 중이면 첫 빈 슬롯을 선택합니다. 잘못된 값은 무시됩니다.
오류 대응과 시각·데이터 순서에 직접 영향을 주는 옵션입니다.
======================= ========================================================
barrier=1 This enables/disables barriers. barrier=0 disables it,
barrier=1 enables it.
errors=remount-ro(*) Remount the filesystem read-only on an error.
errors=panic Panic and halt the machine if an error occurs.
intr (*) Allow signals to interrupt cluster operations.
nointr Do not allow signals to interrupt cluster
operations.
noatime Do not update access time.
relatime(*) Update atime if the previous atime is older than
mtime or ctime
strictatime Always update atime, but the minimum update interval
is specified by atime_quantum.
atime_quantum=60(*) OCFS2 will not update atime unless this number
of seconds has passed since the last update.
Set to zero to always update atime. This option need
work with strictatime.
data=ordered (*) All data are forced directly out to the main file
system prior to its metadata being committed to the
journal.
data=writeback Data ordering is not preserved, data may be written
into the main file system after its metadata has been
committed to the journal.
preferred_slot=0(*) During mount, try to use this filesystem slot first. If
it is in use by another node, the first empty one found
will be chosen. Invalid values will be ignored.
커밋, 로컬 할당, inode와 접근 제어
77-98`commit=nrsec`은 모든 데이터와 메타데이터를 `nrsec`초마다 동기화합니다. 기본값은 5초이며 전원 손실 시 최근 최대 5초의 작업을 잃을 수 있지만 저널링 덕분에 파일시스템 자체가 손상되지는 않습니다. 낮은 값은 데이터 안전성에 유리하지만 성능을 낮추고, 큰 값은 성능을 높입니다. 0은 기본 5초와 같습니다.
기본 `localalloc=8`은 로컬 할당 영역 크기를 MiB 단위로 지정합니다. 값이 지나치게 크면 파일시스템이 조용히 기본값으로 되돌립니다. `localflocks`는 클러스터 인식 `flock`을 비활성화합니다.
`inode64`는 inode 번호의 유효 비트가 32비트를 넘게 되는 위치를 포함하여 파일시스템 어디에든 inode를 만들 수 있게 합니다. 기본 `user_xattr`은 사용자 확장 속성을 활성화하고 `nouser_xattr`은 비활성화합니다. `acl`은 POSIX ACL을 활성화하며 기본 `noacl`은 이를 비활성화합니다.
동기화 주기, 할당, inode 위치와 접근 제어를 설정합니다.
commit=nrsec (*) Ocfs2 can be told to sync all its data and metadata
every 'nrsec' seconds. The default value is 5 seconds.
This means that if you lose your power, you will lose
as much as the latest 5 seconds of work (your
filesystem will not be damaged though, thanks to the
journaling). This default value (or any low value)
will hurt performance, but it's good for data-safety.
Setting it to 0 will have the same effect as leaving
it at the default (5 seconds).
Setting it to very large values will improve
performance.
localalloc=8(*) Allows custom localalloc size in MB. If the value is too
large, the fs will silently revert it to the default.
localflocks This disables cluster aware flock.
inode64 Indicates that Ocfs2 is allowed to create inodes at
any location in the filesystem, including those which
will result in inode numbers occupying more than 32
bits of significance.
user_xattr (*) Enables Extended User Attributes.
nouser_xattr Disables Extended User Attributes.
acl Enables POSIX Access Control Lists support.
noacl (*) Disables POSIX Access Control Lists support.
예약, 클러스터 일관성과 비동기 저널
99-117기본 `resv_level=2`는 할당 예약의 적극성을 정하며 유효 범위는 예약을 끄는 0부터 최대 공간을 예약하는 8까지입니다. `dir_resv_level=`은 기본적으로 디렉터리 예약을 파일 예약에 맞춰 확장합니다. 일반적으로 변경할 필요가 없고 할당 예약이 꺼져 있으면 효과가 없습니다.
기본 `coherency=full`은 동시 `O_DIRECT` 쓰기를 금지하고 클러스터 inode 잠금을 잡아 다른 노드가 캐시를 버리게 하므로 직접 I/O에서도 완전한 클러스터 일관성을 보장합니다. `coherency=buffered`는 노드 사이의 EX 잠금 없이 동시 `O_DIRECT` 쓰기를 허용하여 성능을 높이지만 다른 노드가 오래된 데이터를 볼 위험이 있습니다.
`journal_async_commit`은 descriptor block을 기다리지 않고 commit block을 디스크에 쓸 수 있게 합니다. 이 옵션을 켜면 오래된 커널은 장치를 마운트할 수 없으며, 내부적으로 `journal_checksum`도 활성화됩니다.
공간 예약, 직접 I/O 일관성, 저널 호환성 사이의 선택입니다.
resv_level=2 (*) Set how aggressive allocation reservations will be.
Valid values are between 0 (reservations off) to 8
(maximum space for reservations).
dir_resv_level= (*) By default, directory reservations will scale with file
reservations - users should rarely need to change this
value. If allocation reservations are turned off, this
option will have no effect.
coherency=full (*) Disallow concurrent O_DIRECT writes, cluster inode
lock will be taken to force other nodes drop cache,
therefore full cluster coherency is guaranteed even
for O_DIRECT writes.
coherency=buffered Allow concurrent O_DIRECT writes without EX lock among
nodes, which gains high performance at risk of getting
stale data on other nodes.
journal_async_commit Commit block can be written to disk without waiting
for descriptor blocks. If enabled older kernels cannot
mount the device. This will enable 'journal_checksum'
internally.
======================= ========================================================
요약·해설
ocfs2.rst:1-117OCFS2는 extent 기반 공유 디스크 클러스터 파일시스템입니다. 마운트 옵션은 오류 처리와 저널 데이터 순서뿐 아니라 클러스터 작업 중단, inode 위치, 할당 예약, `O_DIRECT` 일관성, 확장 속성과 POSIX ACL까지 제어합니다.
데이터 안전성을 우선하면 `data=ordered`, 짧은 `commit` 주기, `coherency=full`의 의미를 유지해야 합니다. `coherency=buffered`와 `journal_async_commit`은 성능을 높일 수 있지만 stale data 위험과 구형 커널 호환성 제한을 함께 검토해야 합니다.
안전성, 성능, 호환성에 큰 영향을 주는 옵션을 묶었습니다.