Asked by:
During TFS 2012 Restore Database Backups Operation - receiving "cannot access the specified path"

Question
-
So this is bizarre. I have a share that the account I am logged into can access directly on the server AND from the TFS App Tier through Windows Explorer. The TFS 2012 Restore Tool is claiming that same user, from the same machine, cannot access the directory. Below is a screenshot where I am in fact accessing that folder through one tool but then getting blocked in another. Is the TFS Restore tool not using the logged in account to perform the restore or something?
So let's now talk about that error message:
>"Cannot Access the specified Path"
I don't know, I am accessing it FINE from Windows Explorer on the same machine at the same time.
"Please make sure that the directory exists and the account that the SQL Server is running under has read access to it".
See above. Clearly the directory exists, and clearly I have read access to it. But what does "the account that the SQL Server is running under" even mean? I am running a restore tool, not "the SQL Server". Does this need to also be an account that is an Admin on the Data Tier or something? For the record, it is.Maybe I haven't had enough coffee and I am missing something super obvious. I really hope it's that easy. HELP!
Angela Dugan
Thursday, November 1, 2012 2:38 PM
All replies
-
Hi Angela,
Thanks for your post.
Which account your provided in the TFS Power Tools Backup Plan Wizard? That create Backup Plan account is the current logon account(which you used to access that Hold folder from the TFS App Tier through Windows Explorer)?
Try to set Hold folder share for Everyone temporarily, then try to restore backup from that Hold folder using TFS Power Tools again, can read backup files correctly?
John Qiao [MSFT]
MSDN Community Support | Feedback to us
Friday, November 2, 2012 8:04 AMModerator -
The account provided was TFSService which has admin rights on every machine in the TFS implementation, sysadmin on the Data Tier and specifically Read/Write access to the HOLD folder. The account I was logged into the machine as was the SAME account, TFSService, out of desperation because nothing else was working either.
So what account is used? The one I am logged in as? The one supplied in the "Account" tab? Both? It would be nice if that was clear. Otherwise I am guessing and I can't just go granting rights on production to EVERYONE, even temporarily. This company will not allow it.
I ended up just using file explorer to copy everything out of the Holds folder to another location I knew I could access with the Backup tool, so I could restore from there.
Angela Dugan
Friday, November 2, 2012 12:19 PM -
Hi Angela,
Thanks for your reply.
According this document, the service account for the instance of SQL Server need have the read access to your share folder.
That account provide in “Account” tab, that I mean create TFS backup using TFS Power Tools, please refer to this article: http://www.incyclesoftware.com/2012/09/backing-tfs-2012/.
John Qiao [MSFT]
MSDN Community Support | Feedback to us
- Edited by John QiaoModerator Monday, November 5, 2012 3:09 AM
Monday, November 5, 2012 2:58 AMModerator -
I did read that article, what I was saying is that it is not detailed enough. It says "The service account for the instance of SQL Server you identified at the start of this procedure have read access to this share." Do they mean the TFSService account? Some other account? What rights does that account need on SQL Server? Sysadmin? TFSExecRole? Server Administrator? All of the above?
The service account I used DID have access, as in the screenshot you can see I had connected to that share using file explorer while I was running the Backup tool. I was logged into the TFS Server as the same service account that I was specifying in the Account tab. I'd need to verify but I believe the DBA had to give that Account I was using additional SQL server roles (maybe sysadmin?) for this to work.
In that second article you referenced by Incycle, the author of the article conveniently skipped the Account tab altogether, and says "Provide account information & notification settings in next two screens.." and nothing more. Not helpful, at all. Go back and look, they literally skipped that tab, and made no mention of appropriate accounts to use in the account tab and the rights needed.
Angela Dugan
Wednesday, November 7, 2012 5:11 PM -
Hi Angela,
Thanks for your reply.
Does your current SQL Server service account has the required permissions on that backup folder?
John Qiao [MSFT]
MSDN Community Support | Feedback to us
Monday, November 12, 2012 3:22 AMModerator -
According to the DBA it did. It looks like both the account specified AND the account you are running the wizard as needed permissions, it was just documented poorly. Once I was running the wizard as a user with the same access leveles as the account specified in the wizard things worked well.
Angela Dugan
- Marked as answer by John QiaoModerator Tuesday, November 13, 2012 7:08 AM
- Unmarked as answer by Angela Ann DuganMVP Tuesday, December 11, 2012 4:47 PM
Monday, November 12, 2012 2:27 PM -
So we are still receiving this error on our production server.
I am using the TFSService account as the account to run under and the only difference I have noted is that on the server where it is working fine (the development server), TFSService has "Full Control" of the folder being written to. The server where I am getting an "error" status, TFSService only has Read/Write. It does not say anywhere in documentation I have seen, that Full Control is needed on the folder we are writing backups to. But does it need full control?
Also, I noted that manual backups work just fine if I invoke it while logged into the app tier, it is only when they are scheduled and try to run at night that it fails.
Lastly, where are errors written? Right now I see "Last Run Result" = "Error" but I have no idea where to look to see more details. There isn't anything in the TFS logs or the app tier event logs. On the SQL Server where the backups are being saved I see this but no additional detail "Package "TFS BACKUPS-NEW" failed." every night around 10PM when they kick off.
Angela Dugan
Tuesday, December 11, 2012 4:45 PM