Re: Adding a second disk to increase the space for /var on first dislk : but umount /var failed

2008-06-10 Thread Manolis Kiagias

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 22




I am able to   umount  /mnt   but not   /var 




[EMAIL PROTECTED] ~]# umount /var/
umount: unmount of /var failed: Device busy
[EMAIL PROTECTED] ~]# umount /mnt/
[EMAIL PROTECTED] ~]# umount /var/
umount: unmount of /var failed: Device busy
[EMAIL PROTECTED] ~]# df -h
Filesystem SizeUsed   Avail Capacity  Mounted on
/dev/ad7s1a496M329M127M72%/
devfs  1.0K1.0K  0B   100%/dev
/dev/ad7s1e496M5.4M451M 1%/tmp
/dev/ad7s1f 44G 38G2.9G93%/usr
/dev/ad7s1d1.4G221M1.1G16%/var
devfs  1.0K1.0K  0B   100%/var/named/dev
[EMAIL PROTECTED] ~]# umount /dev/ad7s1
ad7s1   ad7s1a  ad7s1b  ad7s1c  ad7s1d  ad7s1e  ad7s1f  
[EMAIL PROTECTED] ~]# umount /dev/ad7s1d 
umount: unmount of /var failed: Device busy
[EMAIL PROTECTED] ~]# umouny /var/ 
bash: umouny: command not found
[EMAIL PROTECTED] ~]# umouny /var 
bash: umouny: command not found

[EMAIL PROTECTED] ~]# umount /var
umount: unmount of /var failed: Device busy
[EMAIL PROTECTED] ~]# pwd
/root
[EMAIL PROTECTED] ~]# umount /var
umount: unmount of /var failed: Device busy
[EMAIL PROTECTED] ~]# 




getting an error   Error org.freedesktop.Hal.Device.PermissionDeniedByPolicy.

Details  hal-storage-fixed -mountrefused 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.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


RE: Adding a second disk to increase the space for /var on first dislk : but umount /var failed

2008-06-10 Thread Tobias Hoellrich
 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf Of dhaneshk k
 Sent: Tuesday, June 10, 2008 7:15 AM
 To: [EMAIL PROTECTED]
 Cc: Manolis Kiagias
 Subject: Adding a second disk to increase the space for /var 
 on first dislk : but umount /var failed
 
 I am able to   umount  /mnt   but not   /var 
 
 [EMAIL PROTECTED] ~]# umount /var/
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# umount /mnt/
 [EMAIL PROTECTED] ~]# umount /var/
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# df -h
 Filesystem SizeUsed   Avail Capacity  Mounted on
 /dev/ad7s1a496M329M127M72%/
 devfs  1.0K1.0K  0B   100%/dev
 /dev/ad7s1e496M5.4M451M 1%/tmp
 /dev/ad7s1f 44G 38G2.9G93%/usr
 /dev/ad7s1d1.4G221M1.1G16%/var
 devfs  1.0K1.0K  0B   100%/var/named/dev
 [EMAIL PROTECTED] ~]# umount /dev/ad7s1
 ad7s1   ad7s1a  ad7s1b  ad7s1c  ad7s1d  ad7s1e  ad7s1f  
 [EMAIL PROTECTED] ~]# umount /dev/ad7s1d 
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# umouny /var/ 
 bash: umouny: command not found
 [EMAIL PROTECTED] ~]# umouny /var 
 bash: umouny: command not found
 [EMAIL PROTECTED] ~]# umount /var
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# pwd
 /root
 [EMAIL PROTECTED] ~]# umount /var
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# 
 
 
 
 getting an error   Error 
 org.freedesktop.Hal.Device.PermissionDeniedByPolicy.
 
 Details  hal-storage-fixed -mountrefused uid 0   How 
 to fix this and umount /var
  
 
 Any hints most welcome : 


Did you switch to single user-mode (shutdown now) before trying to
umount /var? If you did, there may be some other process still using
files/dirs in /var. If you have lsof installed
(/usr/ports/sysutils/lsof), you can identify (as root) which process
still using stuff in /var:

