Quantcast
Channel: SQL Server High Availability and Disaster Recovery forum
Viewing all 4689 articles
Browse latest View live

Witness is Dynamic Quorum env

$
0
0

Hi

We have Always ON in place on SQL/Windows 2016 with dynamic Quorum enabled, the manuall and auto failover is working fine and as expected, do we still need a witness in this config? If yes what benefic can we have by adding a witness ?

Best regards


AlwayOn Backups

$
0
0

Hi Team,

In order to reduce load on Primary, I am planning to take  Copy-Only Full and Log backups on Secondary and Differential Backups on primary, Is it possible?

We are using SQL Server 2016 ENT.




how to open .ndf

Trans log and Diff Backup

$
0
0

Hello guys, i just want to check how Backup works.

Let's say i  will have a settings of Full Backup at 00:00AM (midnight) and 2.5 hours diff backup.

The trans log is already included on the diff and full backup?

Or it has to be done separately?

If needs to be done separately, what would be the ideal schedule?

Thank you for any ideas.


Every second counts..make use of it. Disclaimer: This posting is provided AS IS with no warranties or guarantees and confers no rights.

CPU Usage Shows 95% Continuously

$
0
0

We are using one database on below mentioned hardware configuration. It is a VM on Microsoft Azure.

We have taken a 16 core server and the CPU utilization was continuously going around 95% so upgraded to 32 core CPU but there has been no change in the CPU Utilization. The site traffic has not been much. We would like to understand the solution for this issue.

Server Hardware & Software Configurations:
Microsoft SQL Server 2019 (RTM-CU2) (KB4536075) - 15.0.4013.40 (X64)  Feb  3 2020 16:40:57   Copyright (C) 2019 Microsoft Corporation  Standard Edition (64-bit) on Windows Server 2019  and Server Configurations are Intel(R) Xeon(R) Platinum 8171M CPU @2.6 GHz 2.10 GHz Memory: 256 GB System Type: 64 bit

Thanks

SQL 2017 DAG configuration

$
0
0

HI

WSFC 1 (DC1): gzp-so-prd-db1 & gzp-so-prd-db2 
WSFC 2 (DC2): cml-so-prd-db1 & cml-so-prd-db2

I am trying to configure SQL Server 2017 Distributed Always-On Groups (DAG) from DC1 to DC2 using below steps.  In AG_DISTRIBUTOR, the CLUSTER2_LS - SECONDARY is showing red mark, due to this i am not able to replicate db from DC1 to DC2. Can you please review below steps and correct me with correct steps.

I have executed WSFC validation report, not found any errors in cluster setup.

/*
CLSUETR 1/DC1: gzp-so-prd-db1 & gzp-so-prd-db2 
CLSUETR 2/DC2: cml-so-prd-db1 & cml-so-prd-db2*/

/*STEP1: EXECUTE BELOW COMMAND ON gzp-so-prd-db1*/
CREATE AVAILABILITY GROUP [CLUSTER1_LS]
FOR DATABASE TESTDB
REPLICA ON N'gzp-so-prd-db1' WITH (ENDPOINT_URL=N'TCP://gzp-so-prd-db1.ABC.DEFGH.IJ:5022',
FAILOVER_MODE=AUTOMATIC,
AVAILABILITY_MODE=SYNCHRONOUS_COMMIT,
BACKUP_PRIORITY=50,
SECONDARY_ROLE(ALLOW_CONNECTIONS=NO),
SEEDING_MODE=AUTOMATIC),
N'gzp-so-prd-db2' WITH (ENDPOINT_URL=N'TCP://gzp-so-prd-db2.ABC.DEFGH.IJ:5022',
FAILOVER_MODE=AUTOMATIC,
AVAILABILITY_MODE=SYNCHRONOUS_COMMIT,
BACKUP_PRIORITY=50,
SECONDARY_ROLE(ALLOW_CONNECTIONS=NO),
SEEDING_MODE=AUTOMATIC);
GO

/*STEP2: EXECUTE BELOW COMMAND ON gzp-so-prd-db2*/
ALTER AVAILABILITY GROUP [CLUSTER1_LS] JOIN
ALTER AVAILABILITY GROUP [CLUSTER1_LS] GRANT CREATE ANY DATABASE
GO

