View Full Version : Networking Help
Yo_Mama
8th July 2001, 19:04
Since the old board is gone, your great post on this subject was lost. The internet sharing works - I just had to plug in the IP of my main box. But I can't get the lan file sharing to work. I made a /etc/hosts file that contains the following:
127.0.0.1 localhost
192.168.0.1 tbird.scottnet tbird
192.168.0.2 duron.scottnet duron
192.168.0.3 linux.scottnet linux
I also have the same on the main box. But when I try to hit the network (using Konqueror, going to LocalNetwork), I get the error "Could not connect to host Localhost". Now what? :confused:
Also - when making changes to the hosts file is a reboot required?
Thanks!
You need to add "localhost" to the line for the machine in question. It's how the machine knows "itself".
Reboot just for a config change!!!!! This is Linux, you only need to reboot after re-compiling the kernel, that's al!!!!!
You can change ./etc/hosts and the changes are effective immediately.
You will find scripts in /etc/rc.d/init.d for each daemon. You can start, stop and restart services by calling these.
Ie, to restart your network:
/etc/rc.d/init.d/network restart
Forget rebooting my friend, those days are now well behind you :cool:
Yo_Mama
9th July 2001, 08:14
Umm, okay, guess I'm kinda confused now - there is a localhost line -
127.0.0.1 localhost
192.168.0.1 tbird.scottnet tbird
192.168.0.2 duron.scottnet duron
192.168.0.3 linux.scottnet linux <----- this is the linux box ;)
I even tried-
192.168.0.3 localhost
and-
192.168.0.3 linux.scottnet localhost
and -
192.168.0.3 runmydamnnetoriwillfragyourass.nowdammit
What am I missing? :confused:
The following is correct:
192.168.0.3 linux.scottnet localhost
Try using "ping" on all machines, to "ping" each of the machines. What can't see what?
ie.
from "tbird": ping linux
from "linux": ping tbird
from "linux": ping linux
etc etc.
What do you get?
Yo_Mama
9th July 2001, 18:58
Wierd. Ping works fine. In fact I noticed when I walked in that the lights on my hub are constantly flashing between tbird and linux. What I was going by was the fact that if I click on "Network->Local Network" I get the Konquerer error "Cannot Connect to Localhost". In fact I still get that even tho ping works. WTF???
dnar
10th July 2001, 03:54
Ok, so you can ping any machine from any machine using Alias names, not just IP addresses? Not very familiar with Konq. I blew my KDE away after trying version 2.1. I don't like it. Just a Gnome at heart.
Need more info. You have 3 systems, what CAN talk to what and what can't? And what are you trying to do. You do know you need Samba running on the linux boxen to attach with Windows network drives????
Yo_Mama
10th July 2001, 08:07
I do now :D
You do know you need Samba running on the linux boxen to attach with Windows network drives???? [/B]
Yo_Mama
10th July 2001, 08:36
Ok, so I go to setup Samba, and it tries to go to http://localhost:901. Guess what? It can't find LocalHost! Where is this localhost defined, if not in the hosts file?
dnar
10th July 2001, 10:00
Originally posted by Yo_Mama
Ok, so I go to setup Samba, and it tries to go to http://localhost:901. Guess what? It can't find LocalHost! Where is this localhost defined, if not in the hosts file?
Hummm. port 901 is the Samba Web Admin port. it sure looks like it does not about localhost....
How about posting your /etc/hosts.
Yo_Mama
10th July 2001, 21:04
Already have, mate. Looks just like this:
127.0.0.1 localhost
192.168.0.1 tbird.scottnet tbird
192.168.0.2 duron.scottnet duron
192.168.0.3 linux.scottnet linux
dezekiel
11th July 2001, 02:47
My Samba Http://127.0.0.1:901 keeps telling me it is not accepting connections. SMB is running. So I must have missed something in smb.conf? Or I am just completely lost?
127.0.0.1 is listed as localhost.localdomain localhost (I think)
Any hints? Hell you have been talking about this. I will have to read more about setting up hosts.
What is the relationship of the 127.0.0.1 lo address and the address of my eth0?
Dan
dnar
11th July 2001, 05:50
This should work:
192.168.0.1 tbird.scottnet tbird
192.168.0.2 duron.scottnet duron
192.168.0.3 linux.scottnet linux localhost
But then again, looking at you previous posts, you have tried this....
What does this say about your SMB ports:
netstat -a | more
Yo_Mama
11th July 2001, 08:10
It doesn't list any SMB ports. I did the hosts like you showed. Still no localhost found at 901 using Konquorer. If I do it using Gnomes browser, it takes me to netscape's search page searching on localhost ;) Oh well, at least it crunches :)
dnar
11th July 2001, 09:06
Ok, its most likely port 901 not found on localhost......
Is Samba running? ps -ax | grep smb
check /etc/services and make sure these lines are not commented out:
netbios-ns 137/tcp nbns
netbios-ns 137/udp nbns
netbios-dgm 138/tcp nbdgm
netbios-dgm 138/udp nbdgm
netbios-ssn 139/tcp nbssn
Depending if you are using inetd or xinetd, (find in /etc) you should have the following in /etc/inetd.conf
netbios-ssn stream tcp nowait root /usr/sbin/smbd smbd
netbios-ns dgram udp wait root /usr/sbin/nmbd nmbd
Better still here is the HOWTO (http://linuxdoc.org/HOWTO/SMB-HOWTO.html)
Yo_Mama
11th July 2001, 22:29
Ok, I did everything you said. I went to the howto and it said to start the daemon type "kill -HUP `cat /var/run/inetd.pid`". There is no inetd.pid to run, possibly because I have xinetd? But there is no xinetd.pid, either. Now what?
BTW: I really am enjoying my Linux experience so far ;)
dnar
12th July 2001, 07:07
Originally posted by Yo_Mama
Ok, I did everything you said. I went to the howto and it said to start the daemon type "kill -HUP `cat /var/run/inetd.pid`". There is no inetd.pid to run, possibly because I have xinetd? But there is no xinetd.pid, either. Now what?
BTW: I really am enjoying my Linux experience so far ;)
Cool. :cool: xinet is much better IMHO anyway. So, your daemon will be launched using the symlink method in /etc/rc.d/
The daemon is in /etc/rc.d/init.d (I think?) - I don;t run Samba here, I use Foxtrot instead :rolleyes:
Symlinks to the daemons are maintained in the following directories:
/etc/rc.d/rc0.d - Run level 0
/etc/rc.d/rc1.d - Run level 1
/etc/rc.d/rc2.d - Run level 2
/etc/rc.d/rc3.d - Run level 3
/etc/rc.d/rc4.d - Run level 4
/etc/rc.d/rc5.d - Run level 5
/etc/rc.d/rc6.d - Run level 6
Bottom line, symlinks beginning with S are executed when entering a run level, and K when leaving that runlevel. COOL?
From the HOWTO:
/etc/rc.d/rc3.d/S91smb (Starts SMB services in multiuser mode)
Now, I wonder, maybe you only have symlinks setup for runlevel 3, and you will be using runlevel 5 - multiuser X!!! Have a look m8!
I just had a quick poke in the Samba HOWTO, the instructions are there!
dnar
12th July 2001, 07:16
Originally posted by siggy
This Linux stuff seems real complicated. Are there any benefits?
Siggy, there are heaps of benefits, like:
1. You get to speak all this really cool lingo like "mount the ext2 partition /dev/hda6 into /mnt/test and run e2fsck to check that the superblock is valid".
2. You no longer see "Your installation is complete, please restart Windows"
3. You no longer see the dreaded BSOD!!!
4. You no longer purchase software....
5. You get to laugh when people send you Email saying "Please don;t open that message I sent you yesterday, it has a Virus!"
6. The world does not stop working just coz you installed a new peice of software (DLL Hell as they call it).
7. You get really cool Avitars when you know the right people.. :cool:
Yo_Mama
12th July 2001, 08:05
Ok, runlevels and symlinks went straight over my head - but I was able to wend my way to /etc/rc.d/init.d and run smb (./smb start). Started the daemon right up, woohoo! But I hadn't edited smb.conf yet, so nothing was set right. So I hacked a few things, and I was able to restart the daemon (./smb restart). Great, now I can see the linux boxen from my windows box!! Whee! Only one small problem - it asks me for a password, and I don't know what it is. I looked in /etc/passwords, but of course it doesn't show it. I also browsed thru the samba password doc - no help. I assume it's prolaby something simple that every UnixHead knows, care to let me in on it? ;)
dnar
12th July 2001, 08:24
Very good my friend. You are getting somewere..... :D
Password? Youre thinking too hard obviously, go get a beer from the fridge!
Got that beer, good, lets proceed. Your the sysadmin of your Linux boxen, right? What are your account loggins and passwords ????
[filter all obvious questions mode on]
dnar
12th July 2001, 08:35
Ok, Yo, your catchin on fast m8. Time for a little runlevel lesson.
Linux/Unix have numerous running modes or levels. Your default runlevel is found here:
/etc/inittab
ie.
id:5:initdefault:
The default is runlevel 5.
0 - halt (Do NOT set initdefault to this!!!!!!!!!!!:rolleyes: )
1 - Single user mode
2 - Multiuser, without NFS (The same as 3, if you do not have networking)
3 - Full multiuser mode
4 - unused
5 - X11
6 - reboot (Do NOT set initdefault to this)
to change run levels: /sbin/init 6
will reboot the machine. All logged on user will get a nice message telling em the world is about to blow up, please logg off....
So, your machine most likely boots to runlevel 5. All scripts (daemons) that have links beginning with "S" (shortcuts if you like) in /etc/rc.d/rc5.d will be run when your machine boots. Too easy. If you change to runlevel 1 : /sbin/init 1 then all daemons/scripts in /etc/rc.d/rc5.d beginning with "K" are killed (ie. smbd stop) and then all the "S" damons/scripts in /etc/rc.d/rc1.d are started.
Here endeth the leason.
I hope you understand my explinations, some things are difficult to simplify, under the bonnet Linux is one of them.
:D
Yo_Mama
12th July 2001, 19:06
Uh oh, my only login is root, and there is no password :) I've tried nothing,root, admin, sysadmin,sysadm, nothing works.
And I'm outta beer, dangit.
Yo_Mama
12th July 2001, 22:54
Originally posted by siggy
That sounds too good to be true.
So what do you do for software?
Am I understanding that I can start with Linux and slowly wheen off of windows? Or do you run both? What happens with DOS?
Most software seems to be freebies written for Linux. There are a few appz & gamez being ported now, but not a whole lot. It would be easy to switch totally to Linux if all you do is i-net & networking stuff, but if you're a gamer then it seems dual boot is the best way to go. It really is a shame tho, sure is nice to have a system you don't have to worry about rebooting everyday...
dnar
13th July 2001, 05:56
Originally posted by siggy
That sounds too good to be true.
So what do you do for software?
Am I understanding that I can start with Linux and slowly wheen off of windows? Or do you run both? What happens with DOS?
Two options siggy,
1. Dual-boot Linux/Windows.
2. Linux only, forget Windows.
3. Linux only, run Windows in Linux.
Ok, thats three :D
I first started Dual-boot. It sucks.
Now I boot Linux only (I dont actually boot much, 24x7)... And run Windows 95 for my Acocunting package, old design stuff and old compilers.
I have forced myself to find, try and manage with the Linux alternatives to as much as I can. The native Linux apps I use every day/week are:
WordPerfect 8
Gnumeric (Excel like, read/write Excel + more)
StarOffice - MS Office knock-out
Opera web browser - kicks butt (check my post-o-meter for proof)
PAN - "Pimp Ass Newsreader"
Sylpheed - multi account Email
Quanta - web designer
CD-Roast - CD burner - matches don't work....
VNC - remote graphical control of other Linux / Windows systems.
GFAX - Fax client
Hylafax - Fax server
GIMP - Graphical package (My Avitar "TUX" was designed using GIMP, not by me!!)
RealPlayer 8 - Yep, Linux version
Acrobat Reader - ditto
Jpilot - synchronise / desktop tools for my PalmPilot.
The list goes on and on.
And by the way siggy, WE ARE NOT THERE YET! But were on our way :D
dnar
14th July 2001, 11:45
Originally posted by siggy
Are we there yet?
Remember, I AM the Moderator in these here woods.... Don't make me use the DELETE POST button.....
Have a nice day. :D
(c) 2001 dnar
vBulletin® v3.7.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.