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

sql ag listner dialog box "network mode" greyed out IN SSMS

$
0
0

sql ag listner dialog box "network mode" greyed out IN SSMS

also tried adding using script, it fails with msg "

The specified IP Address 'xx.xxx.xx.xx' is not valid in the cluster-allowed IP range. Check with the network administrator to select values that are appropriate for the cluster-allowed IP range

"

Also previously added other listeners successfully

We know for a fact ip  is in correct range. Here is the dialog box image:



Please suggest remedy

Thanks


kris vemulaalli


Request to suggest tool to achieve log shipping between servers that are not in same network

$
0
0

Hello everyone,

I have got a doubt in setting up loshipping among servers which are not in the same network.

If we have 3 Servers, One primary, One Secondary in the same network, other secondary not in the same network and these are not exposed to internet. Is it possible to establish Log-shipping among these three servers with out VPN may be using any file copy tools. I request you to suggest any tools that can achieve this.

Quorum setting in SQL AlwaysON setup

$
0
0

Hello,

I have a SQL alwaysON setup between on-prem and Azure SQL server (IaaS). Its a 2 node cluster and have configured file share witness for the quorum( On one of the Azure server). There is a site-to-site VPN configured to facilitate all these. 

Of late , we see our primary DB going down due to instability in cluster. It was noticed that our network goes down there by making secondary node and file share in accessible and cluster gets affected . Due to which all the primary DBs becomes in accessible and application downtime. 

This setup was primarily built for DR purpose and accordingly we have placed the quorum on Azure side.

How can we avoid this situation. I assume all this is due to unavailability of Azure node and File share witness ( this too on Azure) are in accessible at the same time whenever network goes down. 

Is there any configuration changes I can make to make the on-prem stable irrespective of the status of secondary node. 

what quorum method I should adapt for these kind of situation. Please help. 

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

Distributed Always-On Groups (DAG) on SQL Server 2017 Enterprise evaluation version

$
0
0
Hello All,

Is it possible to setup Distributed Always-On Groups (DAG) on SQL Server 2017 Enterprise evaluation version ?

I have total 4 DB VM's (A,B,C,D).  A, B VM's are hosted on Cluster 1 and C,D VM's are hosted on Cluster 2.

A is my primary DB server. Need to setup DAG from A-->B-->C-->D.

Fail over Cluster instance Shared Storage

$
0
0

Dears ,

Which is the optimal solution for Shared Storage/disk  in SQL Server Fail over Cluster on HyperV environment (Windows 2012 R2 / Windows 2016 )


1) Shared Virtual Hard Disk Sets (VHDX) on Hyper-V

2) Row device Mapping /Pass through Disks 

Thanks,




Issue with Differential Backup..

$
0
0
I have two server (mdzeastus2wdb03 & mdzeastus2wdb04), configured in SQL Always On availabilty group for sharepoint Applicaiton. On Saturday, Full backup has been completed succesfully. On Sunday, we had Windows patching has taken place. There has been failover / failback on the server. 
After sunday, differential backup is not happening on the SQL databases ( which was happening before sunday's patching).

Error says "-- 
Cannot perform a differential backup for database "XXXXXXX", because a current database backup does not exist. Perform a full database backup by reissuing BACKUP D

Please mark this reply as answer if it solved your issue or vote as helpful if it helped so that other forum members can benefit from it

Bytes per physical sector size on Azure VM Disk

$
0
0

Hello.

We are using AG to Replicate SQL Server 2017 databases to Azure VM.

On premise our Bytes per physical sector size =512K

On the Azure Server Bytes per physical sector size=4096K.

I have witnessed the misaligned log IO's message in my replica log.

I have been researching and found the T1800 flag.   I applied the trace flag to the Server with Bytes per physical sector size =512K.

Questions:

1)   Does this Flag require a server reboot? I applied it directly and added to start up parameters.

2) Is it possible to add DISK in AZURE with Bytes per physical sector size =512K?

     If so how is that accomplished?

Thank you

Mark G


Replication + Always-on

$
0
0

Anyone try before to setup replication on a Always-on AG group ?

Support the publisher is set on primary node, and once the primary node shutdown/failure,

the replication still work when failover to 2nd node ?

how to install cumulative update on sql server on linux

$
0
0

Hi there,

I need you guys advice.

How can I install CU16 in offline. I have SQL on Linux configured failover cluster with 'rose-mirror' and want to update CU from CU6 to CU16 for both Active node and Passive node. Do you have any idea for this?

Thanks in advance! 😊

