Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have tried to setup port forwarding from my zentyal server (port 5000) to my synology NAS (port 5000) too. Here is the result in terms of iptables rules :

Chain fredirects (1 references)
target     prot opt source               destination         
faccept    tcp  --               state NEW tcp dpt:5000
faccept    udp  --               state NEW udp dpt:5000

Now, when I try this with telnet from another server hosted somewhere else on the internet, telnet can't contact my server... any ideas ? How may I do other tests ?

share|improve this question

I don't know Zentyal, but from my understanding you want to forward requests that come from Internet to your NAS on port 5000.

Regarding your rules, you don't seem to forward public_ip:5000 to private_ip:5000.

I would do something like this :

iptables -t nat -A PREROUTING -d your.public.ip.address -p tcp –dport 5000 -j DNAT --to your.synology.nas.ip:5000

# Instead on the rule above, you could also filter on traffic coming to your External (Wan) interface :
iptables -t nat -A PREROUTING -i wan0 -p tcp –dport 5000 -j DNAT –-to your.synology.nas.ip:5000

# Finally allow traffic to your NAS :
iptables -A FORWARD -p tcp -d your.synology.nas.ip --dport 5000 -j ACCEPT

Also, i don't really know what means Chain fredirects in your case, but REDIRECT is a specific iptables target that redirects traffic to the host itself. In your case you don't want to redirect to the host itself but to your NAS.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.