DB Engine :: Database Mail Could Not Be Sent - Rejected Due To Policy Reasons
Jul 29, 2015
I have configured DB Mail in our SQL Server Management Studio. But I am getting the following Error. Also I am getting Same Error while doing SSRS Report Subscription via mail. (Same Server).
Error Message
The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 4 (2015-07-21T04:22:24). Exception Message: Cannot send mails to mail server. (Transaction failed. The server response was: Mail from
analytics@xyz.com rejected for policy reasons.).
)
For your additional info: In SSIS I can able to send email using Mail Task.
The script is working fine if i manually provided file path to @file_attachments. it is showing error i passes the variable @Loc3 to @file_attachments. Below is the error if i passes the variable to @file_attachments parameter.
(1 row(s) affected) (1 row(s) affected) (1 row(s) affected) Msg 22051, Level 16, State 1, Line 0 Attachment file 'E:DatabaseTannaFinanceReportDetail_Reimbursement_1_15_Aug2015.csv is invalid.
I have been searching for a means to change the System Failure Error Check policy that comes as part of the Best Practice policies. I want to look back 24 hours. The WQL query shipped with the policy doesn't have a WHERE clause component that looks at TimeGenerated. That query looks like:
IsNull(ExecuteWql('Numeric', 'rootCIMV2', 'select EventCode from Win32_NTLogEvent where EventCode=6008 and Logfile="System"'), 0)
After searching for an example of how to do this and not finding any that are specific to PBM, I decided to fall back to a very basic approach - use wbemtest.exe to try out where clause additions and see how they work, then plug the result into the policy and see if it works. As a start, I tried the following query using wbemtest.exe:
select Event Code from Win32_NTLogEvent where EventCode = 6008 and Logfile = 'System' and TimeGenerated > '20130101010000.000000–000'
This works great in wbemtest.exe. My next step was to plug this into the policy condition expression as follows: IsNull(ExecuteWql ('Numeric', 'rootCIMV2', 'select EventCode from Win32_NTLogEvent where EventCode=6008 and Logfile="System" and TimeGenerated > "20130101010000.000000–000"'), 0)
When I try to manually evaluate this policy in SSMS, I receive an "Invalid Query" error message.I assume that SWbemDateTime isn't available to use inside Policy Based Management policies. All the examples of how to handle the kind of dynamic date creation I have seen are for use in PowerShell, VBScript, or SSIS. I've played with using DateDiff, DateAdd, and GetDate inside the query string, with no success.
Why does the ExecuteWql above fail?Is it at all possible to dynamically generate a datetime (say, 24 hours ago) as part of the query string parameter of the ExecuteWql call?What might that look like?
I have below table in the snapshot, My task is to send the same output as a attachment in Excel to email. i used the below procedure  EXEC [msdb]..sp_send_dbmail @profile_name='TSSSendMail', @recipients='mymailID@gmail.com.com', @subject='DB Mail', @body='HI Team', @execute_query_database = 'DbName', @query = 'EXEC J16ReimbursementFortnightly1TO15 1', @attach_query_result_as_file=1, @query_attachment_filename = 'SummaryReimbursement.xls'
But I am not getting Proper Output, is seems like CSV Format, but i want it proper tabular format in Excel.
We are using Crystal Report Services XI to generate reports from SQL Server 2000 database running on server within the same domain (LAN).
for some reason, SQL Server is rejecting the Credentials that is provided to CR Services, the user has right to that database. When We run the report manual, it works fine, but when we run Automatic on schedule , it fails.
The Authentication mode is set to Mixed.
The Startup Service accoutn is set to "This Account"
Any idea, why would this failure on User is encoutered.
I have recently upgraded to SQL2014 on Win2012. The Access front end program works fine.
But, previously created Excel reports with built in MS Queries now fail with the above error for users with MS 2013. The queries still work for users still using MS 2007.Â
I also cannot create any new queries and get the same error message. If I log on as myself on the domain to another PC with 2007 installed it works fine, so I don't think it is anything to do with AD groups or permissions.
I have developing sample application for automatically send failure mail to respective person. Also i have storing all the failure mail details to database for unavailability of mail server. Once if the mail server available that time we will send all the failure mail to respective person.
Lokendra writes "I have configured the Database mail profile and account in Sql Server 2005 but the mail is not sending and showing the following error message:
Error,235,The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 1 (2007-03-05T15:16:07). Exception Message: Cannot send mails to mail server. (Mailbox name not allowed. The server response was: Sorry<c/> that domain isn't in my list of allowed rcpthosts.). ),3000,90,,3/5/2007 3:16:07 PM,sa
but while in the same mail set up in previous instance of sql server 2005 the message was sending very well. After installing new instance of sql server 2005 the problem is arising.
Anybody can tell me that what I can do so that i can send mail using the SMTP databasemail account."
Our company use yahoo business mail server for our corporate mails. I know that I can configure database mail with SMTP. But when I try to configure database mail account with yahoo bizmail, I cannot do that. It gets configured but when I test it it doesn't send any mails. Do I need to have any special condiguration for this. SMTP address is smtp.bizmail.yahoo.com. Also I have specified the Authentication using my user name and password. Please help
I want to send a simple mail using DATABASE MAIL feature in SQL SERVER 2005.
I've defined a public profile. I've enabled Database Mail stored procedures through the Surface Area Configuration .
but I can't send a mail with sp_send_dbmail stored procedure in 'msdb' database .
when I execute sp_send_dbmail in the Managment Studio the message is "Mail queued" but the mail is not sent.
Could it be related to Service Broker?Because the Surface Area Configuration indicates:'this inctance does not have a Service Broker endpoint'.If so, how should I make an endpoint?
here is the log file after executing sp_send_dbmail:
1) "DatabaseMail process is started"
2) "The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 2 (2007-03-08T00:49:29). Exception Message: Could not connect to mail server. (No connection could be made because the target machine actively refused it)."
The DatabaseMail90.exe is triggred ,so the mail is transfered to the mail queue but DatabaseMail90.exe couldn't give the mail to SMTP server.The promlem is what should I do to make DatabaseMail90.exe able to connect to the server?
I develop my application on two different workstations (one at work and one at home). On each, I created a database with the same name, and added identical users with the same login ID and password. For simplicity, let's just say the database is called "my_data", and the user is "my_user" with a password of "12345". Recently, for reasons beyond this post, I needed to copy the data from my work database to my home database. I tried both a Detach Database, and a Full Database Backup, and have gotten the following result: When I attach/restore the databases to my home computer, the login "my_user" and "12345" fails. I THINK that even though my databases have users with the same login ID and password in them, that the two users are actually DIFFERENT users because they were created on different servers. I tried to remove the user from the database, but the db server wouldn't let me since the user owned a schema (which I can't uncheck in user preferences because it is grayed out). So I think I need to figure out how to remove the user that is in the restored database, and re-add the user that exists on the server that the database was restored to. Any suggestions? How do I remove the owned schema from the user that is in the database? Thanks! Mike
Maybe is it a newbie question : it is the first time I install a SQL Server licence purchased with the eopen program.
My SQL server licence is a french one. I purchased the correct media kit.
During the installation, I am asked the name, and the company name but the product key is greyed with product id which begin with "RY62Q". I guess it is normal (?)
But later on, when it comes to installing SQL server itself, i get a message telling that my product ID is incorrect. (id : 28021; event type : sqlcasqlcax.cpp@DetectProductID@DetectProductID@x6d75).
I tried dozens of times :
-with another admin account
-after cleaning up the temp and program files subdirectories
-after cleaning up the registry (HKEY_LOCAL_MACHINESOFTWAREMicrosoftMicrosoft SQL Server,HKEY_LOCAL_MACHINESoftwareMicrosoftMSFTESQLInstMap; there was nothing anyway)
If it helps, I first try the installation from a wrong media. As I had no key, I went not far away.
I did received the authorisation number etc from Microsoft but I have no clue of what have to do from that.
During the execution of SSIS Package which is populating huge data into OLEDB Destination from OLEDB Source, then some of the records are getting rejected. Again if we are executing it twice or thrice, the rejected records are getting inserted.
Wants to know, why the records are getting rejected? Target table does not contain any constraints.
What are the reasons for dumpfiles in sql server?All databases have no corruption when I ran DBCC checkdb (system & user dbs) but there were dumpfiles SqlDumpExceptionHandler: Process 9999 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process.what are the main reasons for acess violation dumpfiles?
I am working with an outside consultant to upgrade our SQL 7 instance. He wants to upgrade to SQL 2000 and I want to go to SQL 2005. I want to have concrete reasons backed up with documentation as to why we should go SQL 2005 as opposed to SQL 2000.
For eg. support (why 2005 is better, ie. longer support), security(More secure, documentation), management, stability (number of patches released last year) etc.
I'd really appreciate it if someone could point me to an appropriate resource.
Dear group,we are running a SQL-Server Database which is about 30 GB large. Thepurpose of this database is to contain periodic data from automaticdevices which insert values into some tables.Unfortunately most of these tables don't have a key (and a key can onlybe introduced when the application programmers have changed theirsoftware). Tables have this structuredeviceno timestamp datawhere we expect for every device and timestamp one row of data.In the ongoing operation it happens that the index of this large tablegets corrupted and a select from this table yields 2 rows for somedevices.In fact a select "SELECT DEVICENO, TIMESTAMP, COUNT(*) FROM TABLE GROUPBY DEVICENO, TIMESTAMP HAVING COUNT(*) > 1" returns lots of data.After rebuild of the indexes the table is "clean" again.What could cause the index corruption ?Missing key?Faulty application program ?a combination of both ?How can i prevent this from happening again, as long as there is noupdated database / application ?I'd be grateful for any useful commentRegardsUli
After viewing many reports in reportviewer, I sporadically get the following error message. Each attempt to access any report in report viewer after the error message first appears results in the same error message for a bit of time until it appears to reset itself. I have read that this may be related to running out of memory for report processing... We have 2GB of RAM. How can I prevent this from happening or force the system to free up some memory if it is exhausing the available memory?
For security reasons DTD is prohibited in this XML document. To enable DTD processing set the ProhibitDtd property on XmlReaderSettings to false and pass the settings into XmlReader.Create method.
I am getting this error while running a very large dataset. Please help..
The full description of the error is : "For security reasons DTD is prohibited in this XML document. To enable DTD processing set the ProhibitDtd property on XmlReaderSettings to false and pass the settings into XmlReader.Create method."
I am having hard time figuring out a solution for this. I am using sql 05, SSRS 05, Report viewer
When we develop with the Microsoft SQL Server 2005 Reporting Service. We got the exception on some reports.
For security reasons DTD is prohibited in this XML document. To enable DTD processing set the ProhibitDtd property on XmlReaderSettings to false and pass the settings into XmlReader.Create method.
Ther report renders well first time, but if we click the title to sort the report, it will throw the exception.
And It occurred that we use IE6 and IE7 to view the report at same time, but if we use the same version brower, there are no exception. Can somebody help me?
My development€™s environment :
Windows XP English Professional + SP2 Microsoft SQL Server 2005 Development version + SP 1 + SP 2 Microsoft Visual Studio 2005 Professional Version 8.0.50727.51 (QFE.050727-5100) + SP1 Microsoft .NET Framework Version 2.0.50727
When I try to install SQL Server I get the follwing message when I click on the installation file :
A strong SA password is required for security reasons.
Please use SAPWD switch to supply the same. Refer to readme
for more details. Setup will now exit.
I've checked the readme but can't really find any info on how to fix this. I don't know what password this SA password is nor how to change it. Can anyone help me out?
I would like to reinstall the enterprise manager of sql server 2000,and i have currently sql server 2000 SP4 installed on it.I googled on it, and read that installation of enterprise manager ispossible from the setup disk, however, this is not possible: it rejectsbecause of the service pack.How can I reinstall enterprise manager, without haveing to uninstallsql completely?ThanksPrem
I have subscription by email problem on the following configuration:
Windows XP prof. SQL Server 2005 Enterprise Configured Database Mail with remote SMTP server to send email successfully Configured SSRS to use remote SMTP server
Edited the Rsreportserver.config file as following (by the instructions from MSDN)
I scheduled my subscription and tested it. I didn't receive any mail from the setting email address, but got an error message in ReportServerService log file as following.
Error sending mail, CDO error -2147220978, will not resend Error sending email. System.Runtime.InteropServices.COMException (0x8004020E): The server rejected the sender address. The server response was: 530 authentication required - for help go to http://help.yahoo.com/help/us/mail/pop/pop-11.html
I did a little search, but couldn't find any solution for it. Is anybody successfully to get the Reporting Services subscription by email function working through MS SQL Server Management Studio or if you have a solution for this issue, would you mind to share the experience with me. I will be very appreciated.
This error comes up in the print preview and nothing prints.
We are using VS-2005, SQL 2005 and SSRS 2005.
We had the same problem yesterday , so we have reinstalled IIS, .Net Framework 2.0 and Reporting Services, then reconfigured RS security, uploaded all the reports and enabled remote errors. After doing everything this error was gone and we were operating pretty fine.
Suddenly just we started getting the same annoying message."ROOT ELEMENT MISSING" from Report Server and from Report Manager we have " For security reasons DTD is prohibited in this XML document. To enable DTD processing set the ProhibitDtd property on XmlReaderSettings to false and pass the settings into XmlReader.Create method. "
I have just finished configuring my first test mirrored environment (High safety mode). I setup the database engine service accounts on each of the servers with domainuser. I inherited a production mirrored environment set up by someone else. On the production servers the database engine service account is NT Authorityuser a local account. I am trying to practice installing Windows updates within a mirrored environment and I not sure how to proceed when the service account is NT Authority user account. should I change the service account to a domainuser?
I do a clean install of SQL Server + RS + SP1 with standard setup on Windows Server 2003. I create a simple report (select * from aTable). This report (actually any report) shows the error message "For security reasons DTD is prohibited in this XML document. To enable DTD processing set the ProhibitDtd property on XmlReaderSettings to false and pass the settings into XmlReader.Create method."
This has to do with security settings in Windows Server 2003. On Windows XP everything works fine.
Any help would be greatly appreciated. Thanks!
Edit: The reports do work in the preview tab in BIDS.
I have MS-Access as data source for one of the reports. I can preview the report fine from BI studio however, it does not work when I deploy it on report server.
The error is :
An error has occurred during report processing. Cannot create a connection to data source '<data source name>'.
The Microsoft Jet database engine cannot open the file '<UNC location of the MS-Access database>'. It is already opened exclusively by another user, or you need permission to view its data.
MS-Access database is located on a different server.
Any help to solve this? I understand it has something to do with permission both on server where reporting service is running as well as the server where MS-access database is located. Pls help.
I am trying to modify the files path (primary file, log file) of databases, but it looks like I am not able to mofidy their files path directly from the database property dialogue? Would please any experts here give me some ideas on what else can I try to figure it out? Thanks a lot in advance and I am looking forward to hearing from you shortly.
Can it possible of taking full dump db backup of Logshipping server [Secondary Server.] Or any other way {DTS} on Secondary server, to update third server on daily basis.
please co-operate me on this issue Thanx in advance