VSS Writer SqlServerWriter fails with 3rd party backup solution.

$
0
0

I am having some troubles with the Sql VSS writer. I am using a 3rd party backup solution, and it is failing because each time a snapshot is attempted the writer (SqlServerWriter) fails with a non-retryable error. The same thing happens with the built in Windows Server Backup utility. There are a few notable entries in the Event Logs on the server. One names error 0x800423f4, the other0x80070005, which is an access denied error. Trouble is, the writer is set to run under the local system account, and the local system account has SysAdmin privileges on the databases. I've spent quite a few hours over the past week or two attempting to solve this and have had no luck. Any ideas where this writer is failing? This is a SQL 2008r2 install.

Thanks,

Josh

 

 

Sqllib error: OLEDB Error encountered calling ICommandText::Execute. hr = 0x80040e14. SQLSTATE: 42000, Native Error: 3013
Error state: 1, Severity: 16
Source: Microsoft SQL Server Native Client 10.0
Error message: BACKUP DATABASE is terminating abnormally.
SQLSTATE: 42000, Native Error: 18210
Error state: 1, Severity: 16
Source: Microsoft SQL Server Native Client 10.0
Error message: BackupVirtualDeviceSet::Initialize: CoCreateInstance failure on backup device '{730A7E71-C123-4F80-A1E3-DEF2BDE8E112}3'. Operating system error 0x80070005(Access is denied.).

 

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

A VSS writer has rejected an event with error 0x800423f4, The writer experienced a non-transient error. If the backup process is retried,
the error is likely to reoccur.
. Changes that the writer made to the writer components while handling the event will not be available to the requester. Check the event log for related events from the application hosting the VSS writer.

Operation:
 PrepareForSnapshot Event

Context:
 Execution Context: Writer
 Writer Class Id: {a65faa63-5ea8-4ebc-9dbd-a0c4db26912a}
 Writer Name: SqlServerWriter
 Writer Instance Name: SQL Server 2008 R2:SQLWriter
 Writer Instance ID: {e37d5783-6dd3-4bde-ae44-c179982fb65b}
 Command Line: "C:\Program Files\Microsoft SQL Server\90\Shared\sqlwriter.exe"
 Process ID: 8984

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

This is what the 'vssadmin list writers' command turns up for the SQL Writer after an attempted snapshot. Only way to recover it is to restart the server.

 

Writer name: 'SqlServerWriter'
 Writer Id: {a65faa63-5ea8-4ebc-9dbd-a0c4db26912a}
 Writer Instance Id: {ac3d731f-6a0f-4537-8d6f-1ffad6dd9d8f}
 State: [8] Failed
 Last error: Non-retryable error

 

 

 



Can high CPU on secondary replica effect the primary replica in synchronous Always on AG?

$
0
0

Hi All,

I got the following error on my primary replica when the CPU on the secondary server went 100% and no connections were allowed on secondary replica(only DAC was allowed)

"The connection to the primary replica is not active.  The command cannot be processed."

I also got huge no of blockings on primary replica(Node1) due to which almost all of our applications went down.

Could this be due to the huge CPU on Node2 which subsequently delayed the acknowledgement process? or it could be for any other reason?

Windows server 2016 

Node1 -> Node2 (synchronous always on AG)



Regards, Ashif Shaikh




The log reuse (truncation) wait shows “availability_replica”

$
0
0
The log reuse (truncation) wait shows “availability_replica” (log record truncation is prevented by a secondary replica) but I have never seen this wait type for an availability group which just got one replica, just wondering the reason.

Best Regards, Arun http://whynotsql.blogspot.com/

Standard SQL 2016 Basic availability group

$
0
0

Hi,

I got a requirement to configure basic Alwayson availabillity group in sql 2016 standard edition.
May i know prerequisites.

For Basic Always on do we need Active directory,Fail over cluster, and DNS?

I got 2 new blank vms. Do i need to add this two nodes in fail over cluster??? I have to do it everything from scratch. Please help what else i can do it to configure the basic alwayson in standard sql 2016.

Thanks,
Jo


pols

OpenRowSet without sysadmin rights

$
0
0

Hi,

When I execute

SELECT * FROM OPENROWSET('Microsoft.ACE.OLEDB.12.0','Excel 12.0 Xml;HDR=YES;Database=\\LinkedServer\Share\TEST\emp.xls','SELECT * FROM [Sheet1$]');

 I got error 

"Ad hoc access to OLE DB provider 'Microsoft.ACE.OLEDB.12.0' has been denied. You must access this provider through a linked server."

