Operating System/Solaris2007/07/24 16:27

7장. NVRAM(OK_mod Command)

printenv; 현재 설정되어 있는 System 환경치를 보여준다.
setenv; 환경설정
module-info; CPU Clock Speed
probe-scsi; 현재 접속되어 있는 SCSI DEVICE들이 열거된다. (probe-scsi-all)
words; ok 모드 에서의 명령어 열람
boot -a; Interactive boot option
help diag; Memory, Floppy Drive, Cache Memory 등. Test 명령어 사용법을 보여준다
ok test-memory; Memory 이상 유무 확인 할 때 이상 없다면 prompt만 나타나고, RAM의 배치에 문제가 있다면 align error Message가 나타난다.
TOD 관련 ERROR; F-E-Handbook Vol I --> CPU-131

ok copy-clock-tod-to-io-boards
ok (ioboard# in hex) copy-io-board-tod-to-clock-tod

* 화면 resolution 변경할 때 : setenv output-device screen:r1024x768x76
* Center2000에서 model-100_type array 상태에서의 BOOT_DEVICE 설정치

ok setenv boot-device /io-unit@f,e0200000/sbi@0,0/SUNW,soc@0,0/SUNW,pln@a0000000,78c8d4/SUNW,ssd array의 serial_number ; array A tray 1 번째 disk

7.1 OK mode상에서 banner 및 logo변경

[banner변경]

예를 들어 bannner를 "This is my computer"이라 하자. 먼저 ok prompt mode 즉 forth command mode로 들어가서

ok setenv oem-barner This is my computer
oem-banner = This is my computer banner
ok setenv oem-banner? true
oem-banner?= true
ok

또는 OS상에서

test# eeprom "oem-banner=This is my computer"
test# eeprom "oem-banner?=true"

[logo제작]

ok prompt mode to command를 이용하여 logo를 변경할 수 있으나, 보통 forth language가 익숙하지 않으므로 다음은 OS상에서 변경하는 예제만 살펴보자. NVRAM상의 oem-logo값은 512 byte array(4096 bits 64x64)이다. 각 bit는 우측상단을 기준으로 한 pixel을 control한다. array는 hexedicimal값으로 저장되고 printenv를 사용하는 것은 처음 8 byte를 보여줄 것이다.

1. openwindow에서icon editor를 이용하여 64x64 icon을 생성한 후 file로 save.
2. 예를 들어 만들어진 icon file이 my.logo라 하자.

# eeprom "oem-logo=my.logo" /* my.logo를 NVRAM array에 save */
# eeprom "oem-logo?=true"

3.system을 halt한 후 ok prompt에서 banner command를 수행하면 바꾸어진 logo를 확인할 수 있다.

7.2 NVRAM 값 변경

1) Host-ID란 시스템마다 각기 다른 Serial No.를 의미하는데, 이 Host-ID를 수정하는 이유는 license를 요구하는 특정 S/W사용시 Host-ID를 Check하여 Host-ID가 서로 일치하여야만 비로소 수행되기 때문이다.(호스트 마다 license를 check하는 deamon이 수행되고 있을 것이다)
2) Booting 도중에 break-key(STOP+A)를 누르고 n 을 쳐서 ok mode로 들어간다. 이 상태가 NVRAM 수정가능상태 이다.
3) NVRAM의 내용을 살펴본다.

ok .idprom

ⓐ ⓑ

Format/Type: 1 54 Ethernet: 8 0 20 2 8f 26 Date: 0 0 0 0

ⓒ ⓓ ⓔ ⓕ

Serial: 00 14 20 Checksum: ed Reserved: a5 a5 a5 a5 a5 a5 a5 a5 . . .

여기서 현재의 Host-ID는 "54 00 14 20"이다. 즉 Type와 Serial의 값이다.

+ⓒ+ⓓ+ⓔ

4) 여기서 Host-ID의 값을 "5200fc7d"로 변경한다.

ok 52 1 mkp: 1번지의 내용 변경
ok 00 c mkp: c번지의 내용 변경
ok fc d mkp: d번지의 내용 변경
ok 7d e mkp: e번지의 내용 변경
ok .idprom: NVRAM의 변경 내용 확인

Format/Type: 1 52 Ethernet: 8 0 20 2 8f 26 Date: 0 0 0 0

Serial: 0 fc 7d Checksum: 04 Reserved: a5 a5 a5 a5 a5 a5 a5 a5 . . .

ok 1 52 8 0 20 2 8f 26 0 0 0 0 0 fc 7d: ~ⓕ 까지 나열. ꠏꠈChecksum

ok xor xor xor xor xor xor xor xor xor xor xor xor xor xor (14개) ꠏꠎ

ok .s : checksum값 확인
ok xx : checksum값
ok xx f mkp : ⓕ번지의 checksum값 변경
ok .idprom : NVRAM의 내용 변경여부 확인

Format/Type: 1 52 Ethernet: 8 0 20 2 8f 26 Date: 0 0 0 0

Serial: 0 fc 7d Checksum: xx Reserved: a5 a5 a5 a5 a5 a5 a5 a5 . . .

ok reset

rebooting......

* machine type 을 미리 알고 있어야 번지의 값을 올바로 변경할 수 있다.

ex) ss1+ 64XXXX

ss2 72XXXX 72가 machine type 이 된다.

Creative Commons License
Posted by BLUEDAY™