Date: Wed, 2 Feb 2005 01:51:42 -0800 From: "Loren M. Lang" <lorenl@alzatex.com> To: Eric Kjeldergaard <kjelderg@gmail.com> Cc: FreeBSD Mailing list <freebsd-questions@freebsd.org> Subject: Re: mounted ext2 fs causes bad shutdown Message-ID: <20050202095142.GQ8619@alzatex.com> In-Reply-To: <d9175cad0502010558d0d23c6@mail.gmail.com> References: <20050131110432.GD8619@alzatex.com> <20050201041642.GA1733@oliverfuchs.onlinehome.de> <20050201055342.GC776@gothmog.gr> <20050201112315.GH8619@alzatex.com> <d9175cad0502010558d0d23c6@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Feb 01, 2005 at 07:58:34AM -0600, Eric Kjeldergaard wrote:
> > > One of the many ways to do the same thing without the bugs could be:
> > >
> > > # extfs=$(mount | grep '^/.*(ext2fs,' | awk '{print $1}')
> >
> > Actually, better than that would be extfs=$(mount -t ext2fs | awk '{print $1;}')
> > Or even just replace the whole thing with "umount -a -t ext2fs"
> >
>
> While we're at it, isn't awk a bit of overkill? Seems that the
> following would do:
>
> extfs=$(mount -t ext2fs | cut -d ' ' -f1)
How about save a few more bytes and do:
extfs=`mount -text2fs|cut -d\ -f`
But "umount -a -text2fs" is the shortest version since it doesn't even
need a loop, it does everything in one command.
>
> Every cycle counts :p
>
> --
> If I write a signature, my emails will appear more personalised.
--
I sense much NT in you.
NT leads to Bluescreen.
Bluescreen leads to downtime.
Downtime leads to suffering.
NT is the path to the darkside.
Powerful Unix is.
Public Key: ftp://ftp.tallye.com/pub/lorenl_pubkey.asc
Fingerprint: B3B9 D669 69C9 09EC 1BCD 835A FAF3 7A46 E4A3 280C
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050202095142.GQ8619>
