LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-03-2010, 02:30 AM   #1
hadimotamedi
Member
 
Registered: Aug 2009
Posts: 228

Rep: Reputation: 30
RedHat 9 how to open a port?


Dear All
On my RedHat 9 , I want to open tcp port 4965 but my server does not contain /etc/sysconfig/iptables . Can you please let me know how to open this port ?
Thank you
 
Old 03-03-2010, 03:13 AM   #2
leslieviljoen
LQ Newbie
 
Registered: Sep 2008
Posts: 10

Rep: Reputation: 1
First, are you sure you need to open the port on that machine? Make sure you are opening the port on whichever machine your firewall runs on - which is not guaranteed to be on the machine you are working on. Its often your gateway machine, which connects you to the Internet.

If you have the right machine, there are other ways that a firewall can be set up. You can search the whole /etc directory tree for mention of iptables:

su
cd /etc
grep -ir iptables *

If you want to see your current in-memory firewall setup:
su
iptables -L -v
 
Old 03-03-2010, 03:34 AM   #3
hadimotamedi
Member
 
Registered: Aug 2009
Posts: 228

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by leslieviljoen View Post
First, are you sure you need to open the port on that machine? Make sure you are opening the port on whichever machine your firewall runs on - which is not guaranteed to be on the machine you are working on. Its often your gateway machine, which connects you to the Internet.

If you have the right machine, there are other ways that a firewall can be set up. You can search the whole /etc directory tree for mention of iptables:

su
cd /etc
grep -ir iptables *

If you want to see your current in-memory firewall setup:
su
iptables -L -v

Thank you for your reply . But my server is returning as :
#iptables -L -v
Usage: /etc/rc.d/init.d/iptables {start|stop|restart|condrestart|status|panic|save}
Can you please let me know what is in-complete on my RedHat 9 server ?
 
Old 03-03-2010, 09:33 PM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,252

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
That's an incredibly old and unsupported/unpatched(!) distro.
http://en.wikipedia.org/wiki/Red_Hat_Linux

You have 2 options:
1. get an up to date distro eg Centos 5.4 (free version of RHEL 5.4)
http://en.wikipedia.org/wiki/Red_Hat_Enterprise_Linux
http://en.wikipedia.org/wiki/CentOS

2. read the man pages on your system ie

man iptables

and see what your options are

I seriously recommend option 1.
 
Old 03-04-2010, 07:37 AM   #5
leslieviljoen
LQ Newbie
 
Registered: Sep 2008
Posts: 10

Rep: Reputation: 1
For some strange reason your path seems to be directing you to the iptables script in /etc/init.d before it goes to the bin directory where the iptables binary is (try echo $PATH to see). On my system the iptables binary is at /sbin/iptables.

You can try /sbin/iptables -L -v, or if its not there, you can search your whole system for the iptables binary:

find / -iname iptables

...but you should probably take Chris' advice and upgrade.
 
Old 03-06-2010, 01:11 AM   #6
hadimotamedi
Member
 
Registered: Aug 2009
Posts: 228

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by chrism01 View Post
That's an incredibly old and unsupported/unpatched(!) distro.
http://en.wikipedia.org/wiki/Red_Hat_Linux

You have 2 options:
1. get an up to date distro eg Centos 5.4 (free version of RHEL 5.4)
http://en.wikipedia.org/wiki/Red_Hat_Enterprise_Linux
http://en.wikipedia.org/wiki/CentOS

2. read the man pages on your system ie

man iptables

and see what your options are

I seriously recommend option 1.

For the iptables , I made use of :
#/sbin/iptables
As there is another similar machine from third party that I have remote access to it , I compared them with :
#locate iptrans
And I found some missing packages on mine that I need to add.
Thank you for your help
 
Old 03-06-2010, 01:22 AM   #7
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
I am not sure about iptables. RH9 is very old and I have not seen it for years. There was ipchains then. You can use ipchains for the same purpose.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I open Rsync Port (873) in RedHat 9 farmerjoe Linux - General 2 10-12-2005 06:42 AM
cannot SFTP to SUSE 9.2 box, port 22 open, can putty in though using same port. jgrady Linux - Networking 6 03-29-2005 09:44 AM
How to open port 7025 on RedHat 9.0 klinton Linux - Networking 9 09-07-2004 06:21 PM
how to open a port in the firewall redhat bosewicht Linux - Newbie 2 12-01-2003 10:15 PM
How To Open Port 443 On RedHat 7.1 sc300t Linux - General 4 02-07-2002 10:40 AM


All times are GMT -5. The time now is 01:54 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration