How Do I Download Backups?

ShelaghG

Active Member
Apr 11, 2002
38
0
306
Our server is merrily backing up user accounts every night but there seems to be no way for me to get them off the server. I want to download them every morning and save them on my hard drive. I can't log in via ftp as root, but as the file permissions are 700 I can't touch them unless I am root. Presumably I need to change root's ftp permissions?
 

SprintSlash

Well-Known Member
Jan 18, 2003
162
0
166
It's generally bad to FTP using root account. You should just create an FTP account that points to your backup directory.
 

ShelaghG

Active Member
Apr 11, 2002
38
0
306
How? Everything in the backup directory has rwx permissions for the root user only and it doesn't seem possible to change this (I've tried)
 

FijianTribe

Well-Known Member
Jan 30, 2003
69
0
156
Try making the directory accessible to a usergroup, and add yourself to the user group. Then you should have permissions.
 

ShelaghG

Active Member
Apr 11, 2002
38
0
306
The directory's permissions are :
drwxr----- 5 root root 4096 Feb 5 07:11 cpbackup

I have created another user and made them a member of the root group, the directory that cpbackup is in is it's home directory. However I can't login via ftp, presumably because the user is a member of the same group as root!
 

SprintSlash

Well-Known Member
Jan 18, 2003
162
0
166
I guess you have to allow root access on your FTP.

Assuming that you're using ProFTPd, put this next line in /etc/proftpd.conf:

RootLogin on

For more details, go to http://proftpd.linux.co.uk/localsite/Userguide/linked/config_ref_RootLogin.html
 

ShelaghG

Active Member
Apr 11, 2002
38
0
306
That doesn't work either. The login still comes back as invalid. ProFTPd seems to be using /etc/proftpd/passwd.vhosts to validate users and root isn't in there. Neither is the backup user I created yesterday (using useradd). Maybe if I could figure out how to add my backup user to the authentication file that ProFTPd is using I could download the backups with that user instead of root :) The ftp documentation isn't much help.
 

jamesbond

Well-Known Member
Oct 9, 2002
737
1
168
Have you figured this out yet?

I'm interested in a solution to this 'problem' as well.

If you can't get it to work with proftpd, you could change ownership of the backups to a regular user before you download the files, and afterwards you change ownership back to root?
 

ShelaghG

Active Member
Apr 11, 2002
38
0
306
I have several personal web sites hosted on the server but if I log in using any of those usernames then I am restricted to their home directory. Still trying to figure something out.
 

ShelaghG

Active Member
Apr 11, 2002
38
0
306
dgbaker is the winner for correctly solving today's problem :) I found a free secure ftp client at http://winscp.vse.cz/eng/about.php Also when searching on Google (&secure ftp& ssh) it seems that if you have SSH and ftp clients you can set them up to do this but it seems like a lot of faffing about when there's a nice, free client to download and simplify everything :)

Thank you to everyone for all their input, it's much appreciated.