1.Login to Server and run the following commands for key creation

mkdir /zabbix_key
openssl rand -hex 32 > /zabbix_key/secret.psk
chown zabbix:zabbix secret.psk

2.Edit Config File for zabbix agent
sudo nano /etc/zabbix/zabbix_agentd.conf
TLSConnect=psk
TLSAccept=psk
TLSPSKFile=/zabbix_key/secret.psk
TLSPSKIdentity=my_identity

3.Restart zabbix agent service
sudo service zabbix-agent restart

4.Login to Zabbix GUI and select Host> Encryption.
Set up PSK encryption and add PSK and Identifier