From owner-freebsd-stable Fri Oct 13 10: 1:21 2000 Delivered-To: freebsd-stable@freebsd.org Received: from post.webmailer.de (natmail2.webmailer.de [192.67.198.65]) by hub.freebsd.org (Postfix) with ESMTP id 9305337B66D for ; Fri, 13 Oct 2000 10:01:14 -0700 (PDT) Received: from alvman.IbHaakh.de (p3EE03DCC.dip.t-dialin.net [62.224.61.204]) by post.webmailer.de (8.9.3/8.8.7) with ESMTP id TAA03508; Fri, 13 Oct 2000 19:01:11 +0200 (MET DST) Received: from wilma.IbHaakh.de (wilma.IbHaakh.de [192.168.63.21]) by alvman.IbHaakh.de (8.11.0/8.11.0) with SMTP id e9DH10L01582; Fri, 13 Oct 2000 19:01:02 +0200 (CEST) (envelope-from Andreas@Haakh.de) From: Andreas Haakh Date: Fri, 13 Oct 2000 19:03:25 GMT Message-ID: <20001013.19032590@wilma.IbHaakh.de> Subject: Re: rc.diskless2 tries to use filesystems not mounted yet To: anton@urc.ac.ru (Anton Voronin), freebsd-stable@freebsd.org In-Reply-To: References: X-Mailer: Mozilla/3.0 (compatible; StarOffice/5.1; OS/2) X-Priority: 3 (Normal) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------=_4D48012269D001A94CD0" Content-Transfer-Encoding: 7bit Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG --------------=_4D48012269D001A94CD0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi, i created this little patch to rc.diskless2. Right after mount_mfs ...=20= /var the directory /var/db is created (to pacify mount_nfs). It then=20= tries to mount_nfs the usr filesystem if there is an entry in=20 /etc/fstab and instead of creating the directory hierarchy in /var=20 =BBmanually=AB I use mtree to achieve this. The remainig nfs_mounts occur when required. Andreas >>>>>>>>>>>>>>>>>> Urspr=FCngliche Nachricht <<<<<<<<<<<<<<<<<< Am 09.10.00, 17.49.01, schrieb anton@urc.ac.ru (Anton Voronin) zum=20 Thema rc.diskless2 tries to use filesystems not mounted yet: > Hi all. > Yes, I know that rc.diskless2 may be redefined. But it seems not to=20= work > itself. It uses chown, find and cpio that are located in /usr. But in = the > diskless configuration /usr is usually an nfs partition, so it is=20 mounted > much later than ${mount_diskless} is called. So shouldn't this script= > mount all nfs filesystems itself? > Regards, > Anton Voronin > Ural Regional Center of FREEnet, > Southern Ural State University, > Chelyabinsk, Russia > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-stable" in the body of the message --------------=_4D48012269D001A94CD0 Content-Description: filename="xxyy" Content-Disposition: inline; filename="xxyy" Content-Type: text/plain; name ="xxyy" Content-Transfer-Encoding: quoted-printable --- /etc/rc.diskless2 Sat Oct 7 09:34:36 2000 +++ /nodi/etc/rc.diskless2 Fri Oct 13 18:37:01 2000 @@ -13,18 +13,15 @@ fi =20 mount_mfs -s ${varsize:=3D65536} -T qp120at dummy /var -var_dirs=3D"run dev db msgs tmp spool spool/mqueue spool/lpd spool/outp= ut \ - spool/output/lpd" -for i in ${var_dirs} -do - mkdir /var/${i} -done -chmod 755 /var/run -chmod 755 /var/db -chmod 755 /var/spool -chmod 1777 /var/tmp -chown -R root.daemon /var/spool/output -chgrp daemon /var/spool/lpd +mkdir -p /var/db +case "`mount -d /usr`" in + *mount_nfs*) + echo "Mounting NFS filesystem /usr." + mount /usr + ;; +esac +mtree -deU -f /etc/mtree/BSD.var.dist -p /var/ >/dev/null +echo "Created file hierarchy in /var." # # XXX make sure to create one dir for each printer as requested by lpd # --------------=_4D48012269D001A94CD0-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message