LinuxQuestions.org
Register a domain and help support LQ
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 04-01-2011, 11:10 AM   #1
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Rep: Reputation: 0
Where do I go from here?


Hi all,

I have installed Suse Linux Enterprise Server 11 onto the box that I am using as a server. Connected to the "server" is a Windows Vista PC.

Beyond installing the O/S with all the options I need - I am stuck. The Windows PC will not connect to the internet whereas the Linux server will.

What do I need to setup and in what order to get the pc working on the internet?

The path that I think I need to take is to disable dhcp on the broadband router and setup the server as dhcp (how and what); setup the rules in the firewall (how and what rules?) and setup dns and dhcp (how and what?)

Many thanx in advance for constructive answers.
 
Old 04-01-2011, 11:25 AM   #2
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Arch
Posts: 8,527

Rep: Reputation: 898Reputation: 898Reputation: 898Reputation: 898Reputation: 898Reputation: 898Reputation: 898
You need masquerading
Take a look at
http://opensuse.swerdna.org/suseics.html#suseserv

Kind regards
 
1 members found this post helpful.
Old 04-01-2011, 01:48 PM   #3
wpeckham
Senior Member
 
Registered: Apr 2010
Location: USA
Distribution: Debian, Ubuntu, Fedora, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, Vsido, tinycore, Q4OS
Posts: 1,650

Rep: Reputation: 569Reputation: 569Reputation: 569Reputation: 569Reputation: 569Reputation: 569
pc and server

What exactly do you mean by "connected to" in this context?
 
Old 04-01-2011, 06:05 PM   #4
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Where do i go from here?

The server is connected to the broadband router via a straight through rj45 cable. The windows vista pc is connected to the server via a crossover rj45 cable.

There are 3 rj45 cards in the server (1 onboad), 2 x pci.



Quote:
Originally Posted by wpeckham View Post
What exactly do you mean by "connected to" in this context?
 
Old 04-01-2011, 09:15 PM   #5
gorrillamcd
LQ Newbie
 
Registered: Apr 2011
Location: Mexico
Distribution: Ubuntu, Fedora
Posts: 17

Rep: Reputation: 3
IP-Forwarding

Well, I'm not sure if you've done it yet, but you need to enable kernel ip-forwarding. You can do that by editing your /etc/sysctl.conf file and adding/uncommenting the line net.ipv4.ip_forward=1

You'll also want the appropriate iptables rules for your setup, if they're needed. For instance, if you're doing a squid caching server, you'd want to forward port 80 to port 3128.

Last edited by gorrillamcd; 04-01-2011 at 09:17 PM. Reason: Grammar
 
Old 04-09-2011, 03:17 AM   #6
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Where Do I go from here (bald me thinks!)

Hi,

I have followed the instructions in the link. Makes sense after looking at that.

Just to recap: I am on sky broadband (hardwired username & password) with a Belkin router. Connected to the router via a straight through rj45 in the server and connected to the server via a crossover rj45 in a vista pc.

The most basic of basic task is that I am trying to get the broadband to work on the vista pc. The server has the internet. The vista pc runs Zonealarm as it's firewall and antivirus software and even disabling this does not actuate broadband on the vista pc.

Just a few queries:

1. I still cannot connect to the internet - I can connect to the server but as yet no internet service, but I can't ping the router. Windows Vista is showing that there is a connection from the server to the pc but not from the pc to the internet.

2. I am running sky broadband with a belkin router and can find no where in the router to change the dns server addresses - I am assuming you can't.

Any idea what the true dns server addresses are for sky - when I rang them said they were: 212.135.1.36 and 195.40.1.36

However the addresses I have been given from various sources are completely different from that, in fact very close to the addresses of the router.

3. Does the use dhcp server need to be unticked on the router and the server used as a dhcp server - and if so - what information does the router need?

4. I have set up an account with opendns and I have the dns addresses - so do they need to entered into the dns server areas of linux or do I need to enter the sky dns addresses into linux?

For something seemingly so simple - it appears that it is not.

