sal83 Posted February 15 Share Posted February 15 Hi - i have changed my SSH port to custom port (not 22). I have placed the ssh id_rsa.pub in Hetzner storage box through SCP and able to remote login from my CWP server using the SSH keys. Back up is set up in local machine. The backup folder exists, but the Remote Sync test is failing. Top three tests are green but test for remote connection is tested/activated is red. Checking if config file exists /usr/local/cwp/.conf/remote_backup.conf. Checking if key file exists /root/.ssh/backup/id_rsa.pub Checking if backup folder /backup exists and creating it if not exists. Checking if remote connection is tested and activated. I get below error: Command not found. Use 'help' to get a list of available commands. Connection_Failed What am I missing here? Link to comment Share on other sites More sharing options...
Solution Sandeep B. Posted February 15 Solution Share Posted February 15 to use rsync both source and destination servers should have the rsync package installed. Link to comment Share on other sites More sharing options...
leisegang Posted February 15 Share Posted February 15 i did it like this: ssh -p23 uXXXXX@uXXXXX.your-storagebox.de mkdir backup connects to port 23 to the storage box and makes the folder backup then to send the backup use: rsync --progress -e 'ssh -p23' --recursive /home <username>@<username>.your-storagebox.de:/backup Link to comment Share on other sites More sharing options...
sal83 Posted February 16 Author Share Posted February 16 Thanks for the inputs, I just set it up on another FTP server which provides rsync. Remote sync did not work with Hetzner. Link to comment Share on other sites More sharing options...
Sandeep B. Posted February 16 Share Posted February 16 5 hours ago, sal83 said: Thanks for the inputs, I just set it up on another FTP server which provides rsync. Remote sync did not work with Hetzner. then you need to use scp to transfer files scp -P 23 /path/of/the/source/backupfile.zip username@backup_server_hostname:/path/of/the/backup/directory/ Link to comment Share on other sites More sharing options...
leisegang Posted February 16 Share Posted February 16 The absolute easiest way is to mount the storage box as a volume and then backup to that location. Then use the NEW backup solution in CWP to backup to that location, or you can use rsync to backup to that location. I have one volume at Path: /mnt/backup-server/backup 1 Link to comment Share on other sites More sharing options...
sal83 Posted February 18 Author Share Posted February 18 thanks @leisegang - could you help me with how to set up the mount for the external storage please... Link to comment Share on other sites More sharing options...
leisegang Posted February 19 Share Posted February 19 In Linux-based systems, you can use the following command on the CLI to mount the file system: mount.cifs -o user=<username>,pass=<password> //<username>.your-storagebox.de/backup /PATH/FOLDER By adding the following line to /etc/fstab, your system will automatically mount the file system at boot. (It is a single line!): //<username>.your-storagebox.de/backup /mnt/backup-server cifs iocharset=utf8,rw,credentials=/etc/backup-credentials.txt,uid=<system account>,gid=<system group>,file_mode=0660,dir_mode=0770 0 0 The file /etc/backup-credentials.txt (mode 0600) should contain two lines as follows: username=<username> password=<password> In Debian-based distributions, the command is provided via the package cifs-utils. apt-get install cifs-utils On Debian Wheezy based systems, edit the parameters as follows if you are having problems: rsize=65536,wsize=130048 You should also add the following lines to /etc/rc.local: modprobe cifs echo 0 > /proc/fs/cifs/OplockEnabled Link to comment Share on other sites More sharing options...
Mah1973 Posted April 7 Share Posted April 7 On 2/19/2024 at 8:30 PM, leisegang said: In Linux-based systems, you can use the following command on the CLI to mount the file system: mount.cifs -o user=<username>,pass=<password> //<username>.your-storagebox.de/backup /PATH/FOLDER By adding the following line to /etc/fstab, your system will automatically mount the file system at boot. (It is a single line!): //<username>.your-storagebox.de/backup /mnt/backup-server cifs iocharset=utf8,rw,credentials=/etc/backup-credentials.txt,uid=<system account>,gid=<system group>,file_mode=0660,dir_mode=0770 0 0 The file /etc/backup-credentials.txt (mode 0600) should contain two lines as follows: username=<username> password=<password> In Debian-based distributions, the command is provided via the package cifs-utils. apt-get install cifs-utils On Debian Wheezy based systems, edit the parameters as follows if you are having problems: rsize=65536,wsize=130048 You should also add the following lines to /etc/rc.local: modprobe cifs echo 0 > /proc/fs/cifs/OplockEnabled Tried this a year ago and after spending days testing I failed to get it to work. So I gave up and got a cheap storage vps with rsync and full ssh access. Works like a charm. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now