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.
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.
|
 |
01-21-2004, 09:15 PM
|
#1
|
Member
Registered: Jan 2004
Location: Canada
Posts: 68
Rep:
|
restoring iptables-restore
i saved my iptables settings using /sbin/service iptables save.. and now i have a 'failed' come up on boot up in regards to iptables..
my internet works fine as i have my ipforwarding and firewall stuff saved in another start up file.. but i would like to get rid of the settings in iptables-restore.. just to make sure it won't screw things up later..
also how do you update your search file database.. as i've added a number of new files and i'd like to be able to find them when i search for them.. i know there's a thread about this somewhere.. but i couldn't find it..
thanks..
|
|
|
01-22-2004, 04:18 AM
|
#2
|
Member
Registered: Sep 2003
Location: France
Distribution: RedHat
Posts: 58
Rep:
|
Re: restoring iptables-restore
Quote:
Originally posted by Zaius
i saved my iptables settings using /sbin/service iptables save.. and now i have a 'failed' come up on boot up in regards to iptables..
my internet works fine as i have my ipforwarding and firewall stuff saved in another start up file.. but i would like to get rid of the settings in iptables-restore.. just to make sure it won't screw things up later..
|
the service in /etc/init.d/iptables looks for the file /etc/sysconfig/iptables
this file is a iptables-save file, you can create it and replace it at will.
if this file doesn't exist then the service will not start. This way you can start your own service that loads your rules from another script file.
Quote:
Originally posted by Zaius
also how do you update your search file database.. as i've added a number of new files and i'd like to be able to find them when i search for them.. i know there's a thread about this somewhere.. but i couldn't find it..
|
updatedb will update the files locate database...
when you work at night and sudenly you start to ear your hard disk spinning like crazy, if you look for the running processes with 'top' you'll see updatedb at the top!
|
|
|
01-22-2004, 10:29 AM
|
#3
|
LQ Newbie
Registered: Jan 2004
Location: CT
Distribution: Servers: Debian, RH8, Laptop: Fedora
Posts: 15
Rep:
|
Re: Re: restoring iptables-restore
Quote:
Originally posted by pedro_nf
the service in /etc/init.d/iptables looks for the file /etc/sysconfig/iptables
this file is a iptables-save file, you can create it and replace it at will.
if this file doesn't exist then the service will not start. This way you can start your own service that loads your rules from another script file.
|
To keep the script from running (so you don't get the failed message) you can always remove the executable permission on the iptables script in /etc/init.d
ex - chmod 644 /etc/init.d/iptables
|
|
|
01-22-2004, 10:48 AM
|
#4
|
Member
Registered: Sep 2003
Location: France
Distribution: RedHat
Posts: 58
Rep:
|
Re: Re: Re: restoring iptables-restore
Quote:
Originally posted by slapshotct
To keep the script from running (so you don't get the failed message) you can always remove the executable permission on the iptables script in /etc/init.d
ex - chmod 644 /etc/init.d/iptables
|
... well, thats can lead to problems later, when you want it to run and don't remmember to change its permissions...
I'd prefer to delete the file /etc/sysconfig/iptables, if this data file doesn't exist the service /etc/init.d/iptables doesn't start. You can check this by looking at the /etc/init.d/iptables script, at the top it checks for the /etc/sysconfig/iptables file.
|
|
|
01-22-2004, 11:34 AM
|
#5
|
LQ Newbie
Registered: Jan 2004
Location: CT
Distribution: Servers: Debian, RH8, Laptop: Fedora
Posts: 15
Rep:
|
Re: Re: Re: Re: restoring iptables-restore
Quote:
Originally posted by pedro_nf
... well, thats can lead to problems later, when you want it to run and don't remmember to change its permissions...
I'd prefer to delete the file /etc/sysconfig/iptables, if this data file doesn't exist the service /etc/init.d/iptables doesn't start. You can check this by looking at the /etc/init.d/iptables script, at the top it checks for the /etc/sysconfig/iptables file.
|
That is definitely something to consider for a newbie. For me, I run Linux on my laptop and am constantly 'showing off' Linux to Windows clients and collegues. The last thing I would want them to see is a [FAILED] message. 
|
|
|
01-22-2004, 11:40 AM
|
#6
|
Member
Registered: Sep 2003
Location: France
Distribution: RedHat
Posts: 58
Rep:
|
Re: Re: Re: Re: Re: restoring iptables-restore
Quote:
Originally posted by slapshotct
That is definitely something to consider for a newbie. For me, I run Linux on my laptop and am constantly 'showing off' Linux to Windows clients and collegues. The last thing I would want them to see is a [FAILED] message.
|
 yep, we all must do good publicity of linux!
|
|
|
01-22-2004, 12:03 PM
|
#7
|
Member
Registered: Jan 2004
Location: Canada
Posts: 68
Original Poster
Rep:
|
sweet. thanks a lot.. the updatedb ran at some point as it finds all the new things i installed... but it's good to know how to it when i want to..
i mv the iptables.save file.. and i will see if the error comes up next time i reboot.. if the fail message comes up again. i will try you other solutions..
thanks 
|
|
|
01-22-2004, 12:55 PM
|
#8
|
Member
Registered: Sep 2003
Location: France
Distribution: RedHat
Posts: 58
Rep:
|
Quote:
Originally posted by Zaius
sweet. thanks a lot.. the updatedb ran at some point as it finds all the new things i installed... but it's good to know how to it when i want to..
|
If you have a big disk the updatedb can take long time. The best is to run it often via cron in the periods you are not using your PC (at noon, at night...)
Quote:
Originally posted by Zaius
i mv the iptables.save file.. and i will see if the error comes up next time i reboot.. if the fail message comes up again. i will try you other solutions..
thanks [/B]
|
Normaly if you don't have /etc/sysconfig/iptables you don't have any message at all from the /etc/init.d/iptables service. My current gateway to the internet (at home) is a linux RH and I disabled the default firewall service this way, I already had an older scripts with all my stuff inside.
Greets
Pedro
|
|
|
All times are GMT -5. The time now is 03:11 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
|
|