Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
collegamento pc tramite crossover
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian)
View previous topic :: View next topic  
Author Message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 10:42 am    Post subject: collegamento pc tramite crossover Reply with quote

Ciao a tutti, ho comprato una scheda di rete (perfetamente riconosciuta) e un cavo incrociato, per poter collegare il mio portatile al desktop. Sul portatile ho installato gentoo mentre sul desktop la mandrake (a caso ho solo un 56k.....) che comunque penso di cambiare appena ho tempo con una debian o una slack. Ora sapete dirmi cosa devo configurare per fare questa rete? (sono un esordiente totale in questo campo, ma mi incuriosice molto) oppure magari un howto semplice e magari in italiano?
grazie mille a tutti per il disturbo.

ciao
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 10:55 am    Post subject: Reply with quote

In gentoo dovresti configurare il file /etc/conf.d/net assegnargli un ip una netmask. Su mandrake la stessa cosa, cioe' assegnargli un ip della stessa classe, solo che non so il file di conf (mi pare che harddrake si puo' fare).

Esempio:
Code:
gentoo   ip=192.168.0.1 netmask=255.255.255.0
mandrake ip=192.168.0.2 netmask=255.255.255.0

Per vedere se poi fare da gentoo
Code:
ping 192.168.0.2

e da mandrake
Code:
ping 192.168.0.1

Questo comando deve risponderti qualcosa come
Code:
PING bestia (192.168.0.2) 56(84) bytes of data.
64 bytes from bestia (192.168.0.2): icmp_seq=1 ttl=64 time=0.362 ms
64 bytes from bestia (192.168.0.2): icmp_seq=2 ttl=64 time=0.178 ms
64 bytes from bestia (192.168.0.2): icmp_seq=3 ttl=64 time=0.184 ms

_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 11:34 am    Post subject: Reply with quote

Allora, in /etc/conf.d/net di gentoo ho aggiunto questa riga (il resto era commentato)
Code:

gentoo   ip=192.168.0.1 netmask=255.255.255.0

e con harddrake, ho configurato la mandrake.
Pero' quando effettuo il ping mi dice: connect: Network is unreachable.
Sia con gentoo che con la mk.
Ho provato ad usare dhcpd, ma lavora, e non succede nulla.... che puo' essere?
grazie
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 12:03 pm    Post subject: Reply with quote

mcvash wrote:
Allora, in /etc/conf.d/net di gentoo ho aggiunto questa riga (il resto era commentato)
Code:

gentoo   ip=192.168.0.1 netmask=255.255.255.0

No quello era un esempio. La riga che devi aggiungere e'
Code:
iface_eth0="192.168.0.1 broadcast 192.168.0.255 netmask 255.255.255.0"

e il resto commentato[/code]
_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
shev
Bodhisattva
Bodhisattva


Joined: 03 Feb 2003
Posts: 4084
Location: Italy

PostPosted: Tue Feb 03, 2004 12:08 pm    Post subject: Reply with quote

Consiglio, come ho detto in un altro topic, gli Appunti di informatica libera di Giacomini. Tra i vari tomi trovi questo che oltre a spiegarti come configurare la tua linux box ti da un'infarinatura generale sulle reti e i protocolli, facendoti capire cosa stai facendo. Già, perchè imho è inutile sapere di dover scrivere una determinata riga in un file di config se poi non sai quale sia il suo significato, perchè devi assegnare quei determinati numeri, etc.
_________________
Se per vivere ti dicono "siediti e stai zitto" tu alzati e muori combattendo
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 1:04 pm    Post subject: Reply with quote

grazie mille, l'avevo letto, ma non ci avevo capito molto.... :oops:

Ora dovrei aver configurato il tutto, solo che su gentoo continua a dirmi:
Network is unreachable.

di solito uso dhcpd per collegarmi a fastweb e non ho problemi (dhcpd lo lancio manualmente). Ma per collegarei 2 pc?
Purtroppo avevo bisogno di trasferire dei dati, ma sono sotto esami, e non ho molto tempo per studiarmi le varie reti e protocolli.... :cry:
Adesso provo un po', poi magari vi sapro' dire.
ciao
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 1:12 pm    Post subject: Reply with quote

