What you will be able to do
- Configure a group so that security integrations actually replicate
- Prepare SAML2, OIDC, SCIM and OAuth integrations so sign-in still works after failover
- Check after a refresh that users, integrations, roles and grants arrived
- Use REPLICATION_GROUP_REFRESH_HISTORY to check the state of each refresh
1.Letting security integrations into the group
Snowflake can replicate SAML2 and OIDC (federated SSO), OAuth and SCIM security integrations, across regions and across cloud platforms. Adding INTEGRATIONS to OBJECT_TYPES does not replicate them on its own. A second setting, ALLOWED_INTEGRATION_TYPES, chooses which kinds of integration are included, and security integrations are included only if they are listed there. The configuration guide's example group lists ALLOWED_INTEGRATION_TYPES = API INTEGRATIONS. A group configured like that would replicate API integrations but leave your SSO and provisioning integrations behind.
CREATE FAILOVER GROUP FG OBJECT_TYPES = users, roles, warehouses, resource monitors, integrations ALLOWED_INTEGRATION_TYPES = security integrations ALLOWED_ACCOUNTS = example.northamericaeast REPLICATION_SCHEDULE = '10 MINUTE';Checkpoint 1 of 6· Check yourself
A group has INTEGRATIONS in OBJECT_TYPES and ALLOWED_INTEGRATION_TYPES = API INTEGRATIONS. After a refresh, the Okta SCIM integration is missing in the target account. What needs to change?
A SCIM integration replicates only if the group lists security integrations in ALLOWED_INTEGRATION_TYPES.
“The failover group must include ALLOWED_INTEGRATION_TYPES = security integrations for the SCIM security integration to replicate.”Source: docs.snowflake.com
Sources1
2.SAML2: point the IdP at the connection URL
For each type of integration, the documented test follows the same four steps. First identify the source account, the target account and the connection URL. Then complete the steps in the source account, then the steps in the target account, and finally test failover and failback.
For SAML2, the important point is the connection URL. In the source account, set SAML2_SNOWFLAKE_ISSUER_URL and SAML2_SNOWFLAKE_ACS_URL to the connection URL rather than to the account URL, and configure the IdP application with that same URL. Users must also exist in the source account. If either of these updates is missing, Snowflake cannot verify users and they cannot sign in to the target account.
There is one limitation. Replicating a SAML2 integration that specifies the connection URL works only on the current primary connection. After a failover, SAML SSO works on the new primary connection. If you need SSO on both the primary and the secondary connection at the same time, create and manage a SAML2 integration separately in each account.
ALTER CONNECTION global PRIMARY;Checkpoint 2 of 6· Put it in order
Put the documented general approach for testing integration replication in order
- 1.Identify the source account, target account and connection URL
- 2.Complete the steps in the target account
- 3.Test failover/failback
- 4.Complete the steps in the source account
Configuration in the source account (integration and group) has to be in place before the target account can create replicas and refresh. Failover is tested last.
“Identify the source account and target account for replication, and identify the connection URL.”Source: docs.snowflake.com
Sources1
3.OIDC, SCIM and OAuth after failover
The other integration types each have their own details.
| Integration | What to do for the target account |
|---|---|
| OIDC, OIDC_PROVIDER='CUSTOM' | OIDC_REDIRECT_URIS is generated per account. Run DESC INTEGRATION in the target account and register its redirect URIs with the IdP. Not Client Redirect-aware. |
| OIDC, OIDC_PROVIDER='GOOGLE' or 'MICROSOFT' | Snowflake manages the OAuth client configuration, so there is no per-account redirect URI to register |
| SCIM | Run SHOW CONNECTIONS to confirm the source account holds the primary connection, and list security integrations in ALLOWED_INTEGRATION_TYPES |
| Snowflake OAuth | Refresh, then verify you can connect to each account with the OAuth client of your choice |
OIDC needs particular care. The integration's properties replicate with it, including OIDC_CLIENT_SECRET, which is encrypted at rest. For a custom provider, though, the redirect URIs registered with the IdP are tied to the account where the integration was created. If you fail over through Client Redirect, you must also register the secondary account's redirect URI with the IdP yourself. SAML2 avoids this problem because it advertises both the primary and secondary ACS URLs through SAML2_SNOWFLAKE_OTHER_ACS_URLS. OIDC has no equivalent setting yet.
Checkpoint 3 of 6· Check yourself
A custom-provider OIDC integration replicated cleanly, but SSO fails in the target account after failover. What is the most likely missing step?
Custom-provider redirect URIs are generated for each account and are not Client Redirect-aware. You look up the target account's value with DESC INTEGRATION and register it with the IdP.
“OIDC integrations using OIDC_PROVIDER='CUSTOM' are not Client Redirect-aware.”Source: docs.snowflake.com
Sources1
4.Validating users, roles and grants
Validation starts before the first refresh. Run SHOW USERS and SHOW INTEGRATIONS in the target account to get a baseline. After the refresh, the counts should rise by the number of new users and integrations. Run DESCRIBE INTEGRATION on each replicated integration to confirm its settings. For network policies, check that SHOW NETWORK POLICIES lists them and that DESCRIBE SECURITY INTEGRATION shows the replicated policy on the integration. If users or roles already exist in the target account but not in the source, read Initial replication of users and roles before you create the secondary group.
Role replication includes the privileges granted to roles and the role hierarchy. If users are replicated as well, the grants of roles to users replicate too. The SNOWFLAKE database itself is never listed in a group. Even so, when roles are replicated, the grants of its database roles and application roles to account roles, and IMPORTED PRIVILEGES on it, replicate as well.
Because of this, an audit of the target account has to check SNOWFLAKE database grants directly. A clean source account does not mean the target is clean. Also note that a refresh fails if the user who calls it in the target account has been dropped in the source account. Do not run refreshes as a personal user who might leave the organization.
Checkpoint 4 of 6· Check yourself
After a refresh, which commands confirm that a SAML2 integration and newly provisioned users arrived in the target account?
The documented check compares user and integration counts before and after the refresh, then inspects the replicated integration.
“SHOW INTEGRATIONS (should include 1 new integration) SHOW USERS (should include the number of new users added)”Source: docs.snowflake.com
5.Checking refresh status
Comparing object counts tells you what arrived. The INFORMATION_SCHEMA table function REPLICATION_GROUP_REFRESH_HISTORY tells you how each refresh went: it reports a phase_name, start_time and job_uuid for every refresh of the group. A finished refresh shows the phase COMPLETED and a cancelled one shows CANCELED. A refresh in any other phase is still running. You cannot promote a group while a refresh is in progress, so this query is also the check to run before a failover.
SELECT phase_name, start_time, job_uuid FROM TABLE(INFORMATION_SCHEMA.REPLICATION_GROUP_REFRESH_HISTORY('myfg')) WHERE phase_name <> 'COMPLETED' and phase_name <> 'CANCELED';Checkpoint 5 of 6· Exam question
An auditor asks which roles in the primary account can create replication or failover groups and which roles can refresh a particular group. Which TWO actions give accurate answers?(Select 2)
Correct answers: A, D — Run SHOW GRANTS ON REPLICATION GROUP for the group in question and review the REPLICATE and OWNERSHIP rows returned.; Query SNOWFLAKE.ACCOUNT_USAGE.GRANTS_TO_ROLES, filtering on the group creation privileges and the group object type.
- A. Correct: SHOW GRANTS ON the group object lists which roles hold REPLICATE and OWNERSHIP on it.
- B. Incorrect: LOGIN_HISTORY records authentication events and says nothing about privilege grants on groups.
- C. Incorrect: this view tracks usage and cost per group, not privilege grants.
- D. Correct: GRANTS_TO_ROLES records privilege grants, so filtering on the privilege and object type lists every role holding them.
- E. Incorrect: that view reports credits and bytes consumed by replication, not who holds privileges.
Checkpoint 6 of 6· Check yourself
The query above returns no rows for myfg. What does that tell you?
The filter removes rows in the COMPLETED and CANCELED phases. An empty result therefore means no refresh is still running.
“Verify no refresh operations are in progress for the failover group myfg.”Source: docs.snowflake.com
Sources4
Exam traps
Each one states something that sounds right. Open it to see what is actually true.
1.Adding INTEGRATIONS to OBJECT_TYPES is enough to replicate SAML2, OAuth and SCIM integrations.Why is that wrong?
Security integrations replicate only if ALLOWED_INTEGRATION_TYPES also lists security integrations.
Covered in Letting security integrations into the group
2.A replicated SAML2 integration that uses the connection URL gives SSO on the primary and secondary connections at the same time.Why is that wrong?
It works only on the current primary connection. To have SSO on both, manage a separate SAML2 integration in each account.
Covered in SAML2: point the IdP at the connection URL
3.Revoking a SNOWFLAKE database role grant in the source account removes it from the target account at the next refresh.Why is that wrong?
These grants replicate additively, so a revocation does not propagate and you have to revoke it in the target account as well.
Covered in Validating users, roles and grants
Practise it for real
Set up a failover group with least-privilege roles, refresh it and verify the result
1.In the source account, as ACCOUNTADMIN, run: USE ROLE ACCOUNTADMIN; CREATE ROLE myrole; GRANT CREATE FAILOVER GROUP ON ACCOUNT TO ROLE myrole;
Why: From this point, group creation is done by a narrow role instead of ACCOUNTADMIN
You should see: The statements succeed and myrole holds CREATE FAILOVER GROUP
2.In the target account, run SHOW USERS and SHOW INTEGRATIONS and write down the counts
Why: These counts are the baseline you will compare against after the refresh
You should see: The current number of users and integrations in the target account
3.As myrole in the source account, create a failover group with OBJECT_TYPES that include users, roles and integrations, ALLOWED_INTEGRATION_TYPES = security integrations, and ALLOWED_ACCOUNTS set to the target account only
Why: These settings control which object types leave the source and which account may receive them
You should see: SHOW FAILOVER GROUPS lists the new primary group
4.As the role that owns the group, run GRANT REPLICATE ON FAILOVER GROUP myfg TO ROLE my_replication_role; in both the source and target accounts
Why: REPLICATE is not replicated, so it must be granted in each account
You should see: my_replication_role holds REPLICATE on the group in both accounts
5.In the target account, create the replica with CREATE FAILOVER GROUP ... AS REPLICA OF, then run USE ROLE my_replication_role; ALTER FAILOVER GROUP myfg REFRESH;
Why: Brings the target account up to date with the source
You should see: The refresh completes without error
6.Run SHOW USERS, SHOW INTEGRATIONS and DESCRIBE INTEGRATION in the target account, then run the REPLICATION_GROUP_REFRESH_HISTORY query
Why: Confirms the objects arrived and that no refresh is still running
You should see: Higher counts than the baseline and no rows from the history query
Stuck? Get a nudge
If the refresh fails, check that every object a replicated network policy depends on is included in the group, and that the user calling the refresh still exists in the source account.
Sources
Every claim above is drawn from one of these pages, quoted as it was written on the date shown.
- 1.
“Snowflake supports replicating network policies and security integrations for federated SSO (that is, SAML2 and OIDC), OAuth, and SCIM”
↩︎ Letting security integrations into the group“It is important to update the identity provider to specify the connection URL and that users exist in the source account.”
↩︎ SAML2: point the IdP at the connection URL“create and manage SAML2 security integrations independently on both Snowflake accounts”
↩︎ SAML2: point the IdP at the connection URL“integration properties replicate with it, including OIDC_CLIENT_SECRET (encrypted at rest)”
↩︎ OIDC, SCIM and OAuth after failover“Execute SHOW CONNECTIONS to verify that the connection in the source account is the primary connection.”
↩︎ OIDC, SCIM and OAuth after failover“Verify connecting to each Snowflake account using the OAuth client of your choice.”
↩︎ OIDC, SCIM and OAuth after failover“Prior to replication, verify the number of users and security integrations that are present in the target account”
↩︎ Validating users, roles and grants“Include integrations in the failover group and specify ALLOWED_INTEGRATION_TYPES = security integrations.”
↩︎ Exam trap 1“replicating a SAML2 security integration that specifies the connection URL is only supported on the current primary connection”
↩︎ Exam trap 2“The failover group must include ALLOWED_INTEGRATION_TYPES = security integrations for the SCIM security integration to replicate.”
↩︎ Checkpoint“Identify the source account and target account for replication, and identify the connection URL.”
↩︎ Checkpoint“OIDC integrations using OIDC_PROVIDER='CUSTOM' are not Client Redirect-aware.”
↩︎ Checkpoint“SHOW INTEGRATIONS (should include 1 new integration) SHOW USERS (should include the number of new users added)”
↩︎ Checkpoint - 2.
“Includes privileges granted to roles, as well as roles granted to roles (that is, hierarchies of roles).”
↩︎ Validating users, roles and grants“If users and roles are replicated, roles granted to users are also replicated.”
↩︎ Validating users, roles and grants“A grant on the target account remains in place even after the corresponding grant is revoked on the source account.”
↩︎ Exam trap 3“A grant on the target account remains in place even after the corresponding grant is revoked on the source account.”
↩︎ Prediction - 3.
“If the user who calls the function in the target account was dropped in the source account, the refresh operation fails.”
↩︎ Validating users, roles and grants“If account objects (for example, users or roles) exist in the target account that do not exist in the source account”
↩︎ Validating users, roles and grants - 4.
“Verify no refresh operations are in progress for the failover group myfg.”
↩︎ Checking refresh status