commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Shifman <mark.shif...@yale.edu>
Subject [VFS] Problems resolving smb uri
Date Mon, 11 Jul 2005 18:34:26 GMT
Hi:
I just downloaded commons-vfs-1.0-RC2 today and was trying to get data 
from an smb share.

using:
FileSystemManager fsManager = VFS.getManager();
FileObject smbFile = fsManager.resolveFile( 
"smb://theUser:thePassword@theServer.yu.yale.edu:445/ms79" );
(names and password changed)
I get:
Exception in thread "main" org.apache.commons.vfs.FileSystemException: 
Port number is missing from URI 
"smb://theUser:thePassword@theServer.yu.yale.edu:445/ms79//".
    at 
org.apache.commons.vfs.provider.HostFileNameParser.extractPort(HostFileNameParser.java:232)
    at 
org.apache.commons.vfs.provider.HostFileNameParser.extractToPath(HostFileNameParser.java:137)
    at 
org.apache.commons.vfs.provider.smb.SmbFileNameParser.parseUri(SmbFileNameParser.java:47)
    at 
org.apache.commons.vfs.provider.AbstractFileProvider.parseUri(AbstractFileProvider.java:163)
    at 
org.apache.commons.vfs.impl.DefaultFileSystemManager.resolveName(DefaultFileSystemManager.java:604)
    at 
org.apache.commons.vfs.impl.DefaultFileSystemManager.resolveName(DefaultFileSystemManager.java:552)
    at 
org.apache.commons.vfs.provider.AbstractOriginatingFileProvider.findFile(AbstractOriginatingFileProvider.java:71)
    at 
org.apache.commons.vfs.provider.AbstractOriginatingFileProvider.findFile(AbstractOriginatingFileProvider.java:61)
    at 
org.apache.commons.vfs.impl.DefaultFileSystemManager.resolveFile(DefaultFileSystemManager.java:513)
    at 
org.apache.commons.vfs.impl.DefaultFileSystemManager.resolveFile(DefaultFileSystemManager.java:486)
    at 
org.apache.commons.vfs.impl.DefaultFileSystemManager.resolveFile(DefaultFileSystemManager.java:456)
    at smbtest.main(smbtest.java:42)

I tried it with a port number and without a port number. No dice.

The smb share works, I can mount it from my linux box.

What am I doing wrong?

mas


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message