5. Oh, and whatever I have done so far (follow those instructions and not much else) the internet on the server is now dog slow.
 
Old 04-09-2011, 04:28 AM   #7
Nermal
Member
 
Registered: Jan 2009
Distribution: Debian
Posts: 59
Blog Entries: 2

Rep: Reputation: 6
Might be your default route on the windows box.

if you do the following from the cmd prompt in windows:
Code:
netstat -rn
and post here I can tell.

What we need to do is walk through the network connection to find out where the problem is.

e.g.

Windows box IP 192.168.0.2/255.255.255.0
Linux box internal IP 192.168.0.1/255.255.255.0
Linux box external IP 192.168.2.10/255.255.255.0
Router internal IP address 192.168.2.1/255.255.255.0

You have stated that the Linux Box can see the internet. So we know that the DHCP has worked off the router.
The windows box can see the Linux box thus that bit is right.

If the windows box does not know where to send the off network packets then you need to add the Linux box Internal IP address as the default route on the windows box. Also you need to set the dns server address to the router on the windows box.

if you have done the two above and it is still not working then the problem will be in the iptables on the linux box.
 
1 members found this post helpful.
Old 04-09-2011, 05:35 AM   #8
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Where Do I go from here (bald me thinks!)

Hi,

Information from netstat -rn

ipv4 route table:

network dest netmask gateway interface

0.0.0.0 0.0.0.0 192.168.40.101 192.168.40.111
127.0.0.0 255.0.0.0 on-link 127.0.0.1
127.0.0.1 255.255.255.255 on-link 127.0.0.1
127.255.255.255 255.255.255.255 on-link 127.0.0.1
192.168.40.0 255.255.255.0 on-link 192.168.40.111
192.168.40.111 255.255.255.255 on-link 192.168.40.111
192.168.40.255 255.255.255.255 on-link 192.168.40.111
224.0.0.0 240.0.0.0 on-link 127.0.0.1
224.0.0.0 240.0.0.0 on-link 192.168.40.111
255.255.255.255 255.255.255.255 on-link 127.0.0.1
255.255.255.255 255.255.255.255 on-link 192.168.40.111

persistent routes:

net add: 0.0.0.0
netmask: 0.0.0.0
gateway add: 192.168.40.101

Hope this helps.



Quote:
Originally Posted by Nermal View Post
Might be your default route on the windows box.

if you do the following from the cmd prompt in windows:
Code:
netstat -rn
and post here I can tell.

What we need to do is walk through the network connection to find out where the problem is.

e.g.

Windows box IP 192.168.0.2/255.255.255.0
Linux box internal IP 192.168.0.1/255.255.255.0
Linux box external IP 192.168.2.10/255.255.255.0
Router internal IP address 192.168.2.1/255.255.255.0

You have stated that the Linux Box can see the internet. So we know that the DHCP has worked off the router.
The windows box can see the Linux box thus that bit is right.

If the windows box does not know where to send the off network packets then you need to add the Linux box Internal IP address as the default route on the windows box. Also you need to set the dns server address to the router on the windows box.

if you have done the two above and it is still not working then the problem will be in the iptables on the linux box.
 
Old 04-09-2011, 06:14 AM   #9
Nermal
Member
 
Registered: Jan 2009
Distribution: Debian
Posts: 59
Blog Entries: 2

Rep: Reputation: 6
so the internal ip address of your linux box is on 192.168.40.101 and your windows box IP is 192.168.40.111

that looks about right. How about the DNS settings in windows?

So into the linux box we must go...

Next task....

Lets see what shape your iptables is in:

Code:
iptables-save
and

Code:
cat /proc/sys/net/ipv4/ip_forward
Both off your Linux Box.
 
1 members found this post helpful.
Old 04-09-2011, 06:38 AM   #10
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Hi,

dns server are (windows):

90.207.238.97 and 90.207.238.99

ip forward is 1

When I run iptabels-save or iptables-save>test.log is says permission denied - must be logged on as root - which I am. Any ideas?

