
9th February 2007, 20:23
|
|
Senior Member
|
|
Join Date: Nov 2006
Posts: 116
Thanks: 10
Thanked 7 Times in 3 Posts
|
|
Backup
Hi again,
Is there any way to make backups that are invoked from the panel to be performed as root.
I ask because I run suPHP without open_basedir restriction in effect and my users chmod some of their config files to 600. The sites run fine that way but the backup script can't read the chmodded files.
Another workaround would be to run the script as the user that invokes it. But I believe this is more complicated, because the user could be a reseller or one with more webs than one, wanting to backup all of them in one setting.
So the root user is the one to make backups in my case. Is it possible?
Thanks.
Last edited by smartcall; 9th February 2007 at 20:26.
|

10th February 2007, 19:38
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,872
Thanks: 689
Thanked 4,186 Times in 3,203 Posts
|
|
The only nackup functionality that runs as root user in ISPConfig is the automatic nightly backup which can be activated in the config.inc.php file. The backups where stored in a directory named backup inside the website root dir.
|

11th February 2007, 15:13
|
|
Senior Member
|
|
Join Date: Nov 2006
Posts: 116
Thanks: 10
Thanked 7 Times in 3 Posts
|
|
Thanks!
And will every next backup delete the previous one. Or they will be filling the disk space of the user untill the quota is over.
|

12th February 2007, 14:46
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,593 Times in 2,444 Posts
|
|
Quote:
|
Originally Posted by smartcall
Or they will be filling the disk space of the user untill the quota is over.
|
They will fill up the disk space, so you better watch them regularly.
|

12th February 2007, 16:33
|
|
Senior Member
|
|
Join Date: Nov 2006
Posts: 116
Thanks: 10
Thanked 7 Times in 3 Posts
|
|
So, I could add a code to your backup script that will delete the backup from the previous day. Or delete the whole folder and then create it again?
Where is the script located?
Thanks.
|

13th February 2007, 17:46
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,593 Times in 2,444 Posts
|
|
Quote:
|
Originally Posted by smartcall
So, I could add a code to your backup script that will delete the backup from the previous day. Or delete the whole folder and then create it again?
|
Yes.
Quote:
|
Originally Posted by smartcall
Where is the script located?
Thanks.
|
It's in the /root/ispconfig scripts/shell directory.
This link might be interesting for you: http://www.howtoforge.com/forums/sho...r%2Fbin%2Ffind
|

13th February 2007, 18:34
|
|
Senior Member
|
|
Join Date: Nov 2006
Posts: 116
Thanks: 10
Thanked 7 Times in 3 Posts
|
|
Thanks!
This is the perfect solution.
Just a couple more questions:
If the user directory becomes over quota, would the site and database function properly?
I understand that the user will not be able to add files, but would the database be still operational?
Regards
|

14th February 2007, 11:57
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,872
Thanks: 689
Thanked 4,186 Times in 3,203 Posts
|
|
Quote:
|
If the user directory becomes over quota, would the site and database function properly?
|
Generally yes, but the umail users wont receive any new mail. But ify you run PHP with SuPHP, it might happen that PHP nis not able to make new sessions anymore, if you rum mod_php which is the default, there should be no such problem.
Quote:
|
I understand that the user will not be able to add files, but would the database be still operational?
|
Yes. Because databases are stored under the user and group "mysql".
|

18th February 2007, 11:57
|
|
Senior Member
|
|
Join Date: Nov 2006
Posts: 116
Thanks: 10
Thanked 7 Times in 3 Posts
|
|
Thanks for the answers!
I think of another solutioin which is: - Another harddisk mounted on, let's say /backup. Which directory is not in quota path, because my quota is within /var.
- Backup script creates separate dirs for each web and stores the backup files in corresponding dirs.
- Then makes symlinks to the existing userdirs in /var/www.
Question is: will symlink for a dir outside of quota path count for used space?
|

19th February 2007, 14:48
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,593 Times in 2,444 Posts
|
|
Quote:
|
Originally Posted by smartcall
Question is: will symlink for a dir outside of quota path count for used space?
|
I don't think so, but I'm not sure...
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT +2. The time now is 11:25.
|
Recent comments
2 days 2 hours ago
2 days 11 hours ago
2 days 14 hours ago
2 days 15 hours ago
2 days 16 hours ago
2 days 18 hours ago
2 days 19 hours ago
2 days 21 hours ago
3 days 12 hours ago
3 days 13 hours ago