반응형

alteon 로드밸런서의 SLB 설정 순서는 다음과 같이 진행한다.
step 0. 설정값 준비
step 1. SLB 활성화하기
step 2. Real Server 설정하기 , health check 반복주기설정하기
step 3.Real Server의 그룹 설정하기, Loadbalancing 알고리즘 포함 
step 4. Virtual Server 설정하기
step 5. Service 설정하기
step 6. 설정 저장 및 적용하기
 
[main menu]

(example)
>> l4switch - Main# /
------------------------------------------------------------
[Main Menu]
     info     - Information Menu
     stats    - Statistics Menu
     cfg      - Configuration Menu
     oper     - Operations Command Menu
     boot     - Boot Options Menu
     maint    - Maintenance Menu
     diff     - Show pending config changes  [global command]
     apply    - Apply pending config changes [global command]
     save     - Save updated config to FLASH [global command]
     revert   - Revert pending or applied changes [global command]
     exit     - Exit  [global command, always available]

>> l4switch - Main#

 
[how to Layer 4 config ]

step 0. 설정값 준비


1) real server A의 정보
- number : 21 (임의로 지정한 번호이다. 주로, IP 주소의 일부값을 사용하면 편리하다)
- IP : 10.1.1.21
2) real server B의 정보
- number : 22 (임의로 지정한 번호이다. 주로, IP 주소의 일부값을 사용하면 편리하다)
- IP : 10.1.1.22
3) server Group number 
- number : 20 (관리를 위해 임의로 지정한 번호이다)
4) virtual server 정보 
- number : 20 (관리를 위해 임의로 지정한 번호이다. Group number와 같은 번호를 사용하면 편리하다)
- ip : 10.1.1.20


step 1. SLB 활성화하기


설정명령
# /cfg/slb/on

Current status: OFF
New status: ON

상태 확인
# /cfg/slb/cur

Current Layer 4 settings:
ON,   direct enabled, matrix enabled, vma sport disabled, grace disabled clrbkp disabled
...


step 2. Real Server 설정하기, health check 반복 주기 설정하기


설정명령(1) Real Server 설정하기
# /cfg/slb/real 21/ena/rip 10.1.1.21

Current status: disabled
New status:     enabled
Current real server IP address:     0.0.0.0
New pending real server IP address: 10.1.1.21


# /cfg/slb/real 22/ena/rip 10.1.1.22

Current status: disabled
New status:     enabled
Current real server IP address:     0.0.0.0
New pending real server IP address: 10.1.1.22
 
 
설정명령(2) health check 반복 주기 설정하기
사용할 메뉴
inter    - Set interval between health checks
retry    - Set number of failed attempts to declare server DOWN
restr    - Set number of successful attempts to declare server UP

# /cfg/slb/real 21/inter 2   (측정 주기를 2초로 설정)

Current interval:     2
New pending interval: 2

# /cfg/slb/real 351/retry 3  (측정 실패시 재시도 반복 횟수를 3회로 설정)

Current number of failure retries:     4
New pending number of failure retries: 3


# /cfg/slb/real 351/restr 2  (측정 실패 후 측정 성공 2회 확인되면 정상 상태로 표시하는 설정)

Current number of successful attempts:     2
New pending number of successful attempts: 2


step 3.Real Server의 그룹 설정하기, Loadbalancing 알고리즘 포함 


설정명령
# /cfg/slb/group 20/add 21/met hash  (그룹 20번에 21번 서버를 포함시키고, LB 알고리즘은 hash를 선택) 

Real server 21 added to real server group 20.
Current metric:         leastconns
New pending metric:     hash

# /cfg/slb/group 20/add 22/met hash  (그룹 20번에 22번 서버를 포함시키고, LB 알고리즘은 hash를 선택) 

Real server 22 added to real server group 20.
Current metric:         leastconns
New pending metric:     hash

 


step 4. Virtual Server 설정하기


설정명령
# /cfg/slb/virt 20/ena

Current status: disabled
New status:     enabled


step 5. Service 설정하기 


설정명령
# /cfg/slb/virt 20/ena/vip 10.1.1.20/service 80 http/group 20

Current status: disabled
New status:     enabled
Current virtual server IP address:     0.0.0.0
New pending virtual server IP address: 10.1.1.20
Current real server group:     1
New pending real server group: 20


step 6. 설정 저장 및 적용하기


설정명령
# /apply
# /save


 
 

반응형
반응형

Alteon Application Switch 설정하기 (2) SSH 설정, Telnet 차단, GUI차단 

* 설정 변경 후 apply/save 잊지 말자 
* Alteon Switch 자체의 보안성 강화를 위한 작업
  - telnet 포트 차단 또는 비표준포트로 변경
  - ssh 표준포트를 비표준포트로 변경하고 sshd 사용 
  - web GUI (http, https) 차단 또는 비표준포트로 변경
  
[hostname설정]
 명령 >> /cfg/sys/hprompt ena
     >> /c/sys/ssnmp
        name "my_loadbalancer"

[SSH 설정]
 - ssh 포트 변경 (22 to 2233)
   명령 >> /cfg/sys/access/sshd/sshport
Current SSH server port: 22
Enter new SSH server port [1-65535]: 2233
New SSH server port: 2233 
 - ssh version 1 을 version 3로 변경
   명령 >> /c/sys/sshd/sshv1 dis

 - enable SSH  : >> /cfg/sys/access/sshd/on 
 - disable SSH : >> /cfg/sys/access/sshd/off 


