LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   how to establish lan (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-establish-lan-292519/)

b0nd 02-20-2005 02:53 AM

how to establish lan
 
Hello all,
i'm running "slackware 10.0" on my two machines and now want to have a lan connection among them...
on the home page there is an option of "LAN Browser".......but as soon as i'm clicking on it..........its saying...
.........the lisa daemon does not appear to be running.
..........In order to use the LAN Browser the lisa daemon
must be instlaled and activated by the system administrator...
......
so anyone of u please tell me wat to do next.........am i supposed to download some lisa from the internet or what.......
..
regards...

Artanicus 02-20-2005 02:58 AM

Actually, you dont need that crappy Lisa to establish it.. Heres a quick and dirty way to get your machines LANned:
Add this line for every box youve got into the /etc/rc.d/rc.local:
Code:

/sbin/ifconfig eth0 add 192.168.0.3 broadcast 192.168.0.255
Just set a unique ip for every machine (change the last number that is), but keep the broadcast the same..

This will add a eth0:0 interfase that is the land interfase. If you want it to work rightaway, just enter the same command in the cli as root.. I suggest you add the new ip:s to every machines /etc/hosts so you dont have to remember them by heart.. (;

If you can get a ping from machine to machine with less than 1 ms, then its working..

b0nd 02-20-2005 03:52 AM

Thanx........for such an easy solution......
.....now i can ping from both the machines...
.....one more little problem now.....how can i access the drives of one system from the other one..??

regards

Artanicus 02-20-2005 05:44 AM

Well, that gets a bit more tricky, but not much.. (: What you are looking for, is a NFS mount. (network filesystem)

It can be abit tricky to set up (lousy error system that doesnt help abit in debugging), but Ill try to advise you. These instructions you must do to both computers.
Lets edit a few files, here are examples:
/etc/hosts.deny
Code:

portmap : ALL
lockd : ALL
mountd : ALL
rquotad : ALL
statd : ALL

/etc/hosts.allow
Code:

portmap : 192.168.0.2  # this is the address of the other comp
lockd : 192.168.0.2 
mountd : 192.168.0.2 
rquotad : 192.168.0.2 
statd : 192.168.0.2 
ftp : 192.168.0.2

/etc/exports
Code:

/              192.168.0.2(rw,no_root_squash) # again the ip of the other comp
This exports the / dir to 192.168.0.2 with rw permissions, and a root will be able to root that partition also.. Note that there is no space between the ip and the options.. This is __very__ important.. if theres a space, we get the opposite results..

Lets make it start upon boot:
Code:

chmod +x /etc/rc.d/rc.portmap
chmod +x /etc/rc.d/rc.nfsd

You need to have several daemons running on both computers. portmapper needs to be started first (the startup scripts do this correctly automagicly) and then the nfsd brings the rest up nicely.

So, at this point, lets fire er up.. (;
Code:

/etc/rc.d/rc.portmap start && /etc/rc.d/rc.nfsd start
Do this with both comps.. If there are no errors, there are good chances that its up and running.. Lets test it..

Code:

mkdir /mnt/compname
mount 192.168.0.2:/ /mnt/compname

If all goes well and there are no errors, the other comps disk is now mounted at the mountpoint.. enjoy.. (:

If you get cryptic errors, try the following on both comps:
Code:

/etc/rc.d/rc.nfsd stop
/etc/rc.d/rc.portmap restart
 /etc/rc.d/rc.nfsd start

And try again.. If still not working, a good try might be rebooting to make sure they are loaded as they should..

Oh yeah, if you have a firewall solution, youll need several holes in it.. I dont remember which, but I guess you can nmap yourself and find out when theyre running..

b0nd 02-21-2005 07:07 AM

Hello,
i did all the things and steps instructed by u....
but now facing two problems::
.1> i gave the names to my two machines as "server" and "cleint"..( although there is no such relation among them).
now at the final step of mounting an error occured..."mount: 192.168.0.2:/ failed, reason given by server: Permission denied"
this is happening on "server" machine only......on the "cleint maching everthing is working properly".


2> Although on the client i can see the server as mounted........but its showing all the folders/directories as empty.....
...when i'm cheking the directories "share" property on the "server " it saying "only directories in your home directory can be shared".......
....
what should i do now..???
.
regards

Artanicus 02-21-2005 12:06 PM

id say that sounds abit odd.. Well, the error actually doesnt tell much.. Most of the errors it utters are completely misleading.. (:

The other problem.. Thats even more odd.. If you do a df -h, can you see the size info for the NFS mounted partition?
Does the emptyness occur as a user, and as root?


All times are GMT -5. The time now is 03:34 PM.