LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-09-2012, 05:29 PM   #1
Ltes
LQ Newbie
 
Registered: Jan 2012
Location: Boulder, CO
Posts: 1

Rep: Reputation: Disabled
Creating a .tgz archive on a remote server from local files?


Hello all, I'm wondering if it's possible to create a .tgz file from local files onto a remote server where I'm attempting to backup data. My local machine lacks the space necessary to create the archive locally before uploading. The command I was trying with was
Code:
tar "directory location" | ssh username@host.edu "cat>backup.tgz"
but the printout is "tar: Cowardly refusing to create an empty archive." I know the directory itself is fine, attempting a local .tgz works with the same path. I'm sure I've missed something obvious, but any help or suggestions (or dire warnings) you can give would be most appreciated. Thanks in advance!
 
Old 01-09-2012, 05:53 PM   #2
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007
Hello,

Instead of using ssh itself, use scp to directly transfer over. Should work that way for you; I would verify, but I'm currently at work.

Cheers,

Josh
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Error trying to extract a tgz archive gemboek Linux - Newbie 4 09-18-2011 03:26 PM
Add mysqldump to exisiting archive.tgz pe_ Linux - Newbie 3 02-04-2010 04:37 PM
[SOLVED] Creating local NFS mounted home directory for remote LDAP authenticated user someshpr Linux - Newbie 2 12-15-2009 06:14 PM
shell script to compare filese b/w local and remote and delete files from local serve dsids Linux - Networking 9 08-23-2006 07:20 AM
Creating RPM's from .tgz files kaplan71 Linux - General 1 03-24-2005 08:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:40 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration