[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

Re: [NOVICE] route



On Tue, Jul 24, 2007 at 00:32:50 +0200, Allan Jensen wrote:
> Hej håber en kan hjælpe mig med et problem.
> 
> Har en maskin jeg har lagt Knoppix på ( nok ikke vigtigt ). Den har to
> net udgange, en trådløs og en almindelig ethernet udgang. Er det muligt
> at gøre så den bruger den alm. ethernet udgang ( som jeg har givet IP
> add. 192.168.1.150 ) når
> jeg kalder host 192.168.1.200 og bruger trådløs ( som får tildelt det
> hele via DHCP ) til alle andre hosts.
> Har prøve efter "man" men har nok ikke forstå det helt ;-)

Det er normalt i opsætningen at man tilgår nettet 192.168.1.xxx 
via 192.168.1.150 forudsat netmask er 255.255.255.0 på den device (eth0 ?)

ellers kan man manuelt sætte med ifconfig :
  ifconfig eth0 192.168.1.150 netmask 255.255.255.0

route -n skal så ende med at have et par linier (route -n) 
i stil med :
  ....
192.168.1.0  0.0.0.0       255.255.255.0 U  0 0 0 eth1
192.168.1.0  192.168.1.150 255.255.255.0 UG 0 0 0 eth1
 ....

jeg bruger så debian og har tilføjet i filen /etc/network/interfaces 
nogle linier så den automatisk sætter det ved opstart :
(Knoppix er måske lidt anderledes)

   ...
iface eth0 inet static
 address 192.168.1.150
 network 192.168.1.0
 netmask 255.255.255.0
 broadcast 192.168.1.255
 up route add -net 192.168.1.0 netmask 255.255.255.0 gw 192.168.1.150 dev $IFACE
 down route del -net 192.168.1.0 netmask 255.255.255.0 gw 192.168.1.150 dev $IFACE

   ...


så det er kommandoen ved "up" linien du kan prøve med :

 route add -net 192.168.1.0 netmask 255.255.255.0 gw 192.168.1.150 dev eth0

brug eksemplet i "down" linien når route skal fjernes igen.


OBS 
eth1 (trådlø) må IKKE have en  adresse i 192.168.1.* !


-- 
mvh Frank Damgaard  | 



 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2007-08-01, 02:02 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *