디스크가 온라인 상태가 되면 /root 디렉토리로 다시 변경하고 장치를 포맷합니다. 이는 전체 수명 동안 DASD에 한 번만 필요합니다.
cd /root
dasdfmt -b 4096 -d cdl -p /dev/disk/by-path/ccw-0.0.4b2e
Drive Geometry: 10017 Cylinders * 15 Heads = 150255 Tracks
I am going to format the device /dev/disk/by-path/ccw-0.0.4b2e in the following way:
Device number of device : 0x4b2e
Labelling device : yes
Disk label : VOL1
Disk identifier : 0X4B2E
Extent start (trk no) : 0
Extent end (trk no) : 150254
Compatible Disk Layout : yes
Blocksize : 4096
--->> ATTENTION! <<---
All data of that device will be lost.
Type "yes" to continue, no will leave the disk untouched: yes
cyl 97 of 3338 |#----------------------------------------------| 2%
# cd /root
# dasdfmt -b 4096 -d cdl -p /dev/disk/by-path/ccw-0.0.4b2e
Drive Geometry: 10017 Cylinders * 15 Heads = 150255 Tracks
I am going to format the device /dev/disk/by-path/ccw-0.0.4b2e in the following way:
Device number of device : 0x4b2e
Labelling device : yes
Disk label : VOL1
Disk identifier : 0X4B2E
Extent start (trk no) : 0
Extent end (trk no) : 150254
Compatible Disk Layout : yes
Blocksize : 4096
--->> ATTENTION! <<---
All data of that device will be lost.
Type "yes" to continue, no will leave the disk untouched: yes
cyl 97 of 3338 |#----------------------------------------------| 2%
Copy to ClipboardCopied!Toggle word wrapToggle overflow
진행률 표시줄이 끝에 도달하고 형식이 완료되면 dasdfmt 는 다음 출력을 출력합니다.
Rereading the partition table...
Exiting...
Rereading the partition table...
Exiting...
Copy to ClipboardCopied!Toggle word wrapToggle overflow
이제 fdasd 를 사용하여 DASD를 분할합니다. DASD에 최대 3개의 파티션을 생성할 수 있습니다. 이 예제에서는 전체 디스크에 걸쳐 하나의 파티션을 만듭니다.
fdasd -a /dev/disk/by-path/ccw-0.0.4b2e
reading volume label ..: VOL1
reading vtoc ..........: ok
auto-creating one partition for the whole disk...
writing volume label...
writing VTOC...
rereading partition table...
# fdasd -a /dev/disk/by-path/ccw-0.0.4b2e
reading volume label ..: VOL1
reading vtoc ..........: ok
auto-creating one partition for the whole disk...
writing volume label...
writing VTOC...
rereading partition table...
Copy to ClipboardCopied!Toggle word wrapToggle overflow
(낮은 수준의 포맷) DASD가 온라인 상태이면 Linux에서 다른 디스크와 마찬가지로 사용할 수 있습니다. 예를 들어 파일 시스템, LVM 물리 볼륨 또는 파티션에 파일 시스템(예: /dev/disk/by-path/ccw-0.0.4b2e-part1 )을 생성할 수 있습니다. 전체 DASD 장치(dev/dasdb)를 dasdfmt 및 fdasd 명령만 사용하면 안 됩니다. 전체 DASD를 사용하려면 위의 fdasd 예에서와 같이 전체 드라이브에 있는 하나의 파티션을 만듭니다.
나중에 /etc/fstab 의 기존 디스크 항목을 분리하지 않고 디스크를 추가하려면 /dev/disk/by-path/ 아래의 영구 장치 심볼릭 링크를 사용합니다.