BACKUP with COMPRESSION OPTION
SQL Server Agent Services
Hi,
In SQL 2014 Always On availability group, with 2 nodes cluster.
SQL1 - Primary Replica
NB SQL Server Agent service is set to Automatic & is started.
SQL2 - Secondary Replica
In regarding to the SQL Server Agent services on the Secondary Replica:
- Does the SQL Server Agent Services in the Secondary Replica need to beStarted on both SQL servers?
- Should it be set to 'Automatic in the Secondary Replica'?
Thank you
SQLServer AAG for DataWarehouse !!
All,
We tried using Double-Take to replicate our DataWarehouse box containing 20TB of data to our DR site but it has failed many times to even do the initial synch up. Every time it breaks during this phase, it restarts the whole syncing process from beginning.
AlwaysOn came up as an option to maintain the DR environment but I told them it is not the right technology for a system like DataWarehouse. Every night we have the daily loads running for 6hrs in addition to the monthly loads that take a lot more time. If we go this route, we have to, change the recovery mode to Full, have the tape backup team backup the database and then restore it on the secondary and eventually synch up and if anything happens to the synch later in the worst case we might have to redo the synch up. The good thing is after the load there are no activities for the replicas to catchup. But I don’t know what the ramifications, in terms of the Transaction Log, are. We could also direct all backups against the DR replica.
I just want to know what technology is being used in other companies/setups.
Thanks,
rajee
Recover deleted rows with no backup
Hi,
I am a rookie at SQL Server and I have deleted by mistake all rows from some tables usingDelete <Table> from a database that has no backup...ever but it's on FULL MODE.
I have seen some samples of how to restore data using LSN, but I just can't understand the procedure, and I have no money to buy an expensive software (like ApexSQL) to get my data back.
I followed instructions on how to do it in here:
https://www.sqlshack.com/how-to-take-advantage-of-sql-servers-transaction-log/
Any simpler way or a REAL free tool to do it?
Thanks in advance.
G.Waters
File backups from Maintenance Plan (2008 R2)
I can never get enough backups, so besides backing up my databases to tape each night, I also have local file backups created under the maintenance plan section that backs up all my databases and their transaction logs.
The one problem I have is that I'd like to only keep 1 backup of each database, so I've set it to expire after 1 day, but apparently that does not delete the older files, and if I don't delete them myself, the disk will fill up pretty quickly (doing FULL backups).
I could've sworn I had this setup so it only keeps the most current backup file before, but now it won't do it.
What am I missing?
Thanks!
XML Task in SSIS 2008 R2 vs SSIS 2016
XML Task performing XSLT transformation to modify an xml file. It uses same flatfile connection as source and destination.
Works fine in SSIS 2008 R2 but the same is not observed in SSIS 2016. In SSIS 2016, it gives error message like "File ABC.xml is being used by another process."
Can someone please advice on this.
Is there some change in the XML task itself? Or is it some bug in SSIS 2008 R2 XML task that was fixed in its successor versions?
Recommendations for SQL 2017 DR solution
Hello.
We have some internal applications that rely on SQL databases (currently using Microsoft SQL Server 2012 on Windows 2008 R2). There are several instances with several DBs each. I have purchased SQL server 2017 licenses to upgrade but would also like to improve our DR solution.
Our current DR solution is to backup the DB in SQL every night and copy it to a file share at the DR site. This would then get restored at the other end when required. Not ideal, as it only gives a 24 hour RPO, but it works.
As I am building new servers for the upgrade (Windows 2016 VMs on VMware ESX hosts) I would like to consider other options to give us real-time replication and a faster restore. The dream would be to have a server powered on and running SQL at the DR site waiting to be manually activated in a DR scenario.
Licensing is also a consideration - I don't want a solution that requires a license for the DR site that will (hopefully) never get used). I can only afford the license for our main site.
The load is low (about 50 users all at one site) and the DBs are only a few GB in size. The ESX hosts are standalone at each site with no shared storage across sites.
Any suggestions of how best to proceed would be gratefully received! I guess I can't use a Failover Cluster Instance without shared storage between the two sites?
2 NODE ALWASYON
In case if we configure the alwasyon automatic fail-over(2 node)
1. how the application connect the either one of the node
2. how the transaction move one node to another node during fail over
2. seen during installation manual and automatic each node do i want select automatic for each node
DC-DR Replication
Hello Experts,
I am new to SQL Database and I need help to understand DC-DR replication in SQL.
So here is the task.
In our production environment, we have Clustered SQL servers in DC and 1 stand alone sql server in DR.
There is not replication of DB between DC & DR. All services are running from DC itself. Now, I want to configure DR site so that in case of failure we can get services up from DR site.
How can I configure SQL so that DB from DC SQL Server replicates to DR SQL Server?
Always on Availability group and HA are not options here.
I would appreciate your advice.
Thanks
SQL Server 2107 upgrading evaluation version to standard edition [Clustered]
Hi,
I implemented an sql server clustering with sql 2017 evaluation version. Now I want to upgrade it to standard edition. When I tried to upgrade, it is showing as source editon: evaluation and target edition standard is a not a valid upgrade path. So how can I do an upgrade . Any body please advise
Listener creation fails in Always on Availability group confirugation
Listener creation fails with below error in SQL Server 2014 Ent edition. Cluster is hosted on Windows 2016 Data center edition.
Msg 19471, Level 16, State 0, Line 3
The WSFC cluster could not bring the Network Name resource with DNS name 'LSNRSQL01.XXX.co.nz' online. The DNS name may have been taken or have a conflict with existing name services, or the WSFC cluster service may not be running or may be inaccessible. Use
a different DNS name to resolve name conflicts, or check the WSFC cluster log for more information.
Msg 19476, Level 16, State 4, Line 3
The attempt to create the network name and IP address for the listener failed. The WSFC service may not be running or may be inaccessible in its current state, or the values provided for the network name and IP address may be incorrect. Check the state of the
WSFC cluster and validate the network name and IP address with the network administrator.
Note: AD Admin confirmed that cluster account have permission to create computer objects.
Found below details in Cluster log:
[RCM] rcm::RcmResource::Control: (AGL_LSNRSQL01, GET_CRYPTO_CHECKPOINTS)
[Verbose] 00001754.00001c98::2018/10/05-11:41:54.433 ERR [RES] Network Name: [NNLIB] Could not generate crypto key, status 5
[Verbose] 00001754.00001c98::2018/10/05-11:41:54.433 ERR [RES] Network Name: [NN] Encrypting password using crypto access failed, error 5
[Verbose] 00001754.00001c98::2018/10/05-11:41:54.437 INFO [RES] Network Name <AGL_LSNRSQL01>: AccountAD: OnInitializeEnd: 5
[Verbose] 00001754.00001c98::2018/10/05-11:41:54.437 INFO [RES] Network Name: Agent: OnInitializeReply, Failure on (4144ad98-b77b-43a1-ba35-2658f9677514,AccountAD): 5
[Verbose] 00001754.00001c98::2018/10/05-11:41:54.437 INFO [RES] Network Name <AGL_LSNRSQL01>: Configuration: InitializeReplyCreation of NetName (type Singleton), result: 5, IsCanceled: false
[Verbose] 000009f0.0000196c::2018/10/05-11:41:54.437 DBG [API] s_ApiSetValue(StatusKerberos)
.
.
[Verbose] 00001754.00002bd4::2018/10/05-11:41:55.022 INFO [RES] Network Name: [NNLIB] FindSuitableDCNew - objectName LSNRSQL01, username - SQLPRODCLSTR$, firstChoiceDCName -
[Verbose] 000009f0.00003178::2018/10/05-11:41:55.376 DBG [GEM] Node 3: Sending GemMaxAckControl message with gid 2465. Last acknowledged gid was 2447
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.050 INFO [RES] Network Name: [NNLIB] Object LSNRSQL01 not found on first choice DC. DCName - .
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.708 INFO [RES] Network Name: [NNLIB] Object LSNRSQL01 not found on second choice DC. DCName -
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.708 INFO [RES] Network Name: [NNLIB] Returning first choice DC that does not have the object LSNRSQL01.
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.745 DBG [RHS] Resource AGL_LSNRSQL01 called SetResourceStatusEx: checkpoint 2. Old state OnlinePending, new state OnlinePending, AppSpErrorCode 0, Flags 0, nores=false
[Verbose] 000009f0.00001930::2018/10/05-11:41:56.745 DBG [RCM] rcm::RcmResource::Control: (AGL_LSNRSQL01, GET_CRYPTO_CHECKPOINTS)
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.772 ERR [RES] Network Name: [NNLIB] Could not acquire crypto context, status 2148073487
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.772 ERR [RES] Network Name: [NN] Encrypting password using crypto access failed, error 2148073487
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.776 INFO [RES] Network Name <AGL_LSNRSQL01>: AccountAD: OnInitializeEnd: -2146893809
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.776 INFO [RES] Network Name: Agent: OnInitializeReply, Failure on (4144ad98-b77b-43a1-ba35-2658f9677514,AccountAD): -2146893809
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.776 INFO [RES] Network Name <AGL_LSNRSQL01>: Configuration: InitializeReplyCreation of NetName (type Singleton), result: -2146893809, IsCanceled: false
[Verbose] 000009f0.00001930::2018/10/05-11:41:56.776 DBG [API] s_ApiSetValue(StatusKerberos)
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.780 INFO [RES] Network Name: Agent: OnInitializeReply, Failure on (4144ad98-b77b-43a1-ba35-2658f9677514,Configuration): -2146893809
[Verbose] 00001754.00002bd4::2018/10/05-11:41:56.780 INFO [RES] Network Name <AGL_LSNRSQL01>: SyncReplyHandler Configuration, result: -2146893809
[Verbose] 00001754.00002cd8::2018/10/05-11:41:56.780 INFO [RES] Network Name <AGL_LSNRSQL01>: PerformOnline - Initialization of Configuration module finished with result: -2146893809
[Verbose] 00001754.00002cd8::2018/10/05-11:41:56.780 ERR [RES] Network Name <AGL_LSNRSQL01>: Online thread Failed: (0)' because of'Initializing netname configuration for AGL_LSNRSQL01 failed with error -2146893809.'
Please help.
Move DB and Log when Old Server is not Reachable
Use to have a SQL DB's stored on a JBoD device attached to a server via SaS. The server has died and not recoverable. I took the SaS HBA and installed it into another server to access all the data on those drives. I built a new SQL cluster on a new server and copied the DB and log file to the new DB space. I then launch SSMS and attach database. Add the mdf (no log file shows up). It fails with something like: it can't find the log ldf on the old server (\\oldserver\log\db.ldf). How can i move this DB to the new server along with the ldf?
Clik here to view.
how to log shipping 2 trabyte data
Hi
How to logshipping in to a 2 TB database so that I do not want to use a network connection I also do not know if I used to use the hardware or network and I do not know how it needs and architecture. Thank you for helping me...
Pivot
Removing Always On and leaving standalone SQL instance? (SQL 2014 Always On)
I've got a 2 node SQL Server Environment that was setup as always on. (Windows 2012R2/SQL 2014). I have removed all the databases that were part of the always on group, deleted the AOAG listener, and deleted the AOAG group.
My question is this..
One of the nodes in the AOAG environment has some databases just on that specific node (not part of the AOAG). Is there a way for me to break down the cluster and get rid of everything but still keep the standalone SQL running on one of the nodes with the databases that were on it?
As an example - let's say my environment looks like this:
SQLNODEA
SQLNODEB
SQLAOAGLISTENER (the AOAG LISTENER)
I've deleted the listener and AOAG above, but I still have some databases JUST served directly off SQLNODEA.
How can I get rid of the Windows clustering stuff but still keep SQLNODEA? Can I evict SQLNODEA from the cluster and let it run standalone? Then delete/shutdown SQLNODEB as it's no longer needed?
I remember in the past with SQL Shared storage clusters that there was no way to get rid of the cluster without uninstalling SQL, but I thought that might not be applicable to Always on since each server is it's own SQL installation? I have a couple of applications pointed directly at the SQL instance on SQLNODEA and ideally I'd like to keep that server running by itself, and shutdown/get rid of SQLNODEB
Thanks for any help!
-Dave
1 DNS A record, 2 ip addresses and 2 servers windows cluster for Always on SQL
so 1 DNS = SQLDNS
1 IP 10.10.10.1/30
2 IP 10.10.10.2/30
So this is my war at work. They have SQL always on set up, ip 1 & 2 are set up as active and stand-by but pointing to same dns A record. It keeps flipping between ip's because of the round robin default rule in dns server. I've read that if disabled it can cause problems. reverse lookup for secondary ip fails as either it is not configured or just because of the state of the interface being stand-by mode which means it does not reply to pings until ip 1 is actually down.
I am a network guy so easy on me on the clustering, SQL HA or DNS specifics..., I know a bit of all but no expert.
Thanks in advance to all
Could not locate statistics very often issue!
Dear all,
Since two weeks ago this issue is coming a recurrent one, disabling all the traffic on one of our databases in AO.
Could not locate statistics '_WA_Sys_0000001F_200E7F64' in the system catalogs.
Solution: rebuild the indexes and then the replication update the stats on the secondary replica.
How can we anticipate this?
Thanks for any input or advice on it,
Enric
Most relevant Azure certification for MSSQL DBA
Dear All,
May be this post is not completely relevant here. However kindly do excuse me for that . I being an SQL server dba will love to complete some Cloud Certifications in Microsoft Azure Cloud platform. Can anyone kindly suggest what will be most relevant certification for MSSQL dba ?
Thanks in advance.
Best Regards,
Sandy
SSRS 2016 Scaled Out Deployment in 2 Data Centers
Is it possible to configure SSRS 2016 in a scaled-out configuration across multi-data centres that are geographically separated?
The SQL Server instances will be configured with AOAG across the 3 nodes and 2 data centres and the SSRS will be scaled out in a similar way. SQL C would be a manual failover, whereas SQL A and B would be auto. I've put together a simple diagram
to try and explain it a little better.
Image may be NSFW.
Clik here to view.
Or would it be simpler to copy SSRS encryption key over the SSRS C and manually configure to point to the SSRS AOAG databases in the event of a failure?
slow to create index on table with 425m of rows
Two days ago we changed the version of sql server 2008 R2 to Sql server 2016 and we have presented the following situation.
On the new server, creating a noncluster index on a table with 425 million records takes 55 minutes, but on the previous server it takes only 4 minutes.
The resources of the new equipment are 16GB RAM and 4 Socket with 8 Processors.
Configuration: Database:
autogrow 512 mb
If you require more information please inform me
Thank you.
SQL SERVER 2016 ALWASYON
Question1
As per the policy backups (log and full)are taking from SQL Server naive (Server dive ) and 3rd party to remote location in this case LSN will break ,correct if I am wrong . How do we take if we want continue the backups from SQL Server naive and 3rd party
Question2 : Alwasyon is auto fail-over (2 node ) and application jobs to be run the primary and ignore on secondary . But Backus should run on only secondary . What condition needs to be add to accomplish this requirement.
Question1
Unfortually Infra team added 1.2 TB on System drive(C drive), do we have any issues if we added the huge space for system drive.