So lets install the dependencies ( I am running ubuntu server 2021 )
$ sudo apt install netatalk
$ sudo apt install avahi-deamon
( avahi-deamon not necessary for the netatalk 3.0 because it comes bundled, just a backup )
- Uncomment timemachine volume in Netatalk config file in /etc/netatalk/afp.conf
[My Time Machine Volume]
path = /home/nicoletti/tmbackup
time machine = yes
you can change the "My Time Machine Volume" name and the Path change for your server
create avahi configuration file:
$ sudo touch /etc/avahi/services/afpd.service
paste XML config into the file:
$ sudo nano /etc/avahi/services/afpd.service
XML
<?xml version="1.0" standalone='no'?><!--*-nxml-*-->
<!DOCTYPE service-group SYSTEM "avahi-service.dtd">
<service-group>
<name replace-wildcards="yes">%h</name>
<service>
<type>_afpovertcp._tcp</type>
<port>548</port>
</service>
<service>
<type>_device-info._tcp</type>
<port>0</port>
<txt-record>model=Xserve</txt-record>
</service>
</service-group>
Now lets reetart all services , and we are done !
$ sudo systemctl restart netatalk. service
$ sudo systemctl restart avahi-daemon.service