All of lore.kernel.org
 help / color / mirror / Atom feed
From: Heinz Mauelshagen <mauelsha@ez-darmstadt.telekom.de>
To: seric@geotec.net
Cc: linux-lvm@msede.com, mge@ts1.ez-darmstadt.telekom.de
Subject: Re: [linux-lvm] vgscan & vgchange -a y location in startup scripts
Date: Sun, 25 Apr 1999 19:53:26 METDST	[thread overview]
Message-ID: <199904251753.AA01936@mailgate1b.telekom.de> (raw)
In-Reply-To: <37233A05.27BFC35E@geotec.net>; from "Eric Smith" at Apr 25, 99 10:51 am

> 
> On my Alpha, with RedHat 5.2 (SysV style init), where exactly should I
> put the vgscan and vgchange -a y?
> 
> ** Should I put it in /etc/init.d/rc.sysinit?  And if so, should it be
> AFTER mounting / and /proc (but before, of course, mounting anything
> else)?

Yes, put it there.
/ has to mounted (see assumption below), /proc doesn't before running vgscan.

> 
> ** Should it be after fsck runs?
> 
> I have the kernel patched and lvm installed (with patch) and I'm ready
> to try it out.  But I need to know just where to put vgscan and vgchange
> -a y!
> 

vgscan accesses /etc/lvmtab.d read/write.
If you want to stay with this directory and its contents in your root
filesystem, do a fsck root and a vgscan afterwards followed by
the "vgchange -ay".

A script fragment follows from my /sbin/init.d/boot on SuSE.
There's a redundand ro mount in it, because SuSEs boot script
remounts / rw afterwards again :)

#############################################################################
#
# Find and activate volume groups (HM 1/1/1999)
#
if [ -x /sbin/vgscan -a -x /sbin/vgchange ]; then
   while read line; do
      set -- $line
      if [ "$2" = "/" ]; then
         root=$1
         type=$3
         break
      fi
   done < /etc/fstab

   fsck -y -t $type $root; ret=$?

   if [ $ret -eq 0 ]; then
      echo "Remounting / read/write for vgscan..."
      mount -n -o remount,rw /
      echo "Scanning for LVM volume groups..."
      /sbin/vgscan
      mount -n -o remount,ro /
      echo "Activating LVM volume groups..."
      /sbin/vgchange -ay
   else
      echo "Error checking / for vgscan..." >&2
   fi
else
   echo "Skipping LVM activation..."
fi
#
# End find and activate volume groups (HM)
#
#############################################################################


Regards,
Heinz

--

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Systemmanagement C/S                             Deutsche Telekom AG
                                                 Entwicklungszentrum Darmstadt
Heinz Mauelshagen                                Otto-Roehm-Strasse 71c
Senior Systems Engineer                          Postfach 10 05 41
                                                 64205 Darmstadt
mge@ez-darmstadt.telekom.de                      Germany
                                                 +49 6151 886-425
                                                          FAX-386
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

  reply	other threads:[~1999-04-25 17:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-04-25 15:51 [linux-lvm] vgscan & vgchange -a y location in startup scripts Eric Smith
1999-04-25 17:53 ` Heinz Mauelshagen [this message]
     [not found] <37234DCA.C4B73BC7@geotec.net>
1999-04-25 19:02 ` Heinz Mauelshagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=199904251753.AA01936@mailgate1b.telekom.de \
    --to=mauelsha@ez-darmstadt.telekom.de \
    --cc=linux-lvm@msede.com \
    --cc=mge@ts1.ez-darmstadt.telekom.de \
    --cc=seric@geotec.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.