473,387 Members | 1,465 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Why SQL2036N error (path not valid) when Load utility uses SMB networkdrive as source ?

I've encountered a strange error with loading delimited files from a
Samba (SMB) network drive, has anyone else seen this before?

(Platform: WinXP Pro, UDB PE 8015, level 02060106, SAMPLE db)

db2 load from M:\org1.del of del replace into org
SQL3109N The utility is beginning to load data from file "M:\org1.del".
SQL2036N The path for the file or device "M:\org1.del" is not valid.

db2diag.log:
2004-07-27-17.59.37.156000 Instance:DB2 Node:000
PID:1080(db2syscs.exe) TID:2228 Appid:none
database utilities sqluMCCheckDevType Probe:10
Media controller -- invalid device path: M:\org1.del

The Samba drives are served from an AIX host, and seem to work fine
otherwise. I created the data file a few moments before, using an export
command and it completed fine. I can also read from this drive with the
import command, and it processes the records without problem.

C:\>net use
Status Lokal Remote Netzwerk
-----------------------------------------------------------------
OK M: \\spsmbp\data_tmp Microsoft Windows-Netzwerk
A db2trace shows the following:

17741 data DB2 oper system services sqloFileAttrib cei
(3.3.15.191.2.2)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229608 probe 2
bytes 11
4D3A5C6F 7267312E 64656C M:\org1.del

17744 exit DB2 oper system services sqloFileAttrib cei (2.3.15.191.2)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229757
rc = 0x870F0011 = -2029060079 = SQLO_PATH

17745 data DB2 database utilities sqluMCCheckDevType fnc
(3.3.21.1275.0.10)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229768 probe 10
bytes 52
4D656469 6120636F 6E74726F 6C6C6572 Media controller
202D2D20 696E7661 6C696420 64657669 -- invalid devi
63652070 6174683A 204D3A5C 6F726731 ce path: M:\org1
2E64656C .del

Seems like the Media controller didn't like the answer returned by the
sqloFileAttrib function, but why? (SQLO_PATH?) I didn't find any
documented limitations for Load using network drives, so I am wondering
if the Samba server could be at fault.

The share definition in smb.conf seems normal, although Oplocks=no is
set. Would Load need byte-range locking on the input file? But not Import ??

Thanks for any feedback...

Nov 12 '05 #1
7 19564
I'm not sure why EXPORT works and LOAD fails but I've run into a similar
problem with networked drives.

UDB is started fairly early in the boot process - usually before the
networked drives have been defined to the system. Things that go through
your user logon (ie. EXPORT) can use the networked drive because you can
see it. UDB itself has no access to the networked drives because they
didn't exist at the time it started.

This obviously isn't what we'd like to see but I think that it's a
characteristic of the Win environment.

Phil Sherman

Eric.Jones wrote:
I've encountered a strange error with loading delimited files from a
Samba (SMB) network drive, has anyone else seen this before?

(Platform: WinXP Pro, UDB PE 8015, level 02060106, SAMPLE db)

db2 load from M:\org1.del of del replace into org
SQL3109N The utility is beginning to load data from file "M:\org1.del".
SQL2036N The path for the file or device "M:\org1.del" is not valid.

db2diag.log:
2004-07-27-17.59.37.156000 Instance:DB2 Node:000
PID:1080(db2syscs.exe) TID:2228 Appid:none
database utilities sqluMCCheckDevType Probe:10
Media controller -- invalid device path: M:\org1.del

The Samba drives are served from an AIX host, and seem to work fine
otherwise. I created the data file a few moments before, using an export
command and it completed fine. I can also read from this drive with the
import command, and it processes the records without problem.

C:\>net use
Status Lokal Remote Netzwerk
-----------------------------------------------------------------
OK M: \\spsmbp\data_tmp Microsoft Windows-Netzwerk
A db2trace shows the following:

17741 data DB2 oper system services sqloFileAttrib cei
(3.3.15.191.2.2)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229608 probe 2
bytes 11
4D3A5C6F 7267312E 64656C M:\org1.del

17744 exit DB2 oper system services sqloFileAttrib cei (2.3.15.191.2)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229757
rc = 0x870F0011 = -2029060079 = SQLO_PATH

17745 data DB2 database utilities sqluMCCheckDevType fnc
(3.3.21.1275.0.10)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229768 probe 10
bytes 52
4D656469 6120636F 6E74726F 6C6C6572 Media controller
202D2D20 696E7661 6C696420 64657669 -- invalid devi
63652070 6174683A 204D3A5C 6F726731 ce path: M:\org1
2E64656C .del

Seems like the Media controller didn't like the answer returned by the
sqloFileAttrib function, but why? (SQLO_PATH?) I didn't find any
documented limitations for Load using network drives, so I am wondering
if the Samba server could be at fault.

