Receiving Bulk Insert Error 1450 (error not found) when executing stored procedure - sql-server

Cannot bulk load because the file "\\servername\sharedfolder\folder\file.txt" could not be opened. Operating System error code 1450 (error not found)
The file.txt is on a shared folder in a remote network. I have already googled and tried to apply almost every single entry on the web related to this issue but still unresolved.
I tried windows authentication,sql server authentication, made sure that I have bulkadmin role, requested full access to shared folder from dba.
The error 1450( error not found) is so vague.

Related

Linked Server Test Connection Not Working (SQL Server to Oracle Database)

Database Versions:
SSMS: 17.9,
Oracle: 19.3
We are trying to establish a linked server connection to our production Oracle DB (hosted by another team) that uses SSL. The LS was created, however our test connection attempts always return this:
Cannot initialize the data source object of OLE DB provider "OraOLEDB.Oracle" for linked server "CDWRP201_TCPS". OLE DB provider "OraOLEDB.Oracle" for linked server "CDWRP201_TCPS" returned message "Error while trying to retrieve text for error ORA-28759". (Microsoft SQL Server, Error: 7303)
I read that this meant "failure to open file" and could be caused by insufficient wallet permissions so I gave our users full access to the files (not sure if this is recommended). I did the same for the ewallet, ORA files, and even their parent folders but still no success.
What's weird is that test connections work for our non-SSL connections, which use the same tnsnames.ora file. We have no problems connecting to the Oracle DB using tnsping and sqlplus as well.
I'm struggling with this because my experience with Oracle and SSMS linked servers are few to none and feel like I've hit a dead end. Any direction you can give will be very much appreciated. I'm happy to provide more details if needed.
Thank you very much.
You actually have TWO problems.
First, your call to oracle returned ORA-28795. AS others are focusing on, that results from a failure to open a wallet. However, rather than looking for permissions issues, I'd note the second error ...
The "Error while trying to retrieve text for error" indicates that your ORACLE_HOME (for the oracle client being used my msssql) is not correctly set. When the call received the ORA-28759, it needed to find the error message file to be able to properly report it. But with improper ORACLE_HOME it was unable to locate the message file.
And it very well might be the case that the invalid ORACLE_HOME is also the root cause of the ORA-28759. I've not much expderince with walllets, but it seems reasonable that it needs ORACLE_HOME to locate the wallet, just as it needs it to locate the message file ... and a bunch of other stuff. In any event, get ORACLE_HOME set correctly and you will get more informative diagnostics/error messages on your ORA-28795.
You said yourself that "The only variable that indicated Oracle was our PATH". You need to also set ORACLE_HOME. If your oracle PATH is 'C:\Oracle\x64\product\19.0.0\client_64\bin', then your ORACLE_HOME should be 'C:\Oracle\x64\product\19.0.0\client_64'

ogr2ogr error: "Unable to initialize connection to the server ...."

I am getting the error detailed in the screenshot below when running ogr2ogr. The command used worked on my other computer. I am wondering if this is an error that is triggering because I do not have proper permissions.
One last detail: the database I am uploading to exists.

SQL Server fails to start after moving database files: "Could not open file .. Access is denied"

I have moved the data files to new location but while moving I have given the wrong data file name. So it is throwing error
A file activation error occurred. The physical file name 'D:\Programfiles\Microsoft Sql server\MSSQL2008\Data\MSDBLog.ldf' may be incorrect. Diagnose and correct additional errors, and retry the operation.
FCB::Open failed: Could not open file D:\Programfiles\Microsoft Sql server\MSSQL2008\Data\modellog.ldf for file number 2. OS error: 5(Access is denied.).
these were the errors I was getting after the data file movement.
Please suggest me what should be done to start the sql server service.

WEBMethods connection string is not working?

The following WEBMethods string is not connecting to the server on our companies network drive. I can take the string and place it in a web broswer and i will get a windows exploer screen but when run from WEBMethods the error is Access is denied.
Question: What is causing the access to be denied through WEBMethods? (I can access the file through internet explorer)
Connection String: (Names change to safe guard any information)
//ServerName/DriveName/S/AB/P/T
Error:
com.wm.app.b2b.server.ServiceException: java.io.FileNotFoundException: \\espr1fs05
\DSSXFER\SYSTEMS\ACCESS BACKUPS\Prod\Test\TBE-FILE02.txt (Access is denied)
New Code Added:
System.out.println("outputDirectory --> " + outputDirectory);
writer = new PrintWriter(new BufferedWriter(new FileWriter("doug.txt")));
I have the code in my Java service and would like to write to a network drive as a test.
allowedWritePaths=//ESPR1FS05/DSSXFER/SYSTEMS/ACCESS BACKUPS/Prod/Test;
allowedReadPaths=//ESPR1FS05/DSSXFER/SYSTEMS/ACCESS BACKUPS/Prod/Test;
allowedDeletePaths=//ESPR1FS05/DSSXFER/SYSTEMS/ACCESS BACKUPS/Prod/Test;
The above is how the fileAccessControl.cnf file is configured and this is the same path that I put into the web service for the input file. When I test a write from Java it will work.
What could be wrong with the above write paths?
Error Statements:
com.wm.app.b2b.server.ServiceException: java.io.FileNotFoundException:
\ESPR1FS05\DSSXFER\SYSTEMS\ACCESS BACKUPS\Prod\Test\T.txt (Access is denied)
com.wm.app.b2b.server.ServiceException: java.io.FileNotFoundException:
\\ESPR1FS05\DSSXFER\SYSTEMS\ACCESS BACKUPS\Prod\Test\T.txt (Access is denied)
I'm not sure but did you try reloading the WMPublic package ? Maybe the changes you made to the fileAccessControl.cnf have not been loaded into memory.
Maybe it requires a webMethods server reboot.
When you can not find a file in webMethods. There are maybe couple of reasons.
The file path is in the cache so it may different from what you think it is. Reloading the proper package will resolve it.
The webMethods flow don't have right permission to write to or read from the file. You can edit it in flow's properties window.
WebMethods server mount to the remote drive but don't have permission to read the file.
And I don't suggest directly process the remote file through webMethods. You should use FTP or SFTP to process the file in webMethods server and send it to remote drive.

Server Error in Application

Whenever I am viewing my file (file is located in shared drive) to a browser, I am getting this error:
Server Error in '/Test' Application.
Security Exception
Description: The application attempted
to perform an operation not allowed by
the security policy. To grant this
application the required permission
please contact your system
administrator or change the
application's trust level in the
configuration file.
Exception Details:
System.Security.SecurityException:
Request for the permission of type
'System.Web.AspNetHostingPermission,
System, Version=2.0.0.0,
Culture=neutral,
PublicKeyToken=b77a5c561934e089'
failed.
Source Error:
An unhandled exception was generated
during the execution of the current
web request. Information regarding the
origin and location of the exception
can be identified using the exception
stack trace below.
I contacted the System Admin, he said he has given the full access rights to my PC. What is going wrong here?
By default you can't host ASP.NET pages from a shared drive since this is an untrusted location. You will need to edit your .NET configuration to allow this location. You can find a quick guide here (The first answer): http://forums.asp.net/t/1371394.aspx
A quick test before doing that is to copy the project locally and run it. If everything works, then that is your problem. If it is important to keep the project on the shared drive you will have to follow the above steps to make it a trusted location.

Resources