Netbackup 문서

넷백업 커맨드 정리 문서.

다운로드:NetBackup_Commands_UNIX

넷백업 클라이언트 관리 가이드

다운로드: VERITAS NetBackup ™ 6.0 Advanced Client System Administrator Guide for UNIX and Win

mod_rewrite를 이용한 http커맨드 제어

PUT, TRACE, DELETE를 사용 불가능하게하기.

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_METHOD} ^TRACE [OR]
RewriteCond %{REQUEST_METHOD} ^PUT   [OR]
RewriteCond %{REQUEST_METHOD} ^DELETE

RewriteRule .* – [F]
</IfModule>

적용전

[root@movie conf]# telnet localhost 80
Trying 127.0.0.1…
Connected to localhost.localdomain (127.0.0.1).
Escape character is ‘^]’.
TRACE / HTTP/1.0
Host: localhost

HTTP/1.1 200 OK
Date: Fri, 06 Nov 2009 03:26:32 GMT
Server: Apache
Connection: close
Content-Type: message/http

TRACE / HTTP/1.0
Host: localhost

Connection closed by foreign host.

적용후

[root@localhost conf]# telnet localhost 80
Trying 127.0.0.1…
Connected to localhost.localdomain (127.0.0.1).
Escape character is ‘^]’.
TRACE / HTTP/1.0
Host: localhost

HTTP/1.1 403 Forbidden
Date: Fri, 06 Nov 2009 03:42:21 GMT
Server: Apache
Content-Length: 321
Connection: close
Content-Type: text/html; charset=iso-8859-1

<!DOCTYPE HTML PUBLIC “-//IETF//DTD HTML 2.0//EN”>
<html><head>
<title>403 Forbidden</title>
</head><body>
<h1>Forbidden</h1>
<p>You don’t have permission to access /
on this server.</p>
<p>Additionally, a 404 Not Found
error was encountered while trying to use an ErrorDocument to handle the request.</p>
</body></html>
Connection closed by foreign host.

이미 만든 개인키에서 비밀번호 제거하기.

 이미 만든 key 화일에서 비밀번호 제거…

openssl rsa -in server.key -out server-nodes.key

처음부터 만들지 않을때는 -nodes옵션 사용.

ssh 터널 뚫기.

방화벽안쪽의 서버에 ssh접속은 해야겠고, 방화역은 안열어주고. 이럴때, ssh터널을 하나 뚫어놓으면, 필요할때 접속 가능

방화벽안쪽 서버. box1, 방화벽 바깥 SSH 서버 box2, 외부의 컴퓨터 box3. box3은 윈도우에 putty를 이용.

먼저, box1 과 box2를 ssh접속해 놓는다.

box1에서 아래의 명령을 실행

ssh -f -N -g -C -R 2222:localhost:22 userid@box2_ipaddress

box3에서, command창을 열고 아래 커맨드 실행

plink -L 3333:localhost:2222 userid@box2_ipaddress

이후, putty 에서, 포트번호 3333으로 box2에 접속하면, box1로 ssh 접속이 된 것을 확인 할 수 있음.

openssl 자체인증서 만들기

openssl   자체인증서 만들기

openssl genrsa -des3 -out ca.key 4096
openssl req -new -x509 -days 3650 -key ca.key -out ca.crt
openssl genrsa -des3 -out server.key 4096
openssl req -new -key server.key -out server.csr
openssl x509 -req -days 3650 -in server.csr -CA ca.crt -CAkey ca.key -set_serial 01 -out server.crt
 여기서, set_serial   옵션이 잘못되었다고 에러. 그래서 그 옵션을 빼면,

openssl x509 -req -days 365 -in server.csr -CA ca.crt -CAkey ca.key  -out server.crt

진행중 아래 에러발생

ca.srl: No such file or directory

 openssl x509 -req -days 365 -in server.csr -CA ca.crt -CAkey ca.key  -CAcreateserial -out server.crt

결국 화일 생성됨

말그대로 ca.srl화일이 없어서 발생.

openssl x509 -req -days 365 -in server.csr -CA ca.crt -CAkey ca.key  -CAcreateserial -out server.crt

오라클 snp 백그라운드 프로세스

다음의 parameter를 init<SID>.ora file에 설정한 후 oracle을 startup하면 SNP0 혹은 J000 process가 뜨게된다.
job_queue_processes = 10   –> 설치시 0 으로 설정되어 있음.
sqlplus 에서는
sql> alter system set job_queue_processes = 10
이렇게 해도 같은 효과.

netservices

solaris10에서  불필요한 네트워크 서비스를 제한할 수 있는 커맨드

netservices [open | limited]

open이면 모든 네트워크 서비스들이 열리고, limited로 하면, nfs같은 사용안하는 서비스는 열리지 않음.

관련커맨드는, svcadm, svccfg등..

Read-only file system

RedHat ES5 에서 오라클 10g R2 운영중 아래와 같은 에러가 발생.

SQL> conn /as sysdba
ERROR:
ORA-09925: Unable to create audit trail file
Linux Error: 30: Read-only file system
Additional information: 9925
ORA-09925: Unable to create audit trail file
Linux Error: 30: Read-only file system
Additional information: 9925

ORA-09925는audit 화일을 생성할 수 없는 경우에 발생한다고 한다. 특히 화일시스템이 full 난 경우처럼.

하지만 아무리 살펴봐도 오라클 문제는 아니었고, 리눅스쪽 문제였다.  Linux Error: 30: Read-only file system

화일을 읽기만 가능하고 쓰기가 불가능한상태.  mkdir, cp, touch 등의 커맨드를 실행하면 Read-only filesystem 이란 메시지만 뿌리면서, 화 일 생성이 안되었다.  LVM을 사용하는 상태라 lvdisplay와같은 커맨드를 실행해보면, 역시 에러가 났다.

화일시스템쪽 에러라 생각되어 이것저것 조치를 해보았으나, 처리가 안되어서, 화일들 백업하고 재부팅 시도. 다행히, 재부팅되었을때 복구가 되었다. 원격지 작업이어서 부팅과정은 살펴볼 수 없었다.

NetBackup

상황:

2009-05-26 오전 8:11:54 – begin Duplicate
2009-05-26 오전 8:11:57 – end Duplicate; elapsed time: 00:00:03
unable to allocate new media for backup, storage unit has none available(96)
2009-05-26 오전 8:11:55 – requesting resource nbumaster_tape
2009-05-26 오전 8:11:55 – Error nbjm(pid=2612) NBU status: 96, EMM status: No media is available   
2009-05-26 오전 8:11:55 – Error nbjm(pid=2612) NBU status: 96, EMM status: No media is available   

미디어 확인 명령어: bpmedialist

미디어(테잎)가 꽈 찬 상태… 해결은? 테이프 교환.

에러메시지

solaris7 에러 발생.

/dev/sysmsg: I/O 오류