The share definition in smb.conf seems normal, although Oplocks=no is
set. Would Load need byte-range locking on the input file? But not
Import ??

Thanks for any feedback...


Nov 12 '05 #2
"Philip Sherman" <ps******@ameritech.net> wrote in message
news:zx****************@newssvr28.news.prodigy.com ...
I'm not sure why EXPORT works and LOAD fails but I've run into a similar
problem with networked drives.

UDB is started fairly early in the boot process - usually before the
networked drives have been defined to the system. Things that go through
your user logon (ie. EXPORT) can use the networked drive because you can
see it. UDB itself has no access to the networked drives because they
didn't exist at the time it started.

This obviously isn't what we'd like to see but I think that it's a
characteristic of the Win environment.

Phil Sherman

I believe that these limitations are documented in the Command Reference
manual for LOAD.
Nov 12 '05 #3
Drive mappings are local to the logon account that creates them. On W2K and
earlier, they were also machine-wide aliases, despite being local to the
logon account - a problem that was first resolved in XP. That problem
prevented distinct mappings of the same drive letter using different logon
accounts.

As a result M: does not exist in the DB2 logon account, where the load is
running, and the error message correctly states this. Export works, as the
export is executed in the client process.

Neither SAMBA, nor DB2 LOAD are in any way involved. This is a Windows
issue - or more precisely, a problem with your understanding of Windows
security.

The fix in XP (W2k3) does not help your case, as what you want is global
aliases and no security, whereas what is fixed is that aliases are now
logon-session local, rather than just beig local to the terminal session.
This means that the drive alias is now scoped to the same object to which
security was tied. In any case, it would obviously be a very bad thing
indeed if DB2 were to see your drive mappings and be able to access your
drives as if it were you. This would be equivalent to no security.
"Eric.Jones" <Er********@hispeed.ch> wrote in message
news:ce**********@newshispeed.ch...
I've encountered a strange error with loading delimited files from a
Samba (SMB) network drive, has anyone else seen this before?

(Platform: WinXP Pro, UDB PE 8015, level 02060106, SAMPLE db)

db2 load from M:\org1.del of del replace into org
SQL3109N The utility is beginning to load data from file "M:\org1.del".
SQL2036N The path for the file or device "M:\org1.del" is not valid.

db2diag.log:
2004-07-27-17.59.37.156000 Instance:DB2 Node:000
PID:1080(db2syscs.exe) TID:2228 Appid:none
database utilities sqluMCCheckDevType Probe:10
Media controller -- invalid device path: M:\org1.del

The Samba drives are served from an AIX host, and seem to work fine
otherwise. I created the data file a few moments before, using an export
command and it completed fine. I can also read from this drive with the
import command, and it processes the records without problem.

C:\>net use
Status Lokal Remote Netzwerk
-----------------------------------------------------------------
OK M: \\spsmbp\data_tmp Microsoft Windows-Netzwerk
A db2trace shows the following:

17741 data DB2 oper system services sqloFileAttrib cei
(3.3.15.191.2.2)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229608 probe 2
bytes 11
4D3A5C6F 7267312E 64656C M:\org1.del

17744 exit DB2 oper system services sqloFileAttrib cei (2.3.15.191.2)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229757
rc = 0x870F0011 = -2029060079 = SQLO_PATH

17745 data DB2 database utilities sqluMCCheckDevType fnc
(3.3.21.1275.0.10)
pid 2480 tid 2052 cpid -1 node 0 sec 0 nsec 4229768 probe 10
bytes 52
4D656469 6120636F 6E74726F 6C6C6572 Media controller
202D2D20 696E7661 6C696420 64657669 -- invalid devi
63652070 6174683A 204D3A5C 6F726731 ce path: M:\org1
2E64656C .del

Seems like the Media controller didn't like the answer returned by the
sqloFileAttrib function, but why? (SQLO_PATH?) I didn't find any
documented limitations for Load using network drives, so I am wondering
if the Samba server could be at fault.

The share definition in smb.conf seems normal, although Oplocks=no is
set. Would Load need byte-range locking on the input file? But not Import ??
Thanks for any feedback...

Nov 12 '05 #4
The share definition in smb.conf seems normal, although Oplocks=no is
set. Would Load need byte-range locking on the input file? But not
Import ??


After a bit more investigation, it seems Samba is not (directly)
implicated. Using Ethereal to monitor the network traffic to the SMB
server, we saw zero packets exchanged during the open attempt. So it's
not failing because of any bad status returned by Samba.

With the feedback from Philip & Mark (thanks guys!), it seems the real
issue lies with Windows network share handling. Although the DB2
instance owner is the same as the login account I am using for export,
it is normally started earlier as a windows service. I'm going to try
some further testing with the focus on sqloFileAttrib.

The original goal was to provide a common filespace for data
distribution to a group of developer machines. The delimited load files
for numerous testcases could be served from Samba and loaded
automatically, without requiring lots of local space on every machine.

With the apparent evolution of "network drive letter" transitioning to
"logon session resource", this may not be a viable approach for Windows
targets.
Nov 12 '05 #5
I have just recently found a issue that may help solve this problem. I
was having problems doing restores and backups to a networked drive
running db2 on win2k3. Anyone else having this issue? I previously did
this with no problem against win2k using mapped drives and service
accounts with domain rights. I was getting the same SQL code you are
getting. Anyway, long story short...Try using UNC paths instead of
mapped drives. That seemed to be the answer for my problem.
"Eric.Jones" <Er********@hispeed.ch> wrote in message news:<ce**********@newshispeed.ch>...
The share definition in smb.conf seems normal, although Oplocks=no is
set. Would Load need byte-range locking on the input file? But not
Import ??


After a bit more investigation, it seems Samba is not (directly)
implicated. Using Ethereal to monitor the network traffic to the SMB
server, we saw zero packets exchanged during the open attempt. So it's
not failing because of any bad status returned by Samba.

With the feedback from Philip & Mark (thanks guys!), it seems the real
issue lies with Windows network share handling. Although the DB2
instance owner is the same as the login account I am using for export,
it is normally started earlier as a windows service. I'm going to try
some further testing with the focus on sqloFileAttrib.

The original goal was to provide a common filespace for data
distribution to a group of developer machines. The delimited load files
for numerous testcases could be served from Samba and loaded
automatically, without requiring lots of local space on every machine.

With the apparent evolution of "network drive letter" transitioning to
"logon session resource", this may not be a viable approach for Windows
targets.

Nov 12 '05 #6
Mike wrote:
[snip]..Anyway, long story short...Try using UNC paths instead of mapped drives. That seemed to be the answer for my problem.

Thanks for relating the backup/restore experiences.
I tried the UNC variation in my short testcase, but also without success.
However, I was able to expose a bit more information using filemon to
view some of the underlying calls.

C:\>db2 load from \\spsmbp\data_tmp\org1.del of del messages org1.msg replace into org

SQL3109N The utility is beginning to load data from file "\\spsmbp\data_tmp\org1.del".
SQL2036N The path for the file or device "\\spsmbp\data_tmp\org1.del" is not valid.

The db2diag.log shows the same complaint from MediaController:

2004-08-11-11.08.44.437000 Instance:DB2 Node:000
PID:2444(db2syscs.exe) TID:2184 Appid:none
database utilities sqluMCCheckDevType Probe:10
Media controller -- invalid device path: \\spsmbp\data_tmp\org1.del

Here's what was happening from the XP filemon trace:
(expanding mail line width to 100, hope it's readible)
:27.843 db2bp.exe:3912 FASTIO_QUERY_OPEN C:\org1.msg SUCCESS Attributes: A
:27.843 db2bp.exe:3912 IRP_MJ_CREATE C:\org1.msg SUCCESS Options: OpenIf WriteThrough Access: All
:27.843 db2bp.exe:3912 IRP_MJ_CREATE \\spsmbp\data_tmp SUCCESS Options: Open Directory Access: Traverse
:27.843 db2bp.exe:3912 IRP_MJ_QUERY_VOLUME_INFORMATION \\spsmbp\data_tmp SUCCESS FileFsDeviceInformation
..
:28.140 db2syscs.exe:1912 FASTIO_QUERY_OPEN \\spsmbp\data_tmp\org1.del FAILURE
:28.140 db2syscs.exe:1912 IRP_MJ_CREATE \\spsmbp\data_tmp\org1.del * 0xC000006D Options: Open Access:All
..
:28.156 db2syscs.exe:1912 FASTIO_QUERY_OPEN \\spsmbp\data_tmp\org1.del FAILURE
:28.156 db2syscs.exe:1912 IRP_MJ_CREATE \\spsmbp\data_tmp\org1.del * 0xC000006D Options: Open Access:All


Notice how the db2bp process has no trouble with the open and volume query.
But this is a local process started during my login session from the CLI window.
Later db2syscs (engine process?) tries (twice!) with FASTIO_QUERY_OPEN but fails.

The IRP_MJ_Create appears to be a filter for the underlying FSD (or UNC redirector).
The 0xC..06D error seems related to Logon Authentication Failure problems, which
suggests why the open does not get a handle returned. I could find very little info
documenting the FASTIO_ functions, so I gave up at this point with WinDDK debug.

Nov 12 '05 #7
Eric.Jones wrote:
Mike wrote:
[snip]..Anyway, long story short...Try using UNC paths instead of


mapped drives. That seemed to be the answer for my problem.

Thanks for relating the backup/restore experiences.
I tried the UNC variation in my short testcase, but also without success.
However, I was able to expose a bit more information using filemon to
view some of the underlying calls.

C:\>db2 load from \\spsmbp\data_tmp\org1.del of del messages org1.msg
replace into org

SQL3109N The utility is beginning to load data from file
"\\spsmbp\data_tmp\org1.del".
SQL2036N The path for the file or device "\\spsmbp\data_tmp\org1.del" is
not valid.

The db2diag.log shows the same complaint from MediaController:

2004-08-11-11.08.44.437000 Instance:DB2 Node:000
PID:2444(db2syscs.exe) TID:2184 Appid:none
database utilities sqluMCCheckDevType Probe:10
Media controller -- invalid device path: \\spsmbp\data_tmp\org1.del

Here's what was happening from the XP filemon trace:
(expanding mail line width to 100, hope it's readible)
:27.843 db2bp.exe:3912 FASTIO_QUERY_OPEN C:\org1.msg SUCCESS
Attributes: A
:27.843 db2bp.exe:3912 IRP_MJ_CREATE C:\org1.msg SUCCESS
Options: OpenIf WriteThrough Access: All
:27.843 db2bp.exe:3912 IRP_MJ_CREATE \\spsmbp\data_tmp SUCCESS
Options: Open Directory Access: Traverse
:27.843 db2bp.exe:3912 IRP_MJ_QUERY_VOLUME_INFORMATION
\\spsmbp\data_tmp SUCCESS FileFsDeviceInformation
.. :28.140 db2syscs.exe:1912 FASTIO_QUERY_OPEN
\\spsmbp\data_tmp\org1.del FAILURE
:28.140 db2syscs.exe:1912 IRP_MJ_CREATE \\spsmbp\data_tmp\org1.del
* 0xC000006D Options: Open Access:All
..
:28.156 db2syscs.exe:1912 FASTIO_QUERY_OPEN
\\spsmbp\data_tmp\org1.del FAILURE
:28.156 db2syscs.exe:1912 IRP_MJ_CREATE \\spsmbp\data_tmp\org1.del
* 0xC000006D Options: Open Access:All

Notice how the db2bp process has no trouble with the open and volume query.
But this is a local process started during my login session from the CLI
window.
Later db2syscs (engine process?) tries (twice!) with FASTIO_QUERY_OPEN
but fails.

The IRP_MJ_Create appears to be a filter for the underlying FSD (or UNC
redirector).
The 0xC..06D error seems related to Logon Authentication Failure
problems, which
suggests why the open does not get a handle returned. I could find very
little info
documenting the FASTIO_ functions, so I gave up at this point with
WinDDK debug.

does the account which is starting the db2 service authorized to access
this unc path? this was the solution to my backup/restore problem with
unc paths.
Nov 12 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Wayno | last post by:
My php logs are coming up empty. I have done all I can think of, and all that made sense to me. Can someone take a look at my php.ini please and tell me what you think may be the problem. I...
8
by: Glenn A. Harlan | last post by:
Why am I receiving the below error when calling - Path.GetTempFileName() The directory name is invalid. Description: An unhandled exception occurred during the execution of the current web...
6
by: Peter Frost | last post by:
Please help I don't know if this is possible but what I would really like to do is to use On Error Goto to capture the code that is being executed when an error occurs. Any help would be much...
6
by: mark | last post by:
I have an asp.net ecommerce web application on a remote web server. I'm using an Access database on the back end. I've notice a few strange things. When I mimic an multiple user environment by...
5
by: Patrick | last post by:
I understand it is built in behaviour that if an ASP.NET's web.config is set to: <customErrors mode="RemoteOnly" /> then I only get a detailed error message on screen when the ASP.NET...
2
by: Ken Powers | last post by:
Hello everyone, I'm getting a strange error when I try to bind a combo box to a Dataset. Here's my code! Private Sub Get_Data() Try Dim sqlcmd = New SqlCommand("Select * from Utility order...
0
by: Ken Powers | last post by:
Hello everyone, Sorry about the repost, my second VB.NET App is done with the exception of this error. I'm getting a strange error when I try to bind a combo box to a Dataset. Here's my code! ...
0
by: HKSHK | last post by:
This list compares the error codes used in VB.NET 2003 with those used in VB6. Error Codes: ============ 3: This Error number is obsolete and no longer used. (Formerly: Return without GoSub)...
3
by: NickP | last post by:
Hi there, Today I try to compile an application of mine and I am getting a whole list of bizaar errors.... ------------------------------------------------ Error 1 The...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.