Jump to content

Help with tar backup file


belick

Recommended Posts

Hi, I am not sure if this is the right place to ask for help but I will try...

 

I am tring to make a file that can be run by a cronjob on my linux. The file suppose to make a tar file for a specific folder and protect it with a password, then to upload it into FTP server...

 

Any help will be thanksful,

 

Thanks.

Link to comment
https://forums.phpfreaks.com/topic/79171-help-with-tar-backup-file/
Share on other sites

To tar a directory....

 

tar -cvf file.tar directory
gzip file.tar

 

To encrypt the new file using a password (ps: Ive never attempted this with anything other than text files).

 

mcrypt file.tar.gz

 

To ftp the encrypted file to a remote server.

 

ftp put file.tar.gz.nc hostname

  • 1 month later...

Questions:

 

#!/usr/bash               

tar -cvf file.tar directory         

gzip file.tar                            do I must go with zip too?

mcrypt file.tar.gz                    where do I place my pasword? I need to protect the file...

ftp put file.tar.gz.nc hostname  hostname means the ftp? where is the username and pass?

 

Thanks

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.