![]() | |
Sun Java(TM) System Directory Server 5.2 2005Q1 �� ���? |
14��
SNMP�� ����Ͽ� Directory Server �����SNMP(Simple Network Management Protocol)�� ��ġ�� �?� �wα�; �ǽð�8�� ����� �� ���ϱ� '�� ǥ��ȭ�� �� �w������Դϴ�. Directory Server�� SNMP ���� �?� �wα����� ������� �� �ֵ��� ��' ������Ʈ �������̽��� f���մϴ�. �̷��� �������̽��� ���� ��Ʈ��ũ �?� �wα�: ���丮 ���� ���¸� Ȯ���ϰ� �۾� d���� ��; �� �ֽ4ϴ�.
Directory Server SNMP ��' ������Ʈ���� �б� ��� ���� ���ԵǾ� �ֽ4ϴ�. SNMP �� �?� �wα�: ����� �۾�; ������ �� ��4ϴ�.
�Ϲ���8�� 13��, "�α� ����; ����Ͽ� Directory Server �����"�� ����� ������ �7� �αװ� ���� ���� �ξ� �ڼ��� d���� f���ϸ� ���� ������ �����ϰ� �����Ͽ� ��d�Ϸt� ��쿡�� �ַ� LDAP �w������� ���˴ϴ�. ���� SNMP ��' ������Ʈ�� ����ϸ� Directory Server �ν��Ͻ��� ��x�� ��Ʈ��ũ �� �ý��ۿ� ������ �� �ֽ4ϴ�.
�� ��: ��= ����8�� �����Ǿ� �ֽ4ϴ�.
Sun Java System ������ SNMP�� �?� �wα�: SNMP�� ����Ͽ� ������Ʈ �Ǵ� ��' ������Ʈ �?� �wα�; �����ϴ� �?� �wα��� ��ġ�� ���� �� �ֽ4ϴ�. SNMP ������Ʈ �Ǵ� ��' ������Ʈ�� SNMP ������ ��� �4��Ͽ� �?� �wα� �Ǵ� ��ġ�κ��� d���� �����մϴ�. �� d���� ������Ʈ�� ���� MIB(Management Information Base)�� d�ǵ� ���̺��� ����� �����˴ϴ�.
�Ϲ���8�� ��Ʈ��ũ ���ڴ� ��' ������Ʈ�� SNMP ���� ���ϰ� ��' ������Ʈ�� ��û�� ��; ��ȯ�մϴ�. ���� SNMP�� ������Ʈ�� Ʈ�� ���� ��� ��Ʈ��ũ ���ڿ��� ���� �̺�Ʈ�� ������ �� �ֵ��� �ϴ� ���; d���մϴ�. Directory Server ������ ����DZ� �� ��' ������Ʈ �� ������ ������Ʈ�� ����ǰ� �ִ� ���, Directory Server ��' ������Ʈ�� Directory Server ���� �Ǵ� ~�� �� ������ ������Ʈ�� SMUX Ʈ��; ����մϴ�. ������ ������Ʈ�� �̰�; SNMP Ʈ��8�� ��ȯ�մϴ�.
ȣ��Ʈ �ý��ۿ� ���� ���� ��' ������Ʈ�� ��ġ�� �� �ֽ4ϴ�. ���� ��� �� ���� ȣ��Ʈ�� Directory Server, Application Server �� Messaging Server�� ��� ��ġ�Ǿ� �ִ� ��� �� ������ ��' ������Ʈ�� ������ ������ ������Ʈ�� ����մϴ�.
UNIX ȯ�濡���� Administration Server�� ��ġ�Ǿ� �ִ� ��� Directory Server �� ��Ÿ Sun Java System fǰ�� SNMP ������ ������Ʈ(MAGT)�� f��˴ϴ�.
SNMP�� ����Ͽ� ���� ������ϴ� ��� ���� �ڼ��� ����: Administration Server �� ���?�� ��v�Ͻʽÿ�.
SNMP�� ���� ������� ���� ��d�ϴ� �Ϲ� ����� ��=�� ���4ϴ�.
- Directory Server MIB; �������Ͽ� SNMP �� �ý��ۿ� �����մϴ�. �ý��� ���?�� ��v�Ͻʽÿ�.
- SNMP ��d�� ����Ǿ� �ִ� ��� ��ǻ�Ϳ� SNMP�� ��ġ�Ͻʽÿ�.
- Directory Server �ܼ�; ���� SNMP ��' ������Ʈ�� �����մϴ�. Directory Server���� SNMP ����; ��v�Ͻʽÿ�.
- Directory Server �ܼ�; ���� SNMP ��' ������Ʈ�� �����մϴ�. SNMP ��' ������Ʈ ���� �� ������ ��v�Ͻʽÿ�.
- MIB�� d�ǵǾ� ������Ʈ�� ���� f��� SNMP �� ��� ��ü�� �����մϴ�. �� �ܰ�� ����8�� SNMP �� �ý��ۿ� ��� ��d�˴ϴ�.
Directory Server ������ �ܰ迡 ���ؼ��� ��= �� �����մϴ�.
Directory Server MIB�� ����Directory Server MIB���� ��=�� ��ü �ĺ��ڰ� �ֽ4ϴ�.
iso.org.dod.internet.private.enterprises.netscape.nsldap
(nsldapd OBJECT IDENTIFIER ::= { 1.3.6.1.4.1.1450.7 })�Ʒ� ���Ͽ� d�ǵǾ� �ֽ4ϴ�.
ServerRoot/plugins/snmp/netscape-ldap.mib
MIB: SNMP�� ���� ������� �� �ִ� ����� �� ���� ���Ե� �� /��; d���մϴ�. ���丮 MIB: �� ���� �� ��� ��ü ���̺�� ���е˴ϴ�.
- �۾� ���̺� - ���丮�� ���ε�, �۾�, ��v �� �7� ���� ��谡 ���ԵǾ� �ֽ4ϴ�. �̷��� ���� ��: cn=snmp,cn=monitor ���丮 ���� �Ӽ����� �ֽ4ϴ�. Directory Server Administration Reference�� ��v�Ͻʽÿ�.
- �� ���̺� - ���丮 �� �� �� ij�� ���� �� ���ԵǾ� �ֽ4ϴ�. �̷��� ���� ��: �۾� ����� �Բ� cn=snmp,cn=monitor ���丮 ���� �Ӽ��� ���˴ϴ�. Directory Server Administration Reference�� ��v�Ͻʽÿ�.
- ��ȣ �ۿ� ���̺� - �� ���丮 ����� ����8�� ����� 5�� ���丮 ���� ���� ��谡 ���ԵǾ� �ֽ4ϴ�. Directory Server Administration Reference�� ��v�Ͻʽÿ�.
- ��ƼƼ ���̺� - Directory Server�� �ν��Ͻ��� �����ϴ� ����(��: ���� ���̵� �� ����)�� ���ԵǾ� �ֽ4ϴ�. Directory Server Administration Reference�� ��v�Ͻʽÿ�.
���丮�� MIB; ����Ϸx� ���� �Ʒ� ���丮�� �ִ� MIB�� �Բ� �������ؾ� �մϴ�.
ServerRoot/plugins/snmp/mibs
MIB ������ ��� ���� �ڼ��� ����: SNMP fǰ ���?�� ��v�Ͻʽÿ�.
SNMP ��dSolaris �÷����� ���
����Ǵ� Solaris ����: Solaris �⺻ ������Ʈ �w��ӿ�ũ�� Directory Service ������ ������Ʈ(MPS/MAGT)�� �÷����ϴ� ���Դϴ�. �� �������� Solaris ������Ʈ snmpdx�� MPS ������Ʈ�� �����ϴ� �ϰ� �ش� MPS ������Ʈ���� Directory Server SNMP ��û; ����ϴ� ��; ����մϴ�. ��, ��û�� Directory Server�� ��õǾ� �ִ��� ���ο� ��� ���� ��� SNMP �� Ŭ���̾�Ʈ�� ǥ�� ��Ʈ 161���� Solaris ������Ʈ�� ������ �� �ֽ4ϴ�.
MPS ������Ʈ�� �ٸ� ��Ʈ(1161�� �����)���� ����ǵ��� �ٽ� �����ؾ߸� Solaris ������Ʈ�� �浹; ��8Ű�� �ʰ� �˴ϴ�. �Ʒ� f��� ���� ������ �̷��� �ܰ谡 ��� �ֽ4ϴ�. MPS ������Ʈ�� �����ϴ� �ڼ��� ��ħ: Administration Server �� ���?�� ���� �ֽ4ϴ�. ���� �� �������� MPS ������Ʈ�� Solaris ������Ʈ�� ���� ���۵Ǿ�� �ϹǷ� MPS ������Ʈ�� ���� �Ǵ� �����ϴ� �� Administration Server�� ������� �ʴ´ٴ� a; �����Ͻʽÿ�.
snmpdx SNMP ������ ������Ʈ�� �÷��� - Solaris ���� ���� �����Ͽ� Solaris snmpdx ������Ʈ(man snmpdx(1M))�� �÷����Ͻʽÿ�. Solaris snmpdx ������Ʈ�� ǥ�� ��Ʈ 161���� ����� �� ��8�� Directory SNMP ��û; Directory Server�� ����մϴ�.
slapd-instance�� ������� ���丮 �ν��Ͻ� �̸�8�� �ٲٽʽÿ�.
- ��Ʈ�� �α����մϴ�.
- MPS ������Ʈ�� ���� ��� ����(/etc/snmp/conf/mps.reg); ����ϴ�.
��= ����; ���Ͽ� �߰��մϴ�.
#
# Registration file for MPS Agent.
#
##########
# agents #
##########
agents = {
{
name = "mps"
subtrees = {
# Directory Server
1.3.6.1.4.1.1450.7,
# Web Server
1.3.6.1.4.1.1450.1.60
}
timeout = 2000000
watch-dog-time = 86400
port = 1161
}
}
- MPS ������Ʈ�� ���� ���ҽ� ����(/etc/snmp/conf/mps.rsrc); ����ϴ�.
��= ����; ����; �߰��մϴ�.
#
# Resource file for MPS Agent.
#
resource =
{
{
registration_file = "/etc/snmp/conf/mps.reg"
policy = "spawn"
type = "legacy"
command = "install-dir/plugins/snmp/magt/magt
install-dir/plugins/snmp/magt/CONFIG
install-dir/plugins/snmp/magt/INIT"}
}
- install-dir/plugins/snmp/magt/CONFIG�� ���� ��= �ڵ� ��; �߰��մϴ�.
TRANSPORT extraordinary SNMP
OVER UDP SOCKET
AT PORT 1161
- �ٽ� ������ ��= magt �wμ����� ��Ʈ 1161���� ����ǰ� �ִ��� Ȯ���մϴ�. ���� ��� ��=�� ���4ϴ�.
$ pgrep magt
219542005-03-25
$ netstat -a | grep 1161
*.1161 Idle
*.1161 Idle
- Directory Server���� SNMP ������ ����� ��� Directory Server ��' ������Ʈ�� �����մϴ�. �⺻ ��Ʈ 199�� ����Ͻʽÿ�.
��Ʈ �� �ڵ�8�� ��' ������Ʈ�� �����ϵ��� ��= ��; �����ϴ� /etc/init.d�� ���� ��ũ��Ʈ�� �ۼ��� �� �ֽ4ϴ�. ��' ������Ʈ�� MPS ������Ʈ�� �̹� ���۵Ǿ�; ���� ���۵˴ϴ�.
$ cd install-dir/bin/slapd/server
[ -x ./64/ns-slapd ] && [ "‘/bin/isainfo -b 2> /dev/null‘" = 64 ] && cd ./64
./ns-ldapagt -d install-dir/slapd-instance
- ��' ������Ʈ�� ����ǰ� �ִ��� Ȯ���մϴ�. ���� ��� ��=�� ���4ϴ�.
$ pgrep ns-ldapagt
22411
Linux �÷����� ���
- Red Hat Linux Advanced Server������ �⺻ snmpd�� ����ǰ� ���� �ʵ��� �ؾ� �մϴ�. �Ʒ� ���; ����Ͻʽÿ�.
$ pgrep snmpd
�⺻ snmpd�� ���� ���̸� ��= ���; ����Ͽ� �����Ͻʽÿ�.
/etc/rc.d/init.d/snmpd stop
- �⺻ snmpd�� �����Ϸt� ��쿡�� �⺻ snmpd�� ��Ʈ ��ȣ�� �ٲߴϴ�. �̴� �⺻��8�� Directory Server MPS(MAGT) ������ ������Ʈ�� �⺻ snmpd�� ��� ��Ʈ 161; ����ϱ� �����Դϴ�.
��Ʈ ��ȣ�� �ٲٷx� /etc/rc.d/init.d/snmpd���� OPTIONS ���� ��=�� ���� ��d�Ͻʽÿ�.
OPTIONS="-s -l /dev/null -P /var/run/snmpd.pid -a -p 1161" adding -p 1161
�̷��� �ϸ� snmpd ��Ʈ�� 1161�� �ٲ�ϴ�.
- ��=; �����Ͽ� �⺻ snmpd�� �����մϴ�.
/etc/rc.d/init.d/snmpd start
Linux�� SNMP ��� ��Ʈ
Linux���� SNMP�� ������ ���� ��= ����; ����ؾ� �մϴ�.
- Directory Server���� SNMP ������ ����Ǿ� �ִ� ��� Directory Server SNMP ��' ������Ʈ�� ������ ���� �⺻ ��Ʈ 199�� ����մϴ�.
- Directory Server�� �� MAGT(MPS) SNMP ������ ������Ʈ, SNMP ��' ������Ʈ�� ����, ����, �ٽ� �����ϴ� ��ũ��Ʈ�� ����Ϸx� �ڵ� �� 14-1�� �ڵ带 ����Ͻʽÿ�. directorysnmp��� ���� �̸�; ����Ͽ� /etc/init.d�� ��ũ��Ʈ�� ����ʽÿ�.
�ڵ� �� 14-1
SNMP Linux ��ũ��Ʈ directorysnmp#!/bin/sh
DIR=""
BASEDIR=‘/bin/rpm -qa --queryformat ’%{INSTPREFIXES}’ sun-directory\* | head -1‘
[ -r "$BASEDIR/directory-server/5.2/shared/config/serverroot.conf" ] || exit 0
VAR=‘/bin/cat $BASEDIR/directory-server/5.2/shared/config/serverroot.conf‘
for di in $VAR/slapd-*
do
[ -d "$di" ] && DIR="$DIR $di"
done
start() {
[ ! -z "$DIR" ] || exit 0
# Start the Directory Server or Servers
for di in $DIR; do
$di/start-slapd
done
# Start the master agent
cd $VAR/plugins/snmp/magt
./magt ./CONFIG ./INIT >/dev/null 2>&1 &
# Give the master agent a chance to start.
#
loop_counter=1
max_count=10
while [ $loop_counter -le $max_count ]; do
n=‘/usr/bin/pgrep -f magt | /usr/bin/wc -l‘
if [ $n -gt 0 ]; then break; fi
loop_counter=‘expr $loop_counter + 1‘
sleep 1
done
if [ $n -eq 0 ]; then
echo "Directory Server agents not started."
exit 1
fi
# Start the subagent
cd $VAR/bin/slapd/server
for di in $DIR; do
./ns-ldapagt -d $di >/dev/null 2>&1 &
done
}
stop() {
[ ! -z "$DIR" ] || exit 0
# Stop the subagent
for di in $DIR; do
lkfile=${di}/logs/NSLDAPAGT.LK
if [ -r $lkfile ]; then
pid=‘/usr/bin/cut -f 1 -d’ ’ $lkfile‘
kill $pid >/dev/null 2>&1
fi
done
# Stop the master agent
/usr/bin/pkill magt
# Stop the Directory Server
for di in $DIR; do
$di/stop-slapd
done
}
# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
restart)
stop
start
;;
*)
echo $"Usage: $0 {start|stop|restart}"
exit 1
esac
exit 0
cd /etc/rc3.d
ln -s ../init.d/directorysnmp S98directorysnmp
cd /etc/rc5.d
ln -s ../init.d/directorysnmp S98directorysnmp
�̷��� �ϸ� directorysnmp�� ���� ���� 3�� 5(���� ����� ���� ����)���� ��� ����˴ϴ�. X-Windows�� ����ϴ� �ý���(GUI �α���): ���� 5���� ����Ǹ� ���� 3: X-Windows�� ������� �ʴ� �ý���; '�� ���Դϴ�.
Directory Server���� SNMP ��������ϴ� �÷��� SNMP ������Ʈ �Ǵ� ���� ��d�� �Ŀ��� Directory Server �ν��Ͻ��� SNMP �Ű� ���� �����ؾ� �մϴ�. Directory Server �ֿܼ��� SNMP ��d; �����Ϸx� ��=; �����մϴ�.
- Directory Server �ܼ��� �ֻ�' ���� �ǿ� �ִ� ���� Ʈ���� ��Ʈ���� ���� ��带 ������ ��= �8��� �гο��� SNMP ��; �����մϴ�.
- "��� ��= ���" Ȯ�ζ�; �����մϴ�. �ڿ� ���; ����Ű�� '�� �⺻��8�� SNMP ���� ���� ���� ������� �ʽ4ϴ�. SNMP�� ������� ��8�� LDAP�� ���� cn=snmp,cn=monitor ���� �Ӽ�; ��������� �ʴ� ��쿡�� �� Ȯ�ζ�; ���� ��ҵ� ���·� �״�� �ξ�� �մϴ�.
- ������ ������Ʈ�� ȣ��Ʈ �̸��� ��Ʈ ��ȣ�� �ش� �ؽ�Ʈ �ʵ忡 �Է��մϴ�.
�⺻��: ���� localhost�� ��Ʈ 199�Դϴ�.
- ���� ���d�� ������ �ؽ�Ʈ �ʵ忡 d���� �Է��մϴ�. ��=�� ��: ��: �� ����� f���ϴ� SNMP ��ƼƼ ���̺? �ݿ��˴ϴ�.
- ����; ���� ���� ����; �����մϴ�.
- ��= ���� ���? ��� SNMP ������Ʈ�� �����ϰų� �ٽ� �����մϴ�.
SNMP ��' ������Ʈ ���� �� ������= ����� Directory Server �ֿܼ��� SNMP ��' ������Ʈ�� ����, ����� �Ǵ� �����ϴ� ����Դϴ�.
��
������ ȣ��Ʈ���� �ٸ� ���� �ν��Ͻ��� �߰��ϰ� �� �ν��Ͻ��� SNMP ��Ʈ��ũ�� �Ϻΰ� �ǵ��� �Ϸx� SNMP ��' ������Ʈ�� �ٽ� �����ؾ� �մϴ�.
SNMP ��' ������Ʈ�� ����, ���� �� �ٽ� �����Ϸx� ��=; �����մϴ�.
- Directory Server �ܼ��� �ֻ�' ���� �ǿ� �ִ� ���� Ʈ���� ��Ʈ���� ���� ��带 ������ ��= �8��� �гο��� SNMP ��; �����մϴ�.
- ���� ���d�� ���� �Ʒ��� �ִ� ��' ������Ʈ f�� ��ư; ����Ͽ� ��' ������Ʈ�� ����, ���� �Ǵ� �ٽ� �����մϴ�.
���丮�� �����ص� ���丮 ��' ������Ʈ�� ������� �ʽ4ϴ�. ��' ������Ʈ�� �����Ϸx� �� �ǿ��� �����8�� ��d�ؾ� �մϴ�.