Networking Forums

Networking Forums > Computer Networking > Linux Networking > Firestarter on Fedora

Reply
Thread Tools Display Modes

Firestarter on Fedora

 
 
ChrisW
Guest
Posts: n/a

 
      11-25-2007, 04:43 PM
Hi,

I hope this is the correct place to post this... (and apologies if I
get any teminology wrong, I'm still a relatively newbie with Linux
admin).

I've got the following setup:

Internet connection -> wireless router (192.168.0.1) -> Fedora (eth0)
(DHCP / 192.168.0.3) -> Fedora (eth1) (192.168.0.100)-> Switch -> ~10
Windows computers (192.168.0.101-110)

I want to share the internet between all 10 Windows computers, and
after trying to understand iptables, realised Firestarter should do
all the hardwork for me! I've downloaded and installed it, but I still
have problems. The most obvious problems are
- after installing Firestarter, I can't get any of the Windows
computers to recognise the internet (whether using static or dynamic
IP addresses)
- even though I've run the Firestarter internet sharing wizard (using
the DHCP options), I get a message saying

"Failed to start the firewall

An unknown error occurred

Please check your network device settings and make sure your internet
connection is active"

My internet connection is active (I'm using it to write this!).

If I deactivate eth1 then I don't get the error message. When I
restart the network (/etc/init.d/network restart) I get the following:

--------

Shutting down interface eth0: Firewall started
Failed to start DHCP server
[ OK ]
Shutting down interface eth1: [ OK ]
Shutting down loopback interface: [ OK ]
Disabling IPv4 packet forwarding: net.ipv4.ip_forward = 0
[ OK ]
SIOCGIFFLAGS: No such device
Bringing up loopback interface: [ OK ]
Bringing up interface eth0:
Determining IP information for eth0...External network device eth0 is
not ready. Aborting..
Internal network device eth1 is not ready. Aborting..
done.
[ OK ]
Bringing up interface eth1: [ OK ]
--------

When I run ifconfig -a, for eth1, it gives the inet addr as
192.168.1.100 (*not* 192.168.0.100) - is this something that could be
causing a problem? I can post the full results of ipconfig and route -
n if it's helpful. I also hope to run Samba eventually - is this
something I should take into consideration at this stage?

If anyone can answer any of my problems I'd be most grateful!

Thanks,
Chris
 
Reply With Quote
 
 
 
 
Ashish Shukla आशीष शुक्ल
Guest
Posts: n/a

 
      11-26-2007, 08:12 AM
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

ChrisW wrote:
> Hi,
>
> I hope this is the correct place to post this... (and apologies if I
> get any teminology wrong, I'm still a relatively newbie with Linux
> admin).
>
> I've got the following setup:
>
> Internet connection -> wireless router (192.168.0.1) -> Fedora (eth0)
> (DHCP / 192.168.0.3) -> Fedora (eth1) (192.168.0.100)-> Switch -> ~10
> Windows computers (192.168.0.101-110)


I've not used Firestarter.

You've not indicated any network masks, so I'm assuming they're /24. Is
there any specific reason you chose eth0 and eth1 of your Fedora box to be
of same network.

If you put your 'eth1' and your Windows boxen in different network
than 'eth0', you can setup internet connection sharing very easily.

Edit '/etc/sysctl.conf' and set 'net.ipv4.ip_forward' equals to '1'. This
will enable IPv4 packet forwarding between your interfaces. Now you need to
enable masquerading, to do this simply execute:

root# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

Now try accessing internet from your other Windows box, if it works, you
need to save this firewall configuration, execute:

root# iptables-save >/etc/sysconfig/iptables

Above command will also overwrite your existing firewall rules. So it is
better to first create a desired firewall, using 'iptables' command, and
then save all rules at once using 'iptables-save'.

HTH
- --
Ashish Shukla आशीष शुक्ल http://wahjava.wordpress.com/
·-- ·- ···· ·--- ·- ···- ·- ·--·-· --· -- ·- ·· ·-·· ·-·-·- -·-· --- --
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHSo4JHy+EEHYuXnQRAo4kAJ9RKhYVETcdWKiWhk47c5 HJ1MpNDQCeMpH5
qu9ygfbOjgZfcJKI/bKv8Rs=
=SGgn
-----END PGP SIGNATURE-----
 
Reply With Quote
 
ChrisW
Guest
Posts: n/a

 
      11-26-2007, 12:49 PM
> You've not indicated any network masks, so I'm assuming they're /24. Is
> there any specific reason you chose eth0 and eth1 of your Fedora box to be
> of same network.


Would it be correct then to have eth0 as 192.168.0.3 and eth1 as
192.168.1.100, and the Windows computers as 192.168.1.101-110?

> If you put your 'eth1' and your Windows boxen in different network
> than 'eth0', you can setup internet connection sharing very easily.
>
> Edit '/etc/sysctl.conf' and set 'net.ipv4.ip_forward' equals to '1'. This
> will enable IPv4 packet forwarding between your interfaces. Now you need to
> enable masquerading, to do this simply execute:
>
> root# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
>
> Now try accessing internet from your other Windows box, if it works, you
> need to save this firewall configuration, execute:
>
> root# iptables-save >/etc/sysconfig/iptables
>
> Above command will also overwrite your existing firewall rules. So it is
> better to first create a desired firewall, using 'iptables' command, and
> then save all rules at once using 'iptables-save'.
>


Thanks, I'll have a go (presumably this should "just work" if my
assumption about different networks (see above) is correct...?)

