From owner-freebsd-questions Wed Oct 3 17:33:57 2001 Delivered-To: freebsd-questions@freebsd.org Received: from mail.tgd.net (rand.tgd.net [64.81.67.117]) by hub.freebsd.org (Postfix) with SMTP id C8DA437B406 for ; Wed, 3 Oct 2001 17:33:53 -0700 (PDT) Received: (qmail 85102 invoked by uid 1001); 4 Oct 2001 00:33:33 -0000 Date: Wed, 3 Oct 2001 17:33:32 -0700 From: Sean Chittenden To: Odhiambo Washington Cc: FBSD-Q Subject: Re: Tar over ssh crontab - how ? Message-ID: <20011003173330.C84600@rand.tgd.net> References: <20011003192002.E16935@ns2.wananchi.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="JYK4vJDZwFMowpUq" Content-Disposition: inline In-Reply-To: <20011003192002.E16935@ns2.wananchi.com>; from "wash@wananchi.com" on Wed, Oct 03, 2001 at = 07:20:02PM X-PGP-Key: 0x1EDDFAAD X-PGP-Fingerprint: C665 A17F 9A56 286C 5CFB 1DEA 9F4F 5CEF 1EDD FAAD X-Web-Homepage: http://sean.chittenden.org/ Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --JYK4vJDZwFMowpUq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable > I have ssh setup btw two hosts for root. I have a simple backup command t= hat I need to run > via a cron entry. > On the command line it runs file but in cron nothing happens absolutely. >=20 > Please help. >=20 > The command is: >=20 > /usr/bin/nice --20 /usr/bin/tar -czf - /etc /usr/local/etc | /usr/bin/ssh= HOSTB \ > '( cd ~wash/Administration/Backups; cat > ns2_`/bin/date +\%Y%m%d`.tgz )' >=20 > The cron entry that doesn't work is: > 18 40 * * * root /home/wash/Administration= /backup-ns2.sh > /var/log/ns2-backup.log 2>&1 >=20 > A real testrun gives.... >=20 > ns2# ./backup-ns2.sh=20 > /usr/bin/tar: Removing leading / from absolute path names in the archive. > ns2# >=20 > I really need to either log the output or mail it to myself. >=20 > MTIA Hmm... I've never done this with ssh, but I know you can do this over kerberized rsh (encrypted/secure rsh) if you get a non-expiring ticket. =20 It takes some reading, but ports/security/krb5 is pretty cool. -sc --=20 Sean Chittenden --JYK4vJDZwFMowpUq Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Comment: Sean Chittenden iEYEARECAAYFAju7rlYACgkQn09c7x7d+q3O0gCfVF0aJlcU7DFiyRe5z3m/3nd5 5AAAn1qJcrmJmaKxtPijauVaYr21e458 =fsTb -----END PGP SIGNATURE----- --JYK4vJDZwFMowpUq-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message