How to set up Time Machine over SMB in Jail

Status
Not open for further replies.

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
I will flesh this out as I have time. I have TM over SMB working in a samba jail on my FreeNAS server

Step 1: Create Jail
Step 2: Pkg update in jail
Step 3: Portsnap fetch and extract
Step 4: Add storage to jail under /srv/TimeMachine
Step 5: Copy samba patches to /usr/ports/net/samba46/files

- patch-libcli__smb__smb2_create_ctx.h
- patch-source3__modules__vfs_fruit.c
- patch-source3__smbd__avahi_register.c
Step 6: Compile samba from ports with avahi support
cd /usr/ports/net/samba46
make install clean
Step 7: Copy config files (avahi and samba) to jail
Code:
/usr/local/etc/smb4.conf
/usr/local/etc/avahi/services/samba.service.app

Step 8: Create samba user
- adduser smb_user
- pdbedit -a smb_user
Step 9: Enable avahi and samba in /etc/rc.conf
Code:
dbus_enable="YES"
avahi_daemon_enable="YES"
avahi_dnsconfd_enable="YES"
samba_server_enable="YES"

Step 10: Start samba and configure Time Machine on the Mac
 

Attachments

  • TM_PATCHES.zip
    7.2 KB · Views: 267
Last edited:

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
What's keeping this from working on the base system?
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
What's keeping this from working on the base system?
Avahi dependency. Not sure if it works with mdnsresponder. Time Machine over SMB won't be in Samba until 4.8, which is probably a year out. I've been running this in a jail for a few weeks and it seems pretty stable. From a personal standpoint, I prefer doing it in a jail because it gives me the option of not using vfs_fruit on the base system.
 

Ericloewe

Server Wrangler
Moderator
Joined
Feb 15, 2014
Messages
20,194
Ok, let's see where that goes.
 

vbGvMWpXht4kEm

Dabbler
Joined
Oct 17, 2016
Messages
33
Followed these instructions, but can't seem to get the Mac to recognize the share.

Notes:
* FreeNAS-11.1-PRERELEASE
* The required version of Perl was missing, so sudo pkg install perl5-5.24.3
* Version of readline was outdated, so sudo pkg install readline
* I kept everything for Samba config the defaults except turning on Avahi
* Recursive dep configs were default
 

Robertr

Dabbler
Joined
Sep 22, 2017
Messages
31
It would be great if we could have a more detailed how-to with complete commands for us who are new to FreeNAS, Jails, SMB and all this stuff.
 
Status
Not open for further replies.
Top