안녕하세요. 

 

오늘은 AP를 직접 IP주소랑 Default Gateway를 설정하고 WLC에 Manuall하게 등록해 보겠습니다. 

 

 

테스트 IP주소 입니다. 

AP IP: 192.168.200.200

AP GW: 192.168.200.181

WLC: 192.168.100.182

 

AP주소를 초기에 설정시 아래와 같이 Username/Passowrd는 Cisco 입니다. 

Username: Cisco
Password: Cisco
APC884.A1CC.2F48>en
Password: Cisco
APC884.A1CC.2F48#

 

1. AP에 IP주소랑 Gateway를 설정 합니다. 

capwap ap ip 192.168.200.200 255.255.255.0 192.168.200.181

 

IP주소를 입력하면 CAPWAP discovery 패킷을 Broadcase를 사용 해서 전송 하고 있습니다.

하지만 AP랑 WLC가 같은 L2도메인 안에 없기 때문에, WLC 찾을수 없습니다. 

[*12/24/2024 10:37:43.9513] Check whether client_ip_table entry need to be cleared 0
[*12/24/2024 10:37:43.9613] Clearing client entry
[*12/24/2024 10:37:46.6105] AP IPv4 Address updated from 0.0.0.0 to 192.168.200.200
[*12/24/2024 10:37:46.6305] send CAPWAP ctrl msg to the socket: Socket operation on non-socket
[*12/24/2024 10:37:46.6305] dtls_init: Use MIC certificate
[*12/24/2024 10:37:46.9404] 
[*12/24/2024 10:37:46.9404] CAPWAP State: Init
[*12/24/2024 10:38:02.6655] PNP:Server not reachable, Start CAPWAP Discovery
[*12/24/2024 10:38:02.6855] 
[*12/24/2024 10:38:02.6855] CAPWAP State: Discovery
[*12/24/2024 10:38:02.8954] Discovery Request sent to 255.255.255.255, discovery type UNKNOWN(0)
[*12/24/2024 10:38:02.9054] 
[*12/24/2024 10:38:02.9054] CAPWAP State: Discovery

 

2. AP Hostname를 변경하고 WLC주소를 입력합니다.

APC884.A1CC.2F48#capwap ap hostname AP01
APC884.A1CC.2F48#capwap ap primary-base WLC01 192.168.100.182

 

아래처럼 WLC가 Discovery Response 패킷을 전송하였습니다. 

그리고 Found Confirued WLC01 이후 DTLS setup 시작 합니다. 

