SQL Server Maintenance Plan does not run DEL command in .BAT
Hello,
I have a T-SQL Statement task in my Maintenance Plan that runs a .BAT file and it runs OK when manually executed. The .BAT file has a del d:\backups\*.* command in it. However, when the plan runs automatically at a scheduled time, the .BAT file does
not delete files. Could this be a permissions issue?
Paul
Hi Paul,
This looks like a permission issue. Make sure the account SQL instance is running has delete permissions on the folder from which you are trying to delete and also make sure the account has execute permission on that batch file.
Thanks,
Bhanu
Similar Messages
-
I know this question has been asked before, but never for R2, that I can tell, and the posted fixes aren't working. I have just installed SCVMM 2008 R2 on a Windows Server 2008 R2 server, using a remote SQL 2008 SP1 database. When I attempt to connect to SCVMM, I get the following error:
"The SQL Server service account does not have permission to access Active Directory Domain Services (AD DS).
Ensure that the SQL Server service is running under a domain account or a computer account that has permission to access AD DS. For more information, see "Some applications and APIs require access to authorization information on account objects" in the Microsoft Knowledge Base at http://go.microsoft.com/fwlink/?LinkId=121054.
ID: 2607"
What I've seen online is that this is usually becuase the domain account SCVMM is running as does not have the proper permissions on the SQL database. Here's what I've confirmed:
1) My SCVMM service account is a local admin on the SCVMM server
2) My SCVMM service account is a dbowner on the SCVMM database in SQL
3) My SQL service account is a dbowner on the SCVMM database in SQL
4) My SQL service account is a domain user (even made it a domain admin, just in case, and it still "doesn't have access to AD DS," which is obviously untrue)
5) Neither service account is locked out
Has anyone run in to this? It says in Technet that remote SQL 2008 is supported, as long as the SQL management studio is installed to the SCVMM server, and I installed and patched before I began the SCVMM installation. I just don't know what else to try - I have no errors in event logs, no issues during the installation itself...
Andrew ToppThat answer was very unhelpful fr33m4n. The individual mentions that they've received the error that points to the KB article. I currently receive the same error -- there seems to be no resolution. I've run the Microsoft VBS script to add TAUG to the WAAG
as suggested by 331951, and that made absolutely no difference.
1) My SCVMM service account is a local admin on the SCVMM server
2) My SCVMM service account is a dbowner on the SCVMM database in SQL
3) My SQL service account is a dbowner on the SCVMM database in SQL
4) My SQL service account is a domain user (even made it a domain admin, just in case, and it still
"doesn't have access to AD DS," which is obviously untrue)
The user is also a member of WAAG, the machines have delegated authority to each other. Is there any other solution? -
Simple Operational Profile and Plan does not run against agent
So i'm attempting to use the Operational Profile function of Ops Center to extend some functionality which it does not have (set up bonded interfaces during build process of OL 6.x)
However my script is having issues it never seems to run as a remote shell. So I simplified it, and broke my script down to simply
#!/bin/bash
/bin/pwd
/bin/ls
exit 0
And it still failed to run.
I've poured over the documentation, my script runs fine when manually incanted from the command line.
I've attempted following https://blogs.oracle.com/oem/entry/ops_center_using_operational_profiles but as you can see even my simple of simple plans does not run, let alone anything more complex.
Full job logs:
Job ID : EC-SERVER.com.au.664
Job Name : do ls script;AGENT
Job Type : Execute-DeploymentPlan
Job Description : -
Run ID : 1
Status : FAILED
Mode : Actual run
Owner : xvmadm
Create Date : 11/11/2014 09:03:04 AM EST
Start Date : 11/11/2014 09:03:04 AM EST
Last Updated : 11/11/2014 09:03:08 AM EST
Execution Order : PARALLEL
Failure Policy : CONTINUE_ON_FAILURE
Task : AGENT
Task : CmpExecuteTask
Task : ExecuteTask
Task Run ID : 24369
Target : AGENT
Status : FAILED
Result : Task failed. (15030)
Logs :
11/11/2014 09:03:04 AM EST INFO EC-SERVER.com.au.664.1.24369 acquired the recursive lock on the target - PC-SERVER.com.au-172a7b21/AGENT.com.au-abf1fc69/com.sun.hss.domain:name=localhost,type=OperatingSystem for the duration of Task
11/11/2014 09:03:04 AM EST INFO Task is posted to the Proxy Controller (PC-SERVER.com.au-172a7b21), from the Enterprise Controller. (15011)
11/11/2014 09:03:08 AM EST INFO Task is received by the Proxy Controller. (15012)
11/11/2014 09:03:08 AM EST INFO Task is posted to the Agent Controller (AGENT.com.au-abf1fc69), from the Proxy Controller. (15013)
11/11/2014 09:03:08 AM EST INFO Task is received by the agent controller.
11/11/2014 09:03:08 AM EST INFO EC-SERVER.com.au.664.1.24369 released the recursive lock on the target - PC-SERVER.com.au-172a7b21/AGENT.com.au-abf1fc69/com.sun.hss.domain:name=localhost,type=OperatingSystem for the duration of Task
I wanted to avoid raising an SR for something so potentially trivial, but what the heck is going on here?Nothing? no one uses this functionality?
-
SQL Server Maintenance Plan Issue
SQL Server Version:
Microsoft SQL Server 2005 - 9.00.5000.00 (Intel X86)
Dec 10 2010 10:56:29
Copyright (c) 1988-2005 Microsoft Corporation
Enterprise Edition on Windows NT 5.2 (Build 3790: Service Pack 2)
Issue : Maintenance Plan - DB backup plan & TRN Log backup plan skipped / some times not deleting the old backup files.
Error : Failed to retrieve date for this request (Microsoft.SqlServer.SmoEnum)
Additional Informaiton
An exception occurred while executing a Transact-SQL statement or batch.
(Microsoft.SqlServer.ConnectionInfo)
A Server error occurred on the current command.
The results, if any should be discarded (Microsoft Sql Server)
Any experts can help me to resolve this issue.
Thanks
drmrpush
MRVSFLYHello,
Same issue reported here:
https://social.msdn.microsoft.com/Forums/sqlserver/en-US/601fd83c-c49f-4bf8-b69d-95431197652d/maintenance-plan-is-not-opening-on-sql-server-2005-sp2?forum=sqlkjmanageability
Please check solution on :
https://social.msdn.microsoft.com/Forums/sqlserver/en-US/3e53ba8b-ea23-4629-98db-43c80ba9888e/cannot-save-maintenance-plans?forum=sqltools
This problem occurs if some of the stored procedures while installing SP2 has not been applied successfully. So manually run the script below and it may resolve
your issue. It resolved ours and we went throught exact same process of re-installing several times.
1)
First go to the folder Install . The default location is this = “C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Install “ .
Please post back still your issue not resolves.
2)
Then in this folder find this “sysdbupg.sql” .
3)
Please open this script with a nodepad.
4)
Then copy the
whole script and then paste it in the Query window of the Management studio.
5)
Then execute this script.
6)
Once this script has been successfully executed, The issue should be resolved.
Regards, Pradyothana DP. Please Mark This As Answer if it solved your issue. Please Mark This As Helpful if it helps to solve your issue. ========================================================== http://www.dbainhouse.blogspot.in/ -
SQL Server Agent Job is not running as per schedule
I have a job that is supposed to run every 6 AM. It was running last week but not this morning.
The big problem is that there are no error messages what so ever. I checked Agent History, SQL server logs and Windows system logs.
I checked the schedule and it is set to run everyday and there are no limits on how long it is supposed to run and it is enabled.
Did anyone get this problem before?Hi,
Sometimes there are valid reasons a job will NOT kick-in on the scheduled time. Sometime ago, our database full backup job didn't start on time and in fact just
got skipped over. Upon further investigation, a idiot started doing defragging on the target (destination) server without informing anybody in the enterprise and the previous days backup was running over 24+ hours instead of 2 hours. Sometime people cheat
and try to enable/disable jobs and in those cases you may want to add notification if something like this happens. http://www.mssqltips.com/sqlservertip/1803/auto-alert-for-sql-agent-jobs-when-they-are-enabled-or-disabled/
Sankar Reddy
Blog: http://SankarReddy.com/
Twitter: http://twitter.com/SankarReddy13/ -
SQL-Server detection/discovery does not work in win 10 build 10041
Hello,
I'm using the default .NET-function to detect SQL-server-instances in the network. It works fine in win xp, win7, win8 up to win 2012r2. It also works in earlier win 10 builds, but it's broken in build 10041.
It's reproduceable with the powershell-call
[System.Data.Sql.SqlDataSourceEnumerator]::Instance.GetDataSources()
On other systems the function call takes about 10 to 15 seconds before returning a list of SQL instances in the network. Under win 10 build 10041 it returns immedeately without any results.
Please fix this problem before the final build!Share: The abiltity to place a link to the feedback-"post" somewhere else ... facebook, twitter, or this forum here.
I've only a virtual machine with windows 10 installed. So it's really annoying, that I have to log on on to check the state or the "me too" count of my feedback-post. Would be great if this post is reachable through the web from other (pre windows
10) machines.
Answer: The ability to reply to the feedback-"post". like "it's solved now", "it does not work with build xxxxx", "i can't reproduce", "we're working on a bugfix" -
Update of MySQL and SQL Server JDBC Driver does not work in 1.2.1
Hi,
always after the update process is started i got the MySQL and SQL Server JDBC driver
update notification.
But all the time after i install the update i got the notification again but no errormessage
that the update was maybe not successful ???
FrankOk
then my subject was false
i always try to update the extensions and now i can see that they are updated on the filesystem but the IDE does not recognize them as updated
....\sqldeveloper\sqldeveloper\extensions\oracle.sqldeveloper.thirdparty.drivers.mysql
is available and new after the update process
and under
...\sqldeveloper\sqldeveloper\tmp\update\oracle.sqldeveloper.thirdparty.drivers.mysql.5239.zip
the downloaded zip file is also available.
In the update window the message is that the extension with version 5206 is available
Maybe that is the problem cause the downloaded files are version 11.1.1.5239
if you look at the bundle.xml file inside the META-INF directory
Frank -
[CS4 Server Win]: Plugin does not run on Windows Server 2003?
Hi,
can anybody help?
My plugin is running on Windows XP and Windows Vista.
On both operation systems the scripting methods are visible in ExtendScript Toolkit and can be called by javascript.
On Windows Server 2003 my plugin is not running, the scripting methods are not visible in ExtendScript Toolkit!
What is missing?
Thanks,
Alois Blaimer> I am using Visual Studio 2008 with the VC++ 9.0 compiler.
> Could this be a problem?
Yes.
CS4: use VC2005 + SP1
CS3: use VC2005 without SP1
CS2: use VC2003
In my previous post I described one of the problems I found out the hard way - walking around in disassembler is a pain, even more Intel and Windows, comparing to Mac, and PowerPC. Since then I only use the official tools even if others tell it worked for them, and I keep the InDesign installations for final build and test on the earliest supported operating system.
Dirk -
Add does not run with sql server 2008
Hi all,
My add on in the development environment does not run with SQL SERVER 2008. It ran well with SQL Server 2005 and sap b1 2207 B.
On executing the project file system throws an error "YOU ARE NOT CONNECTED TO THE COMPANY"
we are trying this scenario on a test machine where SAP B1 2007B with temporary license for one month and SQL server 2008
is installed.
Help needed.
Thanking you
PradnyaHi Use this
Dim i as integer
i=oCompany.Connect()
if i<> 0 Then
msgbox(ocompany.GetLastErrorDescription ())
end if
the you will get the error description also use try catch wherever necessary
Alternatively you can use
Dim SboGuiApi As SAPbouiCOM.SboGuiApi
Dim sConnectionString As String
Set SboGuiApi = New SAPbouiCOM.SboGuiApi
sConnectionString = Command
SboGuiApi.Connect sConnectionString
Set SBO_Application = SboGuiApi.GetApplication()
Set ocompany = New SAPbobsCOM.Company 'initialate DI company object
ocompany = SBO_Application.Company.GetDICompany
HTH,
Atul -
Adobe Media Server Installer does not run
I am trying to install Adobe Media Server 5 on Windows 2008 R2 64 bit on i3 logged in as an administarive user over RDP.
The installer simply does not run - a very short hourglass then nothing. Not logs in applicaiton, system of setup logs.
The bundled Adobe Media Gateway installer runs just fine.
Tried a machine restart, and still no go...
Any ideas gratefully received
Simonok, got it... go properties on the file and 'unblock'
This was because I downloaded it on another machine, and then copied it over. Windows 2008 knew it had not been made locally and silently blocked execution. -
My adobe captivate6 installs but does not run on my windows7 dell inspiron
my adobe captivate6 installs but does not run on my windows7 dell inspiron with 4gb ram and 500gb hdsk, i downloaded the trial first 32bit and it installed fine and didnt run. so i thought that a full version with a 64bit installation will do the trick, but after that the captivate 6 did not still work on my system. i also tried it on an acer with duo core and the captivate software installed and did not still work. it only shows the captivate flash screen.
a friend installed his on an acer laptop 64bit, i3processor, and it works fine. please i will be glad if i can be helped on how to correct this
thanksHave you tried right clicking on the Cp icon and selecting Run as Administrator? This is something you MUST do in Win7 but was not necessary on Xp.
-
Summary: DSC fails to fully install the SQL Server 2012 Failover Cluster, but the identical code snippet below run in powershell ise with administrator credentials works perfectly as does running the SQL server install interface.
In order to develop DSC configurations, I have set up a Windows Server 2012 R2 failover cluster in VMware Workstation v10 consisting of 3 nodes. All have the same Windows Server 2012 version and have been fully patched via Microsoft Updates.
The cluster properly fails over on command and the cluster validates. Powershell 4.0 is being used as installed in windows.
PDC
Node1
Node2
The DSC script builds up the parameters to setup.exe for SQL Server. Here is the cmd that gets built...
$cmd2 = "C:\SOFTWARE\SQL\Setup.exe /Q /ACTION=InstallFailoverCluster /INSTANCENAME=MSSQLSERVER /INSTANCEID=MSSQLSERVER /IACCEPTSQLSERVERLICENSETERMS /UpdateEnabled=false /IndicateProgress=false /FEATURES=SQLEngine,FullText,SSMS,ADV_SSMS,BIDS,IS,BC,CONN,BOL /SECURITYMODE=SQL /SAPWD=password#1 /SQLSVCACCOUNT=SAASLAB1\sql_services /SQLSVCPASSWORD=password#1 /SQLSYSADMINACCOUNTS=`"SAASLAB1\sql_admin`" `"SAASLAB1\sql_services`" `"SAASLAB1\cubara01`" /AGTSVCACCOUNT=SAASLAB1\sql_services /AGTSVCPASSWORD=password#1 /ISSVCACCOUNT=SAASLAB1\sql_services /ISSVCPASSWORD=password#1 /ISSVCSTARTUPTYPE=Automatic /FAILOVERCLUSTERDISKS=MountRoot /FAILOVERCLUSTERGROUP='SQL Server (MSSQLSERVER)' /FAILOVERCLUSTERNETWORKNAME=SQLClusterLab1 /FAILOVERCLUSTERIPADDRESSES=`"IPv4;192.168.100.15;LAN;255.255.255.0`" /INSTALLSQLDATADIR=M:\SAN\SQLData\MSSQLSERVER /SQLUSERDBDIR=M:\SAN\SQLData\MSSQLSERVER /SQLUSERDBLOGDIR=M:\SAN\SQLLogs\MSSQLSERVER /SQLTEMPDBDIR=M:\SAN\SQLTempDB\MSSQLSERVER /SQLTEMPDBLOGDIR=M:\SAN\SQLTempDB\MSSQLSERVER /SQLBACKUPDIR=M:\SAN\Backups\MSSQLSERVER > C:\Logs\sqlInstall-log.txt "
Invoke-Expression $cmd2
When I run this specific command in Powershell ISE running as administrator, logged in as domain account that is in the Node1's administrators group and has domain administrative authority, it works perfectly fine and sets up the initial node properly.
When I use the EXACT SAME code above pasted into my custom DSC resource, as a test with a known successful install, run with the same user as above, it does NOT completely install the cluster properly. It still installs 17 applications
related to SQL Server and seems to properly configure everything except the cluster. The Failover Cluster Manager shows that the SQL Server Role will not come on line and the SQL Server Agent Role is not created.
The code is run on Node1 so the setup folder is local to Node1.
The ConfigurationFile.ini files for the two types of installs are identical.
Summary.txt does have issues..
Feature: Database Engine Services
Status: Failed: see logs for details
Reason for failure: An error occurred during the setup process of the feature.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x86D8003A
Error description: The cluster resource 'SQL Server' could not be brought online. Error: There was a failure to call cluster code from a provider. Exception message: Generic
failure . Status code: 5023. Description: The group or resource is not in the correct state to perform the requested operation. .
It feels like this is a security issue with DSC or an issue with the setup in SQL Server, but please note I have granted administrators group and domain administrators authority. The nodes were built with the same login. Windows firewall
is completely disabled.
Please let me know if any more detail is required.Hi Lydia,
Thanks for your interest and help.
I tried "Option 3 (recommended)" and that did not help.
The issue I encounter with the fail-over cluster only occurs when trying to install with DSC!
Using the SQL Server Install wizard, Command Prompt and even in Powershell by invoking the setup.exe all work perfectly.
So, to reiterate, this issue only occurs while running in the context of DSC.
I am using the same domain login with Domain Admin Security and locally the account has Administrators group credentials. The SQL Server Service account also has Administrators Group Credentials. -
Hello All,
1. I have a BAM 10.1.3.4 installation and a IBM Webspehere MQ client V6.0 installed in the same server
2. Have configured JmsAdmin appropriately to have a Topic Connection Factory and a Topic Pointing to a Queue in the Server
3. Have tested the client connectivity using ivtRun and MQIVP.class, they seem to work fine connecting to the channel and the topic.
4. I have configured an EMS for IBMWebSphereMQ in BAM with the below given parameters
Name: BPEL_TO_BAM
Owner: AMERICAS\Jai_Mani
Created: 12/1/2009 2:07:48 AM
Last modified: 12/1/2009 9:48:03 AM
Type: IBM WebSphere MQ
Initial Context Factory: com.sun.jndi.fscontext.RefFSContextFactory.
JNDI Service Provider URL: file:/C:/JNDI-BOSS-DAO.
TopicConnectionFactory Name: ivtTCF.
Topic Name: ivtT.
JMS Message Type: TextMessage.
Durable Subscriber Name (Optional): .
Message Selector (Optional): .
Client ID (Optional): .
Name Flow name Type Max size Formatting
rawData. rawData. String 40000 (none).
5. I have a subscribe plan configured in to enterprise Link which has a EMSReceiever and a grid to display the messages
6. I have the "run forever" flag checked in the Receiver and go a head and post a message in the Queue configured in the server.
7. The plan does not display any messages in the grid.
All configuration on the MQ Server and Client side are proper but BAM EL Plan is not displaying the data in the grid.
Have also had turned on DEBUG on the servers and restarted BAM, they don't seem to throw any errors.
Kindly advice, what could be wrong in the Plan or EMS configuration which is causing this.
Thanks & regards,
Jai.Is this working for you? What errors do you get in the logs (bam, EL)?
-
My client has MS SQL database administrators that are highly recommending doing a periodic reindex as they are seeing a high level of fragmentation. I am unable to find any documents on proper MS SQL Server maintenance from Cisco. In the absence of recommendations from "the vendor" (as the DBA puts it) should we apply generally accepted maitenance procedures for MS SQL? Should we set our log files to Autogrow as they are currently set to none?
Thanks,
MarkHi,
since MS SQL Server is not used in UCCX anymore, I assume you are talking about Cisco ICM.
It has already a system implemented that periodically checks the size of tables and removes old data according to the schedule.
I don't really see the meaning of index "defragmentation", as data is written sequentially to the historical tables. You can rebuild the index of the configuration tables, if, for instance, agents are added and removed frequently.
G. -
SSIS Job deployment does not run my .exe but is described as a success
Hi i have scripted a simple script task in c# to run an exe with the following code
Process.start(filename.exe);
i have also tried using the 'Execute Process task' in the SSIS toolbox.
both methods work when i debug.
However when deployed to the SQL server as a job, the jobs are described as a success but my program does not run?!
The exe file is published from SQL visual studio and the resultant filename is setup.exe which i am trying to run.
Any help pleasE?
I am not using any shared file resources, the setup.exe is on my desktop.this is all i get
Message Type
Message Time
Message
Message Source Name
Subcomponent Name
Execution Path
OnPostExecute
8/22/2014 4:15:09 PM
Package:Finished, 4:15:09 PM, Elapsed time: 00:00:00.234.
Package
\Package
OnPostExecute
8/22/2014 4:15:09 PM
Execute Process Task:Finished, 4:15:09 PM, Elapsed time: 00:00:00.203.
Execute Process Task
\Package\Execute Process Task
OnPostValidate
8/22/2014 4:15:09 PM
Execute Process Task:Validation is complete.
Execute Process Task
\Package\Execute Process Task
OnPreExecute
8/22/2014 4:15:09 PM
Execute Process Task:Start, 4:15:09 PM.
Execute Process Task
\Package\Execute Process Task
OnPreValidate
8/22/2014 4:15:09 PM
Execute Process Task:Validation has started.
Execute Process Task
\Package\Execute Process Task
OnPreExecute
8/22/2014 4:15:09 PM
Package:Start, 4:15:09 PM.
Package
\Package
OnPreValidate
8/22/2014 4:15:09 PM
Package:Validation has started.
Package
\Package
OnPreValidate
8/22/2014 4:15:09 PM
Execute Process Task:Validation has started.
Execute Process Task
\Package\Execute Process Task
OnPostValidate
8/22/2014 4:15:09 PM
Execute Process Task:Validation is complete.
Execute Process Task
\Package\Execute Process Task
OnPostValidate
8/22/2014 4:15:09 PM
Package:Validation is complete.
Package
\Package
OnInformation
8/22/2014 4:15:08 PM
Package:Information: Succeeded in upgrading the package.
Package
\Package
OnInformation
8/22/2014 4:15:08 PM
run exe:Information: The Script Task "ST_6ba434db5c5649b7b68ab5fb14977781" has been migrated.
The package must be saved to retain migration changes.
run exe
\Package\run exe
OnWarning
8/22/2014 4:15:04 PM
run exe:Warning: Found SQL Server Integration Services 2012 Script Task "ST_6ba434db5c5649b7b68ab5fb14977781"
that requires migration!
run exe
\Package\run exe
Maybe you are looking for
-
External Lacie drive crashed, now I can't find a recent backup for LR3 catalog.
I have LR3 on a Mac running OS 10.6.8. My catalog, cache and images were stored on an external Lacie 1TB drive (partitioned so it can be used by a pc and mac). My catalog backup files were saved on another external drive MXTR as well as copies of a
-
Anybody has any idea of how to open an url (or webpage) from a webform in the same window. I cannot use Web.Show_Document() as it opens the webpage in a new window. Thanx in advance.
-
Hello Experts, I have done fiscal year change (AJRW) for fixed asset on 1st april 2015, I have not done the asset year end closing, as we still have many more entries to come for the year 2014-15. When the fiscal year change has been done, there is n
-
Access Web Dynpro Java application through direct URL
Hi Guys, we have a requirement that there is a link in web dynpro abap screen, click on it will open a new ie window running web dynpro java application, so what i did is i have given direct url link for that web dynpro java application: as this: htt
-
How to stop the "BEACHBALL" spinning forever with every move I do?
Sorry for the lack of a better word. I have (2) G3 imacs running 10.3.9 w/cable internet, the graphite is linked directly to the cable modem w/ Airport Extreme and and the Flower Power uses an Airport Express. The Flower Power has no problems and is