Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 32

Thread: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

  1. #21
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by freeflyjohn View Post
    Thanks CharlesA, I ran the following command so that it backed up to a destination folder (called testrsync) on the Mac ...

    Code:
    rsync --archive --verbose --itemize-changes -b --backup-dir="deleted_$(date +\%Y-\%m-\%d)" --delete --exclude-from /Users/username/rsync/rsync-exclude-list.txt /Users/username /Users/username/testrsync 2>&1 | tee -a logfile.txt
    It worked fine without any issues.

    So for some reason, rsycn fails when the destination is the server.

    But how do I find out why and how do I fix it ?
    That's good news! At least that means the command is working correctly.

    So, you have the server's folder mounted to /Users/myusername/Volumes/Storage/Backup/Mac/rsync right?

    How is that mounted?

    As for troubleshooting, you can run this command from the server and monitor it while the rsync is running.

    Code:
    watch 'dmesg | grep -v UFW | tail -n 50'
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  2. #22
    Join Date
    Oct 2005
    Location
    Lab, Slovakia
    Beans
    10,468

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Hmm, I am one of the folks who use SSH for everything. So I backup my Macs over SSH with rsync and that works OK for me.

  3. #23
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by HermanAB View Post
    Hmm, I am one of the folks who use SSH for everything. So I backup my Macs over SSH with rsync and that works OK for me.
    Same here. That's probably the next step if this doesn't work.

    I'm trying to figure out if it's the way they are transferring the files via local mount instead of SSH that is the problem or if it's something else.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  4. #24
    Join Date
    Nov 2017
    Beans
    101

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by CharlesA View Post
    That's good news! At least that means the command is working correctly.

    So, you have the server's folder mounted to /Users/myusername/Volumes/Storage/Backup/Mac/rsync right?

    How is that mounted?

    As for troubleshooting, you can run this command from the server and monitor it while the rsync is running.

    Code:
    watch 'dmesg | grep -v UFW | tail -n 50'
    The server appears in Finder (on the Mac) as 'HOMESERVER' as shown in the screenshot below...



    When I click on a drive such as 'Storage' the mount symbol appears.

    However, it is temperamental because sometimes it works, sometimes it doesn't.

    When it doesn't work, I have to use the Finder menu Go->Connect to server...





    My samba config (/etc/samba/smb.conf) is as follows - I think it's supposed to advertise the server on the network (?)...

    Code:
    security = user
    username map = /etc/samba/smbusers
    name resolve order = bcast wins lmhosts
    
    
    netbios name = HomeServerSMB
    
    
    [Plex]
    comment = Plex Media Server
    path = /media/plex
    read only = no
    writable = yes
    [General]
    comment = General server
    path = /media/general
    read only = no
    writable = yes
    [Time machine]
    comment = Time machine backup
    path = /media/timemachine
    read only = no
    writable = yes
    [Home]
    comment = Ubuntu Home
    path = /home
    read only = no
    writable = yes
    [Storage]
    comment = Storage
    path = /media/storage
    read only = no
    writable = yes
    I don't know whether its a Mac issue, because when I use a Windows machine (my work laptop) it always seems to connect to the server without a problem.
    Attached Images Attached Images

  5. #25
    Join Date
    Nov 2017
    Beans
    101

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by HermanAB View Post
    Hmm, I am one of the folks who use SSH for everything. So I backup my Macs over SSH with rsync and that works OK for me.
    I didn't think there would be any point in using SSH, because I am backing up over my internal LAN network so its safe.

    I thought SSH was more for remote connections, when accessing your sever from outside the LAN network ?

    I do have SSH setup and running which I use for remote access.

  6. #26
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by freeflyjohn View Post
    I didn't think there would be any point in using SSH, because I am backing up over my internal LAN network so its safe.

    I thought SSH was more for remote connections, when accessing your sever from outside the LAN network ?

    I do have SSH setup and running which I use for remote access.
    You can use SSH to do file transfers even on local connections. It's just the protocol in use.

    I use it when I am backing up to my second server.

    Instead of trying to use the mounted smb share, try it over SSH:

    Code:
    rsync --archive --verbose --itemize-changes -b --backup-dir="deleted_$(date +\%Y-\%m-\%d)" --delete --exclude-from /Users/username/rsync/rsync-exclude-list.txt /Users/username user@hostname:/Users/username/testrsync 2>&1 | tee -a logfile.txt
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  7. #27
    Join Date
    Nov 2017
    Beans
    101

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by CharlesA View Post
    You can use SSH to do file transfers even on local connections. It's just the protocol in use.

    I use it when I am backing up to my second server.

    Instead of trying to use the mounted smb share, try it over SSH:

    Code:
    rsync --archive --verbose --itemize-changes -b --backup-dir="deleted_$(date +\%Y-\%m-\%d)" --delete --exclude-from /Users/username/rsync/rsync-exclude-list.txt /Users/username user@hostname:/Users/username/testrsync 2>&1 | tee -a logfile.txt
    Thanks CharlesA I'll give that a go

    I have changed the SSH default port so when I use SSH I have to define the port number (e.g. ssh user@hostname -p 12345), so what would the syntax need to be in the example you gave ?

    Would it be user@hostname -p 12345:/Users/username/testrsync ?

    Would it slow the transfer speed using SSH, doesn't it have to encrypt the data and then decrypt it at the server end ?

    Just seems an additional process to secure the data which on an internal network seems unnecessary, or am I missing something ?

    If it does work with SSH, then I wonder why it won't work directly with samba ?
    Last edited by freeflyjohn; July 25th, 2021 at 08:34 PM.

  8. #28
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Quote Originally Posted by freeflyjohn View Post
    Thanks CharlesA I'll give that a go

    I have changed the SSH default port so when I use SSH I have to define the port number (e.g. ssh user@hostname -p 12345), so what would the syntax need to be in the example you gave ?

    Would it be user@hostname -p 12345:/Users/username/testrsync ?
    It'll be a little different if you are not using the default port.

    You'll need to add -e "ssh -p 2222" like the example below, so rsync knows what port to connect on.

    Code:
    rsync -avz -e "ssh -p 2232" SRC/ user@remote.host:/DEST/
    Would it slow the transfer speed using SSH, doesn't it have to encrypt the data and then decrypt it at the server end ?

    Just seems an additional process to secure the data which on an internal network seems unnecessary, or am I missing something ?
    I haven't really noticed much of a performance hit when transferring files over ssh. It can be slower than SMB, but it shouldn't be a huge difference.

    It may be unnecessary, but I find it a lot less complicated than trying to set up a mounted SMB share.

    If it does work with SSH, then I wonder why it won't work directly with samba ?
    If it works over SSH, then we know something with Samba is causing it to fail.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  9. #29
    Join Date
    Nov 2017
    Beans
    101

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Found how to specify SSH port number using:
    Code:
    rsync -a -b --rsh='ssh -p 12345' --progress --backup-dir="deleted_$(date +\%Y-\%m-\%d)" --delete --exclude-from /Users/username/rsync/rsync-exclude-list.txt /Users/username user@hostname:/Users/username/testrsync 2>&1 | tee -a logfile.txt

  10. #30
    Join Date
    Nov 2017
    Beans
    101

    Re: Is it possible to backup Mac APFS personal data to Ubuntu server ext4 HDD ?

    Thanks all, especially to CharlesA

    SSH worked without any problems, using a wired network connection I managed to backup the Downloads and Desktop folders on the Mac to the server fairly quickly which is impressive considering the amount of time its taken to get it working !

    I'm now uncommenting folders from the exclude list one by one and performing an rsync each time.

    So it seems samba was the problem ?

    From the sounds of it most of you are using SSH with rsync, so I may as well stick with SSH and forget about samba ?

    Im just curious now as to why samba didnt work ?

    Is samba not very good, is that the reason why the Mac doesnt always connect to the server without having to use the "Go->Connect to server..." method ?

Page 3 of 4 FirstFirst 1234 LastLast

Bookmarks

Posting Permissions

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