Linux newbie networking question

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
I just installed Mandrake 8.2 on a notebook. I have an SMC wireless PCMCIA ethernet card and a 3Com PCI nic (I want to use wirless). Mandrake apparently loaded 3com drivers for the wireless card. Funny thing is it works for LAN but not Internet. I am using an SMC wireless cable/dsl router to connect to cable Internet connection. I can remotely connect to the notebook using the built in remote software and VNC viewer. I can ping and see the router from the Linux notebook. I just can't load a web page or ping any url's. Why would my local LAN work, but not Internet?

I of course intend to RTFM, but right now I'm lazy. Should I get a Linux compliant wireless card, or find Linux drivers for the SMC wireless nic?
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
Make sure the DSL router is the default gateway for the Linux box, type 'route -n' and see if the correct IP is in there.
 

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
ip is not there it says gateway 0.0.0.0

Is there an easy way to get that in there?
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
'route add default gw ipaddress'

I'm not sure how Mandrake does the network config to get it in there permanently.
 

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
That seemed to work. I can now ping yahoo.

I set up Mandrake with gui configuration thingy and set all that up. In fact in mandrake control center | network & internet | connections | the gateway was entered there.

I'll have to reboot and see if it stuck I guess. At least I got a start though. Like I said, I am pretty much a newbie. It's fun to learn though. I'm just conditioned to "windows". :)

next thing I want to do is get samba going.
 

skriefal

Golden Member
Apr 10, 2000
1,424
3
81
If the route is gone after you reboot, then you could always add it the "old fashioned" way by editing the configuration file directly. That way you'll know that the setting will be saved.

Just pop open the file /etc/sysconfig/network-scripts/ifcfg-eth0 in your favorite text editor, and check for a line that begins with GATEWAY=. If there is no such line, then add it add set it's value to your DSL router's IP address. If it is there but the IP is incorrect, then fix it.
 

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
Thanks for your help. It is now working. Do you think I should just leave the 3com driver for the smc 802.11b card?

Now for some reason I can't get smb working correctly....off to RTFM. :)
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
If the driver works why change it?

More than likely your card is just a repackaged 3Com (or maybe vice-versa), a lot of NICs share the same chipsets and you just pay for branding.
 

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
pretty sure it is Intersil Prism2. Anyway, now my Samba configuration is a little more of a challenge than I thought it would be. I found a link that I thought was going to make it easy, but it doesn't work. I also read the smb section on linuxnewbie.org, but that didn't work for me either. I wonder if it's because my windows machines are xp. I can see the samba server in network neighborhood, but it keeps prompting me for a login and password. I created a group and user and assigned it fileshare. I think it might be because there is such a learning curve for me.

Nothinman are you willing to help me through this? Can you suggest a certain link or man page I should read? I want to learn this so I can get a linux file server going at work. There are so many Novell and Microsoft experts at work now, I think it would be cool to know something they don't. There is only a couple people who know Linux.

<edit>what I want to do exactly is have a shared folder with no login or password with a limit of 1 user at a time if possible</edit>
Oh, and what distro do you think I should start with? I of course already I have Mandrake up and running. Isn't Redhat very similar? Is it worth it to try Redhat or Suse?

 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
The smb.conf man page has info on all the directives you can put in the file.

Make sure you run 'smbpasswd -a username' to create a NTLM hashed password, Linux and NT don't use the same cryto algorithm and as such can't use the same password file.

Also if you enable swat (look in /etc/inetd.conf and /etc/xinet.d/ because I'm not sure which one Mandrake uses) you can configure Samba via a web page.

If you're still having problems I can paste a portion of a smb.conf that should work for you, but reading the docs yourself will help you understand it more =)

RedHat and SuSe are both good distros from what I hear, I've really only used RedHat and Debian though. Debian is my current choice, I think it's better than all the rest (although it's not as nice to new users)
 

marat

Senior member
Aug 2, 2001
207
0
0
What you should do:

0. chage to root
su root

1. Add valid user for samba

smbpasswd -a username

2. Edit /etc/samba/smb.conf
edit setting in [global]
workgroup
netbios name

uncomment [homes] section - it will let you see you /home/username directory

to add new shares add:
[share]
comment = some comment
path = /path/to/dir
valid users = username (for more users - use comma)
writable = yes
public = no
printable = no
creare mask = 755

3. restart samba
/etc/init.d/smb restart

tip: Use mc (midnight commander - it looks like Norton Commander)
 

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
Thanks again. I have read about SWAT on linuxnewbie. I think until I do learn more, this needs to be easy. I did install a couple different versions of Redhat, Mandrake, Corel Linux and probably a couple more in the past, but I couldn't get past the learning curve and got board of reading manuals, so I got disinterested and became an MS worshiper. ;)

Here is a page I was reading about setting up the smb.cfg file, but it appears to be down right now. http://samba.netfirms.com/

<edit>thank you too marat</edit>
 

Relayer

Diamond Member
Oct 30, 1999
3,424
0
76
:D it worked! :D

Thanks guys. I have a grasp on things I think and already have a good understanding on things here, so my file server at work should go well.

I have some 1 meter aerial maps of our county that we need to share that are on like 10 CD's. I am going to copy them to the linux box and share them. I still need to find out how to limit the use to only one user at a time though.