Solved

Errors when ex tracing tar file from other box

Posted on 2006-11-19
5
242 Views
Last Modified: 2010-04-20
Hello,

I have two Linux boxes that are configured EXACTLY the same (one is for development and one is for production)

I got things working just the way I wanted on my DEV box, then did this:

       tar cf projectname.tar /home/projectname/public_html/project

Then on my PROD box I did this:

       wget http://projectname.dev.mysite.com/projectname.tar
       tar xf projectname.tar

The wget works fine BUT tar xf gives me dozens of errors like this:
        tar: project/images/clear.gif: Cannot open: No such file or directory
And finally:
        tar: Error exit delayed from previous errors

How can I do this?  It should be simple and easy!

Thanks!

0
Comment
Question by:hankknight
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 48

Assisted Solution

by:Tintin
Tintin earned 250 total points
ID: 17976869
What users are you running the tar command as?  root?
0
 
LVL 16

Author Comment

by:hankknight
ID: 17978760
No, I created them as user "dev" and I am trying to extract it as user "prod"

The reason that I did not SU (as root) is because I was worried that then when I log in as "prod" I would not be able to make updates to the files.

Is there a way I can specifically change ALL permissions from "dev" to "prod"?  Would that fix it?  Thanks.
0
 
LVL 5

Assisted Solution

by:ircpamanager
ircpamanager earned 200 total points
ID: 17980622
you can change the permissions of tar file by typing as root in terminal window:
chown prod.prod projectname.tar
*notice the owner name is prod and group name(second one) is prod, this assuming that there is a user name prod and group named prod.
*is project a directory?If so what are the permissions of the directory and subdirectorys?
0
 
LVL 30

Assisted Solution

by:Kerem ERSOY
Kerem ERSOY earned 50 total points
ID: 17981537
It seems that you have no permision to write to the directory.
also try to ls -al files at the both ends to see if the files ar e the same size.

0
 
LVL 48

Accepted Solution

by:
Tintin earned 250 total points
ID: 17982147
The error will occur from prod not having permissions to read/set permissions on the files it is extracting.

Either use the same user to create/extract the tar file, or use root.
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
number in printf 13 42
RHEL 6.7 Gnome Desktop on VMware 6 VM 9 113
postfix start error! 9 54
Enable SPF on IMSVA 6 21
I am a long time windows user and for me it is normal to have spaces in directory and file names. Changing to Linux I found myself frustrated when I moved my windows data over to my new Linux computer. The problem occurs when at the command line.…
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question