DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 2nd January 2009
zerhacke's Avatar
zerhacke zerhacke is offline
Real Name: Jason
Insane BSD Fanatic
 
Join Date: Jul 2008
Location: Cambridge, OH, USA
Posts: 3
Thanked 0 Times in 0 Posts
Default smb mounting question

I am really happy that FreeBSD has had SMBFS in userland for several years now. I just have one question with SMB mounts...

The SMB server is a Vista machine that requires username and password for connecting to shares. On Linux you simply add username=foo,password=bar to fstab and it works. FreeBSD complains that the username and password options in fstab are not supported.

How do I login to the SMB server with username and password parameters? I am comfortable with doing it by the CLI if need be but what I would really like is to do it all by fstab.

Thanks in advance.
__________________
How many times have you heard a new BSD user say, "What, no runlevels?"
Reply With Quote
  #2   (View Single Post)  
Old 2nd January 2009
arch arch is offline
Port Guard
 
Join Date: Jun 2008
Posts: 38
Thanked 2 Times in 2 Posts
Default

check /etc/nsmb.conf
__________________
Verbose mode can also be turned on for SSH2 with the (surprise!) VerboseMode keyword.
Reply With Quote
  #3   (View Single Post)  
Old 2nd January 2009
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Thanked 112 Times in 104 Posts
Default

Assuming you are using mount_smbfs, judging by the manual page, I would be taking a wild guess that: 0/ you can not use the user/password params because mount_smbfs apparently does not support -o username=foo, etc. 1/ It would seem, you need to specify the user in the fstab entry:

Code:
//guest@samba/public    /smb/public	   smbfs  rw,noauto 0	0
and 2/ for a required password, setup a nsmbrc for it to use during boot, and hope it will skip interactive prompting when pw is found there, without having to specify -N.
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote
  #4   (View Single Post)  
Old 2nd January 2009
zerhacke's Avatar
zerhacke zerhacke is offline
Real Name: Jason
Insane BSD Fanatic
 
Join Date: Jul 2008
Location: Cambridge, OH, USA
Posts: 3
Thanked 0 Times in 0 Posts
Default

Brilliant the both of you! I have done some googleing on the location of .nsmbrc and am led to believe that it is in ~, correct?
__________________
How many times have you heard a new BSD user say, "What, no runlevels?"
Reply With Quote
  #5   (View Single Post)  
Old 2nd January 2009
arch arch is offline
Port Guard
 
Join Date: Jun 2008
Posts: 38
Thanked 2 Times in 2 Posts
Default

it's been some time last i did such thing.
now i tried again.
here it goes
/etc/nsmb.conf
Code:
# The 'FSERVER' is an NT server.
[IP_OF_SHARE_SRV]
#charsets=koi8-r:cp866
addr=IP_OF_SHARE_SRV

[IP_OF_SHARE_SRV:guest]
# use persistent password cache for user 'joe'
password=aqddsfd
now the password is plain text (see man nsmb.conf) in my case there is no need of password so i put that thing.
for fstab entry as TerryP suggest - it work but if you dont want to see at boot time password prompt i suggest to put -N option i Options colon in fstab. so pretty much that's it
__________________
Verbose mode can also be turned on for SSH2 with the (surprise!) VerboseMode keyword.
Reply With Quote
  #6   (View Single Post)  
Old 3rd January 2009
TerryP's Avatar
TerryP TerryP is offline
Arp Constable
 
Join Date: May 2008
Location: USofA
Posts: 1,547
Thanked 112 Times in 104 Posts
Default

Was just going by what passes as it's manual page ;-)
__________________
My Journal

Thou shalt check the array bounds of all strings (indeed, all arrays), for surely where thou typest ``foo'' someone someday shall type ``supercalifragilisticexpialidocious''.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
mounting external XFS HDD rativid OpenBSD General 5 3rd September 2010 02:31 PM
external drive partition question + fdisk question gosha OpenBSD General 15 15th June 2009 02:00 PM
mounting issues??? mt85m FreeBSD General 19 17th July 2008 07:58 PM
Mounting sniper007 FreeBSD General 7 2nd July 2008 06:50 AM
mounting UFS hirohitosan Other BSD and UNIX/UNIX-like 2 27th June 2008 02:40 PM


All times are GMT. The time now is 08:14 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick