Results 1 to 10 of 10

Thread: Admin backup on WebDAV/ownCloud

  1. #1
    Join Date
    Nov 2013
    Posts
    76

    Admin backup on WebDAV/ownCloud

    I am trying to use WebDAV attached to a remote server to store my admin backups. The server uses software based on ownCloud (Transip / STACK).

    I have set up a mount point to the server from my VPS to the remote server. User/group is admin/admin.

    Before I backup, the rights are rwx for averybody:

    Code:
    drwxrwxrwx  2 admin admin  752 Jan  2 10:15 backup
    When I run the backup, I get the following message:

    Code:
    Copy error: /home/xxx/imap/xxx.xx/webmaster: <b>Parent directory does not allow write, or one of the directories didn't allow search (execution) permission</b>
     Unable to create the directory /home/admin/stack/backup/xxx/backup/xxx.xx/email/data/imap/webmaster/Maildir
    Afterwards the permissions have been changed:

    Code:
    drwx--x--x  2 admin admin  720 Jan  2 10:16 backup
    Can I solve this by using the proper settings in WebDAV or is this something DA does?

  2. #2
    Join Date
    Nov 2015
    Posts
    71
    I'm using Stack everyday to store my backups, so it certainly is possible. I have DirectAdmin running on a server with Ubuntu 14.04 LTS.

    I assume you installed davfs2? And added the right Stack-credentials in the secrets file?

    I mount Stack in /etc/fstab this way:
    Code:
    https://xxxxxxxxxx.stackstorage.com/remote.php/webdav/ /media/stack davfs _netdev,rw,user,file_mode=0640,dir_mode=0755 0 0
    My stack-folder is assigned to root:
    Code:
    drwxr-xr-x 6 root root 216 jan 24 06:28 stack

  3. #3
    Join Date
    Nov 2013
    Posts
    76
    Thanks for your reply.

    I have different mount settings, so I am going to try yours:

    Quote Originally Posted by ZipperZapper View Post
    I mount Stack in /etc/fstab this way:
    Code:
    https://xxxxxxxxxx.stackstorage.com/remote.php/webdav/ /media/stack davfs _netdev,rw,user,file_mode=0640,dir_mode=0755 0 0

  4. #4
    Join Date
    Jun 2013
    Location
    Dutch Mountains
    Posts
    240
    I will be inplementing this too pretty soon.

    Ed, did you follow this article on TransIP site?
    https://www.transip.nl/vragen/756-st...ijn-gebruiken/

  5. #5
    Join Date
    Nov 2013
    Posts
    76
    The settings for the mount point given by ZipperZapper (thanks!) do the trick. So follow the Stack manual, but use the fstab entry given above.

    I use this only for the admin backup. For the application backups, I have entered a new location in Installatron to go directly to Stack as a webdav. Both are working fine now. The only thing I have not tested yet is to restore from Stack.

  6. #6
    Join Date
    Dec 2015
    Posts
    5
    Since a few days the stack connection with my Debian 7.0 server has issues. When I try to connect to it it tells me

    Code:
    /sbin/mount.davfs: warning: the server does not support locks
    Do one of you know what is going on?

  7. #7
    Join Date
    Oct 2016
    Posts
    1
    Hey All,

    So I'm also trying to make this mount to make directadmin backups to my Stack.

    It all already starts with the next error:
    Code:
    /sbin/mount.davfs: Warning: can't write entry into mtab, but will mount the file system anyway
    then accours:

    Code:
    Error copying ./data/users/xxx/bandwidth.tally to /home/admin/stack/Backups/xx/xx/backup/bandwidth.tally : Unable to rename /home/admin/stack/Backups/week-4/xxx/backup/bandwidth.tallyhWgEID to /home/admin/stack/Backups/xx/xx/backup/bandwidth.tally: Permission denied
    
    Error copying /home/xxx/.shadow to /home/admin/stack/Backups/week-4/xx/backup/.shadow : Unable to rename /home/admin/stack/Backups/week-4/xx/backup/.shadowtu6F5r to /home/admin/stack/Backups/week-4/xxx/backup/.shadow: Permission denied
    
    Error copying ./data/users/xxx/history to /home/admin/stack/Backups/week-4/xx/backup/history : Unable to rename /home/admin/stack/Backups/week-4/xx/backup/history/2016-08.logMpjgSm to /home/admin/stack/Backups/week-4/xxx/backup/history/2016-08.log: Permission denied
    Unable to open /home/admin/stack/Backups/week-4/xxx/backup/history/2016-09.logBcpH8Q for writing
    
    Error writing /home/admin/stack/Backups/week-4/xx/backup/xxx.com/domain.conf to insert local_domain & private_html_is_link: Unable to stat /home/admin/stack/Backups/week-4/xxx/backup/xxx.com/domain.conf.temp for filesize after write
    ConfigFile::removeFile(/home/admin/stack/Backups/week-4/xxx/backup/xxx.com/domain.conf) filename does not match
    
    Could not read /home/admin/stack/Backups/week-4/xxx/backup as <user>
    Info as root: /home/admin/stack/Backups/week-4/xxx/backup: <user>:<group> drwx------, running as root:root
    <21:19:29>
    (user, group and xxx changed)

    What am I doing wrong here?
    Can someone hint me in the right direction?

    Greetz,

  8. #8
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,040
    Hello,

    Though the question hardly related to Directadmin... you'd have more chances to get a help here if you show how you mount the Stack-drive. As it seems you've the issue with mounting the drive.

    And what you see with

    Code:
    cat /proc/mounts
    ?

    Code:
    df -h
    ?
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

  9. #9
    Join Date
    Nov 2013
    Posts
    76
    I am (again) struggling to get this to work. I have tried several options, but none seem to work.

    The error can be one of the following.

    1.
    If I mount as admin

    Code:
    https://xxx/remote.php/webdav/ /mnt/stack davfs _netdev,rw,uid=admin,gid=admin,file_mode=664,dir_mode=775 0 0
    I get

    Code:
    Error copying ... Permission denied
    ...
    Could not read /mnt/stack/backup/s1/2017-08-19/mywebuser/backup as mywebuser
    Info as root: /mnt/stack/backup/s1/2017-08-19/mywebuser/backup: 'mywebuser:mywebuser' drwx------, running as root:root
    ...
    2.
    If I mount as root and set the sticky bit

    Code:
    https://xxx/remote.php/webdav/ /mnt/stack davfs _netdev,rw,user,file_mode=0664,dir_mode=0775 0 0
    I get

    Code:
    Unable to create backup directory (uid=admin): /mnt/stack/backup/s2/2017-08-19 : <b>Parent directory does not allow write, or one of the directories didn't allow search (execution) permission</b>
    Anyone have any clue what parameters I should use?

  10. #10
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,040
    I simply mount it with:

    Code:
    /bin/mount -t davfs ${URL} ${LOCAL_DIR};
    where

    ${URL} - url of a stack drive
    ${LOCAL_DIR} - local directory e.g. /opt/stack
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •