LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Problems connecting to the internet (https://www.linuxquestions.org/questions/linux-networking-3/problems-connecting-to-the-internet-584775/)

Furlinastis 09-14-2007 11:43 PM

Problems connecting to the internet
 
Please skip to post 23 Thanks.

soroccoheaven 09-15-2007 04:16 AM

you have to enable ip forwarding.edit file sysctl.conf edit it something like that... ipv4_forward = 1

Furlinastis 09-15-2007 04:22 AM

Yea, I set that in dhcpd.conf ... Hmm, would dnsmasq do what I want?

soroccoheaven 09-15-2007 04:58 AM

you can not do this with dhcpd.conf pls search forum or google for linux as router.if i am not misunderstood you want your eth0 for internet access and as default gateway for your other eth's so if you are connecting hub/switch to eth1 this will work and if you are diretly connecting other pc's NIC use cross cable.

Furlinastis 09-15-2007 08:31 PM

The only tutorial I seem to be able to find for a linux router is this:

http://www.stanford.edu/~fenn/linux/

But that's way more complex than what I need. I don't need firewall or bind configuration. I have a domain name, but I can't use it because my internet connection is DHCP and I have no control over the router I'm connected to.

I did edit sysctl.conf but it still didn't work.

Another thing is, I can't ping my other machine by its name only with its IP address. I don't know if that has anything to do with the problem.

soroccoheaven 09-16-2007 01:40 AM

Quote:

I can't ping my other machine by its name only with its IP address. I don't know if that has anything to do with the problem.
include this in your /etc/hosts file with ip addres like ..
ip_address host_name
now you can ping
#ping host_name

Furlinastis 09-16-2007 01:51 AM

My hosts file is identical on both on my machines. Yet, on the comp in my sig can ping by hostname but this one can only ping by IP address.

I've tried a few different ways to configure resolv.conf, but I don't see what good adding DNS servers there if I can't see the internet from here.

Samba works fine, but I had to add the ip address to fstab to mount my shared folder. I don't know if that's normal or not, but smbmount will only mount shares if I specify the IP as well.

soroccoheaven 09-16-2007 02:27 AM

can you pls post little more about your connection setup so that we can understand it easily.

Furlinastis 09-16-2007 02:46 AM

Oh... I'm sorry.

I have two computers connected by a switch. The computer in my sig is connected to the internet on devices eth0 to a public wireless connection via a wireless bridge. I know the ISP is earthlink but I don't know anything else about it.

My gaming rigs specs are:
AMD Athlon 3800 dual core socket 939
MSI K8N Neo-F (one built in ethernet jack) Marvell 88E1111 PHY ethernet
http://www.msicomputer.com/product/p...eo4-F&class=mb
7950gt video card/auzentech xmeridian and turtle beach santa cruz sound card
2 80gb/1 250gb/1 150gb hard drives all western digital and SATA
plextor 712a dvdrw drive

If I'm missing something let me know. I'm not sure what config files to add?

soroccoheaven 09-16-2007 02:56 AM

ok...so all the machines are connected directly to switch ?..and how your switch connected to internet. using modem/dialup ?..dont mess all the things right now ..just let the connection up first after this everything
will be on the way ..

Furlinastis 09-16-2007 03:08 AM

My connection is up. I'm not sure what kind of connection it is, I assume its some sort of broadband as it is a public... I can't think of the name... like they have at a coffee shop or something. Just about everyone around here does that. I suppose one of these days I should get my own connection, I just don't have a decent choice that isn't ridiculously expensive.

My comp in my sig has two ethernet cards, and one is connected to a bridge which is connecting to the internet. The other card connects to the switch. And my gaming rig is also connected to the switch.

If I could configure squid to allow ALL internet traffic from my gaming rig would suit me. But I'm thinking that's impossible as I need to configure every app to use a proxy, and some apps just don't give me that option. Plus, setting up a proxy is kind of overkill just to connect to the net.

My question is really, what program/config file/etc do I need to configure to allow all internet traffic to flow my gaming rig through my comp in my sig?

soroccoheaven 09-16-2007 03:15 AM

ok ..is it like this

internet --->>office comp.(having two NIC )--->> eth0 (your main ofice compu) and eth1 connected to ---->>Switch and from switch ----->> game PC


so first of all know your IP/defaultgateway/dns/dhcp server(if needed)
try command ifconfig -a on office comp ..and post it

Furlinastis 09-16-2007 03:36 AM

I'm better visually, so it's hard for me to put it into words but here's crappy pic I drew in the gimp:

http://h1.ripway.com/xpyrate/setup.jpg

Code:

eth0      Link encap:Ethernet  HWaddr 00:0F:B5:F9:0E:14
          inet addr:192.168.1.100  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::20f:b5ff:fef9:e14/64 Scope:Link
          UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:51856 errors:0 dropped:0 overruns:0 frame:0
          TX packets:41394 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:64340441 (61.3 MiB)  TX bytes:5040802 (4.8 MiB)
          Interrupt:19

eth1      Link encap:Ethernet  HWaddr 00:14:6C:CB:66:2F
          inet addr:192.168.0.1  Bcast:192.168.14.255  Mask:255.255.255.0
          inet6 addr: fe80::214:6cff:fecb:662f/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:4500  Metric:1
          RX packets:84608 errors:0 dropped:0 overruns:0 frame:0
          TX packets:116787 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:12229355 (11.6 MiB)  TX bytes:136127015 (129.8 MiB)
          Interrupt:18 Base address:0x2000

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:71 errors:0 dropped:0 overruns:0 frame:0
          TX packets:71 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:8589 (8.3 KiB)  TX bytes:8589 (8.3 KiB)

I know the DNS servers but I only know the gateway(192.168.1.1) I have setup a subnet 192.168.0 for my internal needs.

soroccoheaven 09-16-2007 03:57 AM

run command ..

#iptables -t nat -A POSTROUTING -0 eth-0 -j MASQUERADE

archtoad6 09-16-2007 05:54 AM

Don't forget /proc/sys/net/ipv4/ip_forward:
Code:

echo 1 > /proc/sys/net/ipv4/ip_forward


All times are GMT -5. The time now is 11:55 AM.