Samba 4.9.x package support thread



Not for a normal user, the easiest way and prefered way to handle those cases is to setup a extroot:


thanks, looks too difficult. I'll give up then :slight_smile:


Hello Andy;

Do you have a port for your Samba 4.8 development?

I am running on a wrt1200AC that I am trying to setup as a Time Machine server, and I do not mind much if the USB drive needs to be reformatted or if the os needs to be reinstalled (as long as you do not brick it).

I also do not mind reinstalling Samba daily;
I do not have a server for compilation.

Let me know.


@rzighel Sure if you want to be the tester, i can compile a version for you. I have no mac so could never test if timemachine worked or whats missing. I found some guides and it seems i have to move some vfs modules around, since all guides use them by default: catia fruit streams_xattr.

Will upload a version later, do you need anything special for the firmware? I usually add adblock and sqm? I will use the 18.06 branch as basis, so you should be able to install official extra packages from there repo.


@rzighel ok here is the firmware with hopefully everything in place to test time machine and samba4.
BTW you need to run Sierra or High Sierra for this.

  1. Firmware:

  2. Flash guide:
    (OEM->Openwrt) if you are on stock firmware
    (Openwrt->Openwrt) after you have openwrt running for future updates

  3. Timemachine Guide:

Ok i have to fly blind here, so the first step is to pick a filesystem for your usb drive. My guess is that f2fs for flash device and ext2/4 or btrfs/xfs for disks should work the best. You can create those externally (livedisk) or have to use ssh/console, i included the mkfs.xy tools and fdisk/cfdisk.

I don't have support for custom share options in luci yet, so we cant add fruit:time machine = yes to the share options via luci (will try add this later).
So we don't create a share entry via luci and instead directly add a manual share to the smb template via luci (edit template).

So at the end you add (change the path to the openwrt mount and create the folders for the backup drive as you see fit):

    comment = Time Machine
    path = /data/backup/timemachine
    browseable = yes
    writeable = yes
    guest only = yes
    vfs objects = catia fruit streams_xattr
    fruit:time machine = yes

Optionally if read/write errors happens, you can try add this: (force full read/write access as root user):

   create mask = 0666
   directory mask = 0777
   force group = root
   force user = root

If this works you can create a smbuser and restrict access via smbpasswd etc.

Report back how far you got :stuck_out_tongue:

PS: Here is the documentation for the fruit module, if you want to play around with options:



I am sorry; I messed up. My router is a wrt1900ACv2, not a 1200.

I am running High Sierra.

Can you provide samba not on the wrt firmware?

Thank you.



I do not seem to be able to download the files. I see the directory, but I cannot act on it.


Need to recompile the fw than.

The google link is not working? There should be a download button at the top right for the zip, google just previews the content.


@rzighel oki new FW (wrt1900ACv2) is linked, build from the latest 18.06 release branch


Andy; I have two questions about Samba4 for you:

  • Did you hardcoded the name of the server? I have replaced openwork with my server name, Confusion in every place I can find it all over the machine. Time Machine will not accept the drive unless I name the server OpenWRT.

  • When trying to access a file with not enough permissions, instead of warning ‘no permission’ or something like that, the original finder window closes.

  • Raul


The name in finder/share section is defined via webui /system/system the hostname field.

Try with and without those settings, for your [timemachine] share:

create mask = 0666
directory mask = 0777
force group = root
force user = root
guest only = yes

Try also without this module:


Could you please share samba 4.8 ipk? My router is WRT1900ACS. Cannot flash the firmware you compiled.


To help me test Timemachine or just to run samba4?
If you are just looking for samba4, its now in the master aka grab snapshots here:


Thanks. I'll try to install the package.


Hello, I can't find this package when I look for available packages in the luci-app interface. The only package that shows up is the samba36-server. Is there any plan to merge samba4 in into the master package feed for WRT1900ACS?

Also, why is compiling new firmware needed for 4.8? Should we just need a new package that we can install native to 18.06?


It was merged into master 2 weeks ago, you probably run 18.06 not snapshot?

Was just merged into master very close to the 18.06 release, so i wanted some feedback from master/snapshot users first. I made sure to have related packages available in 18.06, so it compiles against it and yes i will try get this backported to 18.06. So in theory the snapshot packages should also run on 18.06, but i did not specifically test this.

PS: I'm also currently working on a easy to use docker based package-builder, which should make it very easy for everyone to build/rebuild specific packages for 18.06/snapshot. So you can get the latest changes via custom feeds or use custom build options, without having to dig deep into the openwrt sdk framework.

You can also give this online image builder a shot:


Yes correct, I am on 18.06. To get this package do I just need to add the custom feed?

I am more than able to test this especially if the package you build has Time Machine support since that's what I'll be mostly using it for. Let me know what feed I should add to test Time Machine on 18.06!


@Andy2244 Can you add samba hostplug support as samba36 did?


Is there a simple way to switch from your extra Repo to the integrated samba now?
wondering if your extra package will now bite the integrated samba4 setup


@yaravawiba I don't provide a feed with build packages for all targets. You can try use the snapshot builds for your target and manually install the package. Be aware that i have not yet enabled avahi support out of the box, so the snapshot versions wont announce samba to the mac-finder, yet the fruit (timemachine) module is available already. Maybe manual smb:/name will work?
If you give me your target/subtarget/version i can compile a samba4 package with avahi enabled for you, so you can try get timemachine running, by using the additional steps i posted a while ago.

@panda Sure, will add it to my list.

@johnnysl I think if you move to snapshots it should be automatic and i have no clue how to use the snapshot repos automatically for 18.06. You may be able to manually install the snapshots, they "should" be compatible with 18.06.

The idea is that i will try get this backported to 18.06 and i also try to get my package-builder ready.