LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 09-30-2009, 02:32 AM   #1
svar0g
LQ Newbie
 
Registered: Sep 2009
Posts: 3

Rep: Reputation: 0
Question config iptables in Slacware 13


Subj,I ask to tell where it is? In default places nothing
 
Old 09-30-2009, 02:43 AM   #2
foodown
Member
 
Registered: Jun 2009
Location: Texas
Distribution: Slackware
Posts: 611

Rep: Reputation: 219Reputation: 219Reputation: 219
The easiest way that I know of is to insert your calls to iptables into the /etc/rc.d/rc.local script. (Or, really, any startup script . . . rc.local is just good since it is for local configuration options.
 
Old 09-30-2009, 02:43 AM   #3
kakaka
Member
 
Registered: Sep 2003
Posts: 382

Rep: Reputation: 87
Are you asking in what directory the iptables command can be found?
 
Old 09-30-2009, 02:47 AM   #4
svar0g
LQ Newbie
 
Registered: Sep 2009
Posts: 3

Original Poster
Rep: Reputation: 0
foodown thanks,
kakaka after restart I think customisations which wrote in console are deleted
 
Old 09-30-2009, 03:13 AM   #5
lutusp
Member
 
Registered: Sep 2009
Distribution: Fedora
Posts: 835

Rep: Reputation: 102Reputation: 102
Quote:
Originally Posted by svar0g View Post
Subj,I ask to tell where it is? In default places nothing
I don't know about Slackware, but on Fedora the iptables file is located at /etc/sysconfig/iptables.

You can always try:

Code:
# find /etc -name "iptables"
 
Old 09-30-2009, 03:21 AM   #6
foodown
Member
 
Registered: Jun 2009
Location: Texas
Distribution: Slackware
Posts: 611

Rep: Reputation: 219Reputation: 219Reputation: 219
Quote:
Originally Posted by kakaka View Post
Are you asking in what directory the iptables command can be found?
Usually it is located at /usr/sbin/iptables

Be sure to invoke it with its absolute path for each rule that you add.
 
Old 09-30-2009, 05:10 AM   #7
svar0g
LQ Newbie
 
Registered: Sep 2009
Posts: 3

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by lutusp View Post
I don't know about Slackware, but on Fedora the iptables file is located at /etc/sysconfig/iptables.

You can always try:

Code:
# find /etc -name "iptables"

nothing

Quote:
Be sure to invoke it with its absolute path for each rule that you add.
And there is a difference?
 
Old 09-30-2009, 08:50 PM   #8
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,241

Rep: Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325Reputation: 2325
The cfdg file is probably under /etc
Code:
find /etc -name '*iptables*' -print 2>/dev/null
note the single quotes to ensure that only 'find' sees the wildcards, not the shell.
If not found, try searching the entire drive space ie
Code:
find / -name '*iptables*' -print 2>/dev/null
as root user in both cases.
 
Old 09-30-2009, 11:37 PM   #9
Berhanie
Senior Member
 
Registered: Dec 2003
Location: phnom penh
Distribution: Fedora
Posts: 1,625

Rep: Reputation: 165Reputation: 165
This is from /etc/rc.d/rc.inet2:
Code:
...
# If there is a firewall script, run it before enabling packet forwarding.
# See the HOWTOs on http://www.netfilter.org/ for documentation on
# setting up a firewall or NAT on Linux.  In some cases this might need to
# be moved past the section below dealing with IP packet forwarding.
if [ -x /etc/rc.d/rc.firewall ]; then
  /etc/rc.d/rc.firewall start
fi
So, as you can see, the firewall rules in Slackware go in rc.firewall.
 
  


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
iptables config not working creapet Linux - Security 10 02-02-2009 07:59 PM
iptables config - what do you think? OTIM Linux - Security 4 01-22-2008 02:56 PM
Where is iptables config file satimis Ubuntu 4 09-12-2007 11:25 PM
iptables config ? ryanjliles Linux - Networking 2 09-01-2005 05:45 AM
iptables config - RTT Linux - Security 2 01-10-2004 03:40 PM


All times are GMT -5. The time now is 08:18 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