title: Cannot initialize the data source object of OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server
body: <p>I'm trying to establish a linked server from <code>SQL Server 2008 R2</code> to an <code>Access database</code>. The <code>Access database</code> is not password protected. As I have seen in other posts (<a href="https://stackoverflow.com/questions/1362108/cannot-initialize-the-data-source-object-of-ole-db-provider-msdasql-for-linked">specifically this one</a>), this is usually due to the current user not having access to the Temp folder inside the NetworkService folder. Since we are running this in <code>Windows Server 2008</code>, the directory structure is quite different than what most are eluding to. I have allowed access to every temp folder in the <code>"root:\Documents and Settings\" directory</code>, and to no avail.</p>
  
  <p>This is the procedure I am using to add the linked server:</p>
  
  <pre><code>EXEC sp_addlinkedserver 
  @server = N'OS_Access', 
  @provider = N'Microsoft.ACE.OLEDB.12.0', 
  @srvproduct = N'',
  @datasrc = N'C:\RTBData\Data\OS.mdb';
  GO
  </code></pre>
  
  <p>It creates the linked server with no problem, but I am not able to view the tables/views of the database. Likewise, my ASP.NET application cannot access it either.</p>
  
  <p>I have tried both <code>ACE and JET(64-bit)</code>(by installing the Data Connectivity Components for Office), and they both do not work. I have also tried configuring the ACE provider with <code>"Dynamic Parameter"</code> and <code>"Allow InProcess"</code> to true. </p>
  
  <p>Additionally, I tried upping the memory usage by the <code>MSSQLSERVER services</code> by adding <code>"-g512;</code>" in front of <code>"startup parameters"</code> string in SQL configuration manager to rule out memory issues.</p>
  
  <p>If anyone could shed some light on this that would be fantastic! Thanks!</p>
  
  <p><strong>UPDATE:</strong> I logged into SQL using the sa account, and I was able to view the linked server. My current user account has full permissions in SQL server, so I am unsure of what the difference is between the accounts. Maybe I gave permissions to the wrong <code>Temp</code> folder, in which the sa account (being built-in) has access to. If someone could point me in the right direction here, that would be great, and I think it would also help a lot of other people.</p>