LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-20-2004, 03:53 AM   #61
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15

finally found somebody on msn to help ...

the solution is very simple (ofcourse, I never doubted that)
After figuring and solving a mysterious hardware problem,
it all came down to this:

just 2 command lines in linux

echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -s 192.168.0.0/16 -j MASQUERADE


on the windows side (and this you all forgot to explain me folks)
network properties
ip address 192.168.0.2
Subnet mask 255.255.255.0
Default gateway: 192.168.0.1

Preferred DNS Server: ip adres found in /etc/resolv.conf (using cable)

and ...
if ping doesn't work, it's a hardware problem or the linux install just screwed up ...

One problem remains:
iptables-save
has a nice output, but I loose the settings after reboot anyway.
What to do so linux saves these 2 lines settings ?
 
Old 08-21-2004, 09:18 PM   #62
J[]sie
LQ Newbie
 
Registered: Aug 2004
Posts: 22

Rep: Reputation: 15
its funny but i'm having the same problem....
It sounds like you have a simular setup, so that I can get myself closer to your understanding.. hehe
Hows ur machines setup?
example, heres how mine are setup:
I have 4 boxes 1 usr dsl router and 1 sprint dsl modem
the router is linked to the dsl modem, and the router doubles as my network hub with four ports... I have my 3 windows98se machines connected to hub ports 1 through 3, and on port 4 i have my linux box(mandrake 10 with kde gui installed) The network configurations for all 3 98se machines are setup as follows
network components installed:
microsoft fam login
file and printer sharing for microsoft networks
network adapter (varies from machine to machine) ie on this machine: 'intel pro/100 ve network connection'
Protocol: tcp/ip network (also varies from machine to machine) ie on this machine: 'intel pro/100 ve network connection'
primary network logon: windows logon

Settings for the Protocol: tcp/ip are as follows:

bindings tab: 3 checks beside: client for microsoft networks, file and printer sharing for microsoft networks, microsoft family logon

DNS configuration tab: Disable DNS checked

Gateway tab: no gateways added

wins configuration tab: disable wins resolution checked

IP address tab: Obtain an ip address automatically checked

Runing the command winipcfg and clicking on more info to show a full view presents me with this information about my ips' addresses and settings:

Host Information
host name: xxxxx
DNS Servers: 192.168.xxx.xxx
Node Type: Broadcast
netbios: blank
ip routing: blank
netbios resol. dns: blank

Ethernet adapter information

PPP Adapter selected in drop down menu:

adapter address xx-xx-xx-xx-xx-xx
ip address 0.0.0.0
subnet mask 0.0.0.0
default gate. blank
dhcp server 255.255.255.255
primary wins server blank
secondary wins s. blank
lease obtained blank
lease expires blank

(my adapter which varies machine to machine) selected in drop down menu:

adapter address xx-xx-xx-xx-xx-xx
ip address 192.168.xxx.xxx
subnet mask 255.255.255.0
default gate. 192.168.xxx.xxx <-- these two ip addresses are the same for both default gateway and dhcp server.
dhcp server 192.168.xxx.xxx <---^^
primary wins server blank
secondary wins s. blank
lease obtained (a date and time)
lease expires (a date and time)

Now here's what i've found out runing linux mandrake 10 with kde gui on my 4th machine
the network card installed on my linux box is one 3com 3c590 tx corporate which uses the 3c59x module (driver). The card is recognized by mandrake with no problems, ie, mandrake identifies it during installation. I configure via the option during the installation. You are presented with about 6 options,
I chose to configure LAN.
>>eth0: 3com corporation|3c590 10baseT [vortex]
>>Manual configuration: Here are the options i'm presented with
IP address:
Netmask:
Track network card id:
Network Hotplugging:
Start at boot:

basically from here on I copy my ip addresses from my present windows98se machine like this with exception to the actual IP for the network card which is labeled 'IP address' in this case. so in other words my 3 windows machines from hub port 1 to 3 have simular ips to this example