santafe# lsof +D /var/
COMMANDPID  USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
dhclient   321 _dhcp  cwd   VDIR  0,100  512 14578696 /var/empty
dhclient   321 _dhcp  rtd   VDIR  0,100  512 14578696 /var/empty
dhclient   321 _dhcp  jld   VDIR  0,100  512 14578696 /var/empty
dhclient   321 _dhcp6w  VREG  0,100 1007 14582324
/var/db/dhclient.leases.msk0
devd   537  root4u  unix 0xc6a78188  0t0
/var/run/devd.pipe
devd   537  root5w  VREG  0,1003 14580313
/var/run/devd.pid
syslogd603  root3w  VREG  0,1003 14580315
/var/run/syslog.pid
syslogd603  root4u  unix 0xc6a84310  0t0
/var/run/log
syslogd603  root5u  unix 0xc6a84188  0t0
/var/run/logpriv
...

Stop the processes (dhclient, devd, syslogd, etc.) that still use /var
and then try to umount it again.

Hope this helps - Tobias
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


RE: Adding a second disk to increase the space for /var on first dislk : but umount /var failed

2008-06-10 Thread Tobias Hoellrich
 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf Of dhaneshk k
 Sent: Tuesday, June 10, 2008 7:15 AM
 To: [EMAIL PROTECTED]
 Cc: Manolis Kiagias
 Subject: Adding a second disk to increase the space for /var 
 on first dislk : but umount /var failed
 
 I am able to   umount  /mnt   but not   /var 
 
 [EMAIL PROTECTED] ~]# umount /var/
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# umount /mnt/
 [EMAIL PROTECTED] ~]# umount /var/
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# df -h
 Filesystem SizeUsed   Avail Capacity  Mounted on
 /dev/ad7s1a496M329M127M72%/
 devfs  1.0K1.0K  0B   100%/dev
 /dev/ad7s1e496M5.4M451M 1%/tmp
 /dev/ad7s1f 44G 38G2.9G93%/usr
 /dev/ad7s1d1.4G221M1.1G16%/var
 devfs  1.0K1.0K  0B   100%/var/named/dev
 [EMAIL PROTECTED] ~]# umount /dev/ad7s1
 ad7s1   ad7s1a  ad7s1b  ad7s1c  ad7s1d  ad7s1e  ad7s1f  
 [EMAIL PROTECTED] ~]# umount /dev/ad7s1d 
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# umouny /var/ 
 bash: umouny: command not found
 [EMAIL PROTECTED] ~]# umouny /var 
 bash: umouny: command not found
 [EMAIL PROTECTED] ~]# umount /var
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# pwd
 /root
 [EMAIL PROTECTED] ~]# umount /var
 umount: unmount of /var failed: Device busy
 [EMAIL PROTECTED] ~]# 
 
 
 
 getting an error   Error 
 org.freedesktop.Hal.Device.PermissionDeniedByPolicy.
 
 Details  hal-storage-fixed -mountrefused uid 0   How 
 to fix this and umount /var
  
 
 Any hints most welcome : 


Did you switch to single user-mode (shutdown now) before trying to
umount /var? If you did, there may be some other process still using
files/dirs in /var. If you have lsof installed
(/usr/ports/sysutils/lsof), you can identify (as root) which process
still using stuff in /var:

santafe# lsof +D /var/
COMMANDPID  USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
dhclient   321 _dhcp  cwd   VDIR  0,100  512 14578696 /var/empty
dhclient   321 _dhcp  rtd   VDIR  0,100  512 14578696 /var/empty
dhclient   321 _dhcp  jld   VDIR  0,100  512 14578696 /var/empty
dhclient   321 _dhcp6w  VREG  0,100 1007 14582324
/var/db/dhclient.leases.msk0
devd   537  root4u  unix 0xc6a78188  0t0
/var/run/devd.pipe
devd   537  root5w  VREG  0,1003 14580313
/var/run/devd.pid
syslogd603  root3w  VREG  0,1003 14580315
/var/run/syslog.pid
syslogd603  root4u  unix 0xc6a84310  0t0
/var/run/log
syslogd603  root5u  unix 0xc6a84188  0t0
/var/run/logpriv
...

Stop the processes (dhclient, devd, syslogd, etc.) that still use /var
and then try to umount it again.

Hope this helps - Tobias
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]