Working at Domain Controller: Server
Local Publishing: Publisher and Distributor
Publishing Database: Toronto
Distributor Database: Distribution
SNAPSHOT file folder: D:\Data and its share name is DATA.
Check or modify the Default Snapshot Folder to be D:\Data -- Distributor's Properties and select the Publisher -- Click the far right ... button
Create Windows Logins
VIP\SnapshotAgent and VIP\DistributionAgent
MAP VIP\SnapshotAgent to DB_OWNER database role of Distribution Database.
Create a publication--Addresses
Confirm or modify its snapshot folder to D:\Data. This D:\Data folder has the permissions set up as shown in the above picture.
Right-click on the Publication of Addresses --Press Start button
Check the D:\Data folder
Configuring the Publication to be accessible for Subscribers
The published files in D:\Data folder must be read by VIP\DistributionAgent.
The Publication:Addresses properties --PAL
--Add VIP\DistributionAgent to Publication Access List.
MAP VIP\DistributionAgent to a database user VIP\DistributionAgent.
Configuring a subscriber--PUSH
Distribution database at DC:Server
Make sure that VIP\DistributionAgent to be a member of db_owner role.
Subscriber database BData at the member server: KingPC
Create a Windows Login: VIP\DistributionAgent
MAP VIP\DistributionAgent to database user VIP\DistributionAgent of BData database with DB_OWNER role
Initiating the subscription wizard--Push type
You will find the Addresses table is created in BData database.
Attach or modify a recurring schedule for a snapshot publication
Work at DC:Server
SQL Server Agent -- Jobs
Locate the Server-Toronto-Addresses-# job --Properties --Schedules
The Distribution Agent knows which one to push onto the subscribers.
NOTE:
Look at relationship between Jobs, Proxies, and Credentials?
- Create a credential that has Windows user account and password.
- Create a proxy associated with a credential
- Create a job that uses the proxy
Before SQL Server Agent runs a job step that uses a proxy, SQL Server Agent impersonates the credentials defined in the proxy, and then runs the job step by using that security context.
A proxy associates a credential with one or many subsystems:
- ActiveX script
- Operating System(CmdExec)
etc.
The question is when to drop the old files in Default Snapshot Folder?
Distribution Clean up: Distribution job will take care of it.
PULL subscription
You must configure the Default Snapshot Folder with UNC path: \\Server\Data.