LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (http://www.linuxquestions.org/questions/linux-networking-3/)
-   -   CIFS share on old WinNT host - smbclient works, mount -t cifs doesn't (http://www.linuxquestions.org/questions/linux-networking-3/cifs-share-on-old-winnt-host-smbclient-works-mount-t-cifs-doesnt-940480/)

Electrode 04-18-2012 12:28 PM

CIFS share on old WinNT host - smbclient works, mount -t cifs doesn't
 
I'm trying to access a network share on a Windows NT 3.51 host from a Linux client (Gentoo x86, kernel 3.2.1).

smbclient works:
Code:

electrode@linux:~$ smbclient -N //winnt/share
Domain=[SMS] OS=[Windows NT 3.51] Server=[NT LAN Manager 3.51]
smb: \> ls
(file listing)
smb: \> quit

mount does not:
Code:

electrode@linux:~$ sudo mount -t cifs -o guest,ro //winnt/share /mnt/net
mount error(112): Host is down
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

So, where to begin debugging this?

Edit: smbnetfs works!

wpeckham 04-18-2012 01:32 PM

Naturally
 
You should look up when CIFS (as such) was introduced. It is not the original SMB standard and has gone through several modifications since OS/2 was new. The latest versions were not available for WinNT. IN fact the latest standard was released with VISTA, and WIN8 has an even newer update! (Just because MS likes to improve things, or just because they like to mess with us, take your pick: same outcome.)

The break that make CIFS drivers preferable over older SMB names came in 2007. Since WinNT was ANCIENT by then it did not get the memo (or any updates)!

The older standard is just fine, a little network chatty but solid, still available for *nix, still used by many *smb* tools, and I recommend it for connection to a server that dated.

I will not even ask WHY you are using an OS that old. I myself have NT4 in the back in an original box - just in case I ever need it, because a new license for MS Server 2008 is priced beyond my comfort level. (OS/2 Warp 3.2 and 4 also, though I cannot imagine what I would ever do with them.)

Electrode 04-18-2012 03:23 PM

Quote:

Originally Posted by wpeckham (Post 4656353)
The older standard is just fine, a little network chatty but solid, still available for *nix, still used by many *smb* tools, and I recommend it for connection to a server that dated.

So, how do I go about mounting using the old standard? The "smbfs" stuff doesn't appear to be in the kernel anymore...

wpeckham 04-19-2012 07:55 AM

mount old stuff
 
I should have addresses that question in my earlier post. Did not think it far enough out. Here we go....

1. verify that the mount is really shared out and that you can mount it over the network (even if only from the same old WinNT box). If this is not working, nothing else will.

2. you did not say what kernel version you are on, but in some versions the smbfs was retained even after the cifs was added. There was a warning that its use was depreciated, but the links still worked. You can try.

3. Make sure that the FQDN and hostname (as alias) resolve to its correct IP address in your hosts file or DNS server (preferabley both). Name resolution is a bit different and critical for communications between WinNT and any standard TCPIP nodes. (They do this netbios based thing from the dark ages. Must be something in the Microsoft religion.)

The mount command for smbfs looks like
# mount -t smbfs -o username=guestname,password=ABCD1234 //ntservername/share /mnt/ntserver
where you replace my generic stuff with the real suspects:
guestname with your account name for the share, ABCD1234 with that accounts real password,
ntservername with the hostname if the winNT machine, share with the shared folder name,
/mnt/ntserver with the name of the real folder to mount over.

Actually, the cifs driver should be able to fall back to the older behavior. That mount command you know, but for the record it looks like
# mount -t cifs //ntservername/share -o username=guestname,password=ABCD1234 /mnt/ntserver

If you can mount it manually, then you can update fstab to mount it on boot.
If the share is not taking, or it is but you still cannot do a manual mount, DO NOT mess with fstab!!
We need to get it working for the manual mount before it can be automated.

Electrode 04-19-2012 10:11 AM

Quote:

Originally Posted by wpeckham (Post 4657247)
1. verify that the mount is really shared out and that you can mount it over the network (even if only from the same old WinNT box). If this is not working, nothing else will.

In the OP, I said I was able to access the share using smbclient. It is also successfully mounted on a few Win2K and WinXP boxes.

Quote:

2. you did not say what kernel version you are on, but in some versions the smbfs was retained even after the cifs was added. There was a warning that its use was depreciated, but the links still worked. You can try.
Again, in the OP I specified I was using kernel 3.2.1. smbfs does not appear to be present in this kernel.

Quote:

3. Make sure that the FQDN and hostname (as alias) resolve to its correct IP address in your hosts file or DNS server (preferabley both). Name resolution is a bit different and critical for communications between WinNT and any standard TCPIP nodes. (They do this netbios based thing from the dark ages. Must be something in the Microsoft religion.)
Confirmed.

Quote:

Actually, the cifs driver should be able to fall back to the older behavior. That mount command you know, but for the record it looks like
# mount -t cifs //ntservername/share -o username=guestname,password=ABCD1234 /mnt/ntserver
As I mentioned in the OP, this doesn't work.

Edit: I've come across a FUSE-based thing called smbnetfs, which seems to work by hooking onto Samba's smb* tools. Might do the trick, will report back once I've tried it.


All times are GMT -5. The time now is 05:31 AM.