Hiển thị các bài đăng có nhãn Net Solutions. Hiển thị tất cả bài đăng
Hiển thị các bài đăng có nhãn Net Solutions. Hiển thị tất cả bài đăng
Chuyển đổi Domain Controller

Chuyển đổi Domain Controller

Chuyển đổi Domain Controller sang máy khác

Giới thiệu: Mặc dù W2k/W2k3 hỗ trợ Multi Master (các DC hoạt động song song nhau, không phân biệt chính/phụ ). Tuy nhiên vẫn còn một số chức năng hoạt động ở chế độ Single Master, cụ thể là:
1. Schema Master: Quản lý schema, mỗi forest có 1 cái
2. Domain Naming: Quản lý danh sách các domain, mỗi forest có 1 cái
3. PDC: Giả lập server NT để chứng thực cho các WS đồi cũ (win9x), mỗi domain có 1 cái
4. RID: cấp số ID cho user, mỗi domain có 1 cái
5. Infrastructer: Quản lý danh sách user ở domain khác tham dự vào các nhóm của domain hiện tại., mỗi domain có 1 cái

Mô hình: Có 2PC là Domain Controller đang hoạt động song song nhau. Do nhu cầu thay đổi Hardware, hay một lý do nào đó, chúng ta muốn chuyển Domain Controller từ PDC sang SDC.
+ Mặc định các chức năng do DC1 nắm giữ. Khi DC1 chết thì những thao tác liên quan đến 5 chức năng này sẽ không thực hiện được.
+ Trong mô hình này thì Dc1 chưa chết.

Các bước thực hiện như sau:
Bước 1: Hoàn thành các bước làm trong bài viết này http://tuyenninhduan.blogspot.com/2007/11/thit-lp-hai-server-chy-song-song-phn-i.html

Bước 2:

Register Schmmgmt.dll

1. Click Start --> Run.
2. Type regsvr32 schmmgmt.dll --> click OK.
3. --> Click OK when you receive the message that the operation succeeded.

Transfer the Schema Master Role

1. Click Start --> Run, type mmc --> OK.
2. On the File, menu click Add/Remove Snap-in.
3. Click Add.
4. Click Active Directory Schema, click Add, click Close, and then click OK.
5. In the console tree, right-click Active Directory Schema, and then click Change Domain Controller.
6. Click Specify Name, type the name of the domain controller that will be the new role holder, (Nhập vào tên máy DC mà sẽ nắm giữ Domain Controller) --> OK.
7. In the console tree, right-click Active Directory Schema, and then click Operations Master.
8. Click Change.
9. Click OK to confirm that you want to transfer the role, and then click Close.

Transfer the Domain Naming Master Role

1. Click Start, point to Administrative Tools, and then click Active Directory Domains and Trusts.
2. Right-click Active Directory Domains and Trusts, and then click Connect to Domain Controller.
3. Do one of the following:
* In the Enter the name of another domain controller box, type the name of the domain controller that will be the new role holder, and then click OK.

-or-
* In the Or, select an available domain controller list, click the domain controller that will be the new role holder, and then click OK.
4. In the console tree, right-click Active Directory Domains and Trusts, and then click Operations Master.
5. Click Change.
6. Click OK to confirm that you want to transfer the role, and then click Close.

Transfer the RID Master, PDC Emulator, and Infrastructure Master Roles

1. Click Start, point to Administrative Tools, and then click Active Directory Users and Computers.
2. Right-click Active Directory Users and Computers, and then click Connect to Domain Controller.
3. Do one of the following:
* In the Enter the name of another domain controller box, type the name of the domain controller that will be the new role holder, and then click OK.

-or-
* In the Or, select an available domain controller list, click the domain controller that will be the new role holder, and then click OK.
4. In the console tree, right-click Active Directory Users and Computers, point to All Tasks, and then click Operations Master.
5. Click the appropriate tab for the role that you want to transfer (RID, PDC, or Infrastructure), and then click Change.
6. Click OK to confirm that you want to transfer the role, and then click Close.

Link: http://support.microsoft.com/default.aspx?scid=kb;EN-US;324801

Config VPN on One NIC (2k3)

Config VPN on One NIC (2k3)
(Phần 1: Basic)
Hiện trạng Server cấu hình VPN
  • Server 2k3.
  • Active Directory
  • DHCP Server
  • DNS Server

Các bước thực hiện:

    • Server name: TDSER01
    • IP Address: 192.168.1.7/24

Start --> Administrative Tools --> Routing and Remote Access.

Next ở hộp thoại đầu tiên --> Custom Configuration --> Next --> Check vào VPN access + LAN routing. --> Next --> Finish --> Chọn Yes để start service RRAS.

Giao diện đầu tiên:

R-Click TDSER01 --> Properties --> chọn tab IP --> Chọn option Static address Pool --> Add --> nhập vào địa dãi địa chỉ IP sẽ cấp phát cho client khi VPN.

R-click vào Port để hiệu chĩnh các thông số cần thiết.

Edit các lựa chọn sau đây
WAN Miniport (PPTP) --> chỉnh thông số Maximum = 5. --> Chỉ cho phép 5 kết, sử dụng giao thức chứng thực là PPTP.

