![]() | Oracle System Handbook - ISO 7.0 May 2018 Internal/Partner Edition | ||
|
|
![]() |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Solution Type Predictive Self-Healing Sure Solution 1595549.1 : Oracle ZFS Storage Appliance: How to set up Replication
To provide configuration details, suggestions and recommendations when setting up replication. In this Document
Applies to:Oracle ZFS Storage ZS4-4 - Version All Versions and laterOracle ZFS Storage Appliance Racked System ZS4-4 - Version All Versions and later Sun Storage 7210 Unified Storage System - Version All Versions and later Sun Storage 7310 Unified Storage System - Version All Versions and later Sun ZFS Storage 7320 - Version All Versions and later 7000 Appliance OS (Fishworks) PurposeThis document provides configuration details, suggestions and recommendations when setting up replication.
ScopeTo provide configuration assistance when setting up replication on the Series 7000 NAS/ZFS Storage Appliance for the first time.
DetailsSun ZFS Storage Appliances support snapshot-based replication of projects and shares from a source appliance to any number of target appliances manually, on a schedule, or continuously. The replication includes both data and metadata. Remote replication (or just "replication") is a general-purpose feature optimized for the following use cases:
Useful terms and acronyms concerned with replication
Considerations when planning a replication configuration Are you intending to provide a dedicated (private) network for replication traffic ? Are you intending to provide dedicated network interfaces for replication traffic ? The replication functionality works best when replication is at the PROJECT level instead of the SHARE level. Ensure that the network interfaces and routing configuration are setup (and working) correctly BEFORE starting to setup the replication configuration on the source and target systems.
Cluster considerations for replication On cluster systems, ensure that the network interfaces used for replication and the associated zpool are 'tied' together (ie. 'active' on the same cluster head at all times). So that, on cluster takeover or failback, the network interfaces ownership always moves with the zpool ownership. When configuring replication from both heads in a 'source' cluster system, you must configure the replication targets to use different IP addresses on the 'target' system. If replicating to or from a cluster, the routing configuration is CRITICAL and should be done BEFORE starting the replication setup.
Special considerations for setting up replication between two clusters DO NOT use any private cluster interfaces for replication. To avoid any future problems, configure replication with both heads in the CLUSTERED state (ie. all cluster resources owned by their 'assigned' owner) and use SEPARATE replication targets for the pools owned by each head. Be aware that when the above considerations have NOT been followed, all can work fine initially, but may break in the future when ownership of resources change. Here are some examples of what can happen when the above considerations have not been followed: When you're configuring a replication target on (system) A for replication to (system) C and that A's cluster peer is called (system) B. If you configure the target with A in the OWNER state (i.e. having imported IP addresses owned by B), either of the following may happen:
Project-level vs Share-level Replication The appliance allows administrators to configure remote replication on both the project or share level. Like other properties configurable on the Shares screen, each share can either inherit or override the configuration of its parent project. Inheriting the configuration means not only that the share is replicated on the same schedule to the same target with the same options as its parent project is, but also that the share will be replicated in the same stream using the same project-level snapshots as other shares inheriting the project's configuration. This may be important for applications which require consistency between data stored on multiple shares. Overriding the configuration means that the share will not be replicated with any project-level actions, though it may be replicated with its own share-level actions that will include the project. It is not possible to override part of the project's replication configuration and inherit the rest. It is strongly recommended that project- and share-level replication be avoided within the same project because it can lead to surprising results (particularly when reversing the direction of replication).
Replication Implementation Notes Replication source and target systems must be running the same 'major' Appliance Firmware Release. Replication target system must be running the same or later 'minor' Appliance Firmware Release. (Note: Replication between systems running Appliance Firmware Release 2013.1.0.x and 2011.1.8.x is supported. Replication between systems running 2013.1.0.x and earlier versions of 2011.1.x IS supported provided certain software features are NOT being used, eg. "Multiple Initiator Groups per LUN" and/or "LUNs or Datasets with 1M record sizes"). See also Document ID 1958039.1 - Remote Replication Compatibility. Replication runs on TCP/IP port 216. (and for 2013.1.4.0/AK8.4.0 and later, port 217 is also required) Encryption is a (performance) bottleneck. Replication actions are based on IP address. You cannot change IP address after the configuration has been set (This restriction has been removed in the 2013.1.x (AK-8) release). Replication uses ZFS features, this means you need to apply deferred updates after code upgrades are completed. Replication was designed to run at the project level. This means that it will take a snapshot of ALL the shares in a project on the source system, even if you are only replication one share. It also means you will have to remove all these extra snaps after each successful replication is complete.
REPLICATION SETUPIdeally, you should configure a dedicated (private) network and use dedicated network interfaces for replication traffic.
1. Setup routing correctly first - to make sure traffic from source to destination will go out through the correct (cluster or not) interface that is tied to the source zpool.It may be a good idea to add a host-specific route to the target system IP address via the dedicated network interface: NAS_src:configuration services routing> create
NAS_src:configuration services route (uncommitted)> get family = (unset) destination = (unset) mask = (unset) gateway = (unset) interface = (unset) NAS_src:configuration services route (uncommitted)> set family=IPv4 NAS_src:configuration services route (uncommitted)> set destination=12.34.56.78 NAS_src:configuration services route (uncommitted)> set mask=32 NAS_src:configuration services route (uncommitted)> set gateway=12.34.56.254 NAS_src:configuration services route (uncommitted)> set interface=nge3 NAS_src:configuration services route (uncommitted)> commit
(mask=32 means this is a host-specific route)
NAS_src:configuration services routing> show
route-000 0.0.0.0/0 123.24.30.254 nge0 static route-001 123.24.30.0/24 123.24.30.28 nge0 dynamic route-002 123.24.150.0/24 123.24.150.10 ibd0 dynamic route-003 123.24.101.65/32 123.24.30.254 nge1 inactive route-005 12.34.56.78/32 12.34.56.254 nge3 static
2. Additionally, setup routing correctly on the target system to make sure traffic to the source is routed back to the correct (cluster or not) interface
NOTE: If replicating to or from a cluster, routing configuration is CRITICAL to be done before starting the replication setup
3. Setup the replication targetBefore a source appliance can replicate to a target, the two systems must set up a replication peer connection that enables the appliances to identify each other securely for future communications.
NAS_src:configuration services replication targets> target
NAS_src:configuration services replication target (uncommitted)> NAS_src:configuration services replication target (uncommitted)> set hostname=10.123.225.201 NAS_src:configuration services replication target (uncommitted)> set root_password=rootpassword NAS_src:configuration services replication target (uncommitted)> set label=repl_1 NAS_src:configuration services replication target (uncommitted)> commit
NOTE: When setting up a replication action, it may be better to set the 'hostname' field to a specific IP address - to ensure that the replication traffic is forced over a specific network interface (and route)
4. Setup the replication actionAfter at least one replication target has been configured, administrators can configure actions on a local project or share by navigating to it in the BUI and clicking the Replication tab or navigating to it in the CLI and selecting the "replication" node. These interfaces show the status of existing actions configured on the project or share and allow administrators to create new actions. Replication actions have the following properties, which are presented slightly differently in the BUI and CLI:
Modes: Manual, Scheduled, or Continuous Replication actions can be configured to send updates manually, on a schedule, or continuously. The replication update process itself is the same in all cases. This property only controls the interval. Because continuous replication actions send updates as frequently as possible, they essentially result in sending a constant stream of all filesystem changes to the target system. For filesystems with a lot of 'churn' (many files created and destroyed in short intervals), this can result in replicating much more data than actually necessary. However, as long as replication can keep up with data changes, this results in the minimum data lost in the event of a data-loss disaster on the source system. Note that continuous replication is still asynchronous (it schedules the "next" replication iteration as soon as the current one is finished). Sun Storage appliances do not currently support synchronous replication, which does not consider data committed to stable storage until it's committed to stable storage on both the primary and secondary storage systems.
To configure replication actions, see Creating and Editing Actions below:
NAS_src:shares PROJECT1/SHARE1 replication> action
NAS_src:shares PROJECT1/SHARE1 action (uncommitted)> get Properties: target = (unset) pool = (unset) enabled = true continuous = false include_snaps = true max_bandwidth = unlimited use_ssl = true NAS_src:shares PROJECT1/SHARE1 action (uncommitted)> set target=repl_sys target = repl_sys (uncommitted) NAS_src:shares PROJECT1/SHARE1 action (uncommitted)> set pool=pool-0 pool = pool-0 (uncommitted) NAS_src:shares PROJECT1/SHARE1 action (uncommitted)> set include_snaps=false include_snaps = false (uncommitted) NAS_src:shares PROJECT1/SHARE1 action (uncommitted)> set use_ssl=false use_ssl = false (uncommitted) NAS_src:shares PROJECT1/SHARE1 action (uncommitted)> commit
NAS_src:shares PROJECT1/SHARE1 replication> ls
Properties: inherited = false Actions: TARGET STATUS NEXT action-000 repl_sys idle manual
NAS_src:shares PROJECT1/SHARE1 replication> select action-000
NAS_src:shares PROJECT1/SHARE1 action-000> ls Properties: id = a751dc0f-abcd-1234-6789-f5e8315eaffa target = repl_sys enabled = true continuous = false include_snaps = false max_bandwidth = unlimited use_ssl = false state = idle state_description = Idle (no update pending) last_sync = <unknown> last_try = <unknown> next_update = manual
5. Perform the initial replication updateThe initial/first replication MUST complete successfully or you must clean up any remnants ('old' actions/snapshots etc.) and start it again. Because the first replication is so critical, it may be useful to replicate as little info as possible on the initial pass by either replicating an empty project or at least do not elect to replicate the snapshots in the project/shares. These can be added later if you really want them to be replicated. If you want the data on the target system to be compressed while it is being written on the target system, enable compression at the project level on the SOURCE system. NOTE: Encryption can be enabled or disabled on the replication stream, and can be changed for the "next" replication iteration.
NAS_src:shares PROJECT1/SHARE1 action-000> sendupdate
6. Select the project to replicate, setup an appropriate schedule (such as 'daily') then enable the action. (The frequency can be selected from one of "halfhour", "hour", "day", "week" or "month") NAS_src:shares PROJECT1/SHARE1 action-000> schedule
NAS_src:shares PROJECT1/SHARE1 action-000 schedule (uncommitted)> set frequency=day frequency = day (uncommitted) NAS_src:shares PROJECT1/SHARE1 action-000 schedule (uncommitted)> set hour=23 hour = 23 (uncommitted) NAS_src:shares PROJECT1/SHARE1 action-000 schedule (uncommitted)> set minute=05 minute = 05 (uncommitted) NAS_src:shares PROJECT1/SHARE1 action-000 schedule (uncommitted)> commit NAS_src:shares PROJECT1/SHARE1 action-000>
The above (example) replication schedule is - Daily at 23:05 pm NAS_src:shares PROJECT1/SHARE1 action-000> ls
Properties: id = a751dc0f-abcd-1234-6789-f5e8315eaffa target = repl_sys enabled = true continuous = false include_snaps = false max_bandwidth = unlimited use_ssl = false state = idle state_description = Idle (no update pending) next_update = Wed Sep 01 2013 23:05:00 GMT+0000 (UTC) last_sync = Wed Sep 01 2013 10:24:05 GMT+0000 (UTC) last_try = Wed Sep 01 2013 10:24:05 GMT+0000 (UTC) last_result = success Schedules: NAME FREQUENCY DAY HH:MM schedule-000 day - 23:05
***Checked for relevance on 25-MAY-2018*** References<NOTE:1958039.1> - Oracle ZFS Storage Appliance: Remote Replication Compatibility<NOTE:2196548.1> - Oracle ZFS Storage Appliance: How to configure dedicated management interfaces <BUG:24388115> - REPLICATION ACTION STUCK IN 'SENDING' STATE WAITING FOR NOTIFICATION FROM REPLD Attachments This solution has no attachment |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|