From owner-freebsd-questions@FreeBSD.ORG Tue Jun 10 14:55:29 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F03921065676 for ; Tue, 10 Jun 2008 14:55:29 +0000 (UTC) (envelope-from sonicy@otenet.gr) Received: from aiolos.otenet.gr (aiolos.otenet.gr [195.170.0.93]) by mx1.freebsd.org (Postfix) with ESMTP id 7660B8FC0C for ; Tue, 10 Jun 2008 14:55:29 +0000 (UTC) (envelope-from sonicy@otenet.gr) Received: from atlantis.dyndns.org (athedsl-4367213.home.otenet.gr [79.130.19.93]) by aiolos.otenet.gr (8.13.8/8.13.8/Debian-3) with ESMTP id m5AEtRUT021044; Tue, 10 Jun 2008 17:55:27 +0300 Message-ID: <484E95DF.9040208@otenet.gr> Date: Tue, 10 Jun 2008 17:55:27 +0300 From: Manolis Kiagias User-Agent: Thunderbird 2.0.0.14 (X11/20080607) MIME-Version: 1.0 To: dhaneshk k References: <20080609205426.N23640@awww.jeah.net> <9145C6E6-4C2F-4DA3-B953-4A91DC4C476B@goldmark.org> <484E32C9.5060709@otenet.gr> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: "freebsd-questions@freebsd.org" Subject: Re: Adding a second disk to increase the space for /var on first dislk : but umount /var failed X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Jun 2008 14:55:30 -0000 dhaneshk k wrote: > > I followed as per the directions up to this > > >> Now, unmount /var and /mnt and mount your new var: >> >> umount /var /mnt >> mount -o rw /dev/da1s1e /var >> >> Edit /etc/fstab and update it for the new disk: >> >> /dev/da1s1e /var ufs rw 2 2 >> > > > I am able to umount /mnt but not /var > > > > [root@storm ~]# umount /var/ > umount: unmount of /var failed: Device busy > [root@storm ~]# umount /mnt/ > [root@storm ~]# umount /var/ > umount: unmount of /var failed: Device busy > [root@storm ~]# df -h > Filesystem Size Used Avail Capacity Mounted on > /dev/ad7s1a 496M 329M 127M 72% / > devfs 1.0K 1.0K 0B 100% /dev > /dev/ad7s1e 496M 5.4M 451M 1% /tmp > /dev/ad7s1f 44G 38G 2.9G 93% /usr > /dev/ad7s1d 1.4G 221M 1.1G 16% /var > devfs 1.0K 1.0K 0B 100% /var/named/dev > [root@storm ~]# umount /dev/ad7s1 > ad7s1 ad7s1a ad7s1b ad7s1c ad7s1d ad7s1e ad7s1f > [root@storm ~]# umount /dev/ad7s1d > umount: unmount of /var failed: Device busy > [root@storm ~]# umouny /var/ > bash: umouny: command not found > [root@storm ~]# umouny /var > bash: umouny: command not found > [root@storm ~]# umount /var > umount: unmount of /var failed: Device busy > [root@storm ~]# pwd > /root > [root@storm ~]# umount /var > umount: unmount of /var failed: Device busy > [root@storm ~]# > > > > getting an error Error org.freedesktop.Hal.Device.PermissionDeniedByPolicy. > > Details hal-storage-fixed -mount refused uid 0 How to fix this and umount /var > > > > > Notice I have asked you to switch to single user mode before copying or unmounting var. But from your prompt, I understand you are still running full multiuser, and of course, /var will not unmount then. Remount /usr and issue the command: shutdown now to switch to single user mode. You need console access for this, do not attempt it remotely (unless you have a serial console) ! Then continue from the point you copy the data using the tar command. If you have already copied data from /var to the new partition, this may well be stale since /var was in use. You may wish to newfs the new partition again in this case.