WAN Miniport (L2TP) --> chỉnh thông số Maximum = 5. --> Chỉ cho phép 5 kết, sử dụng giao thức chứng thực là L2TP.

Cài Đặt Windows Qua Mạng (RIS)

Cài đặt window qua mạng (RIS)
Phần I: Cài Đặt RIS server

Nguồn:
Training Kit 70 – 270
http://support.microsoft.com/kb/325862

Các bước cấu hình:
Cài Window 2003 Server RIS
Tạo Image lưu trên server
Tạo file answer
Authorize RIS trong Active Directory
Phân quyền USER để dùng RIS cài window

Môi trường làm việc - Cấu hình phần cứng và phần mềm:
Máy server: Sử dụng window 2003 server, phải cấu hình các dịch vụ mạng sau:
Domain Name System (DNS Service)
Dynamic Host Configuration Protocol (DHCP)
Active Directory "Directory" service
Máy client: Phải có đĩa mềm hay card mạng có thể boot được.

1.Cài Window 2003 Server RIS
Start -> Control Panel -> Add or Remove Programs. -> Add/Remove Windows Components -> Remote Installation Services -> Next. -> Finish ->restart computer.

2.Tạo Image lưu trên server:
Khởi động RIS: Start-> Administrative tool-> Remote intallation service setup (Run -> Risetup)
Click next tại màn hình welcome -> xuất hiện hộp thoại, Chọn vị trí đặt thư mục share file ảnh



Chọn dòng Respond to client computers requesting service



Chọn đường dẫn chứa source của win cần cài đặt.

Click next trong các hợp thoại tiếp theo và chờ 1 tí sau đó click vào Done trong hợp thoại sau:

3.Tạo file answer
Giải nén file DEPLOY.cab trong thư mục Tools của winxp. Chạy file setupmgr.exe.
Click next trong hộp thoại welcome ..., Chọn dòng Remote Installation Services

Chọn dòng Fully Automated

Điền đầy đủ thông tin vào cửa sổ Window Setup Manager
Sau đó lưu file remboot.sif tại đường dẫn R:\RemoteInstall\Setup\English\Images\WINDOWS\i386\templates (nơi chứa source cài đặt window)

4.Authorize RIS trong Active Directory
Sau khi cài đặt RIS, RIS server phải được authorized trong Active Directory.
Start -> Administrative Tools -> DHCP. Right-click DHCP -> Manage Authorized Servers.
Nếu không có server trong danh sách thì ta click Authorize, chọn tên hay địa chỉ IP của RIS server, khi đó click OK.

5.Phân quyền USER để dùng RIS cài window
Start -> Administrative Tools -> Active Directory Users and Computers.
Tạo OU, trong OU tạo user (user này ta cấp quyền để cài đặt window). Click phải vào OU vừa tạo, chọn Delegate Control.
Click next tại hộp thoại welcome -> click add tại hộp thoại tiếp theo -> ta chọn user vừa tạo trong OU lúc nãy.
Click next, chọn "Create a Custom task to delegate" trong hộp thoại task to delegate -> next
Chọn option "This Folder, existing object in this folder, and..." trong hộp thoại Active Derectory Object Type.
Click next và chọn các option "Create/Deletion of Specific Child Object" và option "Create Computer Objects" -> click next và finish

Trong AD, click phải vào tên miền chọn properties -> Chọn group policy -> edit. Trong group policy object -> user configuration ->window setting ->remote installation service ->double click vào choice option bên phải. Chọn Enable trong mục Automatic Setup ->OK

Câu hỏi về TCP - FIN - RST ...

Câu hỏi về TCP - FIN - RST ...