I run it without sysadmin roles or rights. I give ADMINISTER BULK OPERATIONS permission to the user. Even using this user I can execute   EXEC xp_cmdshell  'dir "\\LinkedServer\Share\TEST\emp.xls"' 

How to execute OPENROWSET command without sysadmin permission plz help me.


Unable to identify Global primary or Forwarder by code (AlwaysOn - SQL Server 2017)

$
0
0
In a DAG topology there is a need to identify the Global primary and the forwarder replica by database. 
The existing function - sys.fn_hadr_is_primary_replica returns 1 in both cases and if for example we have a job that need to write then it can be done only on Global primary (Forwarder is read only). 
We need a simple way to identify these role without a very complex query.

I Think that it will be important to have a column in related DMV/system views to identify them both in order to avoid exceptions.

How to tell if one sql server database need to be moved to HA cluster or keep on standalone instance?

$
0
0

This question is more business than technical.

If you ask the user, every one wants to move to HA. But it will cost huge for business.

Any suggestion? THanks

Basic Availability setup without active directory

$
0
0

Hi ,

I am trying to configure Basic Allwayson in SQL 2016 Standard edition using the below ebsite

https://www.sqlpassion.at/archive/2016/01/11/how-to-create-a-sql-server-availability-group-without-an-active-directory-domain/

I did below things.

Firewalls off in both nodes SQL-1 & Sql-2
I created DNS Suffix in both servers as Testing.com
Remote registry and Remote administration is enabled in both nodes.
i enabled Failover clustering

In powershell command i tried this beow command

new-cluster -name sqlbag –Node SQL-1,SQL-2 -StaticAddress 1.2.3.4 -NoStorage –AdministrativeAccessPoint DNS

got below error:

New-Custer: There was an error adding node SQL-1 to the cluster
failed to access remote registry on sql-1.Testing.com .. Ensure that the remote registry service is running and have remote administration enabled.The network path was not found.

Note :Remote registry and Remote administration is enabled in both nodes.

Please help how to resolve this?


pols

SQL Server and Windows Backup Bug/Issue.

$
0
0

Hello,

I have two servers, both with Windows 2019 STD + SQL Server 2017 STD installed.

The hosted MS SQL Databases are being replicated using Basic Always on Availability Groups, while testing Windows Server Backup (full server backup) on the primary and secondary SQL Server, I've found out that the backup completes successfully on the primary server, but on the replica server the backup finishes with errors.

Before jumping to conclusions, during the testing period I used SQL Server 2017 Evaluation (feature level equivalent to SQL Server 2017 Enterprise), with the same configuration, and on both primary and secondary servers, Windows Server Backup finishes without issues.

The reason it doesn't work on the Standard version of SQL Server 2017 is because the secondary replica cannot be set to readable during the backup process, and so the backup finishes with errors.

The error as shown in the Event Viewer:

Log Name:      Application
Source:        SQLWRITER
Date:          9/10/2019 12:52:52 AM
Event ID:      24583
Task Category: None
Level:         Error
Keywords:      Classic
User:          N/A
Computer:      SERVERNAME
Description:
Sqllib error: OLEDB Error encountered calling ICommandText::Execute. hr = 0x80040e14. SQLSTATE: 42000, Native Error: 3013
Error state: 1, Severity: 16
Source: Microsoft SQL Server Native Client 11.0
Error message: BACKUP DATABASE is terminating abnormally.
SQLSTATE: 42000, Native Error: 976
Error state: 1, Severity: 14
Source: Microsoft SQL Server Native Client 11.0
Error message: The target database, 'WideWorldImporters', is participating in an availability group and is currently not accessible for queries. Either data movement is suspended or the availability replica is not enabled for read access. To allow read-only access to this and other databases in the availability group, enable read access to one or more secondary availability replicas in the group.  For more information, see the ALTER AVAILABILITY GROUP statement in SQL Server Books Online.

Is there any way to do a full server backup on the secondary replica server? I mean other than doing a fail over, backup and then fail back to primary.

Thank you!

Creating SQL Login in an AlwaysOn SQL node

$
0
0

Hello,

I have a 2 node SQL cluster for AlwaysOn availability groups.  I will be using the group listener for an application that will create the database but need to provide a SQL login for the authentication.  If I create a sql login on the SQL node that is currently the primary, how will this account get created on the secondary node?

I'm looking for some for how to handle this the best/correct manner. 

Thank you,


Rumi

Viewing all 4532 articles
Browse latest View live


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