/*STEP 3:EXECUTE BELOW COMMAND ON gzp-so-prd-db1*/
ALTER AVAILABILITY GROUP [CLUSTER1_LS]
ADD LISTENER 'Listener_CLUSTER1_LS' (WITH IP
((N'X.Y.8.248',N'255.255.254.0') 
), PORT=1433);
GO

/*STEP 4:EXECUTE BELOW COMMAND ON cml-so-prd-db1*/
CREATE AVAILABILITY GROUP [CLUSTER2_LS]
FOR
REPLICA ON N'cml-so-prd-db1' WITH (ENDPOINT_URL=N'TCP://cml-so-prd-db1.ABC.DEFGH.IJ:5022',
FAILOVER_MODE=MANUAL,
AVAILABILITY_MODE=SYNCHRONOUS_COMMIT,
BACKUP_PRIORITY=50,
SECONDARY_ROLE(ALLOW_CONNECTIONS=NO),
SEEDING_MODE=AUTOMATIC),
N'cml-so-prd-db2' WITH (ENDPOINT_URL=N'TCP://cml-so-prd-db2.ABC.DEFGH.IJ:5022',
FAILOVER_MODE=MANUAL,
AVAILABILITY_MODE=SYNCHRONOUS_COMMIT,
BACKUP_PRIORITY=50,
SECONDARY_ROLE(ALLOW_CONNECTIONS=NO),
SEEDING_MODE=AUTOMATIC);
GO

/*STEP 5:EXECUTE BELOW COMMAND ON cml-so-prd-db2*/
ALTER AVAILABILITY GROUP [CLUSTER2_LS] JOIN
ALTER AVAILABILITY GROUP [CLUSTER2_LS] GRANT CREATE ANY DATABASE
GO

/*STEP 6:EXECUTE BELOW COMMAND ON cml-so-prd-db1*/
ALTER AVAILABILITY GROUP [CLUSTER2_LS]
ADD LISTENER 'LISTNER2' (WITH IP
((N'X.Y.9.248',N'255.255.254.0') 
), PORT=1433);
GO

/*STEP 7:EXECUTE BELOW COMMAND ON gzp-so-prd-db1*/
CREATE AVAILABILITY GROUP [AG_DISTRIBUTOR]
WITH (DISTRIBUTED)
AVAILABILITY GROUP ON 
'CLUSTER1_LS' WITH 
(
LISTENER_URL='TCP://Listener_CLUSTER1_LS:5022',
AVAILABILITY_MODE=ASYNCHRONOUS_COMMIT,
FAILOVER_MODE=MANUAL,
SEEDING_MODE=AUTOMATIC
),
'CLUSTER2_LS' WITH
(
LISTENER_URL='TCP://LISTNER2:5022',
AVAILABILITY_MODE=ASYNCHRONOUS_COMMIT,
FAILOVER_MODE=MANUAL,
SEEDING_MODE=AUTOMATIC
);
GO

/*STEP 8:EXDCUTE BELOW COMMAND ON cml-so-prd-db1*/
ALTER AVAILABILITY GROUP [AG_DISTRIBUTOR] 
JOIN
AVAILABILITY GROUP ON
'CLUSTER1_LS' WITH
(
LISTENER_URL='TCP://Listener_CLUSTER1_LS:5022',
AVAILABILITY_MODE=ASYNCHRONOUS_COMMIT,
FAILOVER_MODE=MANUAL,
SEEDING_MODE=AUTOMATIC
),
'CLUSTER2_LS' WITH
(
LISTENER_URL='TCP://LISTNER2:5022',
AVAILABILITY_MODE=ASYNCHRONOUS_COMMIT,
FAILOVER_MODE=MANUAL,
SEEDING_MODE=AUTOMATIC
);
GO

Secondary Databases Not Recovering

$
0
0

We had a fail over last night due to Windows patches being applied.  Most databases were fine but we had a few that were stuck in Initializing / In Recovery.  From the logs I see the following for the databases in question.

 

-Availability database 'dbname', which is in the secondary role, is being restarted to resynchronize with the current primary database. This is an informational message only. No user action is required.

