[jcifs] "A duplicate name exists on network" when a host has multiple names

Praveen Tammana a10pkt8 at gmail.com
Mon Oct 17 18:23:24 GMT 2005


On 10/17/05, Michael B Allen <mba2000 at ioplex.com> wrote:
>
> On Mon, 17 Oct 2005 10:45:03 -0700
> Praveen Tammana <praveen.public at gmail.com> wrote:
>
> > On 10/17/05, Michael B Allen <mba2000 at ioplex.com> wrote:
> > >
> > > On Mon, 17 Oct 2005 01:32:08 -0700
> > > Praveen Tammana <praveen.public at gmail.com> wrote:
> > >
> > > > Hi,
> > > >
> > > > I am working with 1.2.1 and I am getting errors when working with a
> host
> > > > that has multiple names. (eg: deathstar = zpac23 =
> > > > 172.25.181.23 <http://172.25.181.23> <http://172.25.181.23><
> http://172.25.181.23>).
> > > > For example, when I run the ListFiles example:
> > > >
> > > > java ListFiles smb://deathstar/ ------- works
> > > > java ListFiles smb://zpac23/ ------- does not
> > > > java ListFiles smb://172.25.181.23/ ------- works
> > >
> > > Where exactly does it fail? What's the exception?
> >
> >
> > Forgot to add the stack trace, sorry 'bout that.
> >
> > Exception in thread "main" jcifs.smb.SmbException: A duplicate name
> exists
> > on the network.
> > at jcifs.smb.SmbTransport.checkStatus(SmbTransport.java:456)
> > at jcifs.smb.SmbTransport.send(SmbTransport.java:556)
> > at jcifs.smb.SmbSession.sessionSetup(SmbSession.java:263)
> > at jcifs.smb.SmbSession.send(SmbSession.java:220)
> > at jcifs.smb.SmbTree.treeConnect(SmbTree.java:137)
> > at jcifs.smb.SmbFile.connect(SmbFile.java:791)
> > at jcifs.smb.SmbFile.connect0(SmbFile.java:761)
> > at jcifs.smb.SmbFile.send(SmbFile.java:660)
> > at jcifs.smb.SmbFile.doNetEnum(SmbFile.java:1619)
> > at jcifs.smb.SmbFile.listFiles(SmbFile.java:1568)
> > at jcifs.smb.SmbFile.listFiles(SmbFile.java:1478)
> > at ListFiles.main(ListFiles.java:17)
>
> This is coming from the server. I don't think there's any way around
> this. I think other CIFS clients will give you the same error. If you try
> another client and it does not give you the error using the name zpac23
> then get a packet capture and we can see how it's avoiding the problem.


That sounds bad. I'll try some other clients and see if they work.

Thanks
-Praveen

Mike
>
-------------- next part --------------
HTML attachment scrubbed and removed


More information about the jcifs mailing list