Chris

 
Reply With Quote
 
Ashish Shukla आशीष शुक्ल
Guest
Posts: n/a

 
      11-26-2007, 05:18 PM
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

,--- ChrisW writes:

[...]

| Would it be correct then to have eth0 as 192.168.0.3 and eth1 as
| 192.168.1.100, and the Windows computers as 192.168.1.101-110?

It'll be correct, but make sure network mask of both interfaces are
255.255.255.0 .

HTH
- --
Ashish Shukla आशीष शुक्ल http://wahjava.wordpress.com/
·-- ·- ···· ·--- ·- ···- ·- ·--·-· --· -- ·- ·· ·-·· ·-·-·- -·-· --- --
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHSw4DHy+EEHYuXnQRAoK2AKDu6CUT7Vh3dnFgP4E4nr yZMUz7dQCfWcOj
iY1V6PkPA2mTn6knRaFHfvI=
=GJbM
-----END PGP SIGNATURE-----
 
Reply With Quote
 
ChrisW
Guest
Posts: n/a

 
      11-29-2007, 02:37 PM
>
> | Would it be correct then to have eth0 as 192.168.0.3 and eth1 as
> | 192.168.1.100, and the Windows computers as 192.168.1.101-110?
>
> It'll be correct, but make sure network mask of both interfaces are
> 255.255.255.0 .


Thanks very much, this works! (After I worked out I had to supply
Windows with an appropriate DNS server as well). It only worked after
restarting Fedora, not just restarting the network service.. is there
any reason for this?

Chris
 
Reply With Quote
 
Ashish Shukla आशीष शुक्ल
Guest
Posts: n/a

 
      12-01-2007, 03:46 PM
ChrisW wrote:

>>
>> | Would it be correct then to have eth0 as 192.168.0.3 and eth1 as
>> | 192.168.1.100, and the Windows computers as 192.168.1.101-110?
>>
>> It'll be correct, but make sure network mask of both interfaces are
>> 255.255.255.0 .

>
> Thanks very much, this works! (After I worked out I had to supply
> Windows with an appropriate DNS server as well). It only worked after
> restarting Fedora, not just restarting the network service.. is there
> any reason for this?


That's probably due to the fact that sysctl 'net.ipv4.ip_forward' is not set
to 1 which is required for packet forwarding between IPv4 interfaces. You
just set the entry in '/etc/sysctl.conf' and entries
from '/etc/sysctl.conf' are read and executed the time of bootup.

If you want that to be immediately effective, you could try:

root# sysctl net.ipv4.ip_forward=1

Sorry I forgot to mention this.

>
> Chris


HTH
--
Ashish Shukla आशीष शुक्ल http://wahjava.wordpress.com/
·-- ·- ···· ·--- ·- ···- ·- ·--·-· --· -- ·- ·· ·-·· ·-·-·- -·-· --- --
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Virtualbox, host networking and firestarter problem Boris Linux Networking 0 11-07-2008 04:12 PM
firestarter problem Nikola Skoric Linux Networking 4 09-23-2007 06:11 PM
Close telnet with firestarter? Johan Linux Networking 1 12-04-2006 07:07 PM
firestarter question, NAT at boot time? Ohmster Linux Networking 5 05-14-2005 12:00 AM
firestarter on FC3/kernel-2.6.9-1.681 Bob Tennent Linux Networking 0 12-05-2004 11:22 AM



1 2 3 4 5 6 7 8 9 10 11