Results 1 to 6 of 6

Thread: How to open a port on Ubuntu Server 13.10

  1. #1
    Join Date
    Aug 2007
    Location
    UK
    Beans
    126

    How to open a port on Ubuntu Server 13.10

    I want to open port 8333, how do I do it? I tried this to list the rules, but nothing is there, so a bit confused. I normally use CentOS, so I'm a bit lost.
    Code:
    # iptables -L INPUT --line-numbers
    Chain INPUT (policy ACCEPT)
    num  target     prot opt source               destination

  2. #2
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: How to open a port on Ubuntu Server 13.10

    Code:
    iptables -A INPUT -p tcp --dport 8333 -j ACCEPT
    http://bodhizazen.net/Tutorials/iptables

    With that being said, it doesn't look like you have any firewall rules in place to block access to that port.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  3. #3
    Join Date
    Jan 2014
    Location
    Netherlands
    Beans
    188
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: How to open a port on Ubuntu Server 13.10

    Quote Originally Posted by CharlesA View Post
    Code:
    iptables -A INPUT -p tcp --dport 8333 -j ACCEPT
    http://bodhizazen.net/Tutorials/iptables

    With that being said, it doesn't look like you have any firewall rules in place to block access to that port.
    so i did iptables -A INPUT -p tcp --dport 21 -j [ enter]
    followd by service proftpd restart [ enter]

    question:
    is this permanent?
    i mean, i have my pc virtually allway's on, and want to sync to the nas using a schedule

    so after a reboot everything must work as before.

  4. #4
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: How to open a port on Ubuntu Server 13.10

    Unless you have a script that applies iptables rules after a reboot, the changes are only temporary.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

  5. #5
    Join Date
    Nov 2008
    Location
    Metro Boston
    Beans
    9,152
    Distro
    Kubuntu 14.04 Trusty Tahr

    Re: How to open a port on Ubuntu Server 13.10

    Quote Originally Posted by CharlesA View Post
    Unless you have a script that applies iptables rules after a reboot, the changes are only temporary.
    If you don't know where to put this script, I recommend placing it in /usr/local/sbin and executing it from /etc/rc.local with a line like

    Code:
    /usr/local/sbin/myfirewall
    Make sure myfirewall is executable by the root user.
    If you ask for help, please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  6. #6
    Join Date
    Oct 2009
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: How to open a port on Ubuntu Server 13.10

    Good idea.

    I have mine set up in /etc/interfaces/if-preup.d/ and call it from the /etc/networking/interfaces file.
    Come to #ubuntuforums! We have cookies! | Basic Ubuntu Security Guide

    Tomorrow's an illusion and yesterday's a dream, today is a solution...

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •