Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Dec 2003 22:07:09 +0200
From:      "Marian" <mari@onix.ro>
To:        "Joachim Dagerot" <freebsd@dagerot.nu>, "paul beard" <paulbeard@mac.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: How can I automatically mount a windows-xp share from a freeBSDbox using windows usernameandpassword?
Message-ID:  <009c01c3ce47$57318990$26836050@onix.ro>
References:  <200312291931.hBTJV7402283@thunder.trej.net>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
Hi,

On my 5.1 system the example file its in
/usr/share/examples/smbfs/dot.nsmbrc
You need to create your own /root/.snmbrc and add the authentication details
there.
My .nsmbrc file looks like this and it works without asking for password:

[NTSERVER:ADMINISTRATOR]
# use persistent password cache for user 'administrator'
password=myplaintextpassword

And then when I issue the following command as root it doesnt ask for a
password
mount_smbfs -I 192.168.1.2 //administrator@ntserver/docs /mnt


Good luck,

Marian

----- Original Message ----- 
From: "Joachim Dagerot" <freebsd@dagerot.nu>
To: "paul beard" <paulbeard@mac.com>
Cc: <freebsd-questions@freebsd.org>
Sent: Monday, December 29, 2003 9:31 PM
Subject: Re: How can I automatically mount a windows-xp share from a
freeBSDbox using windows usernameandpassword?


> -------------------
>  |
>  | On Dec 29, 2003, at 10:58 AM, Joachim Dagerot wrote:
>  |
>  | > I know this question has been touched earlier this year, but no
> answer
>  | > came up at that point. So basically, has anyone been able to
> mount a
>  | > windows share from a script in freeBSD? If yes, how did you do?
>  | >
>  |
>  | I have done it in Mac OS X so the procedure should be similar: you
> need
>  | to use .nmbrc to store your authentication details, but it should
> "just
>  | work."
>  |
>  | man nsmbrc for more specifics.
>
>
> My system keeps telling me that theres no such entry. However I found
> an example under /usr/share/examples/smbfs nad copied/renamed it to
> /root/
>
> I edited the file and changed all values to reflect my system. Then I
> tried
> mount_smbfs //username@servername/sharename /mountpoint
>
> and still it asks for a password.
>
> Any advice is welcome.
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"freebsd-questions-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?009c01c3ce47$57318990$26836050>