[jcifs] jcifs.smb.SmbException: Incorrect function

Michael B Allen ioplex at gmail.com
Thu Jul 10 20:02:22 GMT 2008

So maybe the path in the SMB_COM_TREE_CONNECT_ANDX needs to match what
NetApp was configured for. Or perhaps it's a DNS issue. I used an FQDN
ok but I didn't try the NetBIOS name (not running WINS here). Another
thing to try is the IP.

I know the NetApp Filers are fast but I think they're based on NT 3.x
code which makes them a bit fickle. We'll just have to learn how to
dodge the quirks.


On 7/10/08, tinius_paul at emc.com <tinius_paul at emc.com> wrote:
> We've found that if you use the FQDN the NetApp filer you will receive
>  the "incorrect function". Removing the FQDN seems to clear up the issue.
>  -----Original Message-----
>  From: jcifs-bounces+tinius_paul=emc.com at lists.samba.org
>  [mailto:jcifs-bounces+tinius_paul=emc.com at lists.samba.org] On Behalf Of
> Michael B Allen
>  Sent: Thursday, July 10, 2008 12:52 PM
>  To: harald.preczek at bundesbank.de
>  Cc: jcifs at lists.samba.org
>  Subject: Re: Re: Re: [jcifs] jcifs.smb.SmbException: Incorrect function
>  On 7/10/08, harald.preczek at bundesbank.de <harald.preczek at bundesbank.de>
>  wrote:
>  >
>  >  Mike,
>  >
>  >  we've done a little debugging using Jcifs 1.2.21/1.2.22 and here is
>  what we
>  >  found.
>  >
>  >  when we try to set up a connection with the NetApp-filer we receive
>  an
>  >  error c0000002. according to the defined constants this means "not
>  >  implemented". the exception is thrown by the jcifs-method
>  checkStatus.
>  >
>  >  It don't know wether this means the filer returns a status jcifs
>  can't
>  >  handle or jcifs tried to use a function that's not implemented on the
>  >  filer.
>  Hi Harald,
>  The 0xc0000002 "Incorrect function" error means the NetApp basically
>  does not like the specific operation you are trying to perform. It
>  could be some flags or something that it doesn't like.
>  Please provide a minimal test program that fails with NetApp. Provided
>  I can reproduce the issue with the simulator here at my end I will fix
>  it asap.
>  Otherwise, as I said before, all of the examples run fine against the
>  simulator here so I need to know exactly what is failing.
>  >  we checked this with our own programs as well as with the geturl.java
>  >  example shipped with jcifs. the results ar always the same.
>  The GetURL.java example works fine against the simulator here:
>  $ java -Djcifs.properties=../user2.prp GetURL
>  smb://na2.w.net/tmp/test/file.txt
>  $ cat ../user2.php
>  jcifs.smb.client.username=user2
>  jcifs.smb.client.password=pAsswOrd
>  jcifs.smb.client.domain=w.net
>  jcifs.resolveOrder=DNS,BCAST
>  Perhaps you should get a packet capture instead. If you're not sure
>  how to do that, let me know and I'll walk you through it.
>  I assume the NetApp server is a member of a Windows domain?
>  Mike
>  --
>  Michael B Allen
>  PHP Active Directory SPNEGO SSO
>  http://www.ioplex.com/

Michael B Allen
PHP Active Directory SPNEGO SSO

More information about the jcifs mailing list