mcvash wrote:
Ora dovrei aver configurato il tutto, solo che su gentoo continua a dirmi:
Network is unreachable.

Ma hai una o due schede di rete (dimmi come e' impostata la macchina gentoo)? Puoi anche associare 2 interfaccie alla stessa scheda di rete.
_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
randomaze
Bodhisattva
Bodhisattva


Joined: 21 Oct 2003
Posts: 9985

PostPosted: Tue Feb 03, 2004 1:52 pm    Post subject: Reply with quote

mcvash wrote:

Ora dovrei aver configurato il tutto, solo che su gentoo continua a dirmi:
Network is unreachable.


Posta l'output dei comandi:
Code:

#ifconfig -a
#route
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 2:15 pm    Post subject: Reply with quote

Quote:

Posta l'output dei comandi:
Code:

#ifconfig -a
#route


allora: quello della mandrake:
Code:

# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:06:7B:05:C6:0A
          inet addr:192.168.0.1  Bcast:192.168.0.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:65 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:0 (0.0 b)  TX bytes:11525 (11.2 Kb)
          Interrupt:12 Base address:0x3000

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:102 errors:0 dropped:0 overruns:0 frame:0
          TX packets:102 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:7146 (6.9 Kb)  TX bytes:7146 (6.9 Kb)

# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
192.168.0.0     *               255.255.255.0   U     0      0        0 eth0
127.0.0.0       *               255.0.0.0       U     0      0        0 lo


quello di gentoo:
Code:

# ifconfig
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface


Ora, il route della mandrake l'ho fatto io, ma non ero sicuro che fosse giusto, quindi non l'ho inserito anche in gentoo.
Poi in gentoo mi manca tutta la parte della eth0, che invece ho con la mandrake, il problema dovrebbe essere questo?

Quote:
Ma hai una o due schede di rete (dimmi come e' impostata la macchina gentoo)? Puoi anche associare 2 interfaccie alla stessa scheda di rete.


La macchina gentoo e' il potratile con una sola scheda di rete, la mandrake e' il fisso, con una sola scheda di rete.....
Come faccio ad avere 2 interfacce?

grazie
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 2:23 pm    Post subject: Reply with quote

mcvash wrote:
Poi in gentoo mi manca tutta la parte della eth0, che invece ho con la mandrake, il problema dovrebbe essere questo?

hai montato il modulo? se no lspci che ti da?

mcvash wrote:
La macchina gentoo e' il potratile con una sola scheda di rete, la mandrake e' il fisso, con una sola scheda di rete.....
Come faccio ad avere 2 interfacce?

Faccio l'esempio se un interfaccia va con dhcp e l'atra e' statica. Sempre in /etc/conf.d/net metti
Code:
iface_eth0="dhcp"  #interfaccia di base
alias_eth0="192.168.0.1" #seconda interfaccia con la stessa scheda

_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 3:10 pm    Post subject: Reply with quote

Quote:

hai montato il modulo? se no lspci che ti da?

Il modulo e' montato, infatti per utilizzare internet basta che lancio dhcpd.....

Per collegare i 2 pc, devono essere entrambe le schede statiche, o posso utilizzare dhcpd?
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 3:13 pm    Post subject: Reply with quote

mcvash wrote:
Per collegare i 2 pc, devono essere entrambe le schede statiche, o posso utilizzare dhcpd?

Puoi fare sia uno che l'altro. Se sono statiche sa che numero gli hai assegnato tu.
_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 4:05 pm    Post subject: Reply with quote

Ho fatto altri tentativi ma non funziona nulla...... ho dato il comando:
Code:

route add -net 192.168.0.0 netmask 255.255.255.0 dev eth0

ma dice:
SIOCADDRT: Network is down.
Come faccio a farlo partire senza utilizzare dhcpd (che non mi funziona con il crossover)?

Magari mi manca qualcosa nella configurazione del kernel, ma mi sembra strano, visto che la eth0 con fastweb funziona....
ciao
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 5:57 pm    Post subject: Reply with quote

mcvash wrote:
Ho fatto altri tentativi ma non funziona nulla...... ho dato il comando:
Code:

route add -net 192.168.0.0 netmask 255.255.255.0 dev eth0

ma dice:
SIOCADDRT: Network is down.
Come faccio a farlo partire senza utilizzare dhcpd (che non mi funziona con il crossover)?

E' vero mi ero dimenticato che li colleghi con un crossover. Comunque in gento metti quello che ti ho detto (iface_eth0="dhcp" e alias_eth0="192.168.0.2) e poi /etc/init.d/net.eth0 restart. In mandrake ho visto che va con l'ip 192.168.0.1.
_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 7:32 pm    Post subject: Reply with quote

Ok, qualcosina comincia ad andare, dopo aver modificato un po' i file, provato ad inserire alcuni comandi, ora i 2 ip funzionano, cioè, se da gentoo che è 192.168.0.2 pingo questo ip, lo trova, ed idem con la mk.
Il problema è che non riesco a pingare gli ip da un pc ad un altro, in pratica non si vedono......
il messaggio che mi restituisce è:
Code:
PING 192.168.0.2 (192.168.0.2) 56(84) bytes of data.
From 192.168.0.1 icmp_seq=1 Destination Host Unreachable
From 192.168.0.1 icmp_seq=2 Destination Host Unreachable
From 192.168.0.1 icmp_seq=3 Destination Host Unreachable

--- 192.168.0.2 ping statistics ---
4 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3024ms
, pipe 3


Ora, non so' piu' che fare.... pero' mi è venuto un sospetto, che magari il cavo non sia fatto come dio comanda (penso sia strano, in quanto gli ho richiesto un crossover, e siccome non c'erano disponibili è andato sul retro a prepararmelo). E' possibile che sia altro?
Back to top
View user's profile Send private message
cerri
Bodhisattva
Bodhisattva


Joined: 05 Mar 2003
Posts: 2957
Location: # init S

PostPosted: Tue Feb 03, 2004 7:37 pm    Post subject: Reply with quote

Fai un ifconfig -a su entrambe le macchine e posta il risultato.
Inoltre: riesci a vedere i colori dei connettori? Puoi dirli?
_________________
Enjoy your freedom.
Sex is like hacking. You get in, you get out, and you hope you didnt leave something behind that can be traced back to you.
<----------------------->
Andrea Cerrito
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 8:30 pm    Post subject: Reply with quote

allora, l' ifconfig -a di gentoo è:
Code:

eth0      Link encap:Ethernet  HWaddr 00:08:0D:CC:AD:50
       BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Interrupt:11 Base address:0xb000
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

mentre i colori dell' uscita sono da sinistra: arancio arancio verde azzurro bianco marrone verde marrone.

della mdk:
Code:

eth0      Link encap:Ethernet  HWaddr 00:06:7B:05:C6:0A
          inet addr:192.168.0.1  Bcast:192.168.0.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4 errors:0 dropped:0 overruns:0 frame:0
          TX packets:161 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:240 (240.0 b)  TX bytes:26785 (26.1 Kb)
          Interrupt:12 Base address:0x3000

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:185 errors:0 dropped:0 overruns:0 frame:0
          TX packets:185 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:13414 (13.0 Kb)  TX bytes:13414 (13.0 Kb)
Back to top
View user's profile Send private message
cerri
Bodhisattva
Bodhisattva


Joined: 05 Mar 2003
Posts: 2957
Location: # init S

PostPosted: Tue Feb 03, 2004 9:08 pm    Post subject: Reply with quote

I colori dei connettori non devono avere lo stesso ordine. Cmq la box gentoo non è configurata.
_________________
Enjoy your freedom.
Sex is like hacking. You get in, you get out, and you hope you didnt leave something behind that can be traced back to you.
<----------------------->
Andrea Cerrito
Back to top
View user's profile Send private message
randomaze
Bodhisattva
Bodhisattva


Joined: 21 Oct 2003
Posts: 9985

PostPosted: Tue Feb 03, 2004 9:14 pm    Post subject: Reply with quote

ma la linea:
Code:


iface_eth0="192.168.0.2 broadcast 192.168.0.255 netmask 255.255.255.0"


la hai messa nel file /etc/init.d/net della gentoo :?:

e dopo, sempre nella gentoo, hai dato il comando:
Code:

/etc/init.d/net.eth0


:?:

Se si, puoi dire che output ti ha dato?

cerri dice: corretto l'ip
Back to top
View user's profile Send private message
mcvash
Tux's lil' helper
Tux's lil' helper


Joined: 15 Oct 2003
Posts: 119

PostPosted: Tue Feb 03, 2004 9:40 pm    Post subject: Reply with quote

Le righe non commentate nel file /etc/conf.d/net sono:

iface_eth0="192.168.0.2 broadcast 192.168.0.255 netmask 255.255.255.0"
alias_eth0="192.168.0.2"

(quella dhcpd l'ho commentata per ora, se no non fungeva nulla)

era questo che chiedevi?
Code:

# /etc/init.d/net.eth0 restart
 * Bringing eth0 up...                                                 [ ok ]
  *   Adding aliases...
   *     eth0:0...
   SIOCSIFADDR: File exists
   SIOCSIFFLAGS: Cannot assign requested address                   [ ok ]
Back to top
View user's profile Send private message
cerri
Bodhisattva
Bodhisattva


Joined: 05 Mar 2003
Posts: 2957
Location: # init S

PostPosted: Tue Feb 03, 2004 9:47 pm    Post subject: Reply with quote

Togli l'alias.
_________________
Enjoy your freedom.
Sex is like hacking. You get in, you get out, and you hope you didnt leave something behind that can be traced back to you.
<----------------------->
Andrea Cerrito
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 9:48 pm    Post subject: Reply with quote

mcvash wrote:
iface_eth0="192.168.0.2 broadcast 192.168.0.255 netmask 255.255.255.0"
alias_eth0="192.168.0.2"

La seconda riga commentala non ti serve. Ti serve soltanto se vuoi dargli due interfaccie diverse alla scheda (nel senso due interfaccie diverse due ip diversi).
_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
cerri
Bodhisattva
Bodhisattva


Joined: 05 Mar 2003
Posts: 2957
Location: # init S

PostPosted: Tue Feb 03, 2004 9:51 pm    Post subject: Reply with quote

fedeliallalinea wrote:
La seconda riga commentala non ti serve. Ti serve soltanto se vuoi dargli due interfaccie diverse alla scheda (nel senso due interfaccie diverse due ip diversi).

No, l'alias serve ad assegnare più ip alla stessa interfaccia.
_________________
Enjoy your freedom.
Sex is like hacking. You get in, you get out, and you hope you didnt leave something behind that can be traced back to you.
<----------------------->
Andrea Cerrito
Back to top
View user's profile Send private message
fedeliallalinea
Administrator
Administrator


Joined: 08 Mar 2003
Posts: 31745
Location: here

PostPosted: Tue Feb 03, 2004 9:53 pm    Post subject: Reply with quote

cerri wrote:
No, l'alias serve ad assegnare più ip alla stessa interfaccia.

Si mi sono espresso con non dico cosa. Comunque e' quello che volevo dire.
_________________
Questions are guaranteed in life; Answers aren't.

"Those who would give up essential liberty to purchase a little temporary safety,
deserve neither liberty nor safety."
- Ben Franklin
https://www.news.admin.ch/it/nsb?id=103968
Back to top
View user's profile Send private message
randomaze
Bodhisattva
Bodhisattva


Joined: 21 Oct 2003
Posts: 9985

PostPosted: Tue Feb 03, 2004 9:54 pm    Post subject: Reply with quote

Quote:
cerri dice: corretto l'ip


:oops: grazie!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian) All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum