Hi Can you please help to run backup command automatically when error log have error like error 3041 and error 18210
-
Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking.– Community BotCommented Dec 7, 2022 at 10:23
-
actually what happened we are taking tape backups with third-party tools. we are facing some issues in that. we need to take local backup in server. I want to automate that when we get error 3041 or 18210 at that time automatically run the backup command in server. for this i need help to automate.– Srinivas SCommented Dec 7, 2022 at 10:29
-
is there a chance to run the job automatically when we get the error 3041– Srinivas SCommented Dec 7, 2022 at 10:31
1 Answer
Error 18210
This message indicates that an I/O error was reported by the operating system after a file handle was successfully opened. The error occurs when reading from or writing to a device specified as part of a BACKUP or RESTORE command, often when there is not enough disk space available for a write operation. This error may also be seen if third-party software that uses a virtual device to perform SQL Server backups cancels the operation.
It looks like there is not enough disk space.
Edit after new information about the needs To automate the backup on another way is that you can create a SQL Agent Job for it which does the backup to the other location. Then, you can create an Alert for the given error which kicks of that job.
In response tab you can add the job which will do the backup to the other location:
-
yes, we are taken tape backups when there is no enough disk space this error occurs at that time need to take local backup. is there any way to automate this Commented Dec 7, 2022 at 10:26
-
Well that wasn't very clear in the opening question ;-) So you are running a backup, and when there is not enough space, it should create another backup to another location?– PeterCommented Dec 7, 2022 at 10:36
-
-
1Just a note that you should verify that this error number is written to the Windows eventlog. Agent polls the eventlog (not the errorlog file). There are cases when there are rare differences between what is in the eventlog vs the errorlog, so check eventlog just to be certain. Commented Dec 7, 2022 at 14:35
-
1