SlackwareThis Forum is for the discussion of Slackware Linux.
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.
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.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello.
I have set up a Slackware 12 box as a web server, FTP, DNS, use some simple iptables rules. The problem is that if I have a SSH connection open, after some half hour, maybe hour, the SSH disconnects and I can't acces any of the web services on the server - no http, no ftp, nothing. It seems, that server just bans my IP and forbid any access. Nothing of that shows up in log files.
Then if I plug from wireless to wired, my IP changes and I can access the server again.
Maybe anybody have some ideas, what's wrong? Is it some anti-spam protection or what?
Sorry, if this is discussed before.
Thank you for any help.
try adding your IP to the hosts.allow file in /etc.
Other than that, try using fail2ban or denyhosts, they keep track of all the banning of most hacking attempts. That is what i used whn i had an SSH and FTP server running. i just left Iptables alone and the two programs filled it in for me.
If so, your ISP might not allow you to run servers of any sort unless you upgrade to a "business" type internet plan. It sucks, but that's the way it works...
If so, your ISP might not allow you to run servers of any sort unless you upgrade to a "business" type internet plan. It sucks, but that's the way it works...
If all the tests were done on the local network this shouldn't be a problem, though.
rkelsen> yes, it is a home based computer, but it is behind a NAT firewall (ports forwarded) and I am accessing the server from local network. SSH is not allowed to outside world.
My ISP allows to run servers.
shadowsnipes> my simple rules
Code:
#Firewal rules
iptables -F
iptables -P INPUT DROP
iptables -P FORWARD DROP
iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A INPUT -s 127.0.0.0/8 -d 127.0.0.0/8 -i lo -j ACCEPT
iptables -A INPUT -p icmp -j ACCEPT
iptables -A INPUT -p udp --dport 53 -j ACCEPT
iptables -A INPUT -p tcp --dport 20 -j ACCEPT
iptables -A INPUT -p tcp --dport 21 -j ACCEPT
iptables -A INPUT -p tcp --dport 22 -j ACCEPT
iptables -A INPUT -p tcp --dport 25 -j ACCEPT
iptables -A INPUT -p tcp --dport 53 -j ACCEPT
iptables -A INPUT -p tcp --dport 80 -j ACCEPT
iptables -A INPUT -p tcp --dport 110 -j ACCEPT
iptables -A INPUT -p tcp --dport 143 -j ACCEPT
iptables -A INPUT -p tcp --dport 443 -j ACCEPT
iptables -A INPUT -p tcp --dport 587 -j ACCEPT
iptables -A INPUT -p tcp --dport 3128 -j ACCEPT
iptables -A INPUT -p tcp --dport 8000 -j ACCEPT
iptables -A INPUT -p udp --dport 8000 -j ACCEPT
iptables -A INPUT -p tcp --dport 4081 -j ACCEPT
iptables -A INPUT -p tcp --dport 4001 -j ACCEPT
iptables -A INPUT -p tcp --dport 10000 -j ACCEPT
iptables -A INPUT -p tcp --dport 20000 -j ACCEPT
Anyway, the problem is not so big to me. I just thought, maybe someone had this same problem.
Then if I plug from wireless to wired, my IP changes and I can access the server again.
Wait a minute, do you still have access to a network or internet during this time? Sounds like an issue with your wireless connection losing connectivity, not your server. Is the server on wireless or wired?
Server is wired.
My laptop ir connected to wireless AP, which is connected to local network.
But I think this is not a Wireless problem, since internet/lan still works and if I restart the server, then I can access it again.
Last edited by AigarsABCD; 06-05-2008 at 03:46 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.