Regards


Quote:
Originally Posted by Nermal View Post
so the internal ip address of your linux box is on 192.168.40.101 and your windows box IP is 192.168.40.111

that looks about right. How about the DNS settings in windows?

So into the linux box we must go...

Next task....

Lets see what shape your iptables is in:

Code:
iptables-save
and

Code:
cat /proc/sys/net/ipv4/ip_forward
Both off your Linux Box.
 
Old 04-09-2011, 07:03 AM   #11
hks1233
Member
 
Registered: Nov 2010
Posts: 30

Rep: Reputation: 1
Linux machine :
Nc1:Ip for getting Net(eth0)
Nc2:192.168.40.101/24 (eth1)

Windows Vista
Nc1:192.168.40.111/24


For getting Internet in Linux set Iptables like this


iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A FORWARD -s 192.168.40.111/24 -j ACCEPT
iptables -A INPUT -j ACCEPT
iptables -A OUTPUT -j ACCEPT

Settings for Windows Vista
Gatway as 192.168.40.101
Dns:-8.8.8.8 (Global resolver)


Hope this will help you
 
1 members found this post helpful.
Old 04-09-2011, 09:47 AM   #12
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Where Do I go from here (bald me thinks!)

The vista pc is stating that it cannot connect with the primary dns server - which is why it can't get on the internet.

Where do I find in suse the dns addresses that suse is using to connect to the internet?

or am i going about the wrong way?


The blow section - I cannot add this - I am assuming that I enter this whilst using the gnome terminal?

If this is the case - then the commands do not work - what am i doing wrong?

For getting Internet in Linux set Iptables like this


iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A FORWARD -s 192.168.40.111/24 -j ACCEPT
iptables -A INPUT -j ACCEPT
iptables -A OUTPUT -j ACCEPT

Settings for Windows Vista
Gatway as 192.168.40.101
Dns:-8.8.8.8 (Global resolver)


Hope this will help you[/QUOTE]
 
Old 04-09-2011, 01:26 PM   #13
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Where Do I go from here (bald me thinks!)

Hi All,

I have just spoken to sky and after a long winded conversation with one so called tech support person I was passed to a supervisor who informed me that their dns server addresses are hardwired to their login ip address for their routers - namely 192.168.0.1

If that is the case - if you change that address does that mean that the dns will not work? I think not coz I have changed mine.

However, it does beg the question - would that affect static ip addresses from servers to windows pc - as is the case with my problem.

These sky router are a pain in the proverbial.

Anyway - thank you to everyone who has offered help today and don't stop please. I am going to try something later with this router - and will keep you posted.

Best Regards
 
Old 04-09-2011, 02:15 PM   #14
Nermal
Member
 
Registered: Jan 2009
Distribution: Debian
Posts: 59
Blog Entries: 2

Rep: Reputation: 6
Aye up,

Been out for a while,


Code:
cat /etc/resolv.conf
The DHCP will update this file with the DNS servers.
 
Old 04-11-2011, 07:54 PM   #15
futsysmids
LQ Newbie
 
Registered: May 2006
Location: Folkestone
Distribution: SLES
Posts: 19

Original Poster
Rep: Reputation: 0
Smile Where do I go from here - follow up

Hi All,

Thanks to everyone over the last few days.

I have cracked it and it was the most stupid of things as well.

The onboard rj45 connection is where the rj45 connection from the sky router comes into the server and a new pci rj45 network is what a crossover cable is connected to that connects the server to the windows box.

I had assumed that the onboard rj45 connector was eth0 and the pci was eth2 (eth1 is disconnected all the time) so I assigned eth0 as an external zone and eth2 as an internal zone. I set up the static ip's as suggested and got a sort of connection but then lost the internet connection on the server.

As soon as that happened I knew what the problem was and changed the internal and external zones around and the static ip's and now I have server internet and windows box internet.

Excellent.

So my next question is:

What do I do now?

What security do I need to install or setup and how do I go about adding the extra features to the server that I want?
 
  


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




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