Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
From: ScriptOmatic <ScriptOmatic@ChironComputing.Com>
Subject: Re: Backup script: output redirection
Date: Sat, 26 Oct 2002 02:03:39 GMT	[thread overview]
Message-ID: <3DB9F717.689CD722@ChironComputing.Com> (raw)
In-Reply-To: 6445524b.0210250851.20765dd3@posting.google.com

Dub wrote:
> 
> Hi,
> 
> This is a very simple question, it deals more with shell programming
> than with Tru64. Anyway, I'm sure some of you have a working variant.
> 
> I have a script with many vdump command (backup of all filesystems).
> 
> backup.sh:
> vdump ...
> vdump ...
> 
> I'd like to get copy of the output (actually file list) in one file,
> named list.$DATE  (I know how to get date in a variable).
> 
> Many thanks in advance for sharing a compact nice variant!
> 
> BR,
> Dub

If I understand what you want ...

backup.sh:

#! /bin/sh

LIST=list.$DATE; # you got that part you say
(
vdump ...
vdump ...
) > ${LIST} 2>&1



OR TO HAVE BOTH USE tee

(
.... same stuff 
) 2>&1 | tee [-a] $LIST  # -a for append, probably you know, eh?


-- 
http://ftp.opensysmon.com is a shell script archive site with an
open source system monitoring and network monitoring software package.
Many platforms are supplied already compiled.


  reply	other threads:[~2002-10-26  2:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-25 16:51 Backup script: output redirection Dub
2002-10-26  2:03 ` ScriptOmatic [this message]
2002-10-28  7:47   ` Dub
2002-10-28  7:47   ` Dub
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox