Date: Tue, 11 Dec 2012 14:08:38 -0800 (PST) From: Bill Tillman <btillman99@yahoo.com> To: "freebsd-questions@freebsd.org" <freebsd-questions@freebsd.org> Subject: Re: Mounting a samba share on boot? Message-ID: <1355263718.29274.YahooMailNeo@web165003.mail.bf1.yahoo.com> In-Reply-To: <20121211175759.310ec79f.freebsd@edvax.de> References: <CAON8%2BsbL_1AOF7vaqDg1AeX0Gi2ZL9fCT80Zf1Rxrv8ieDDM=Q@mail.gmail.com> <20121211175759.310ec79f.freebsd@edvax.de>
next in thread | previous in thread | raw e-mail | index | archive | help
=0A=0A=0A=0A________________________________=0AFrom: Polytropon <freebsd@ed= vax.de>=0ATo: Hanafi Syahroini <hanafi@zigma-jp.com> =0ACc: freebsd-questio= ns@freebsd.org =0ASent: Tuesday, December 11, 2012 11:57 AM=0ASubject: Re: = Mounting a samba share on boot?=0A=0AOn Tue, 11 Dec 2012 23:25:56 +0700, Ha= nafi Syahroini wrote:=0A> [nothing]=0A=0AFirst of all, it's not uncommon to= place the question into=0Athe message body (which you did not), and using = a descriptive=0Asubject (which you did). :-)=0A=0ASo I assume your question= is _how_ to mount a SMB share at=0Aboot.=0A=0AThis can be easily done by a= dding the required line to the=0A/etc/fstab file. Because network connectio= n is required to=0Aperform the mount, you could use the "late" option in=0A= addition to other options you might need. See "man mount"=0Afor detais, as = well as /etc/rc.d/mountlate.=0A=0AThe line would be like this:=0A=0A=A0=A0= =A0 //USERNAME@SERVERNAME/share=A0 /smb/share=A0 smbfs=A0 rw,late=A0 0=A0 0= =0A=0AIn this example, SERVERNAME is the server to access, and "share"=0Ath= e name of the share; /smb/share will be the directory it will=0Abe mounted = at.=0A=0AAccess to multiple "drive letters" would look like this:=0A=0A=A0= =A0=A0 //Administrator@WINPC/a$=A0 /smb/a=A0 smbfs=A0 rw,late=A0 0=A0 0=0A= =A0=A0=A0 //Administrator@WINPC/c$=A0 /smb/c=A0 smbfs=A0 rw,late=A0 0=A0 0= =0A=A0=A0=A0 //Administrator@WINPC/d$=A0 /smb/d=A0 smbfs=A0 rw,late=A0 0=A0= 0=0A=A0=A0=A0 //Administrator@WINPC/e$=A0 /smb/e=A0 smbfs=A0 rw,late=A0 0= =A0 0=0A=A0=A0=A0 //Administrator@WINPC/f$=A0 /smb/f=A0 smbfs=A0 rw,late=A0= 0=A0 0=0A=0AHere "WINPC" is the name of the server. Using "Administrator"= =0Ain this case is not safe, but no problem in settings where=0Apeople don'= t care for security anyway. :-)=0A=0AAlso see "man smbfs" and "man fstab" f= or details.=0A=0AIt might be required to put additional information in=0A/e= tc/nsmb.conf, for example:=0A=0A=A0=A0=A0 [default]=0A=A0=A0=A0 workgroup= =3DYOUR_WORKGROUP_NAME=0A=0A=A0=A0=A0 [SERVERNAME]=0A=A0=A0=A0 addr=3D192.1= 68.2.2=0A=0A=A0=A0=A0 [SERVERNAME:USERNAME]=0A=A0=A0=A0 password=3DTOPSECRE= T=0A=0ASubstitute SERVERNAME, USERNAME and TOPSECRET for the=0Aorganisation= al information and access credentials that apply.=0ASee "man nsmb.conf" for= details.=0A=0AFurther instructions can easily be found in the online docs:= =0A=0Ahttp://www.freebsd.org/doc/faq/book.html#mount-smb-share=0A=0Ahttp://= www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-samba.html=0A=0A= =0A=0ANote that if you still encounter network problems, it's better=0Ato w= rite a short rc.d style script that performs the mount_smb=0Acommands, and = use the proper keywords to have it run when the=0Anetwork connection is up = and running. See "man rc.d" for=0Adetails.=0A=0A=0A-- =0APolytropon=0AMagde= burg, Germany=0AHappy FreeBSD user since 4.0=0AAndra moi ennepe, Mousa, ...= =0A_______________________________________________=0Afreebsd-questions@free= bsd.org mailing list=0Ahttp://lists.freebsd.org/mailman/listinfo/freebsd-qu= estions=0ATo unsubscribe, send any mail to "freebsd-questions-unsubscribe@f= reebsd.org"=0A=0A=0AThat's a great answer but let me insert that most peopl= e, not all but most, do not use Samba to access a server from other FreeBSD= servers. So I feel the two replies thus far are overkill. Typically, Samba= is used so that Windows or other SMB type OS'es can access the server. Tha= t said, I would simplify all this with the way I have mine setup. You will = of course need the shares configured in your smb.conf, then simply put a co= mmand in your /etc/rc.local or /etc/rc.d/ to launch smdb and nmbd. I don't = rely on anything in /etc/fstab to use samba. It's all in my smb.conf file.= =0A=0AHowever, Polytropon has presented a great answer here. From owner-freebsd-questions@FreeBSD.ORG Tue Dec 11 22:13:27 2012 Return-Path: <owner-freebsd-questions@FreeBSD.ORG> Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5147245C; Tue, 11 Dec 2012 22:13:27 +0000 (UTC) (envelope-from vrwmiller@gmail.com) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 983E68FC16; Tue, 11 Dec 2012 22:13:26 +0000 (UTC) Received: by mail-la0-f54.google.com with SMTP id j13so4255865lah.13 for <multiple recipients>; Tue, 11 Dec 2012 14:13:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=jwoZtTsCwlw9bhanv8e2LmpmGRNTxSbnO4+QPd6sBZc=; b=YiH17uQPt06e1XPfHKwW0A7ll19/CAxNZHy/oikVRedUYuNEMWHzbX7WbdctAb6UnI lfoWEBQ+ZLCKmYoPhqELF0OBYIJd14g/p+DhDYHxM3/ynH5NaRzuv1sYUK70FwZTY4CP qIHSKCssW/UNQ0kTScYU9KgkmuXLOqV2kWm2XxuMlfULcgUby8tt5NgGUe7BsquPbk+A xlJW3axVZ5gVzFjAaMN9fbIU9U2+KgEtMUYe85mNqmzodaMRwoh1QP3K83Kzlxd/RjOn QUVwCdr9G827cU6ZS7TSQRBwFOB/eWG0KMi9hPWymOiom8kNz3ScjjdR03QuVl4nbQ93 9aVA== MIME-Version: 1.0 Received: by 10.112.44.225 with SMTP id h1mr8409032lbm.63.1355264004969; Tue, 11 Dec 2012 14:13:24 -0800 (PST) Sender: vrwmiller@gmail.com Received: by 10.112.3.68 with HTTP; Tue, 11 Dec 2012 14:13:24 -0800 (PST) In-Reply-To: <1531C946-2259-4295-B388-42DC94FBE7FB@fisglobal.com> References: <CAHzLAVHBfoodHoe72f9Ls_Wq1hnG8y-98DX7LkkZbs=79SjOdw@mail.gmail.com> <04ABE8E0-8D63-4C68-92C4-69B516818160@fisglobal.com> <CAHzLAVHVPpSA2azavb3wZ+AmN+YUPT22LAKMP6VF8envqRVVng@mail.gmail.com> <1531C946-2259-4295-B388-42DC94FBE7FB@fisglobal.com> Date: Tue, 11 Dec 2012 17:13:24 -0500 X-Google-Sender-Auth: FICsztrrQcux_uqqBkCzns0Q1aQ Message-ID: <CAHzLAVH582Fk+SgwBzkmm2n5_HUF8b5zW+_dchn+eS48XVDKZw@mail.gmail.com> Subject: Re: make release and mfsroot From: Rick Miller <vmiller@hostileadmin.com> To: Devin Teske <dteske@freebsd.org> Content-Type: text/plain; charset=ISO-8859-1 Cc: FreeBSD Questions <freebsd-questions@freebsd.org> X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions <freebsd-questions.freebsd.org> List-Unsubscribe: <http://lists.freebsd.org/mailman/options/freebsd-questions>, <mailto:freebsd-questions-request@freebsd.org?subject=unsubscribe> List-Archive: <http://lists.freebsd.org/pipermail/freebsd-questions> List-Post: <mailto:freebsd-questions@freebsd.org> List-Help: <mailto:freebsd-questions-request@freebsd.org?subject=help> List-Subscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-questions>, <mailto:freebsd-questions-request@freebsd.org?subject=subscribe> X-List-Received-Date: Tue, 11 Dec 2012 22:13:27 -0000 On Tue, Dec 11, 2012 at 5:05 PM, Devin Teske <devin.teske@fisglobal.com> wrote: > > Though, to resize the mfsroot, I still rely on release(7) and the above > patches. Here's another question, have you applied this approach to boot_crunch.conf? I simply replaced the default boot_crunch.conf with my own in the source tree. This is how I discovered MFSSIZE, because the resulting boot_crunch binary was larger than the available space. -- Take care Rick Miller
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1355263718.29274.YahooMailNeo>