98se machine 1: 192.168.50.50
98se machine 2: 192.168.50.51
98se machine 3: 192.168.50.52
so i set up machine 4 on hub port 4 with an ip like this: 192.168.50.53
So...

IP address: 192.168.xxx.xx3
Netmask: 255.255.255.0 <-- I'm guessing this is subnetmask? in windows
Track network card id: unchecked
Network Hotplugging: checked
Start at boot: checked
I click next and here is whats shown and how I have it configured:
Hostname: blank
DNS server 1: 192.168.xxx.xxx <--same dns ip as host information on 98se machines.
dns 2 and 3 are left blank
Search domain: blank
Gateway: 193.168.xxx.xxx <--same as dns server

I click next and then...:

zeroconf host name: 'name of my host' ie: peguin
I am not sure what this is, but I think its the same thing that windows uses to name your computer when you are on a file sharing network.
then i click next and finish, it seems happy but
I try to browse the network.. and nothing works, nore can I view web pages accross the internet.
here's how you browse your local network if you don't know:
in KDE gui you open konqueror and in the location text box you type 'smb:/'
This will browse your local network, if working it will show your windows work group that you've named, and you can continue in by clicking the icon and so on so forth.
although nothing seems to work... I was able to browse the network if I do the following:
open console
type su (switches users)
console prompts for my password, i type in my ROOT password, you can't do this with out logging into root.
then I type:
ifconfig eth0
it displays some information about my ethernet card but no ip addresses are listed, i'm guessing this is because it failed initialization during startup as i'm sure urs is doing right?
ie: Bringing up eth0 [Failed]
so, I type:

ifconfig eth0 192.168.xxx.xx3 broadcast 192.168.xxx.xxx

192.168.xxx.xx3 <--this is the ip I tried to set earlier that for somereason doesn't take I guess I dunno.

broadcast 192.168.xxx.xxx <-- this is the ip for my DNS as i also tried to set with the configuration tool

and I open KDE's Konqueror
type smb:/ in the text box and bam i can browse the network... when i restart the network with the command 'service network restart' I lose the changes and I can no longer browse the network. Same thing when i restart the computer or session... It does not save changes... Now here is one last interesting thing...
I don't know what this all means but I do understand that linux assigns devices and such id's like eth0 for your first ethernet card and so on. so anyway when I have a fresh install and i have NOT opened the configuration editor for the network, and I do make changes using the console like I just said, and I am able to browse the network as said, I get the following feed back from this command in the console logged in as root keep in mind this is before I open any configuration tool for the network, this is a fresh install and after the following commands in console:

[root@localhost xxxxx]# ifconfig eth0 192.168.xxx.xx3 broadcast 192.168.xxx.xxx
[root@localhost xxxxx]# ifconfig
eth0 Link encap:Ethernet HWaddr xx:xx:xx:xx:xx:xx
inet addr:192.168.xxx.xx3 Bcast:192.168.xxx.xxx Mask:255.255.255.0
inet6 addr: xxxx::xxx:xxxx:xxxx:xx/xx Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:603 errors:0 dropped:0 overruns:0 frame:0
TX packets:90 errors:0 dropped:0 overruns:0 carrier:1
collisions:0 txqueuelen:1000
RX bytes:182148 (177.8 Kb) TX bytes:8728 (8.5 Kb)
Interrupt:3 Base address:0x1020

[root@localhost xxxxx]#

I am able to browse the network, but restarting the machine or network or session negates all changes. Notice, there is only one device listed.... eth0 <-- this is the device
Now I open the configuration tools and edit away.. and I do this command again logged in as root in console:

[root@localhost xxxxx]# ifconfig
eth0 Link encap:Ethernet HWaddr xx:xx:xx:xx:xx:xx
inet6 addr: xxxx::xxx:xxxx:xxxx:xx/xx Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:601 errors:0 dropped:0 overruns:0 frame:0
TX packets:90 errors:0 dropped:0 overruns:0 carrier:1
collisions:0 txqueuelen:1000
RX bytes:182028 (177.7 Kb) TX bytes:8728 (8.5 Kb)
Interrupt:3 Base address:0x1020

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:194 errors:0 dropped:0 overruns:0 frame:0
TX packets:194 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:12588 (12.2 Kb) TX bytes:12588 (12.2 Kb)

Notice, after opening the configuration tools going through the motions a new device is created... I don't know why this is or why it didn't not edit the eth0 device, again I don't even know if this matters, but it seems to me something isn't working right because in eth0 my addresses are wiped out again, and in lo, which i have a feeling stands for local has an address of 127.0.0.1 and netmask of 255.0.0.0 which i've noticed on other post having the same problems as us

so.. there you have it, i don't know if any of this information will help you or the people trying to help you, but hopefully it can provide some insight into both our problems, I've been messing with this now for a week and I dunno what to think, I'm pretty sure if I just switch linux distros or even put another nic card in, the prob would probably go away, but I wanna know what the heck is going on, and how to configure this for my own knowlegde..

good luck
and if any one has solved this or can help me please contact me via yahoo messenger
i will post the context of chat for future references

yahoo id: conan78va

Thanks

[ ]
 
Old 08-21-2004, 09:36 PM   #63
J[]sie
LQ Newbie
 
Registered: Aug 2004
Posts: 22

Rep: Reputation: 15
one more thing,
these two commands don't work for me:
in the console logged in as root:

lspci
iptables

anyone know why??

what shell are you in? bash? arch? sh? csh? what?

-
 
Old 08-22-2004, 12:16 AM   #64
J[]sie
LQ Newbie
 
Registered: Aug 2004
Posts: 22

Rep: Reputation: 15
I just solved all my problems and possibly all of yours pelgrim. It has a little something to do with a function called 'hot plugging' which I really don't understand the purpose of. But if your still lost and you are willing to give it a shot here is what you should do:
set your win98se machines back to obtaining an ip automatically, if you do have a dsl/cable router/ network hub in one. This should make your life easier when setting up your network.
Do a fresh install of linux mandrak 10 so you don't have any lingering settings.
during the installation, if you configure your devices there, just leave the network alone for now, until your gui is up and running, I hope you use KDE for your default gui?
Once Loaded, in KDE, click on:
Main Menu>>System>>Configuration>>Configure you computer
It should prompt for your root password, enter it
Clickon: Network & Internet>>Manage connections
You should see in the first drop down list from the top: eth0: 'your ethernet adapter'. You shouldn't see anything else in there unless you have another ethernet device in your computer. Under the tab TCP/IP there is a drop down list, click it and choose DHCP, this should automatically find an ip for your network, and setup the netmask and gateway. Then click the 'Options' Tab.
This is where the problem is... By default linux checks Network Hotplugging. Uncheck this, and all these settings will be saved. Even if you make your changes in the console, unchecking this should allow linux to save your changes made in the console. I think what is happening here is, the ethercard is failing to load because it isn't compatible with network hotplugging. So your network isn't loading up so any changes being made to it are being over written when the network is restarted and the card fails, linux probably drops the changes. Its all just a guess but anyway next click apply, then ok, and if you go to the console and login as root, and type 'service network restart' you should see: bringing up eth0 [ok].
If not just message me in yahoo, conan78va I'm pretty sure I can get your network fixed. Good Luck!
 
Old 08-22-2004, 01:55 AM   #65
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15
Lightbulb

too much info to read

but anyway, this problem is solved here,
in total 3 things needed to be done here:

in stead of
echo 1 > /proc/sys/net/ipv4/ip_forward
edit etc/sysctl.conf and set ip_forward = 1
and the commands
iptables -t nat -A POSTROUTING -s 192.168.0.0/16 -j MASQUERADE
service iptables save
 
Old 08-22-2004, 01:56 AM   #66
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15
and you were asking for my configuration ?

1 linux, eth0 with cable connection to internet,
eth1 to a hub
2 windoze connected to the hub (win 98 & xp)
 
Old 08-22-2004, 08:37 AM   #67
J[]sie
LQ Newbie
 
Registered: Aug 2004
Posts: 22

