|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
CREATE ASSEMBLY failed because it could not open the physical fileServer: windows server 2003 with sqlexpress installed,named serverA. Client: windows xp, named clientB problem:Want to create assembly from a assembly dll file located in client machine. I use statement Create assembly foo from '<PATHFILE>' to create assembly in database. If <PATHFILE> is the absolute path of serverA, every thing is ok. If <PATHFILE> is in Shared Directory of clientB, such as \\clientB\SharedDocs\routine.dll, the following message appeared: CREATE ASSEMBLY failed because it could not open the physical file '\\clientB\SharedDocs\routine.dll': 5(access denied). How to fix it ? Thanks. Ajang Here is what BOL says:
===== When attempting to access the assembly specified in <client_assembly_specifier>, SQL Server impersonates the security context of the current Windows login. If <client_assembly_specifier> specifies a network location (UNC path), the impersonation of the current login is not carried forward to the network location because of delegation limitations. In this case, access is made using the security context of the SQL Server service account. ===== You need to ensure that proper permissions are present. -- Show quoteHTH, SriSamp Email: sris***@gmail.com Blog: http://blogs.sqlxml.org/srinivassampath URL: http://www32.brinkster.com/srisamp "AJang" <AJ***@discussions.microsoft.com> wrote in message news:A89D695D-F76C-43B0-8C88-EFFD352E5531@microsoft.com... > Scenario: > Server: windows server 2003 with sqlexpress installed,named serverA. > Client: windows xp, named clientB > problem:Want to create assembly from a assembly dll file located in client > machine. > > I use statement > Create assembly foo from '<PATHFILE>' > to create assembly in database. > > If <PATHFILE> is the absolute path of serverA, every thing is ok. > > If <PATHFILE> is in Shared Directory of clientB, such as > \\clientB\SharedDocs\routine.dll, the following message appeared: > > CREATE ASSEMBLY failed because it could not open the physical file > '\\clientB\SharedDocs\routine.dll': 5(access denied). > > How to fix it ? Thanks. > > Ajang > This should be access right problem. Seems that SQL Server uses the security
context of the SQL Server service account to access the network loation (UNC path). -- Martin C K Poon Senior Analyst Programmer ============================== "AJang" <AJ***@discussions.microsoft.com> ¼¶¼g©ó¶l¥ó·s»D:A89D695D-F76C-43B0-8C88-EFFD352E5***@microsoft.com... Server: windows server 2003 with sqlexpress installed,named serverA.Scenario: Client: windows xp, named clientB problem:Want to create assembly from a assembly dll file located in client machine. I use statement Create assembly foo from '<PATHFILE>' to create assembly in database. If <PATHFILE> is the absolute path of serverA, every thing is ok. If <PATHFILE> is in Shared Directory of clientB, such as \\clientB\SharedDocs\routine.dll, the following message appeared: CREATE ASSEMBLY failed because it could not open the physical file '\\clientB\SharedDocs\routine.dll': 5(access denied). How to fix it ? Thanks. Ajang In fact, ServerA is a domain controller of domain TEST,ClientB is a member
machine of TEST. In ServerA's active directory, in users group, there are groups such as SQLServer2005MSSQLServerADHelperUser$serverA SQLServer2005MSSQLUser$serverA$SQLEXPRESS SQLServer2005SQLBrowserUser$serverA I can't locate the "SQL Server service account" in active directory. In \\clientB\SharedDocs properies page, security tab," everyone" and "serverA\Domain users" have permissions READ/EXECUTE/Browse. The error message are the same. How to solve the access right problem? Ajang Show quote "Martin C K Poon @ Hong Kong" wrote: > This should be access right problem. Seems that SQL Server uses the security > context of the SQL Server service account to access the network loation (UNC > path). > > -- > Martin C K Poon > Senior Analyst Programmer > ============================== > > > "AJang" <AJ***@discussions.microsoft.com> ¼¶¼g©ó¶l¥ó·s»D:A89D695D-F76C-43B0-8C88-EFFD352E5***@microsoft.com... > Scenario: > Server: windows server 2003 with sqlexpress installed,named serverA. > Client: windows xp, named clientB > problem:Want to create assembly from a assembly dll file located in client > machine. > > I use statement > Create assembly foo from '<PATHFILE>' > to create assembly in database. > > If <PATHFILE> is the absolute path of serverA, every thing is ok. > > If <PATHFILE> is in Shared Directory of clientB, such as > \\clientB\SharedDocs\routine.dll, the following message appeared: > > CREATE ASSEMBLY failed because it could not open the physical file > '\\clientB\SharedDocs\routine.dll': 5(access denied). > > How to fix it ? Thanks. > > Ajang > > > The other posters are referring to the start-up service account for the SQL
Server service. Go to Services and make sure the account in which the service runs has sufficient privileges on the destination path. ML --- http://milambda.blogspot.com/ Using SQL Server Management Studio, I can't create assembly as I mention above.
In the same configuration, using sqlcmd, I DO create assembly successfully. So, may be it is a BUG of SQL Server Management Studio ? By the way, my Microsoft SQL Server Management Studio's version is 9.00.1399.00 HJY Show quote "ML" wrote: > The other posters are referring to the start-up service account for the SQL > Server service. Go to Services and make sure the account in which the service > runs has sufficient privileges on the destination path. > > > ML > > --- > http://milambda.blogspot.com/ =?Utf-8?B?QUphbmc=?= <AJ***@discussions.microsoft.com> wrote in
news:94B69361-59F2-4F99-91B0-1B6918CE8CC6@microsoft.com: Are you by any chance logging on to the SQL Server in SSMS by using SQL > Using SQL Server Management Studio, I can't create assembly as I > mention above. > > In the same configuration, using sqlcmd, I DO create assembly > successfully. > > So, may be it is a BUG of SQL Server Management Studio ? > By the way, my Microsoft SQL Server Management Studio's version is > 9.00.1399.00 Server security, and not Windows integrated? Also, are you absolutely sure the path is exactly the same when you do it in SSMS compared to SqlCmd? Niels -- ************************************************** * Niels Berglund * http://staff.develop.com/nielsb * nielsb at develop dot com * "A First Look at SQL Server 2005 for Developers" * http://www.awprofessional.com/title/0321180593 **************************************************
Show quote
"Niels Berglund" wrote: The Sql server instance is in pure Windows integrated authenticate mode.> =?Utf-8?B?QUphbmc=?= <AJ***@discussions.microsoft.com> wrote in > news:94B69361-59F2-4F99-91B0-1B6918CE8CC6@microsoft.com: > > > Using SQL Server Management Studio, I can't create assembly as I > > mention above. > > > > In the same configuration, using sqlcmd, I DO create assembly > > successfully. > > > > So, may be it is a BUG of SQL Server Management Studio ? > > By the way, my Microsoft SQL Server Management Studio's version is > > 9.00.1399.00 > > Are you by any chance logging on to the SQL Server in SSMS by using SQL > Server security, and not Windows integrated? > Yes, I use Copy/Paste strategy to ensure identically the same SQL script.> Also, are you absolutely sure the path is exactly the same when you do > it in SSMS compared to SqlCmd? Show quote > > Niels > > -- > ************************************************** > * Niels Berglund > * http://staff.develop.com/nielsb > * nielsb at develop dot com > * "A First Look at SQL Server 2005 for Developers" > * http://www.awprofessional.com/title/0321180593 > ************************************************** > =?Utf-8?B?QUphbmc=?= <AJ***@discussions.microsoft.com> wrote in
news:DDABC7CD-B60F-4220-B322-1625C32265B0@microsoft.com: And the login which you use for SSMS has access to the path where the> The Sql server instance is in pure Windows integrated authenticate > mode. dll is located? > Can you please post the statement that gives you the error from SSMS.>> >> Also, are you absolutely sure the path is exactly the same when you >> do it in SSMS compared to SqlCmd? > > Yes, I use Copy/Paste strategy to ensure identically the same SQL > script. Please post it exactly as you you have it in SSMS. Niels -- ************************************************** * Niels Berglund * http://staff.develop.com/nielsb * nielsb at develop dot com * "A First Look at SQL Server 2005 for Developers" * http://www.awprofessional.com/title/0321180593 **************************************************
Show quote
"Niels Berglund" wrote: Thanks a lot.> =?Utf-8?B?QUphbmc=?= <AJ***@discussions.microsoft.com> wrote in > news:DDABC7CD-B60F-4220-B322-1625C32265B0@microsoft.com: > > > The Sql server instance is in pure Windows integrated authenticate > > mode. > > And the login which you use for SSMS has access to the path where the > dll is located? > > > >> > >> Also, are you absolutely sure the path is exactly the same when you > >> do it in SSMS compared to SqlCmd? > > > > Yes, I use Copy/Paste strategy to ensure identically the same SQL > > script. > > Can you please post the statement that gives you the error from SSMS. > Please post it exactly as you you have it in SSMS. After looking through all the detail, I found that 1. In SSMS , I connect to <IP address>\sqlexpress 2. In Sqlcmd, I connect to <NetBiosName>\sqlexpress So, I know it IS an access right problem. Now, can you tell me 1. In connecting to <IP address>\sqlexpress case, Sql server impersonate as which account to access an UNC path file. 2. In connecting to <NetBiosName>\sqlexpress case, Sql server impersonate as which account to access an UNC path file. HJY Show quote > > Niels > > > -- > ************************************************** > * Niels Berglund > * http://staff.develop.com/nielsb > * nielsb at develop dot com > * "A First Look at SQL Server 2005 for Developers" > * http://www.awprofessional.com/title/0321180593 > ************************************************** > =?Utf-8?B?QUphbmc=?= <AJ***@discussions.microsoft.com> wrote in
news:54E4FCEB-B9CC-4DB0-8438-0333C0A77F4E@microsoft.com: Create the assembly from a byte stream instead.> In fact, ServerA is a domain controller of domain TEST,ClientB is a > member machine of TEST. > [snip] > The error message are the same. > How to solve the access right problem? Niels -- ************************************************** * Niels Berglund * http://staff.develop.com/nielsb * nielsb at develop dot com * "A First Look at SQL Server 2005 for Developers" * http://www.awprofessional.com/title/0321180593 ************************************************** |
|||||||||||||||||||||||