[Telnet 활성화, 비활성화]
  * OS version 9.0에서 default disable 상태임
 - disable telnet : >> /cfg/sys/tnet dis 
 - enable telnet : >> /cfg/sys/tnet ena
 - change telnet port : >> /cfg/sys/access/tnport
       >> apply/save 
 
 
[GUI http/https 차단]
   명령 >> /cfg/sys/access/http dis
   명령 >> /cfg/sys/access/https dis
   

반응형
반응형

[설정 초기화 작업]

- 최초 설정시 기존 config 및 software를 초기화한다 
 명령: /boot/conf/reset
 후속 옵션 : factory
 후속 옵션 : y
 결과확인 : 리부팅 메시지에서 Software version 확인
        리부팅 완료 후 /cfg/dump 실행하여 config가 모두 삭제되었는지 확인 

 
 작업예시

>> Main# /boot/conf factory/reset
Currently set to use active config block on next boot.
Specify new block to use ["active"/"backup"/"factory"]:  factory
Next boot will use factory default config block instead of active.

Reset will use software "image1" and the factory default config block.
>> Note that this will RESTART the Spanning Tree,
>> which will likely cause an interruption in network service.
Confirm reset [y/n]: y
Resetting at 11:04:22 Mon Apr 10, 2023...

**** System Reset from boot cli ****
INIT: Sending processes the TERM signal
...
Restarting system.
... 
Software Version 27.0.5.0 (FLASH image1), factory default configuration.
...
 

설정 확인
>> Main# /cfg/dump
script start "Alteon Application Switch 4408" 4  /**** DO NOT EDIT THIS LINE!
/* Configuration dump taken 11:07:30 Mon Apr 10, 2023
/* Configuration last applied at 17:44:38 Wed Mar 13, 2019
/* Configuration last save at 17:44:45 Wed Mar 13, 2019
/* Version 27.0.5,  Base MAC address 00:03:b2:9e:a0:40
/
script end  /**** DO NOT EDIT THIS LINE!

>> Configuration#


[관리용 IP 설정]

 - IP Interface 1 에 기본 관리 IP를 설정한다
   새로 설정한 interface는 enable 해준다 

준비한 정보 :
   ip address 192.168.0.165, subnet mask : 255.255.255.224
   broadcast ip : 192.168.0.191, gateway ip : 192.168.0.161
 
명령 : >> /c/ip/if 1
          addr 192.168.0.165
  mask 255.255.255.224
  broad 192.168.0.191
  ena
 
명령 : >> /c/ip/gw 1
          addr 192.168.0.161
  ena 


설정 확인 후 설정 저장
 명령 : >> diff 
        - 기존 config와 변경한 config를 보여준다
 명령 : >> apply/save 
        - 새 config를 확정하고, 저장한다 

  작업예시
 
>> Configuration# /c/ip/if 1
------------------------------------------------------------
[IP Interface 1 Menu]
     ip6nd    - IP6 Neighbor Discovery Menu
     ipver    - Set IP version
     addr     - Set IP address
     mask     - Set subnet mask/prefix len
     vlan     - Set VLAN number
     relay    - Enable/disable BOOTP relay
     ena      - Enable IP interface
     dis      - Disable IP interface
     del      - Delete IP interface
     cur      - Display current interface configuration

>> IP Interface 1# addr 192.168.0.165
Current IP address:     0.0.0.0
New pending IP address: 192.168.0.165
Pending new subnet mask:        255.255.0.0

>> IP Interface 1# mask 255.255.255.224
Current subnet mask:     0.0.0.0
New pending subnet mask: 255.255.255.224

>> IP Interface 1# broad 192.168.0.191

>> IP Interface 1# ena
Current status: disabled
New status:     enabled
 

>> Configuration# /c/ip/gw 1
------------------------------------------------------------
[Default gateway 1 Menu]
     ipver    - Set IP version
     addr     - Set IP address
     intr     - Set interval between ping attempts
     retry    - Set number of failed attempts to declare gateway DOWN
     vlan     - Set VLAN number
     prio     - Set priority of default gateway route
     arp      - Enable/disable ARP only health checks
     ena      - Enable default gateway
     dis      - Disable default gateway
     del      - Delete default gateway
     cur      - Display current default gateway configuration

>> Default gateway 1# addr 192.168.0.161
Current IP address:     0.0.0.0
New pending IP address: 192.168.0.161

>> Default gateway 1# ena
Current status: disabled
New status:     enabled

>> Default gateway 1# apply/save
------------------------------------------------------------------
Apply complete; don't forget to 'save' updated configuration.
Request will first copy the FLASH "active" config to "backup",
 then overlay FLASH "active" with new config.
Confirm saving to FLASH [y/n]: y
New config successfully saved to FLASH.

>> Default gateway 1#

결과확인 
>> Default gateway 1# /c/dump
script start "Alteon Application Switch 4408" 4  /**** DO NOT EDIT THIS LINE!
/* Configuration dump taken 11:14:31 Mon Apr 10, 2023
/* Configuration last applied at 11:14:03 Mon Apr 10, 2023
/* Configuration last save at 11:14:05 Mon Apr 10, 2023
/* Version 27.0.5,  Base MAC address 00:03:b2:9e:a0:40
/c/l3/if 1
        ena
        ipver v4
        addr 192.168.0.165
        mask 255.255.255.224
        broad 192.168.0.191
/c/l3/gw 1
        ena
        ipver v4
        addr 192.168.0.161
/
script end  /**** DO NOT EDIT THIS LINE!

>> Configuration#

반응형

+ Recent posts