[*12/24/2024 10:40:01.2284] CAPWAP State: Discovery
[*12/24/2024 10:40:01.4283] Discovery Request sent to 192.168.100.182, discovery type STATIC_CONFIG(1)
[*12/24/2024 10:40:01.6383] Discovery Request sent to 192.168.100.182, discovery type STATIC_CONFIG(1)
[*12/24/2024 10:40:01.8382] Discovery Request sent to 255.255.255.255, discovery type UNKNOWN(0)
[*12/24/2024 10:40:01.8482] Discovery Response from 192.168.100.182
[*12/24/2024 10:40:01.8482] Found Configured MWAR 'WLC01' (respIdx 0).
[*12/24/2024 10:41:34.0000] Started wait dtls timer (60 sec)
[*12/24/2024 10:41:34.0000] 
[*12/24/2024 10:41:34.0000] CAPWAP State: DTLS Setup
[*12/24/2024 10:41:34.0399] Invalid event 2 & state 3 combination.
[*12/24/2024 10:41:34.0399] CAPWAP SM handler: Failed to process message type 2 state 3.
[*12/24/2024 10:41:34.0399] Failed to handle capwap control message from controller - status 1
[*12/24/2024 10:41:34.0399] Failed to process unencrypted capwap packet 0x2c1ab000 from 192.168.100.182
[*12/24/2024 10:41:34.0399] Failed to send capwap message 0 to the state machine. Packet already freed.
[*12/24/2024 10:41:34.0999] First connect to vWLC, accept vWLC by default
[*12/24/2024 10:41:34.0999] 
[*12/24/2024 10:41:34.1399] dtls_verify_server_cert: vWLC is using SSC, returning 1
[*12/24/2024 10:41:34.2099] 
[*12/24/2024 10:41:34.2099] CAPWAP State: Join
[*12/24/2024 10:41:34.3699] Sending Join request to 192.168.100.182 through port 5248, packet size 1376
[*12/24/2024 10:41:39.0884] Sending Join request to 192.168.100.182 through port 5248, packet size 1376
[*12/24/2024 10:41:39.1784] Join Response from 192.168.100.182, packet size 1397
[*12/24/2024 10:41:39.1784] AC accepted previous sent request with result code: 0
[*12/24/2024 10:41:39.1784] Received wlcType 0, timer 30
[*12/24/2024 10:41:39.2284] nss_capwapmgr_enable_tunnel[1682]:ef30c000: tunnel 0 is already enabled
[*12/24/2024 10:41:39.3183] 
[*12/24/2024 10:41:39.3183] CAPWAP State: Image Data
[*12/24/2024 10:41:39.3183] AP image version 17.13.0.107 backup 17.8.0.144, Controller 17.13.0.107
[*12/24/2024 10:41:39.3183] Version is the same, do not need update.
[*12/24/2024 10:41:39.3883] status 'upgrade.sh: Script called with args:[NO_UPGRADE]'
[*12/24/2024 10:41:39.4383] do NO_UPGRADE, part2 is active part
[*12/24/2024 10:41:39.4483] 
[*12/24/2024 10:41:39.4483] CAPWAP State: Configure
[*12/24/2024 10:41:39.6682] Radio [2] Administrative state DISABLED  change to ENABLED 
[*12/24/2024 10:41:39.6782] Radio [1] Administrative state DISABLED  change to ENABLED 
[*12/24/2024 10:41:39.6782] Radio [0] Administrative state DISABLED  change to ENABLED 
[*12/24/2024 10:41:39.6782] DOT11_CFG[1]: Starting radio 1
[*12/24/2024 10:41:39.6782] DOT11_DRV[1]: Start Radio1 - Begin
[*12/24/2024 10:41:39.6782] DOT11_DRV[1]: Start Radio1 - End
[*12/24/2024 10:41:39.6782] DOT11_CFG[0]: Starting radio 0
[*12/24/2024 10:41:39.6782] DOT11_DRV[0]: Start Radio0 - Begin
[*12/24/2024 10:41:39.6882] DOT11_DRV[0]: Start Radio0 - End
[*12/24/2024 10:41:40.1481] Radio Authority: no country code
[*12/24/2024 10:41:40.1581] Cannot open CDUMP_COUNT!
[*12/24/2024 10:41:40.2680] 
[*12/24/2024 10:41:40.2680] CAPWAP State: Run
[*12/24/2024 10:41:40.3480] AP has joined controller WLC01
[*12/24/2024 10:41:40.3980] Previous AP mode is 0, change to 2
[*12/24/2024 10:41:40.4080] DOT11_CFG[0] Radio Mode is changed from Local to FlexConnect
[*12/24/2024 10:41:40.4280] DOT11_DRV[0]: Stop Radio0 - Begin
[*12/24/2024 10:41:40.4380] DOT11_DRV[0]: Stop Radio0 - End
[*12/24/2024 10:41:40.4380] DOT11_CFG[0]: Starting radio 0
[*12/24/2024 10:41:40.4380] DOT11_DRV[0]: Start Radio0 - Begin
[*12/24/2024 10:41:40.4380] DOT11_DRV[0]: Start Radio0 - End
[*12/24/2024 10:41:40.4380] DOT11_CFG[1] Radio Mode is changed from Local to FlexConnect
[*12/24/2024 10:41:40.4480] DOT11_DRV[1]: Stop Radio1 - Begin
[*12/24/2024 10:41:40.4480] DOT11_DRV[1]: Stop Radio1 - End
[*12/24/2024 10:41:40.4480] DOT11_CFG[1]: Starting radio 1
[*12/24/2024 10:41:40.4480] DOT11_DRV[1]: Start Radio1 - Begin
[*12/24/2024 10:41:40.4480] DOT11_DRV[1]: Start Radio1 - End
[*12/24/2024 10:41:40.5779] DOT11_DRV[0]: Stop Radio0 - Begin
[*12/24/2024 10:41:40.5779] DOT11_DRV[0]: Stop Radio0 - End
[*12/24/2024 10:41:40.5779] DOT11_DRV[0]: Start Radio0 - Begin
[*12/24/2024 10:41:40.5879] DOT11_DRV[0]: Start Radio0 - End
[*12/24/2024 10:41:41.1178] syslog level is being set to 70
[*12/24/2024 10:41:41.1178] 
[*12/24/2024 10:41:41.1578] Previous AP mode is 2, change to 2
[*12/24/2024 10:41:41.1678] Current session mode: ssh, Configured: Telnet-No, SSH-No, Console-Yes
[*12/24/2024 10:41:41.1678] 
[*12/24/2024 10:41:41.3977] Current session mode: telnet, Configured: Telnet-No, SSH-No, Console-Yes
[*12/24/2024 10:41:41.3977] 
[*12/24/2024 10:41:41.4177] Current session mode: console, Configured: Telnet-No, SSH-No, Console-Yes
[*12/24/2024 10:41:41.4177] 
[*12/24/2024 10:41:41.4777] chpasswd: password for user changed
[*12/24/2024 10:41:41.4977] USB Device Disconnected from the AP
[*12/24/2024 10:41:41.5376] chpasswd: password for user changed
[*12/24/2024 10:41:41.7176] 
[*12/24/2024 10:41:41.7176] Same LSC mode, no action needed
[*12/24/2024 10:41:41.7176] Cannot open CDUMP_COUNT!
[*12/24/2024 10:41:41.8975] Same value is already set.
[*12/24/2024 10:41:42.3374] Got WSA Server config TLVs
[*12/24/2024 10:41:43.6270] Socket: Valid Element: wcp/wcp_db Handler: set_vlan_name_map Data: null Length: 10
[*12/24/2024 10:41:45.3265] SD AVC only supports 802.11ax AP
[*12/24/2024 10:41:45.8563] AP tag  change to default-policy-tag
[*12/24/2024 10:42:08.7391] netlink socket init done, pnl->spectral_fd=4
[*12/24/2024 10:42:08.7391] CLEANAIR: Slot 0 admin disabled
[*12/24/2024 10:42:10.7385] CLEANAIR: Slot 1 admin disabled

