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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
07-08-2004, 12:58 PM
|
#1
|
|
LQ Newbie
Registered: Jun 2004
Posts: 16
Rep:
|
Allowing ssh ftp through the firewall
I have a new install of RedHat 9.0 and I believe I blocked myself from being able to ssh and ftp to this new server. How do I reconfigure the firewall to allow ssh and ftp? During the setup I choose the middle setting for the firewall config. thanks
|
|
|
|
07-08-2004, 01:11 PM
|
#2
|
|
Member
Registered: Mar 2004
Location: Minnesota
Distribution: Fedora Core 1, Mandrake 10
Posts: 405
Rep:
|
Here you go...just do this...
# /sbin/iptables -A INPUT -j ACCEPT -m state --state NEW -p tcp --dport 22 --syn
do that as root, and it'll open up port 22, which is the port used for ssh/ftp.
Add the following line to /etc/sysconfig/network to stop the scripts from modifying your custom firewall:
FIREWALL_MODS=no
Finally you save your firewall configuration to /etc/sysconfig/iptables and enable it with:
# /sbin/service iptables save
# /sbin/chkconfig iptables on
Now you should be good to go...
Thanks go to LQ member hazza for this info...
Good luck!
|
|
|
|
07-08-2004, 01:26 PM
|
#3
|
|
LQ Newbie
Registered: Jun 2004
Posts: 16
Original Poster
Rep:
|
Everything seemed to go through but I am still unable to ssh or ftp. What else am I missing?
|
|
|
|
07-08-2004, 02:23 PM
|
#4
|
|
Member
Registered: Mar 2004
Location: Minnesota
Distribution: Fedora Core 1, Mandrake 10
Posts: 405
Rep:
|
Whatkind of response are you getting when you try? Is this just an authentication problem, or indeed related to the firewall?
Please post the response you get when trying to ssh into your machine...
|
|
|
|
07-08-2004, 02:30 PM
|
#5
|
|
LQ Newbie
Registered: Jun 2004
Posts: 16
Original Poster
Rep:
|
I get no response when I try to ftp or ssh. Just a timeout. I'm only assuming its a firewalll setting. I use lokkit but it never saves my settings and is always on the highest settting when I go back and check it.
|
|
|
|
07-08-2004, 02:42 PM
|
#6
|
|
Member
Registered: Mar 2004
Location: Minnesota
Distribution: Fedora Core 1, Mandrake 10
Posts: 405
Rep:
|
Are you behind a router? Also, are you sure sshd is running? you might want to try
/sbin/service sshd start
to make sure it's running. If you are behind a router, you'll need to forward port 22 from your router to the box running ssh.
Otherwise, I'm just about out of ideas...aside from checking /var/log/messages for info regarding this...
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 11:06 PM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|