[jcifs] smb://hostname/ works, but not smb://myworkgroup/ or smb:// - why?

Allen, Michael B (RSCH) Michael_B_Allen at ml.com
Wed Feb 26 15:38:08 EST 2003



> -----Original Message-----
> From:	Dani Ludin [SMTP:dani.ludin at unic.ch]
> Sent:	Tuesday, February 25, 2003 3:34 PM
> To:	jcifs at lists.samba.org
> Subject:	[jcifs] smb://hostname/ works, but not smb://myworkgroup/ or smb:// - why?
> 
> Hello,
> 
> the network I work with looks like this:
> 
> mycomputer     192.168.0.223       in WORKGROUP
> remotecomputer 192.168.0.1         in WORKGROUP
> 
> - both run windows2000pro and jdk 1.4.1 and the latest jcifs package
> - pinging both names returns correctly their corresponding IP.
> - both computers (and their shares) are accessible in the "My Network
> Neighbourhood"
> 
> I have this problem:
> --------------------
> Working on mycomputer, I can create a SmbFile with this URL:
> smb://remotecomputer/ and I get a list of shares and drives on it, like it
> should.
> 
> But I can't get a list of domains/workgroups or a list of computers
> in a specified workgroup - I always receive a SmbException: unknown host.
> 
	There's not much room for me to help you here Dani. We're pretty confident
	that jCIFS actually works at this point :~). I think you need to look closer at
	the diagnostics suggested in the FAQ to better understand your network.
	The smb://workgroup/ URL will provoke the client to do a NetServerEnum
	operation on the local master browser. Is it possible that for whatever reason
	the machines have not established a local master browser? Are you on a
	home LAN or running a laptop? Sometime that sort of functionality is turned
	off. Again go through all of the diagnostics outlined in the FAQ particularly
	the part about the nbtstat command. Otherwise we will require a packet
	capture or at the very least a -Dlog=ALL dump.

> The API says that
> smb:// 	          represents a list of domains and
> smb://myworkgroup/    represents a list of computers in a domain
> 
> When I can access the remote computer with smb://remotecomputer/
> doesn't that mean, that my jcifs-properties should be correct?
> 
> I have played with the settings of jcifs.netbios.wins, first with
> the IP of mycomputer, then remotecomputer - didn't help.
> 
	WINS is a special server. If you were running a WINS server you would
	know it. It's like DNS.

> I also tried to make reasonable settings in jcifs.netbios.baddr, though
> I think that this not the problem anyway, because both computers a in the
> same subnet.
> 
	Setting the baddr property does not have anything to do with cross subnet
	access.

> Also, all the hints from the FAQ didn't help.
> 
	Well then your in trouble because the second question is probably dead on.

	Mike






More information about the jcifs mailing list