AP01#[*12/24/2024 10:42:36.8903] Warning: Stopping dbg_day0_bundle.service, but it can still be activated by:
[*12/24/2024 10:42:36.8903]   dbg_day0_bundle.timer

AP01#

 

3. 이번에는 WLC GUI에 접속해서 AP를 확인해보겠습니다.

Monitoring ->Wireless ->AP statistics 클릭 합니다. 

 

아래 사진처럼 AP01이 WLC에 등록이 되었고 Admin Status를 표시면 초록색으로 정상적입니다. 

 

테스트를 위해서 WLC GUI에서 AP를 Reset 합니다.

 

AP를 더블클릭 합니다. 

 

 

 

지금까지 [C9800CL][#3]-AP Join Process - Manual Method 글을 읽어주셔서 감사합니다.

다음글은 DHCP option43를 이용해서 AP를 WLC에 등록 하는 글을 다루겠습니다.

 

안녕하세요.

 

오늘은 AP가 WLC에 등록할때 AP입장에서 패킷이 어떻게 진행되는지 알아보겠습니다.

 

시스코 공식 홈페이지에 나와 있는지 문서 입니다.

https://www.cisco.com/c/en/us/support/docs/wireless/catalyst-9120axe-access-point/221056-understand-the-ap-join-process-with-the.html

 

Understand the AP Join Process with the Catalyst 9800 WLC

This document describes in detail the AP Join Process with the Cisco Catalyst 9800 WLC.

www.cisco.com

 

만약에 WLC에 다른 지역에 있는 상황이라면
Note
: As per RFC 5415, CAPWAP uses the UDP Ports 5246 (for CAPWAP Control) and 5247 (for CAPWAP Data).

위에 포트는 방화벽에서 허용 되어야 합니다.

 

Session Establishment Process.

  1. Access Point sends a Discovery Request. See the WLC Discovery Methods section for more information on this
  2. WLC sends a Discovery Response
  3. DTLS session establishment. After this, all messages after this are encrypted and are shown as DTLS application data packets in any packet analysis tool.
  4. Access Point sends a Join Request
  5. WLC sends a Join Response
  6. AP performs an image check. If it has the same image version as the WLC, then it proceeds with the next step. If it does not, then it downloads the image from the WLC and reboots to load the new image. In such case, it repeats the process from step 1.
  7. Access Point sends a Configuration Status Request.
  8. WLC sends a Configuration Status Response
  9. Access Point goes to RUN State
  10. During the RUN state, CAPWAP Tunnel Maintenance is pefrormed in two ways:
    1. Keepalives are exchanged to mantain the CAPWAP Data tunnel
    2. AP sends an Echo Request to the WLC, which has to be answered with its respective Echo Response. This is to mantain the CAPWAP Control tunnel.

 

Wireless LAN Controller Discovery Methods

There are several options to let the Access Points know of the existance of one WLC in the network:

  • DHCP Option 43: This option provides the APs the IPv4 address of the WLC to join. This process is convenient for large deployments in which the APs and the WLC are in different sites.
  • DNS Discovery: APs queries the domain name CISCO-CAPWAP-CONTROLLER.localdomain. You must configure your DNS server to resolve either the IPv4 or IPv6 address of the WLC tto join. This option is convenient for deployments in which the WLCs are stored in the same site as the APs.
  • Layer 3 Broadcast: The APs automatically send a broadcast message to 255.255.255.255. Any WLC within the same subnet as the AP is expected to respond to this discovery request.
  • Static configuration: You can use the capwap ap primary-base <wlc-hostname> <wlc-IP-address> command to configure a static entry for a WLC in the AP.
  • Mobility Discovery: If the AP was previously joined to a WLC that was part of a mobility group, the AP also saves a record of the WLCs present in that mobility group.

 

저희는 위에 방식중에 2가지를 테스트 해보겠습니다.

 

1. Static Configuration - AP에서 IP주소랑 Default Gateway를 설정하고 수동으로 WLC IP주소를 입력해서 WLC에 AP를 등록하겠습니다.

 

2. DHCP option 43 - DHCP를 이용해서 AP에 IP주소랑 Default Gateway를 할당하고 WLC주소도 같이 할당하여 AP를 WLC에 등록하겠습니다.

 

테스트는 다음 과정에서 진행 하겠습니다. 

 

안녕하세요.

 

오늘은 Fortigate Explicit Proxy를  UTM기능, SSL deep inspection 같이 사용해보겠습니다.

 

https://itblog-kr.tistory.com/107

 

[Fortigate-#17]- Explicit Proxy

안녕하세요. 오늘은 Fortigate를 Explicit Proxy 설정에 대해서 알아보겠습니다. Forti Proxy 없이 Fortigate를 이용해서 Proxy 구성이 가능 합니다. 하지만 제한적인 기능만 가능합니다.  Explicit Proxy는 User

itblog-kr.tistory.com

 

실습을 하기전에 이전 글을 꼭 확인 부탁드립니다.

 

현재 테스트 가능한 방화벽에서 UTM라이센스를 확인한 결과 아래와 같이 AntiVirus와 Web Filtering를 사용 할수 있습니다. 

 

이 기능만 Enable 하겠습니다. 그리고 대부분에 Traffic이 https로 통신하기 때문에, Fortigate이 SSL를 복호화 해서 패킷을 확인 해야 하기 떄문에 SSL inspection를 deep inspection으로 설정 해야 합니다.

 

1.  Proxy Policy Rule를 더블 클릭 합니다. 

 

2. 아래처럼 설정합니다.

 

3. PC에서 youtube를 접속합니다.

SSL deep inspection를 선택하면 방화벽이 SSL proxy처럼 동작하기 때문에,  certificate issued by 보면 fortigate으로 되어져 있습니다. 

 

이 부분을 해결하기 위해서 Certificate를 설치 합니다. 

4. 방화벽에서 Feature Visibility -> Certificates를 Enable합니다. 

 

System -> Certificates -> Local Certificate -> Fortinet_CA_SSL 를 다운로드 받습니다. 

 

5. Certificate를 PC에 다운로드 하고 설치 합니다. 

 

 

 

 

User PC에서 다시 Youtube를 접속합니다.

 

지금까지 글을 읽어주셔서 감사합니다.

[Fortigate-#18]- Explicit Proxy with UTM function

안녕하세요.

 

오늘은 Fortigate를 Explicit Proxy 설정에 대해서 알아보겠습니다.

 

Forti Proxy 없이 Fortigate를 이용해서 Proxy 구성이 가능 합니다. 

하지만 제한적인 기능만 가능합니다. 

 

Explicit Proxy는 User PC에 Proxy 설정이 되어야지 인터넷 사용이 가능 합니다.

Transperant Proxy는 User PC proxy 설정없이 자동으로 http/https traffic를 redirect to proxy해서 정책 적용 가능 합니다. 

 

지금부터 Fortigate Explicit Proxy 설정에 하겠습니다.

 

FortiGate

WAN: 202.14.X.X

LAN: 192.168.10.181/24

 

PC: 192.168.10.106

GW: 192.168.10.181

 

1. Explicit 기능을 활성화 합니다.

 

2. 실제로 traffic이 fortigate 들어오는 Interface - internal에서 Explicit web proxy를 Enable 합니다.

 

3. Explicit Proxy 설정합니다.

 

4. Proxy Policy 설정합니다. 

 

 

UTM기능을 함깨 사용 할수 있습니다.  보안을 제대로 설정하기 위해서는 SSL inspection를 deep inspection으로 수정하고, Certificate를 PC에 설정한 후에 UTM기능을 사용 하여 보안을 강화 할수 있습니다. 

 

이 부분은 다음장에서 설명 하겠습니다. 

 

5. PC에서 Proxy를 설정합니다. 

 

5-1 open network & Internet setting 

5-2 왼쪽에 proxy를 선택 합니다. 

 

아래처럼 설정 합니다. 

 

PC IP: 192.168.10.106

GW: 192.168.10.181 

Proxy ip: 192.168.10.181

 

Booking.com접속 합니다.

아래 wireshark로 https 패킷을 보면, https 패킷이 Proxy로 전달되는 것을 볼수 있습니다.

 

6. Fortigate에서 Hit count 확인하기

 

Log확인하기

 

Forti View로 확인하기

 

 

지금까지 [Fortigate-#17]- Explicit Proxy 글을 읽어주셔서 감사합니다. 

안녕하세요.

 

이번에는 admin account말고 다른 user account를 생성해서 phpIPAM URL를 접속해보겠습니다. 

 

1. Password Policy를 클릭 합니다. 

 

아래처럼 Password Policy를 수정 하여 규칙이 어긋하면 user account 생성이 불가능 합니다. 

2. Users를 클릭 합니다. 

 

3. Create User를 클릭 합니다. 

 

4. user account를 생성 합니다. 

 

kevin account가 생성 되었습니다.

 

show user를 클릭하면 정보를 확인 할 수 있습니다.

 

 

 

admin계정을 logoff하고 kevin 계정으로 로그인 합니다. 

 

정상적으로 로그인 되었습니다. 

 

지금까지 [phpIPAM][#8]- User 생성 글을 읽어주셔서 감사합니다. 

'IPAM Tools > phpIPAM' 카테고리의 다른 글

[phpIPAM][#8]- IP scan  (0) 2025.01.08
[phpIPAM][#7]- basic administration Setting  (0) 2024.12.22
[phpIPAM][#6]-fping and snmp install for scan  (0) 2024.12.22
[phpIPAM][#5]-phpIPAM install  (1) 2024.12.22
[phpIPAM][#4]-ssh server install  (0) 2024.12.22

안녕하세요.

 

오늘은 phpIPAM에 administration page에 대해서 알아보겠습니다.

 

Site title: KEVIN'S IPPAM 

Pretify links: Yes로 변경 

Default Lanuage: 

Default Theme: 배경을 Black또는 White를 선택 할수 있습니다. 

나머지는 디폴트를 선택 합니다. 

 

Enable FirewallZones

Enable Resolve DNS name

Enable SNMP module

 

나머지는 디폴트로 두고 저장합니다. 

 

kevin@kevin-virtual-machine:/etc/apache2$ cd /bin
kevin@kevin-virtual-machine:/bin$ find fping
fping

kevin@kevin-virtual-machine:/bin$ find ping
ping

 

위에 경로에서 ping과 fping를 찾을수 있습니다. 

 

Title이 KEVIN'S IPPAM 변경되었습니다. 

 

 

'IPAM Tools > phpIPAM' 카테고리의 다른 글

[phpIPAM][#8]- IP scan  (0) 2025.01.08
[phpIPAM][#8]- User 생성  (0) 2024.12.22
[phpIPAM][#6]-fping and snmp install for scan  (0) 2024.12.22
[phpIPAM][#5]-phpIPAM install  (1) 2024.12.22
[phpIPAM][#4]-ssh server install  (0) 2024.12.22

안녕하세요.

 

phpIPAM에서 ip subnet 기반으로 End Device를 scan할수 있습니다.

phpIPAM은 다른 기능으로도 End Device를 scan 할수 있습니다.

 

Discovery scans

1. Ping scan

2. Telent scan

3. SNMP nested subnets scan

4. SNMP ARP scan

5. SNMP MAC address scan

 

관련 기능들을 추가적으로 사용 하기위에서는 fping , snmp등이 설치가 되어야 합니다.

sudo apt-get install fping
sudo apt-get install php-snmp

 

설치 과정 입니다. 

kevin@kevin-virtual-machine:~$ sudo apt-get install fping
[sudo] password for kevin: 
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following NEW packages will be installed:
  fping
0 upgraded, 1 newly installed, 0 to remove and 3 not upgraded.
Need to get 32,0 kB of archives.
After this operation, 90,1 kB of additional disk space will be used.
Get:1 http://id.archive.ubuntu.com/ubuntu jammy/universe amd64 fping amd64 5.1-1 [32,0 kB]
Fetched 32,0 kB in 0s (201 kB/s) 
Selecting previously unselected package fping.
(Reading database ... 171483 files and directories currently installed.)
Preparing to unpack .../archives/fping_5.1-1_amd64.deb ...
Unpacking fping (5.1-1) ...
Setting up fping (5.1-1) ...
Processing triggers for man-db (2.10.2-1) ...
kevin@kevin-virtual-machine:~$ sudo apt-get install php-snmp
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
  php8.1-snmp snmp
The following NEW packages will be installed:
  php-snmp php8.1-snmp snmp
0 upgraded, 3 newly installed, 0 to remove and 3 not upgraded.
Need to get 201 kB of archives.
After this operation, 810 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://id.archive.ubuntu.com/ubuntu jammy-updates/main amd64 php8.1-snmp amd64 8.1.2-1ubuntu2.20 [23,2 kB]
Get:2 http://id.archive.ubuntu.com/ubuntu jammy/main amd64 php-snmp all 2:8.1+92ubuntu1 [1.836 B]
Get:3 http://id.archive.ubuntu.com/ubuntu jammy-updates/main amd64 snmp amd64 5.9.1+dfsg-1ubuntu2.6 [176 kB]
Fetched 201 kB in 0s (689 kB/s)
Selecting previously unselected package php8.1-snmp.
(Reading database ... 171493 files and directories currently installed.)
Preparing to unpack .../php8.1-snmp_8.1.2-1ubuntu2.20_amd64.deb ...
Unpacking php8.1-snmp (8.1.2-1ubuntu2.20) ...
Selecting previously unselected package php-snmp.
Preparing to unpack .../php-snmp_2%3a8.1+92ubuntu1_all.deb ...
Unpacking php-snmp (2:8.1+92ubuntu1) ...
Selecting previously unselected package snmp.
Preparing to unpack .../snmp_5.9.1+dfsg-1ubuntu2.6_amd64.deb ...
Unpacking snmp (5.9.1+dfsg-1ubuntu2.6) ...
Setting up php8.1-snmp (8.1.2-1ubuntu2.20) ...

Creating config file /etc/php/8.1/mods-available/snmp.ini with new version
Setting up snmp (5.9.1+dfsg-1ubuntu2.6) ...
Setting up php-snmp (2:8.1+92ubuntu1) ...
Processing triggers for man-db (2.10.2-1) ...
Processing triggers for libapache2-mod-php8.1 (8.1.2-1ubuntu2.20) ...
Processing triggers for php8.1-cli (8.1.2-1ubuntu2.20) ...

 

그리고 /etc/apache2/apache2.conf 파일에 수정이 필요합니다.

 

vi /etc/apache2/apache2.conf

 

아래처럼 추가합니다.

<Directory /var/www/html>
        Options Indexes FollowSymLinks
        AllowOverride all
        order allow,deny
        Allow from all
        #Require all granted
</Directory>

 

apache를 새로 시작 합니다

sudo systemctl restart apache2

 

지금까지 [phpIPAM][#6]-fping and snmp install for scan 글을 읽어주셔서 감사합니다.

'IPAM Tools > phpIPAM' 카테고리의 다른 글

[phpIPAM][#8]- User 생성  (0) 2024.12.22
[phpIPAM][#7]- basic administration Setting  (0) 2024.12.22
[phpIPAM][#5]-phpIPAM install  (1) 2024.12.22
[phpIPAM][#4]-ssh server install  (0) 2024.12.22
[phpIPAM][#3]-Ubuntu update and upgrade  (1) 2024.12.22

안녕하세요.

 

오늘은 phpIPAM를 설치해보겠습니다. 

 

1. PC에서 putty 또는 crt를 사용해서 ubuntu 서버에 접속합니다. 

 

2. 필요한 utility를 설치 합니다. 

sudo apt install curl wget zip git -y

 

3. Apache httpd랑 mysql를 설치 합니다.

 sudo apt install apache2 mariadb-server mariadb-client -y

 

4. PHP Components를 설치 합니다.

sudo apt install php php-curl php-common php-gmp php-mbstring php-gd php-xml php-mysql php-ldap php-pear -y

 

5. MySQL Database를 설치 합니다

sudo su
mysql_secure_installation


 

 Press Enter to login as root - password를 입력 합니다. 
 Type N and press Enter to not switch to unix socket authentication
 Type Y and press Enter to set a root password, type the password twice to confirm
 Type Y and press Enter to remove anonymous users
 Type Y and press Enter to disallow root login remotely
 Type Y and press Enter to remove the test database
 Type Y and press Enter to reload privilege tables

 

아래는 결과값 입니다. 

kevin@kevin-virtual-machine:~$ sudo su
root@kevin-virtual-machine:/home/kevin# mysql_secure_installation

NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
      SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!

In order to log into MariaDB to secure it, we'll need the current
password for the root user. If you've just installed MariaDB, and
haven't set the root password yet, you should just press enter here.

Enter current password for root (enter for none): 
OK, successfully used password, moving on...

Setting the root password or using the unix_socket ensures that nobody
can log into the MariaDB root user without the proper authorisation.

You already have your root account protected, so you can safely answer 'n'.

Switch to unix_socket authentication [Y/n] n
 ... skipping.

You already have your root account protected, so you can safely answer 'n'.

Change the root password? [Y/n] 
New password: 
Re-enter new password: 
Sorry, passwords do not match.

New password: 
Re-enter new password: 
Password updated successfully!
Reloading privilege tables..
 ... Success!


By default, a MariaDB installation has an anonymous user, allowing anyone
to log into MariaDB without having to have a user account created for
them.  This is intended only for testing, and to make the installation
go a bit smoother.  You should remove them before moving into a
production environment.

Remove anonymous users? [Y/n] y
 ... Success!

Normally, root should only be allowed to connect from 'localhost'.  This
ensures that someone cannot guess at the root password from the network.

Disallow root login remotely? [Y/n] y
 ... Success!

By default, MariaDB comes with a database named 'test' that anyone can
access.  This is also intended only for testing, and should be removed
before moving into a production environment.

Remove test database and access to it? [Y/n] y
 - Dropping test database...
 ... Success!
 - Removing privileges on test database...
 ... Success!

Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.

Reload privilege tables now? [Y/n] y
 ... Success!

Cleaning up...

All done!  If you've completed all of the above steps, your MariaDB
installation should now be secure.

Thanks for using MariaDB!
root@kevin-virtual-machine:/home/kevin# 

 

6. MySQL Table를 생성합니다.

mysql -u root -p

   CREATE DATABASE php_ipam;
   GRANT ALL ON php_ipam.* to 'php_ipam_rw'@'localhost' IDENTIFIED BY 'P4P1p@m!!';
   FLUSH PRIVILEGES;
   EXIT;
   exit

 

아래는 결과값입니다. 패스워드를 위와 같이 사용 하겠습니다. 

root@kevin-virtual-machine:/home/kevin# 
mysql -u root -p
Enter password: 
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 39
Server version: 10.6.18-MariaDB-0ubuntu0.22.04.1 Ubuntu 22.04

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]>    CREATE DATABASE php_ipam;
Query OK, 1 row affected (0,001 sec)

MariaDB [(none)]>    GRANT ALL ON php_ipam.* to 'php_ipam_rw'@'localhost' IDENTIFIED BY 'P4P1p@m!!';
Query OK, 0 rows affected (0,002 sec)

MariaDB [(none)]>    FLUSH PRIVILEGES;
Query OK, 0 rows affected (0,001 sec)

MariaDB [(none)]>    EXIT;
Bye
root@kevin-virtual-machine:/home/kevin#    exit~
exit~: command not found

 

7. 나머지 설정을 하겠습니다.

 

git를 사용해서 phpipam를 다운로드 받습니다.

sudo git clone https://github.com/phpipam/phpipam.git /var/www/html/phpipam

 

root@kevin-virtual-machine:/home/kevin# sudo git clone https://github.com/phpipam/phpipam.git /var/www/html/phpipam
Cloning into '/var/www/html/phpipam'...
remote: Enumerating objects: 35088, done.
remote: Counting objects: 100% (1427/1427), done.
remote: Compressing objects: 100% (425/425), done.
remote: Total 35088 (delta 1243), reused 1002 (delta 1002), pack-reused 33661 (from 3)
Receiving objects: 100% (35088/35088), 28.16 MiB | 1.12 MiB/s, done.
Resolving deltas: 100% (25403/25403), done.
root@kevin-virtual-machine:/home/kevin#

 

8. /var/www/html/phpipam 폴더에 이동합니다.

cd /var/www/html/phpipam

 

9. 최신버전을 확인합니다.

sudo git checkout "$(git tag --sort=v:tag | tail -n1)"

 

아래는 결과값입니다.

root@kevin-virtual-machine:/var/www/html/phpipam# sudo git checkout "$(git tag --sort=v:tag | tail -n1)"
Note: switching to 'v1.7.3'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

HEAD is now at 602d8122 Bugfix: PDNS PHP8 compatibility cleanup. Fixes #4337
root@kevin-virtual-machine:/var/www/html/phpipam# 

 

10. phpipam 폴더 onwer를 설정 합니다.

 sudo chown -R www-data:www-data /var/www/html/phpipam

 

11. sample config file를 복사합니다

sudo cp /var/www/html/phpipam/config.dist.php /var/www/html/phpipam/config.php

 

12. config.php 파일을 수정하기 위해서 vim를 설치 합니다

sudo apt-get install vim

 

13. config.php 파일을 수정합니다. 

sudo vim /var/www/html/phpipam/config.php

 

아래처럼 주석처리 하고 새로운 설정값을 생성하고 저장합니다. 

#$db['host'] = '127.0.0.1';
#$db['user'] = 'phpipam';
#$db['pass'] = 'phpipamadmin';
#$db['name'] = 'phpipam';
#$db['port'] = 3306;

         $db['host'] = '127.0.0.1';
         $db['user'] = 'php_ipam_rw';
         $db['pass'] = 'P4P1p@m!!';
         $db['name'] = 'php_ipam';
         $db['port'] = 3306;

         define('BASE', "/phpipam/");

 

 

14. 서비스를 시작 합니다.

sudo a2enmod rewrite
sudo systemctl restart apache2

 

15. 이제 실제로 phpIPAM를 설치 하기 위해서 아래처럼 입력합니다

http://192.168.10.117/phpipam

 

 

 

 

admin페이지 password를 입력합니다.

 

 

 

안녕하세요.

 

이번에는 PC에서 ubuntu server에 SSH로 접속하기 위해서 ubuntu server에 ssh server를 설치 합니다.

 

1. 아래처럼 openssh-server를 설치 합니다. 

sudo apt-get install openssh-server

 

2. SSH Server를 시작 합니다. 

sudo systemctl start ssh

 

3. 서버가 다시 재부팅되더라도 자동으로 SSH 서비스가 시작 될수 있게 설정 합니다. 

sudo systemctl enable ssh

 

 

5. PC에서 CRT또는 PUTTY를 사용해서 ubuntu 서버에 접속을 시도 합니다. 

 

 

 

지금까지 [phpIPAM][#4]-ssh server install 글을 읽어주셔서 감사합니다. 

'IPAM Tools > phpIPAM' 카테고리의 다른 글

[phpIPAM][#6]-fping and snmp install for scan  (0) 2024.12.22
[phpIPAM][#5]-phpIPAM install  (1) 2024.12.22
[phpIPAM][#3]-Ubuntu update and upgrade  (1) 2024.12.22
[phpIPAM][#2]-Ubuntu 22.04.5 install  (0) 2024.12.22
[phpIPAM][#1]-phpIPAM  (0) 2024.12.22

안녕하세요.

 

저번에는 Ubuntu 22.04.05 LTS 버전을 설치 하였습니다.

package가 최신 버전이 아니기때문에, phpIPAM를 설치 하기전에 ubuntu update & upgrade를 합니다. 

 

1. ubuntu 업데이트 합니다. 

 

아래 처럼 입력하면 밑에 사진처럼 업데이트 package를 다운로드 합니다.

sudo apt-get update

 

2, 아래 사진처럼 y를 입력해서 upgrade합니다. 

sudo apt-get upgrade

 

설치가 완료되었습니다. 

 

지금까지 [phpIPAM][#3]-Ubuntu update and upgrade 글을 읽어주셔서 감사합니다. 

'IPAM Tools > phpIPAM' 카테고리의 다른 글

[phpIPAM][#6]-fping and snmp install for scan  (0) 2024.12.22
[phpIPAM][#5]-phpIPAM install  (1) 2024.12.22
[phpIPAM][#4]-ssh server install  (0) 2024.12.22
[phpIPAM][#2]-Ubuntu 22.04.5 install  (0) 2024.12.22
[phpIPAM][#1]-phpIPAM  (0) 2024.12.22

+ Recent posts