Solved

BCM Backup scrip fails

Posted on 2011-02-22
5
361 Views
Last Modified: 2012-05-11
Hi,

I am getting the folowing errors when running a script to automate the BCM backup. Any ideas?

D:\BCM-Backups>Backup.cmd

D:\BCM-Backups>"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe"
-E -S .\MSSMLBIZ -Q"SET NOCOUNT ON; SELECT 'MSSmallBusiness Backup started at -
' + CONVERT(varchar, GETDATE());"  1>"D:\BCM-Backups\MSSmallBusiness_BackupResul
t.txt"
Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
shing a connection to the server. When connecting to SQL Server 2005, this failu
re may be caused by the fact that under the default settings SQL Server does not
 allow remote connections..
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

D:\BCM-Backups>"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe"
-E -S .\MSSMLBIZ -Q"BACKUP DATABASE MSSmallBusiness TO  DISK = N'D:\BCM-Backups\
MSSmallBusiness.bak' WITH FORMAT, INIT,  NAME = N'Full Database Backup', SKIP, S
TATS = 10"  1>>"D:\BCM-Backups\MSSmallBusiness_BackupResult.txt"
Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
shing a connection to the server. When connecting to SQL Server 2005, this failu
re may be caused by the fact that under the default settings SQL Server does not
 allow remote connections..
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

D:\BCM-Backups>"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe"
-E -S .\MSSMLBIZ -Q"SET NOCOUNT ON; SELECT 'Backup completed at - ' + CONVERT(va
rchar, GETDATE());"  1>>"D:\BCM-Backups\MSSmallBusiness_BackupResult.txt"
Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
shing a connection to the server. When connecting to SQL Server 2005, this failu
re may be caused by the fact that under the default settings SQL Server does not
 allow remote connections..
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

D:\BCM-Backups>REM copy /Z "D:\BCM-Backups\MSSmallBusiness.bak" "<NETWORK_PATH>\
MSSmallBusiness.bak" >>"D:\BCM-Backups\MSSmallBusiness_BackupResult.txt"

D:\BCM-Backups>Backup.cmd

D:\BCM-Backups>"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe"
-E -S .\MSSMLBIZ -Q"SET NOCOUNT ON; SELECT 'MSSmallBusiness Backup started at -
' + CONVERT(varchar, GETDATE());"  1>"D:\BCM-Backups\MSSmallBusiness_BackupResul
t.txt"
Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
shing a connection to the server. When connecting to SQL Server 2005, this failu
re may be caused by the fact that under the default settings SQL Server does not
 allow remote connections..
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

D:\BCM-Backups>"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe"
-E -S .\MSSMLBIZ -Q"BACKUP DATABASE MSSmallBusiness TO  DISK = N'D:\BCM-Backups\
MSSmallBusiness.bak' WITH FORMAT, INIT,  NAME = N'Full Database Backup', SKIP, S
TATS = 10"  1>>"D:\BCM-Backups\MSSmallBusiness_BackupResult.txt"
Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
shing a connection to the server. When connecting to SQL Server 2005, this failu
re may be caused by the fact that under the default settings SQL Server does not
 allow remote connections..
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

D:\BCM-Backups>"c:\program files\microsoft sql server\90\tools\binn\sqlcmd.exe"
-E -S .\MSSMLBIZ -Q"SET NOCOUNT ON; SELECT 'Backup completed at - ' + CONVERT(va
rchar, GETDATE());"  1>>"D:\BCM-Backups\MSSmallBusiness_BackupResult.txt"
Sqlcmd: Error: Microsoft SQL Native Client : An error has occurred while establi
shing a connection to the server. When connecting to SQL Server 2005, this failu
re may be caused by the fact that under the default settings SQL Server does not
 allow remote connections..
Sqlcmd: Error: Microsoft SQL Native Client : Login timeout expired.

D:\BCM-Backups>REM copy /Z "D:\BCM-Backups\MSSmallBusiness.bak" "<NETWORK_PATH>\
MSSmallBusiness.bak" >>"D:\BCM-Backups\MSSmallBusiness_BackupResult.txt"
0
Comment
Question by:optimus_nz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 17

Expert Comment

by:dbaSQL
ID: 34957724
try this to enable remote entry:
EXEC sp_configure 'remote access', 1

0
 

Author Comment

by:optimus_nz
ID: 34965844
Is anywhere special this needs to be entered? Or straight from command line?
0
 
LVL 17

Accepted Solution

by:
dbaSQL earned 500 total points
ID: 34967028
If you've got SSMS, just open a query window, connected to the MSSmallBusiness database, and run that statement.  Just cut/paste it into your query window, and hit the execute button.
0
 

Author Closing Comment

by:optimus_nz
ID: 35087917
Thanks
0
 
LVL 17

Expert Comment

by:dbaSQL
ID: 35088208
My pleasure.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many people use more than one email account and so it becomes difficult for them to manage them when they use separate accounts,  so, in this article, I have shared an easy way to add Other Mail Accounts in your Google Inbox. It helps to combine all…
This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …
Many of my clients call in with monstrous Gmail overloading issues with Outlook. A quick tip is to turn off the All Mail and Important folders from synching. Here is a quick video I made to show you how to turn off these and other folders in Gmail s…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question