How can I specify the ipaddress in smbfs entry in fstab?

Micheal Patterson micheal at tsgincorporated.com
Wed Nov 3 18:28:34 PST 2004




----- Original Message ----- 
From: "Mark Jayson Alvarez" <jay2xra at yahoo.com>
To: "albi" <albi at scii.nl>
Cc: <freebsd-questions at freebsd.org>
Sent: Wednesday, November 03, 2004 7:46 PM
Subject: Re: How can I specify the ipaddress in smbfs entry in fstab?


>
> --- albi <albi at scii.nl> wrote:
>
>> hi,
>>
>> >                          mountpt
>> > //guest at samba/mp3s       /mp3
>>
>> you can probably use e.g.
>>
>> //guest at 10.1.1.1/mp3s      /mp3
>
> It still doesn't work.
> I remember mounting it manually using the command
>
> mount_smbfs -I ipaddress  //guest at samba/mp3s /mtpoint
>
> I don't think substituting ipaddress(eg, 10.1.1.1) for
> "samba" in guest at samba will make any sense because I
> still have to specify its IP address using the "-I"
> option whenever I mount it manually.
>
>
>> in your /etc/fstab, but of course you can also add
>> your samba-server
>> in /etc/hosts
>
> tried it also, but didn't work.
>
> Anymore idea? thanks.
>


If you trust those with root access on your system, you can use the 
/etc/nsmb.conf file and configure that with the proper info for the 
remote server:

[HOST:USER:SHARE_NAME]
addr=HOST_IP
password=USER_password_on_remote_system
workgroup=domain/workgroup

... then edit your fstab to something like:

//USER at HOST/SHARE       /mountpoint        smbfs   rw,-N,-I=remote 
system ip   0  0

USER, HOST, SHARE are the same as in the nsmb.conf file, and I've found 
that these are often case sensitive. If the password is listed in 
nsmb.conf, then the -N in the fstab entry will use that password and not 
require you to enter it. Once done, a simple mount /mountpoint should 
get you on your way.

Hope it helps.

--

Micheal Patterson
TSG Network Administration
405-917-0600

Confidentiality Notice:  This e-mail message, including any attachments,
is for the sole use of the intended recipient(s) and may contain
confidential and privileged information. Any unauthorized review, use,
disclosure or distribution is prohibited. If you are not the intended
recipient, please contact the sender by reply e-mail and destroy all
copies of the original message. 



More information about the freebsd-questions mailing list