Rep: Reputation: 15
I c, well it look like you were still having trouble because the last thing you said was linux wouldn't save your changes. I just unchecked hotplugging for the network adapter, and that solved everything for me, it saves my configurations and I can use the wizzards to change network settings now.

good to hear you got everything up and running.
 
Old 08-22-2004, 09:23 AM   #68
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15
far from done yet

still neet to connect to postgresql,
neet jdbc to run
apache 2 to link to tomcat 5
and get the thing "in the air"

and none promisses to be easy for an linux newcommer ...

It r really marathon days the last weeks ...
 
Old 08-22-2004, 09:31 AM   #69
J[]sie
LQ Newbie
 
Registered: Aug 2004
Posts: 22

Rep: Reputation: 15
I wanted to set up an ftp, but i'm gonna hold off a bit till i learn my way around. I still don't understand this root login thing. I can't find a way to log in as root so I don't have to keep going to the console and opening programs while logged into root from there. I still have a problem with my network. I can't figure out how to make available a hard drive on my linux machine to the windows machines. When i format the drive fat32, mount it /mnt/win_c
but I can't share it! its not in the home directory?? and logging in the console as root doesn't help, same crap, its not in my home dir. What is this, why can't i just log in as root and screw the lock down tight security. It can't be anymore unsecure than my 98se boxes lol! and I don't have iptables like you, how'd u get that?
 
Old 08-22-2004, 09:54 AM   #70
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15
mandrake 10 has standard iptables ...

you can log in as root,
go to the menu:

system - configuration - KDE - system - Login Manager

though it's not advisable ...
It's so damn easy screwing up linux ...

especialy for unexperienced like me
 
Old 08-22-2004, 10:01 AM   #71
J[]sie
LQ Newbie
 
Registered: Aug 2004
Posts: 22

Rep: Reputation: 15
what did you install with mandrake 10? it might have been an extra package or something that i didn't install. I didn't install any server stuff, just client networking. I can't even make a folder in my home dir, it has to be in my home/user dir Can I link to resources devices folders in my home dir to allow me write access?

-thanks
 
Old 08-22-2004, 11:00 AM   #72
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15
Samba server
 
Old 08-28-2004, 12:56 PM   #73
gb1
LQ Newbie
 
Registered: Aug 2004
Posts: 5

Rep: Reputation: 0
maybe same problem

I think I may have the same or a similar problem

Mandrake appears to run fine but I can not ping it from another machine on the same net and I can not see the server under widows networking even though samba is configured and running. (no problem sshing or telnetting to the mandrake box)

I too am getting pretty frustrated and am thinking of switching to REDhat?

Any way to troubleshoot SAMBA?

thanks
 
Old 08-28-2004, 04:15 PM   #74
pelgrimforever
Member
 
Registered: Aug 2004
Location: Pelgrim"s home
Posts: 140

Original Poster
Rep: Reputation: 15
Samba came nice configured "out of the box" I must say,
practically the only thing that went smoot on the whole installation.
 
Old 08-28-2004, 04:53 PM   #75
mermxx
Member
 
Registered: Apr 2004
Location: Wales
Distribution: rh9, winxp
Posts: 411

Rep: Reputation: 30
Have read through all these posts(well skipped over a few bits) and have never seen such a carry on for basic networkingand samba!!!!! It seems to me...(personal opinion here) that because it`s linux , everyone is making things out to be difficult with this command and that command wow! In fact gonna stop here and post in general :-)
 
  


Reply



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
Samba/Cups print sharing problems (/var/spool/samba files) Gates1026 Linux - General 9 06-23-2013 01:33 AM
Sharing internet & file system between Windows98 & Redhat9 cjs_pro Linux - Networking 2 07-15-2004 07:25 AM
Problems -Internet sharing Mandrake & XP Hamid_Son Linux - Networking 0 06-16-2004 04:43 AM
XP, Debian, & Internet Sharing GameboyHippo Linux - Networking 0 10-01-2003 11:34 PM
Internet Connection Sharing and Samba will824 Linux - Networking 5 06-18-2003 05:04 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:31 PM.

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
Open Source Consulting | Domain Registration