How To Tar Untar – Zip Unzip a directory and move to another user
In Linux from the command line, you can tar-untar, or as most people will know zip and unzip a directory. This is useful if you want to move a WordPress site to a different account. Or, let’s assume you want to move the whole public_html folder under the user test to a user on the same NVMe VPS server that has the username transfer.
First, let’s get to the users home directory
Then let’s tar/zip the public_html folder and place the file that’s created in the new users home directory. Tar untar zip unzip ssh
tar /home/test/public_html /home/transfer/
Once complete you can then move the new users home directory
List the directory contents
You should see the public_html.tar.gz file in the directory. Let’s untar-unzip the file overwriting any files already in the directory
tar -xvf public_html.tar.gz
That account should now have an exact copy of the public_html folder from the user test.
Install a free firewall. Install CSF
How was this article? Tar untar zip unzip ssh
More from All About Linux
Ioncube Loaders are a piece of software that is used to protect the underlying code in PHP applications. Its aim …