-Nonqualified transactions are being rolled back in database Administrator for an Always On Availability Groups state change. Estimated rollback completion: 100%. This is an informational message only. No user action is required.

-State information for database 'dbname' - Hardened Lsn: '(20363:176333:1)' Commit LSN: '(20363:176332:1)' Commit Time: 'Apr 8 2020 7:42PM'

-Always On Availability Groups connection with primary database established for secondary database 'dbname' on the availability replica 'nodename' with Replica ID: {...}. This is an informational message only. No user action is required.

-6 transactions rolled forward in database 'dbname' (5:0). This is an informational message only. No user action is required.

-Always On Availability Groups connection with primary database established for secondary database 'dbname' on the availability replica 'nodename' with Replica ID: {...}. This is an informational message only. No user action is required.

 

Those logs lead me to believe the recovery process completed but the databases never actually recovered, syncing did not start back up.  What else can I look at to troubleshoot this issue?  Is this a bug?  We would like to figure out the root cause so this does not occur again.

 

SQL Server version 13.0.5598.27

SQL Server Always on (Read-Scale Availability Group)- Some Question

$
0
0

Hi,

I have implemented SQL Server Always on Availability Group without windows cluster (WSFC) which is a new feature in 2016 version. Though I have implemented it I have some question about how it works internally.

1.       Difference between Synchronous and Asynchronous mode setting separately both in primary and secondary database.
2.       How transaction log transfer from primary to secondary? Is it copied by any job or any other way?
3.       Snapshot possible? Is it possible to stop the link between primary and secondary and use secondary independently?
4.       Long time Secondary down possible? If secondary is down for many days then will primary database keep the transaction log to wait it to be applied in secondary? 
5.       Login password change possible? If we change login password at primary will the password will replicate in Secondary?
6.       Is it beneficial over logshipping? 
7.       If Primary node is shutdown then will the secondary database still be readable?
8.       Is there any query to  find transaction gap analysis in Secondary database?

Please note that this is not traditional Always On Availability group with Windows Server Failover Cluster (WSFC). This is Always on Availability Group without any cluster which is commonly call 'Read-Scale Availability group'.

Regards

Arif


How does sql server FCI respond to failure?

$
0
0

Taking windows role default settings - (n-1) failovers ok within 6 hrs , where n=# of nodes, if nodes = 2, 1 failover within 6 hrs is allowed.

Taking resource default settings - Within 15mins period, 1 restart is allowed on the same node, else failover, RetryPeriodOnFailure is 1 hr

Taking a example of a simple 2 node cluster (node1 & Node2), single sqlFCI (sql), say sql is on node 1 at 9AM.

9AM - sql fails - attempts to restart on Node1 - fails - failsover to Node2 - attempts to restart on Node2 - fails - stays failed.

Now where I am confused is, https://support.microsoft.com/en-us/help/947712/failover-cluster-resource-recovery-behavior-in-windows-server-2008, "If there is no intervention and the resource remains in the failed state for 60 minutes, Windows Server tries to bring the resource online again."

So, according to above, after 60mins, say sometime after 10AM - Does sql try a cycle again :

Attempts sql restart on Node2 - fails - (but cannot failover as 6hrs have not passed)

11AM- Attempts sql restart on Node2 - fails - (but cannot failover as 6hrs have not passed)

12PM - Attempts sql restart on Node2 - fails - (but cannot failover as 6hrs have not passed)

1PM - Attempts sql restart on Node2 - fails - (but cannot failover as 6hrs have not passed)

2PM - Attempts sql restart on Node2 - fails - (but cannot failover as 6hrs have not passed)

3PM - Attempts sql restart on Node2 - fails - failsover to node1 as 6 hrs have passed, tries coming online there , and so on.. is this how it happens? Thanks.


D


SQL 2016 AON AG backup

$
0
0

Hi

We have prepared 2 SQL 2016 Ent with 2 instances and configured 2 X SQL AON AGs. Configured all DBs and AGs are working fine. We set up a full backup of the user databases in a SQL Server Maintenance Plan using the Back Up Database Task.  The full backup job executed successfully, however the backup job did not generate any database backup files.  We want to know the exact procedure to schedule full & differential backups. The backup preference is configured with Secondary

