1

On a ubuntu 10.0.4 server runs redmine. starting webrick with:

./server webrick -e production -b lvps46-173-79-113.dedicated.hosteurope.de -d

makes redmine available in browser. as soon as we enable ufw, webrick can´t be accessed anymore. of course we allowed Port 3000 from anywhere

ufw allow 3000/tcp
ufw allow 3000/udp

find the whole iptables output here http://pastebin.com/k6WNqdPU

checking

lsof -ni tcp:2222

tells me ruby is listening on port 3000

ruby    3457 root    5u  IPv4 864846667      0t0  TCP 46.173.79.113:3000 (LISTEN)

What else can we check? what´s wrong with the ufw rules for port 3000?

10
  • 1
    The iptables test you show is pretty much meaningless, not least because it completely overlooks the possible effects of a blanket DROP policy. If you could cut and paste the entire output of iptables -L -n -v into your question, we may be able to shed some light.
    – MadHatter
    May 28, 2014 at 14:25
  • Hi Mad thanks for this good idea, unfortunately it´s quite long is there are part which is of most interest?
    – Anatol
    May 28, 2014 at 14:27
  • Because iptables rules work on first-match-wins, no part is meaningful in isolation. As long as you paste it in and use SF's built-in formatting engine to declare it as a code sample, the site will box it with its own scrollbar, so you don't need to worry too much about the length.
    – MadHatter
    May 28, 2014 at 14:31
  • edited the question with iptables output ;)
    – Anatol
    May 28, 2014 at 14:34
  • It looks fine, and should be allowing inbound TCP to port 3000 and outbound responses. Can you confirm that there's no other firewall in front of this machine?
    – MadHatter
    May 28, 2014 at 15:01

1 Answer 1

1

Typically, ufw will block input that isn't specifically allowed. It sounds like you "allow 3000/tcp" isn't taking affect. Take a look at ufw's status with

ufw status verbose

Make sure it says "Status: Active" and note the default policy (typically "Default: deny (incoming), allow (outgoing)").

2
  • checked, also the order of the rules. any clue why else a rule can be ignored?
    – Anatol
    May 28, 2014 at 15:25
  • If ufw is "Active" but you don't see any rule in iptables then I would try reloading ufw. Also, check the ufw log in /var/log/ufw.log to see if that helps any.
    – imlepid
    May 28, 2014 at 16:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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