RE: Moving /var - problem with /var/lock and /var/run?
On Fri, 2010-04-09 at 12:06 +1200, Bryce Stenberg wrote: > > > -Original Message- > > From: Steve Holdoway [mailto:st...@greengecko.co.nz] > > The last colum in fstab is marked pass. This defines in what order > > partitions are mounted. You must mount /var in the first pass, as > > software needs it there immediately. So change the root and /var pass > > values to 0 and all should be well. > > > > Thanks Steve, I set it to '1' to force it to be checked (as per Hadley's > comment) and it appears to have booted up fine without errors. > > Cheers everyone, > Bryce Stenberg. Well, that's not quite what Hads said. Filesystems are checked when marked as dirty, and every x mounts ( see tune2fs for for details on how to manipulate this and annoy sysadmins on ext2/3?4 file systems ). The fsck stuff is performed in passes so that ( for example ) dependencies like /var/www can be set up to be mounted after /var. As I suspected, this field also affects the order in which the file systems are mounted even if fsck is not required. By changing the / and /var pass values to be the same, you ensured there was no dependency between the two, and both were mounted at the same time, ensuring the availability of /var when necessary. Steve -- Steve Holdoway http://www.greengecko.co.nz MSN: st...@greengecko.co.nz GPG Fingerprint = B337 828D 03E1 4F11 CB90 853C C8AB AF04 EF68 52E0
RE: Moving /var - problem with /var/lock and /var/run?
> -Original Message- > From: Steve Holdoway [mailto:st...@greengecko.co.nz] > The last colum in fstab is marked pass. This defines in what order > partitions are mounted. You must mount /var in the first pass, as > software needs it there immediately. So change the root and /var pass > values to 0 and all should be well. > Thanks Steve, I set it to '1' to force it to be checked (as per Hadley's comment) and it appears to have booted up fine without errors. Cheers everyone, Bryce Stenberg. DISCLAIMER: If you have received this email in error, please notify us immediately by reply email, facsimile or collect telephone call to +64 3 9641200 and destroy the original. Please refer to full DISCLAIMER at http://www.hrnz.co.nz/eDisclaimer.htm
RE: Moving /var - problem with /var/lock and /var/run?
On Fri, 2010-04-09 at 11:10 +1200, Hadley Rich wrote: > On Fri, 2010-04-09 at 11:03 +1200, Steve Holdoway wrote: > > The last colum in fstab is marked pass. This defines in what order > > partitions are mounted. You must mount /var in the first pass, as > > software needs it there immediately. So change the root and /var pass > > values to 0 and all should be well. > > I don't know if it might be used to define what order they are mounted > in, but I believe the official use it what order to fsck partitions > in. / should be 1 and other partitions should be > 1 or 0 if you don't > want them checked. > > >From the man page; > > The sixth field, (fs_passno), is used by the fsck(8) program to > determine the order in which filesystem checks are done at reboot time. > The root filesystem should be specified with a fs_passno of 1, and other > filesystems should have a fs_passno of 2. Filesystems within a drive > will be checked sequentially, but filesystems on different drives > will be checked at the same time to utilize parallelism available in the > hardware. If the sixth field is not present or zero, a value of zero is > returned and fsck will assume that the filesystem does not need to be > checked. > > > hads > I thought it was both, but am happy to stand/sit corrected (: Cheers, Steve. -- Steve Holdoway http://www.greengecko.co.nz MSN: st...@greengecko.co.nz GPG Fingerprint = B337 828D 03E1 4F11 CB90 853C C8AB AF04 EF68 52E0
RE: Moving /var - problem with /var/lock and /var/run?
On Fri, 2010-04-09 at 11:03 +1200, Steve Holdoway wrote: > The last colum in fstab is marked pass. This defines in what order > partitions are mounted. You must mount /var in the first pass, as > software needs it there immediately. So change the root and /var pass > values to 0 and all should be well. I don't know if it might be used to define what order they are mounted in, but I believe the official use it what order to fsck partitions in. / should be 1 and other partitions should be > 1 or 0 if you don't want them checked. >From the man page; The sixth field, (fs_passno), is used by the fsck(8) program to determine the order in which filesystem checks are done at reboot time. The root filesystem should be specified with a fs_passno of 1, and other filesystems should have a fs_passno of 2. Filesystems within a drive will be checked sequentially, but filesystems on different drives will be checked at the same time to utilize parallelism available in the hardware. If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked. hads -- http://nicegear.co.nz New Zealand's Open Source Hardware Supplier
RE: Moving /var - problem with /var/lock and /var/run?
On Fri, 2010-04-09 at 10:57 +1200, Bryce Stenberg wrote: > > > -Original Message- > > From: Wayne Rooney [mailto:wroo...@ihug.co.nz] > > I don't think your /etc/fstab is quite right. Can you post the file > so we > > can > > see it. > > > > > Fstab: > > # /etc/fstab: static file system information. > # > # Use 'blkid -o value -s UUID' to print the universally unique > identifier > # for a device; this may be used with UUID= as a more robust way to name > # devices that works even if disks are added and removed. See fstab(5). > # > # > proc/proc procdefaults0 0 > /dev/mapper/grp--a-root / ext3errors=remount-ro 0 > 1 > > ## this is the row I added... > /dev/mapper/grp--b-third /var ext3defaults 0 > 2 > > LABEL=BootPart/boot ext2defaults0 2 > /dev/mapper/grp--b-second /home ext3defaults0 > 2 > > UUID=12f9e615-f44d-4392-bd81-457927f82142 noneswapsw > 0 0 > /dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 > 0 > /dev/sde1 /media/usbdrive autorw,user,exec0 0 > > > Cheers, Bryce. FOUND IT! Was confused as I'v been mounting /var separately since it was split away from /usr way back in the dark ages. The last colum in fstab is marked pass. This defines in what order partitions are mounted. You must mount /var in the first pass, as software needs it there immediately. So change the root and /var pass values to 0 and all should be well. Once that is changed, there's no need for any of these weird /.var, symbolic liks, etc solutions. hth, Steve -- Steve Holdoway http://www.greengecko.co.nz MSN: st...@greengecko.co.nz GPG Fingerprint = B337 828D 03E1 4F11 CB90 853C C8AB AF04 EF68 52E0
RE: Moving /var - problem with /var/lock and /var/run?
> -Original Message- > From: Barry [mailto:barr...@paradise.net.nz] > > Could you move /var to where you want it, /new_pos/var,then make a soft > link to it from /var.Then alter fstab to mount the ptn, then reboot > I'm not sure I understand - the new partition will mount as /var. What is this 'soft link' thing, is it like a windows shortcut? Cheers, Bryce. DISCLAIMER: If you have received this email in error, please notify us immediately by reply email, facsimile or collect telephone call to +64 3 9641200 and destroy the original. Please refer to full DISCLAIMER at http://www.hrnz.co.nz/eDisclaimer.htm
RE: Moving /var - problem with /var/lock and /var/run?
> -Original Message- > From: Wayne Rooney [mailto:wroo...@ihug.co.nz] > I don't think your /etc/fstab is quite right. Can you post the file so we > can > see it. > Fstab: # /etc/fstab: static file system information. # # Use 'blkid -o value -s UUID' to print the universally unique identifier # for a device; this may be used with UUID= as a more robust way to name # devices that works even if disks are added and removed. See fstab(5). # # proc/proc procdefaults0 0 /dev/mapper/grp--a-root / ext3errors=remount-ro 0 1 ## this is the row I added... /dev/mapper/grp--b-third /var ext3defaults0 2 LABEL=BootPart /boot ext2defaults0 2 /dev/mapper/grp--b-second /home ext3defaults0 2 UUID=12f9e615-f44d-4392-bd81-457927f82142 noneswapsw 0 0 /dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0 /dev/sde1 /media/usbdrive autorw,user,exec0 0 Cheers, Bryce. DISCLAIMER: If you have received this email in error, please notify us immediately by reply email, facsimile or collect telephone call to +64 3 9641200 and destroy the original. Please refer to full DISCLAIMER at http://www.hrnz.co.nz/eDisclaimer.htm
Re: Moving /var - problem with /var/lock and /var/run?
Wayne Rooney wrote: On Thursday 08 April 2010 09:42:29 Bryce Stenberg wrote: Now when booting I get: mount: mount point /dev/.var/run does not exist montall: mount /var/run [700] terminated with status 32 and mount: mount point /dev/.var/lock does not exist mountall: mount /var/lock [700] terminated with status 32 I don't think your /etc/fstab is quite right. Can you post the file so we can see it. Wayne Could you move /var to where you want it, /new_pos/var,then make a soft link to it from /var.Then alter fstab to mount the ptn, then reboot Barry
Re: Moving /var - problem with /var/lock and /var/run?
On Thursday 08 April 2010 09:42:29 Bryce Stenberg wrote: > Now when booting I get: > > mount: mount point /dev/.var/run does not exist > montall: mount /var/run [700] terminated with status 32 > > and > > mount: mount point /dev/.var/lock does not exist > mountall: mount /var/lock [700] terminated with status 32 I don't think your /etc/fstab is quite right. Can you post the file so we can see it. Wayne
Moving /var - problem with /var/lock and /var/run?
Hi, Using Ubuntu Server 9.10. Thanks for all the suggestions on moving my /var to another disk last week. I went with a new LV and moved /var to it. Then set the partition to mount as /var in fstab. However, I got errors with /var/lock and /var/run not existing when booting. I googled it and found they have to be on the root partition so created a directory 'var' under '/' and copied 'run' and 'lock' directories back to this new var. Now when booting I get: mount: mount point /dev/.var/run does not exist montall: mount /var/run [700] terminated with status 32 and mount: mount point /dev/.var/lock does not exist mountall: mount /var/lock [700] terminated with status 32 So I'm getting a bit lost here - am I not really allowed to move /var at all under Ubuntu or have I missed off some important steps in the move? Maybe I'd be better off re-installing setting /var to new partition from the beginning (although then I don't learn why it is screwed up but it might at least work)? Thanks for any insight you can provide me. Regards, Bryce Stenberg. DISCLAIMER: If you have received this email in error, please notify us immediately by reply email, facsimile or collect telephone call to +64 3 9641200 and destroy the original. Please refer to full DISCLAIMER at http://www.hrnz.co.nz/eDisclaimer.htm