permission denined transfering files from one sever to another
I accidentally deleted my public_html folder. We just moved from an old server so I still have it. I am trying to transfer the folder "public_html" from one server to another and getting errors. Many more permission errors after what I posted. These were working but some files had permission errors so I deleted everything thinking this would solve it. Not it won't transfer anything.
I tried both of these:
rsync -rltzuv /home/user/public_html username@ipaddress:/home/user
rsync -av /home/user/public_html username@ipaddress:/home/user
stdin: is not a tty
building file list ... done
public_html/
rsync: failed to set times on "/home/user/public_html": Operation not permitted (1)
public_html/.htaccess
public_html/_vti_inf.html
public_html/favicon.ico
public_html/index.php
public_html/postinfo.html
public_html/robots.txt
public_html/_private/
rsync: recv_generator: mkdir "/home/user/public_html/_private" failed: Permission denied (13)
*** Skipping any contents from this failed directory ***
-
Or is someone can give me the steps to tar it, send it to the new server and unzip it. All the instructions I have read are not clear. I have seen this but don't want to make anymore mistakes. Not sure what they mean by "above public html" : --------------------------------------------- cd .. tar -crf public_html.tar public_html gzip public_html.tar scp public_html.tar.gz root@your-remote-server's-IP:/home/where-ever/the-directory-is/above-public_html/ --------------------------------------------------- Then: gunzip public_html.tar.gz tar xvf publc_html.tar 0 -
I tried this to zip the folder and I get no file or directory. After I log in to SSH do I need to type something first? tar -pczf backup.tar.gz home/username/public_html/ 0 -
]I have seen this but don't want to make anymore mistakes. Not sure what they mean by "above public html" :
Hello :) It's referring to /home/$username/. Thank you.0 -
I have so many instructions on how to transfer the files I am confused. At first I thought it was working just transferring but many of the files failed due to permissions. Then I deleted everything in the public_html folder assuming this would help. Can anyone give me instructions on the best way to do it? Some say it needs to be zipped, moved, and then unzipped. Shouldn't this work? Do I need to makse sure the public_html folder is on the new server? I have a backup but can't find it doing LS. rsync -rltzuv /home/username/public_html new@000.00.00.00:/home/username 0 -
The instructions in your second post to this thread should work. Just ensure the ownership of your files are correct after the extraction, and the permissions/ownership on the public_html directory matches the format of your other accounts. Thank you. 0 -
After I log in, I have to cd to the /home/username/public_html before I run tar -crf public_html.tar public_html gzip public_html.tar And are these two run one at a time? And I login on the other server do I have to be in the directory to run these? gunzip public_html.tar.gz tar xvf publc_html.tar Tried: tar -crf public_html.tar public_html Got this: tar: You may not specify more than one `-Acdtrux' option Try `tar --help' or `tar --usage' for more information. 0 -
tar -cf public_html.tar public_html gzip public_html.tar scp public_html.tar.gz username@000.00.00.00:/home/user/ I got it zipped and now I get this when i try to transer it. stdin: is not a ttystdin: is not a tty 0 -
I transferred it and did a ls on the home directory and can see it listed there. Then I did gunzip public_html.tar.gz gzip: public_html.tar.gz: No such file or directory 0 -
I am signed into the new server in /home/user/ directory and tried gunzip public_html.tar.gz and it says no such file or directory. Any idea why this is not working? I can see it there when I run "ls" its in red and the file is called public_html.tar. I can list the files inside the public_html.tar 0 -
I was able to get it transferred over. 0 -
]I was able to get it transferred over.
I am happy to see you were able to complete the transfer. Would you mind sharing which steps you ultimately utilized? Thank you.0
Please sign in to leave a comment.
Comments
11 comments