January 28, 2011 at 9:48 am
I have SQL Server 2008 r2. I have written a CLR procedure in C# and generated a DLL. I have a script which loads the assembly into my database and installs the procedures which invoke the CLR procedure.
The problem I am having is that the though the SQLCMD is running with a user of sa, many times the 'create assembly...' operation fails. It appears to be a permission issue. Though this is not the proper solution, I have added the user 'Everybody' to the directory containing the assemblies and the assemblies and granted full permission. With just read permission, I get an access denied error on the 'create assembly...' call.
What I am not clear on is, what is the minimum level of access that a process needs to load the dll? Also, is the 'user' attempting to access the DLL the 'Network Service' under which SQL Server is running?
Any clarification would be appreciated.
January 28, 2011 at 9:59 am
When you have loaded the dll into the database, the dll can effectively be removed from the directory. SO to be clear, the only time the dll needs to be accessed is when it is added to the db.
As far as I know the dll is being loaded with the same credentials as what SQL server is running as - in your case it seems the network service.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply