I migrated from TFS 2015 to TFS 2017 and after the upgrade I moved the distribution of the artifacts from the build to a release-step (after the build-step).
In the release-step I delete all content of the output-folder (on a network share) and copy the artifacts and some needed setups (laying on a network share) to the output folder. Most of the time the copy process works fine but once a while (once every 4-5 tries) the copying of the needed setups fails with a bad-file-descriptor:
2018-12-03T16:10:35.6151925Z ##[debug]testing directory '\\My\Fancy\Network\Share\Development\CD\ExpressionBlend'
2018-12-03T16:10:35.6164686Z ##[debug]task result: Failed
2018-12-03T16:10:35.6210378Z ##[error]Error: EBADF: bad file descriptor, stat '\\My\Fancy\Network\Share\Development\CD\ExpressionBlend'
2018-12-03T16:10:35.6218500Z ##[debug]Processed: ##vso[task.issue type=error;]Error: EBADF: bad file descriptor, stat '\\My\Fancy\Network\Share\Development\CD\ExpressionBlend'
2018-12-03T16:10:35.6235282Z ##[debug]Processed: ##vso[task.complete result=Failed;]Error: EBADF: bad file descriptor, stat '\\My\Fancy\Network\Share\Development\CD\ExpressionBlend'
I'm thankful for every hint, as I don't have any idea where to start...