Thanks in advance


LMS

SQL Server 2017: AlwaysOn In A Two Node Windows Cluster

$
0
0

Win2K16 Standard OS. and SQL Server 2017. Two nodes in the cluster. Node 1 is Primary and Node 2 is Secondary. Both are using for SharePoint 2019 Content Databases.

Manual Fail-over from Node 1 to Node 2 works OK in SSMS, but Manual Fail-over from Node 2 to Node 1 fails at the validation part with the following error message:

"The current WSFC cluster quorum vote configuration is not recommended for this availability group. For more information, see the following topic in SQL Server Books Online: http://go.microsoft.com/fwlink/?LinkId=224159."

At the same time Auto fail-over working fine with both nodes.

Also Auto or Manual fail-over working fine for Configuration Database servers/nodes.



How automatic seeding works internally

$
0
0

Dear Experts,

How automatic seeding works internally


Kiran

SSIS package migration

$
0
0

Dear Experts,

We have 1000 SSIS packages. What is the best way to migrate this


Kiran

sp_help_revlogin

$
0
0

Dear Experts,

Does sp_help_revlogin copy server level permissions?


Kiran

SQL server 2012 cluster failed (agent)

$
0
0

Dear all, 

When I install SQL server 2012 cluster on Windows server 2008 R2 cluster, it failed into the information: 

The cluster resource ‘SQL Server Agent’ could not be brought online. Error: There was a failure to call cluster code from a provider. Exeption message: Generic failure. Status code: 5023. Description: The group or resource is not in the correct state to perform the requested operation.

 Click ‘Retry to Retry the filed action, or click ‘Cancel’ to cancel this action and continue setup.

SQL server Database engine was successful.  does anyone have a solution ? 


Always on , data sync in parallel or serial

$
0
0

Hi , We have 2016 SP2 CU3  enterprise version awlays on configured. DB  contained some varbinary, image  type data tables  which DB expecting to grow annually 2TB. probably will store pdf bills with the DB.  expecting to remain 2 year data with archive plan.  so questions 

Q1.can we manage  the DB with such a big size with always on sync. 

Q2. Is that alwayson sync is parallel or serial . 

Q3. We plan to have backup on primary as expecting secondary may have delay  with data. in this case  if not setup backup from secondary , then L drive get fill up  often. What is the solution ? setup log backup and full backup on secondary  site as well?   

any one can help we great. 

regards

Unable to set listener IP on Multiple Availability Groups

$
0
0

Hi All,

I have 3 Databases and for each Database I have set up Availability Group. On 1st Group I have setup listener IP. Using the same Listener IP I am able to access other Groups as well. But when I am trying to add same Listener IP to other Groups it is giving me error. Can any one recommend the steps what I am missing here. Also i tried to Add other Listener IP to other Groups that is also not working. Please suggest

SQL Log Analysis Probelm

$
0
0

I am Currently Working On Database Forensics , If I make some manual changes in the database through some sql queries there is no entry in the logs to prove it..

Can Anyone Suggest me some tools that can give the desired output. ( i.e. the log of all the manual queries fired )

P.S I am using SQL Server 2005

Any help would be appreciated....

Thanks.

SQL Always On 2 nodes with different CU

$
0
0

Hi,

I am about to add second node to availability set, my first node is SQL server 2016 with SP2 CU4 while second will be SQL server 2016 SP2 CU12, is this config with different SPs supported by Microsoft? 

Thanks


Multiple Availability Group on same Secondary

$
0
0

Good Evening Everyone,

                    I want to know whether we can create include the same secondary to one or more availability groups

the example are as below

AG1 - Sever1 DB11 - Primary | Server9 DB12 - Secondary

AG2 - Server2 DB12 - Primary | Server9 DB12 - Secondary

AG3 - Server3 DB13 - Primary | Server9 DB13 - Secondary

Please let me know if I am not clear, I am in bit hurry sorry I couldn't draft this question some clear and simple

MS documentation link would be really appreciate  


Thanks Saravana Kumar C

Viewing all 4689 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>