Hỏi:
1) Đối với TCP, FIN và RST khác nhau ở những điểm nào?
2) Tại sao tình trạng "man in the middle" có thể xảy ra với giao thức TCP?
3) Thành phần nào quan trọng nhất cho việc inject một TCP packet vào một luồng dữ liệu đang chuyển gởi giữa 2 đầu client / server?
Trả lời:
1/ Trong TCP, cờ FIN (Finish) được sử dụng khi 1 bên muốn kết thúc TCP connection 1 cách "polite", và bên gửi FIN phải chắc chắn rằng bên còn lại đã nhận được FIN rồi mới thật sự đóng connection (do vậy trong tcp khi đóng kết nối sử dụng FIN sẽ có 1 bên gặp tình trạng time-out hay còn gọi là time-wait trong giai đoạn cuối cùng của 1 quá trình đóng kết nối), vì thế lúc vừa gửi FIN đi thì connection vẫn tồn tại (data trong TCP Buffer vẫn còn). Còn cờ RST (Reset) là để đóng TCP conntection 1 cách "impolite", tức là bên gửi RST, sau khi gửi RST thì bên đó ko cần quan tâm đển bên còn lại có nhận được hay ko mà nó sẽ đóng connection ngay lập tức (xoá sạch data trong TCP Buffer) sau khi gửi gói RST kia, và bên còn lại khi nhận gói RST cũng "tự hiểu", tự đóng connection mà ko cần thông báo trở lại cho bên gửi RST
2/ Theo em, TCP là 1 giao thức Reliable (so với UDP), nhưng tính reliability là ở tính toàn vẹn dữ liệu, nhưng toàn vẹn ở đây ko phải là ko bị hacker sửa đổi mà toàn vẹn ở đây là TCP cung cấp cơ chế để kiểm soát luồng dữ liệu (flow data control), do đó ko gây ra việc dữ liệu bị thiếu sót (do nghẽn mạng hay gì gì đó(. Tuy nhiên về mặt Security thì TCP ko hẳn là an toàn. Ở đấy có 2 trường hợp, trường hợp thứ 1 là 1 connection đã được thiếp lập từ trước bởi victim, lúc này attacker sẽ sử dụng kỹ thuật Hjacking (cũng thuộc MIMT) nhưng bởi vì đối với TCP thì số sequence chính là "sinh tử huyệt" của nó do đó trong 1 cuộc tấn công Man In The Middle thì Attack hoàn toàn có thể lấy được số sequence và "nắm quyền" connection đó. Còn đối với trường hợp 2 là victim thiết lập connection sau khi đã bị MIMT thì ko có gì để nói, vì lúc này TCP hay UDP cũng như nhau thôi
3/ Số Sequence và "nguyên tắc" generate chuỗi sequence (tùy thuộc vào cách Implement của từng OS/kernel)
(Hvaonline)

Di chuyển các file Database trong Active Directory

Thông thường khi ta nâng cấp 1 máy Domain Controller thì toàn bộ database của active directory tập trung lưu ở C:\WINDOWS\NTDS. Trong này có các file edb.chk,ntds.dit ,temd.edb là quan trọng nhất Do nhu cầu về bảo mật ta cần di chuyển tất cả các file này vào 1 nơi khác để an toàn hơn.
Để tránh tình trạng hư hỏng các file trong database của active directory xảy ra (do quá trình di chuyển database thất bại ), trước tiên ta nên backup system state để sao lưu lại các file hệ thống.
Bước 1: backup system state: (Dùng lệnh ntbackup)

Bước 2: Di chuyển Database Active Directory.
Sau khi backup xong ta khởi động lại máy ở chế độ Directory Service Restore Mode bằng cách lúc khởi động ta nhấn liên tục phím F8 và chọn Directory Service Restore Mode...

Tiếp theo ta tìm 1 nơi nào đó để lưu trữ các file database này, (lưu ở đâu càng khó tìm thì tính bảo mật càng cao). Ví dụ ở đây mình move vào thư mục theo đường dẫn C:\WINDOWS\datanew\active directory\NTDS
Ta vào của sổ cmd gõ lệnh ntdsutil thì được như sau


Tiếp theo ta gõ lệnh files rùi enter thì được như sau


Tiếp theo gõ lệnh move DB to C:\WINDOWS\datanew\active directory\NTDS (chú ý đường dẫn này có thể thay đổi nếu bạn muốn lưu các file database này ở đâu)
Sau khi gõ lệnh xong enter thì quá trình move database diễn ra.


Sau khi move xong ta gõ lệnh quit 2 lần để thoát ra khỏi file maintenance và ntdsutil.
Sau khi hoàn thành ta vào kiễm tra thì các file edb.chk,ntds.dit ,temd.edb đã được move vào thư mục NTDS theo đường dẫn C:\WINDOWS\datanew\active directory\NTDS .sau khi hoàn tất ta khởi động máy lại bình thường ta có thể xoá hẳn thư mục NTDS trong C:\WINDOWS mà vẫn không có vấn đề gì xảy ra vì mọi database đã được chuyển sang C:\WINDOWS\datanew\active directory\NTDS.

Thiết lập hai server chạy song song - Phần IV: Remove Server have died

Phần IV: Gỡ bỏ server đã chết.

bước 1: Giả sử server 1 chết hẳn
bước 2: từ server 2 thực hiện theo phần 3. sau đó ra CMD ta đánh tiếp các lệnh để gở bỏ xác domain đã chết.

Các lệnh để config (copy từ trong DOS)

-----------------------------------------------------------
Microsoft Windows [Version 5.2.3790]
(C) Copyright 1985-2003 Microsoft Corp.

C:\>ntdsutil "Lệnh đầu tiên trong quá trình remove server have died

ntdsutil: Metadata cleanup "Lệnh 2 trong quá trình remove server have died

metadata cleanup: connections "Lệnh 3 trong quá trình remove server have died
server connections: connect to server ser.anthaifood.com "Lệnh 4 trong quá trình remove server have died
Binding to ser.anthaifood.com ...
Connected to ser.anthaifood.com using credentials of locally logged on user.
server connections: quit "Lệnh 5 trong quá trình remove server have died

metadata cleanup: select operation target "Lệnh 6 trong quá trình remove server have died
select operation target: list domain "Lệnh 7 trong quá trình remove server have died
Found 1 domain(s)
0 - DC=anthaifood,DC=com
--Các bạn để ý dòng found 1 domain(s) chỉ có 1 domain anthaifood thôi, nên ở đây ta sẽ chọn số 0, tương ứng với domain ta có là anthaifood (trường hợp nếu bạn có nhiều domain thì cũng sẽ được liệt kê ở đây)--
select operation target: select domain 0 "Lệnh 8 trong quá trình remove server have died
No current site
Domain - DC=anthaifood,DC=com
No current server
No current Naming Context
select operation target: list sites "Lệnh 9 trong quá trình remove server have died
Found 1 site(s)
0 - CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
--(Các bạn nhìn tại dòng found 1 site(s). Mặc định ta có 1 site tương ứng với số 0--

select operation target: select site 0 "Lệnh 10 trong quá trình remove server have died
Site - CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com

Domain - DC=anthaifood,DC=com
No current server
No current Naming Context
select operation target: list servers in site "Lệnh 11 trong quá trình remove server have died
Found 2 server(s)
0 - CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC
=anthaifood,DC=com
1 - CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=an
thaifood,DC=com
--Bạn nhìn tại dòng found 2 server(S) gồm có SERVER đã chết, tương ứng với số 0 và SER còn sống, tương ứng với số 1.--
select operation target: select server 0 "Lệnh 12 trong quá trình remove server have died
Site - CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com

Domain - DC=anthaifood,DC=com
Server - CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configurati
on,DC=anthaifood,DC=com
DSA object - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site
-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
DNS host name - server.anthaifood.com
Computer object - CN=SERVER,OU=Domain Controllers,DC=anthaifood,DC=com
No current Naming Context
select operation target: quit "Lệnh 13 trong quá trình remove server have died
metadata cleanup: remove select server "Lệnh 14 trong quá trình remove server have died
Transferring / Seizing FSMO roles off the selected server.
Removing FRS metadata for the selected server.
Searching for FRS members under "CN=SERVER,OU=Domain Controllers,DC=anthaifood,D
C=com".

Removing FRS member "CN={c007d6ea-dcc0-4d58-83ad-a80d41cbb4a1},CN=RootDFS|Datase
rver,CN=RootDFS,CN=DFS Volumes,CN=File Replication Service,CN=System,DC=anthaifo
od,DC=com".
Deleting FRS connection "CN={c007d6ea-dcc0-4d58-83ad-a80d41cbb4a1},CN={c09b2596-
d30b-4a94-8d94-d4a35033aedc},CN=RootDFS|Dataserver,CN=RootDFS,CN=DFS Volumes,CN=
File Replication Service,CN=System,DC=anthaifood,DC=com".
Deleting subtree under "CN={c007d6ea-dcc0-4d58-83ad-a80d41cbb4a1},CN=RootDFS|Dat
aserver,CN=RootDFS,CN=DFS Volumes,CN=File Replication Service,CN=System,DC=antha
ifood,DC=com".
(Xuất hiện thông báo, chọn YES)

Removing FRS member "CN=SERVER,CN=Domain System Volume (SYSVOL share),CN=File Re
plication Service,CN=System,DC=anthaifood,DC=com".
Deleting subtree under "CN=SERVER,CN=Domain System Volume (SYSVOL share),CN=File
Replication Service,CN=System,DC=anthaifood,DC=com".
Deleting subtree under "CN=SERVER,OU=Domain Controllers,DC=anthaifood,DC=com".
The attempt to remove the FRS settings on CN=SERVER,CN=Servers,CN=Default-First-
Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com failed because "Element
not found.";
metadata cleanup is continuing.
"CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=an
thaifood,DC=com" removed from server "ser.anthaifood.com"
metadata cleanup: quit "Lệnh 15 trong quá trình remove server have died
ntdsutil: quit "Lệnh 16 trong quá trình remove server have died
Disconnecting from ser.anthaifood.com...

C:\>
-----------------------------------------------------------

- Tiếp theo bạn bỏ dĩa cài win2k3 vào cài thêm bộ support tool (SUPTOOLS.MSI)

- Sau khi cài xong bộ support tool, ta vào start ---> run ---> mmc .
- vào menu file ----> add remove snap in ---> chọn công cụ có tên là ADSI edit ---> mở ADSI edit chuột phải chọn dòng connect to...


Tại dòng select a well known naming context: ta chọn domain

Sau đó ta connect thêm 1 lần nữa .... Nhưng kỳ này ta chọn Configuration.



Sau đó chọn dòng như trong hình, để xóa các dấu vết còn lại của server 1


Delete dòng đang chọn

Đến đây coi như bạn đã hoàn thành remove server 1 đã chết

(Bài viết có tham khảo website nhatnghe.com)

Thiết lập hai server chạy song song - Phần III: Operation Master

PHẦN III: Operation Master

Giới thiệu: Mặc dù W2k/W2k3 hỗ trợ Multi Master (các DC hoạt động song song nhau, không phân biệt chính/phụ ). Tuy nhiên vẫn còn một số chức năng hoạt động ở chế độ Single Master, cụ thể là:
1. Schema Master: Quản lý schema, mỗi forest có 1 cái
2. Domain Naming: Quản lý danh sách các domain, mỗi forest có 1 cái
3. PDC: Giả lập server NT để chứng thực cho các WS đồi cũ (win9x), mỗi domain có 1 cái
4. RID: cấp số ID cho user, mỗi domain có 1 cái
5. Infrastructer: Quản lý danh sách user ở domain khác tham dự vào các nhóm của domain hiện tại., mỗi domain có 1 cái

Mặc định các chức năng do DC1 nắm giữ. Khi DC1 chết thì những thao tác liên quan đến 5 chức năng này sẽ không thực hiện được.

Khi DC1 "chết bất đắc kỳ tử", ta cần "cưỡng chế" DC2 giữ 5 chức năng này. Bài viết sẽ hướng dẫn chi tiết các bước thực hiện việc "cưỡng chế"

Bài viết này gồm 3 bước:
1. Giả sử master DC bị chết (DC1 bị ngủm bất đắc kỳ tử)
2. Từ Addition DC (DC2) ra CMD gõ các lệnh để cưỡng chế 5 chức năng single master của DC1 sang DC2
3. Sau khi thành công, DC2 tạo user và client join domain bằng user mới tạo thành công.

Thực hiện
1./ giả sử DC1 bị die (shutdown DC1)
2./ từ DC2, vào cmd gõ các lệnh để cưỡng chế 5 chức năng single master của DC1 sang DC2
Trình tự các lệnh như sau: (Copy từ màn hình DOS ra)
--------------------------------------------------------
Microsoft Windows [Version 5.2.3790]
(C) Copyright 1985-2003 Microsoft Corp.

C:\>ntdsutil 'Lệnh đầu tiên trong wá trình Operation Master
ntdsutil: ?
'Các lệnh trong 'ntdsutil'
? - Show this help information
Authoritative restore - Authoritatively restore the DIT database
Configurable Settings - Manage configurable settings
Domain management - Prepare for new domain creation
Files - Manage NTDS database files
Group Membership Evaluation - Evaluate SIDs in token for a given user or group
Help - Show this help information
LDAP policies - Manage LDAP protocol policies
Metadata cleanup - Clean up objects of decommissioned servers
Popups %s - (en/dis)able popups with "on" or "off"
Quit - Quit the utility
Roles - Manage NTDS role owner tokens
Security account management - Manage Security Account Database - Duplicate SID Cleanup
Semantic database analysis - Semantic Checker
Set DSRM Password - Reset directory service restore mode administrator account password


ntdsutil: Roles 'Lệnh thứ 2 trong wá trình Operation Master
fsmo maintenance: ?
'Các lệnhh trong 'Roles'
? - Show this help information
Connections - Connect to a specific domain controller
Help - Show this help information
Quit - Return to the prior menu
Seize domain naming master - Overwrite domain role on connected server
Seize infrastructure master - Overwrite infrastructure role on connected server
Seize PDC - Overwrite PDC role on connected server
Seize RID master - Overwrite RID role on connected server
Seize schema master - Overwrite schema role on connected server
Select operation target - Select sites, servers, domains, roles and naming contexts
Transfer domain naming master - Make connected server the domain naming master
Transfer infrastructure master - Make connected server the infrastructure master
Transfer PDC - Make connected server the PDC
Transfer RID master - Make connected server the RID master
Transfer schema master - Make connected server the schema master

fsmo maintenance: connections 'Lệnh thứ 3 trong quá trình Operation Master
server connections: ?
'Các lệnh trong 'connections'
? - Show this help information
Clear creds - Clear prior connection credentials
Connect to domain %s - Connect to DNS domain name
Connect to server %s - Connect to server, DNS name or IP address
Help - Show this help information
Info - Show connection information
Quit - Return to the prior menu
Set creds %s %s %s - Set connection creds as domain, user, pwd.
Use "NULL" for null password,
* to enter password from the console.

server connections: connect to server ser.anthaifood.com 'Lệnh thứ 4 trong wá trình Operation Master
Binding to ser.anthaifood.com ...
Connected to ser.anthaifood.com using credentials of locally logged on user.
server connections: quit 'Lệnh thứ 5 trong wá trình Operation Master

fsmo maintenance: seize schema master 'Lệnh thứ 6 trong wá trình Operation Master
Attempting safe transfer of schema FSMO before seizure.
ldap_modify_sW error 0x34(52 (Unavailable).
Ldap extended error message is 000020AF: SvcErr: DSID-0321032A, problem 5002 (UNAVAILABLE), data 1722
(Xuất hiện thông báo, chọn "YES")


Win32 error returned is 0x20af(The requested FSMO operation failed. The current FSMO holder could not be contacted.))
Depending on the error code this may indicate a connection,
ldap, or role transfer error.
Transfer of schema FSMO failed, proceeding with seizure ...
Server "ser.anthaifood.com" knows about 5 roles
Schema - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Domain - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
PDC - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
RID - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Infrastructure - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com

fsmo maintenance: seize domain naming master 'Lệnh thứ 7 trong wá trình Operation Master
Attempting safe transfer of domain naming FSMO before seizure.
ldap_modify_sW error 0x34(52 (Unavailable).
Ldap extended error message is 000020AF: SvcErr: DSID-0321032A, problem 5002 (UNAVAILABLE), data 1722
(Xuất hiện thông báo, chọn "YES")


Win32 error returned is 0x20af(The requested FSMO operation failed. The current FSMO holder could not be contacted.))
Depending on the error code this may indicate a connection,ldap, or role transfer error.
Transfer of domain naming FSMO failed, proceeding with seizure ...
Server "ser.anthaifood.com" knows about 5 roles
Schema - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Domain - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
PDC - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
RID - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Infrastructure - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com

fsmo maintenance: seize RID master 'Lệnh thứ 8 trong wá trình Operation Master (chữ RID viết hoa)
Attempting safe transfer of RID FSMO before seizure.
ldap_modify_sW error 0x34(52 (Unavailable).
Ldap extended error message is 000020AF: SvcErr: DSID-03210922, problem 5002 (UNAVAILABLE), data 1722
(Xuất hiện thông báo, chọn "YES")


Win32 error returned is 0x20af(The requested FSMO operation failed. The currentFSMO holder could not be contacted.))
Depending on the error code this may indicate a connection,ldap, or role transfer error.
Transfer of RID FSMO failed, proceeding with seizure ...
Searching for highest rid pool in domain
Server "ser.anthaifood.com" knows about 5 roles
Schema - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Domain - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
PDC - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
RID - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Infrastructure - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com

fsmo maintenance: seize PDC 'Lệnh thứ 9 trong wá trình Operation Master
(chữ PDC viết hoa)
Attempting safe transfer of PDC FSMO before seizure.
ldap_modify_sW error 0x34(52 (Unavailable).
Ldap extended error message is 000020AF: SvcErr: DSID-03210511, problem 5002 (UNAVAILABLE), data 1722
(Xuất hiện thông báo, chọn "YES")


Win32 error returned is 0x20af(The requested FSMO operation failed. The current FSMO holder could not be contacted.))
Depending on the error code this may indicate a connection,
ldap, or role transfer error.
Transfer of PDC FSMO failed, proceeding with seizure ...
Server "ser.anthaifood.com" knows about 5 roles
Schema - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Domain - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
PDC - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
RID - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Infrastructure - CN=NTDS Settings,CN=SERVER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com

fsmo maintenance: seize infrastructure master 'Lệnh thứ 10 trong wá trình Operation Master
Attempting safe transfer of infrastructure FSMO before seizure.
ldap_modify_sW error 0x34(52 (Unavailable).
Ldap extended error message is 000020AF: SvcErr: DSID-0321032A, problem 5002 (UNAVAILABLE), data 1722
(Xuất hiện thông báo, chọn "YES")


Win32 error returned is 0x20af(The requested FSMO operation failed. The current FSMO holder could not be contacted.))
Depending on the error code this may indicate a connection,
ldap, or role transfer error.
Transfer of infrastructure FSMO failed, proceeding with seizure ...
Server "ser.anthaifood.com" knows about 5 roles
Schema - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Domain - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
PDC - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
RID - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
Infrastructure - CN=NTDS Settings,CN=SER,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=anthaifood,DC=com
fsmo maintenance: quit 'Lệnh thứ 11 trong wá trình Operation Master
ntdsutil: quit 'Lệnh thứ 12 trong wá trình Operation Master
Disconnecting from ser.anthaifood.com...

C:\>

--------------------------------------------------------

3./ Bây giờ ta thử bằng cách từ máy DC 2 (vừa được lên master) ta tạo user và từ máy client có thể join vào domain bằng user mới được tạo.
Test bằng cách này vẫn chưa đầy đủ lắm, nếu ta mở Domain Controller Security Policy & Domain Security Policy lên được thì đã thành công.

(Bài viết có thao khảo từ nhatnghe.com)

Thiết lập hai server chạy song song - Phần II: Distributed file system – DFS

Phần II: Distributed file system – DFS

Giới thiệu: Sau khi đã thiết lập 2 DC chạy song song (phần 1), thì khi 1 trong 2 DC này chết, thì user vẫn logon vào domain bình thường. Nhưng nhu cầu sử dụng không dừng tại đây, yêu cầu mới được đặt ra:

- Xây dựng một hệ thống thư mục sao cho việc truy xuất dữ liệu của user không bị phụ thuộc vào nơi chưa thư mục đó nhằm mục đích dễ bảo trì hệ thống
- Các File server load balancing với nhau
- Nếu có 1 File server chết vẫn không ảnh hưởng đến user

Đó là lý do sử dụng Distributed file system (DFS)

Yêu cầu: đã làm các bước ở phần 1
Thực hiện bài này gồm các bước:
-bước 1: Trên server1, tạo thư mục (trên 1 ổ dĩa bất kỳ) chứa các thành phần cấu tạo rootdfs, và thư mục data chứa dữ liệu cho user dùng(share 2 thư mục này)
-bước 2:trên server2,tạo thư muc backup root,và thư mục backup data(trên ỗ dĩa bất kỳ)
-bước 3: sữ dụng distributed file system để cấu hình root, và tạo link cho thư mục data.
-bước 4:client Map thư mục data về xài ,test thử bàng cách tạo file ,lưu file và sửa file.và ta thấy các file đều được lưu ở 2 server, tắt 1 trong 2 DC mà client vẫn o biết và sữ dụng thư mục Map bình thường

Thực hiện:
server1
-Trước hết ta tạo trên ổ dĩa bất kỳ 2 thư mục. Tên các bạn đặt tùy ý, ở đây mình đặt là "root dfs" và "data"
-Thư mục "root dfs" chứa các thành phần tạo nên root của Distributed file system. Còn thư mục "data" là thư mục cho user MAP về xài. Sau đó share 2 thư mục trên (share full cho dễ làm)
server 2:
-Đồng thời trên server 2 ,cũng tạo 2 thư mục dùng để backup rootdfs và data.chúng ta cũng share 2 thư mục đó (share full cho dễ làm)

*Sau đó ta quay lại server 1 cấu hình cho DFS:
-Trên server 1:
Vào administrative tool -> chọn Distributed file system. Trong Distributed file system chuột phải chọn New root:
Trong màn hình New Root Winzard chọn Next:

Chọn Domain Root trong cửa sổ Root Type -> click Next

Chọn Domain, nếu trường hợp có nhiều domain.

Chọn server.

Đặt tên cho Root Name. (đặt tên là RootDFS)

Chọn thư mục share Root dfs

Click vào finish. Vậy là ta tạo được 1 rootdfs


- Tiếp theo là bạn sẽ tạo 1 root target: Tại root bạn click chuột phải chọn "New target root". ta sẽ tạo 1 root target trên server2 (tên server2 là ser)

Trong hộp thoại "Root share" ta tìm đến thư mục mà ta share làm backup root dfs ,ở đây mình chọn là "backup root" vậy là ta đã hoàn chĩnh tạo root dfs cho cả 2 DC



- Tiếp theo ta tạo link từ root (khi user MAP thư mục này xài bằng đường link này). Trong ô link name: bạn đặt tên cho link (ở đây tôi đặt tên là Dataserver)
- bạn nhìn xuống ô Preview of UNC path to the link: đây là đường dẫn để user dùng map thư mục data về xài
- Bạn bấm browse sau đó chọn đường dẫn đến thư muc "data" ở "server1". Sau đó bạn bấm OK sẽ tạo được 1 link nàm trong root dfs mà bạn tạo


- Tiếp theo ta sẽ tạo 1 "link target" bằng cách chuột phải lên "link data" ta mới tạo chọn "new target" -> Thưc hiện giống phần trên: trong hộp thoại chọn "browse" tìm đến thư mục chứa "backup data" nằm trên "server2": -> NEXT -> OK, nó sẽ hỏi bạn có Đồng bộ không,? bạn bấm OK ->OK mấy cái cho xong

Sau đó reset 2 máy DC lại ,coi như đã xong .việc tiếp theo là chúng ta đi kiễm tra

TỪ MÁY CLIENT (CHẮC CHẮN MÁY CLIENT ĐÃ JOIN VÀO DOMAIN)

Từ máy client ->start ->run ->cmd
Đánh lệnh: net use z: \\anthaifood\rootdfs\dataserver\%username% để ta MAP thư mục data về cho từng user.
Sau đó trong ỗ dĩa đã MAP bạn tạo thử 1 file.
Sau đó bạn wa bên "DC 1" vào thư mục "data"
Bên "DC2" vào thư mục "backup data" xem coi có file bạn mới tạo chưa? Nếu có thì chúc mừng bạn ..bạn đã thành công.

Thiết lập hai server chạy song song - Phần I

Bài viết này gồm các bước sau:
- Bước 1 : Dựng Domain Controller cho Server1
- Bước 2 : Dùng Server2 join Domain vào Server1 và dựng Domain Controller cho máy Server2
- Bước 3 : Đồng bộ 2 server, bật Gobal Catalog
- Bước 4 : Join domain cho máy client
- Bước 5 : Tắt chế độ cache logon và test thử bằng cách tắt 1 trong 2 Domain Controller.

1/ Máy Server 1: Nâng cấp lên domain controller

Đặt IP tĩnh cho DC theo các tham số sau:
IP: 192.168.1.10
NetMask: 255.255.255.0
Preferred DNS Server: 192.168.1.10

  • Vào Start -> Run -> Chạy chương trình DCPROMO để nâng cấp lên lên Domain Controller
  • Cửa sổ "Active Directory Installation Wizard" , nhấn Next
  • Domain Controller Type, chọn Domain controller for a new domain và click next
  • Ở khung Ceate New Domain, chọn Domain in a new forest
  • Khung New Domain Name, điền vào domains của bạn (ở đây là anthaifood.com)
  • NetBIOS Domain Name, để nguyên giá trị mặc định
  • Chọn giá trị mặc định cho các thư mục chứa cấu hình hệ thống
  • DNS Registration Diagnostics, chọn Install and configure the DNS server on this computer, and set this computer to use this DNS server as its preferrend DNS server
  • Permissions, chọn Permissions compatible only with Windows 2000 or Windows Server 2003 operating systems ....
  • Dicrectory Services Restore Mode Administrator Password, điền password nếu bạn cần.
  • Chọn Finish để kết thúc quá trình cài đặt và reboot lại.
Sau khi reboot lại thì tạo user tên “u1” , password: 123 (Để tạo được thì ta phải chỉnh sữa lại trong Domain Controller Policy một tí)

2/ Máy Server 2: Join vào domain và nâng cấp lên domain controller.

A/ Join domain :

Đặt IP tĩnh cho server2 theo các tham số sau:
IP: 192.168.1.20
NetMask: 255.255.255.0
Preferred DNS Server: 192.168.1.10

Click nút phải chuột trên My Computer / Properties / Computer Name / Change
Điền tên domain “anthaifood.com” vào ô domain

Sau khi OK, sẽ hiện lên 1 của sổ ta điền user để join domains, bạn điền user : administrator (user của máy server1)

OK, reboot lại máy server 2

B/ Dựng Domain Controller

Sau khi rebot lại máy Server2, vào Start -> Run -> Chạy chương trình DCPROMO để nâng cấp lên lên Domain Controller. (lúc này ta vẫn sử dụng tài khoản administrator cục bộ của máy server2)

Cửa sổ "Active Directory Installation Wizard" , nhấn Next
Tại cửa sổ "Domain Controller Type" chọn dòng Additional domain controller for an existing domain.



Network Credentials: Nhập username & password administrator của máy server1


Để mặc định tại các cửa sổ này




Dicrectory Services Restore Mode Administrator Password, điền password nếu cần (là password cần khi chúng ta restore hệ thống Domain Controller)


Đến cửa sổ này thì đợi một tí.


Đến đây thì đã thành công, chọn Finish để kết thúc quá trình cài đặt và reboot lại.


C/ Dựng DNS :

Đặt lại IP cho server2 theo các tham số sau:
IP: 192.168.1.20
NetMask: 255.255.255.0
Preferred DNS Server: 192.168.1.20

Vào Control Panel -> Windows Components, chọn Details
Ở phần Networking Services chọn Domain Name System (DNS) và nhấn OK, nhấn tiếp Next để cài đặt.

3/ Đồng bộ 2 server và join domains cho client

A/ Server1:

Start -> Program File -> Administrator Tool -> Active Directory Site and Services

Trong cữa sổ Active Directory Site and Services chọn Sites -> Defaut-Fist-Site-Name -> Servers thì sẽ thấy 2 server, vào properties từng NTDS Settings của mỗi server và check vào Gobal Catalog -1-.

Trỏ Alternate DNS Server1 về Server2 (192.168.1.20)

B/ Server 2:
Trỏ Alternate DNS Server2 về Server1 (192.168.1.10)

Reboot Server1 & Server2

4/ Máy Client:

Đặt IP tĩnh cho máy Client theo các tham số sau:
IP: 192.168.1.2
NetMask: 255.255.255.0
Preferred DNS Server: 192.168.1.10
Alternate DNS Server : 192.168.1.20

Click nút phải chuột trên My Computer / Properties / Computer Name / Change
Điền tên domain “anthaifood.com” vào ô domain, khi hỏi username và password thì điền vào tài khoản quản trị của Domain Controller (DC)
Reboot lại Client

Sau khi reboot lại đăng nhập bằng tài khoản sau: user: u1 / password : 123

5/ thử nghiệm:

Tắt đi 1 trong 2 server mà máy client vẫn login vào được DC, tạo thêm u2,u3 ... để thử nghiệm.
Ghi chú: tắt chế độ cache logon trong local plicy (interactive logon) test mới chính xác
Cách tắt chế độ cache logon
Security Settings > Local Policies > Security Options
Interactive logon: Number of previous logons to cache (in case domain controller is not available) Not Defined  cho giá trị này = 0.

Ghi chú:
-1-: Global Catalog là một Database rút gọn của bộ AD đầy đủ, Global Catalog chỉ chứa những thuộc tính thường dùng của các object.

Trong môi trường single domain, MS khuyến cáo tất cả các Domain controller đều đảm nhận 2 chức năng là DNS và Global Catalog. Cũng trong mô hình này, Globla Catalog sẽ được build trực tiếp từ AD local mà không cần replicate.
(Tham khảo thêm: http://technet.microsoft.com/en-us/library/cc728188(WS.10).aspx)

(Tham khảo tại trang nhatnghe.com)
Cấu hình DMZ........

Cấu hình DMZ........

Hỏi:
Em có 1 hệ thống thế này: 1 Sever có 3 card mạng.
  • 1 nối vào modem ADSL ra NET.
  • 1 nối vào swich nội bộ.
  • 1 nối ra 1 máy làm Webserver.
Và em tính làm là card mạng nối vào webserver làm DMZ(Mọi kết nối từ ngoài đều chuyển hướng vào máy này,kô ảnh hưởng tới mạng nội bộ).

Em kô dùng ISA để làm mà dùng RRAS trong win sever 2003 làm,và em dự tính là làm thế này:
Em sẽ tạo static route cho IP của Mạng nội bộ với IP của Card mạng DMZ(nối ra máy webserver)
Sau đó tạo NAT cho card DMZ này ra net( Dùng chức năng NAT/Basic firewall)

Vậy cho em hỏi mô hình như vậy thì các máy trong mạng nội bộ có ra NET được kô? Vì card LAn nối cho ra mạng nội bộ kô được NAT ra ngoài mà chỉ được định tuyến tới 1 card mạng được NAT ra ngoài thôi.

Trả lời:
Giả sử ta chia hệ thống làm 3 phần: External (internet); DMZ; Internal (LAN)

Tùy theo khu vục DMZ bạn dùng IP public hay private mà cách làm sẽ khác nhau:

TH1 - Dùng IP Public:
  • Internal <-> External : NAT
  • Internal <-> DMZ: Routing
  • External <-> DMZ: Routing
TH2 - Dùng IP Private:
  • Internal <-> External : NAT
  • Internal <-> DMZ: Routing
  • External <-> DMZ: NAT
Dùng chức năng package filter để quản lý traffic, ví dụ chỉ cho các gói tin từ DMZ có source port là 80 vào internal