windows – SMTP server not sending mail

I’ve acquired a Windows 2019 virtual server at work and have setup an SMTP server which is running and the FQDN is valid etc., all seems to be setup correctly according to a few guides I’ve followed.

I’ve tried to send an email by dropping it in the Pickup folder and it fails, where the .bdr just says

Unable to deliver this message because the follow error was encountered: “Error is processing file in pickup directory.”.

The specific error code was 0xC00402CE.

I tried sending a mail using powershell (where I think I just need to use localhost):

PS C:UsersMy.Account> Send-MailMessage -SMTPServer localhost -To -From -Subject "Email test" -Body "This is the test email from PowerShell"

But that fails:

Send-MailMessage : Unable to connect to the remote server`

I added an inbound rule in the firewall to let port 25 through but it did nothing yet when I try

Test-NetConnection -Port 25 -InformationLevel Detailed
WARNING: TCP connect to (xx : 25) failed

ComputerName            :
RemoteAddress           : ww.xx.yy.zz
RemotePort              : 25
NameResolutionResults   : ww.xx.yy.zz
MatchingIPsecRules      : 
NetworkIsolationContext : Internet
IsAdmin                 : False
InterfaceAlias          : Ethernet0 2
SourceAddress           : aaa.bbb.ccc.207
NetRoute (NextHop)      : aaa.bbb.ccc.1
PingSucceeded           : True
PingReplyDetails (RTT)  : 25 ms
TcpTestSucceeded        : False

But actually turns out the firewall isn’t even turned on! I think it may be controlled by AD group policy.

I’m just not sure where to get details on why it can’t connect?

It’s not even sending bad mail notifications to my nominated address.