LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-23-2010, 04:15 PM   #1
Dulcinea
LQ Newbie
 
Registered: Jan 2006
Posts: 3

Rep: Reputation: 0
How to make practical use of link scope IPv6 addresses?


I am trying to use link scope IPv6 addresses to permit two machines to connect using IPv6, but I cannot figure out how to do it without specifying the interface to use on every connection. Here is an example ping:
[root@ppatel-brn1 ~]# ping6 -c 3 fe80::204:75ff:feb6:2994
connect: Invalid argument
[root@ppatel-brn1 ~]# ping6 -c 3 -I eth0 fe80::204:75ff:feb6:2994
PING fe80::204:75ff:feb6:2994(fe80::204:75ff:feb6:2994) from fe80::214:22ff:febd:7c1f eth0: 56 data bytes
64 bytes from fe80::204:75ff:feb6:2994: icmp_seq=0 ttl=64 time=0.836 ms
64 bytes from fe80::204:75ff:feb6:2994: icmp_seq=1 ttl=64 time=0.286 ms
64 bytes from fe80::204:75ff:feb6:2994: icmp_seq=2 ttl=64 time=0.280 ms

--- fe80::204:75ff:feb6:2994 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 0.280/0.467/0.836/0.261 ms, pipe 2
It makes sense to me that the OS doesn't know that fe80::204:75ff:feb6:2994 is out eth0 because I have two interfaces, but if I add a route, I get the same thing:
[root@ppatel-brn1 ~]# ip -6 route add fe80::204:75ff:feb6:2994 dev eth0
[root@ppatel-brn1 ~]# ping6 -c 3 fe80::204:75ff:feb6:2994
connect: Invalid argument
I have seen network traces of Windows-based machines happily transmitting to and from link scope addresses, but it seems I cannot do this in Linux. What am I doing wrong?
 
Old 06-24-2010, 08:17 AM   #2
TimothyEBaldwin
Member
 
Registered: Mar 2009
Posts: 249

Rep: Reputation: 27
You MUST supply the interface, this can be done by appending it to the address like "fe80::204:75ff:feb6:2994%eth0". This is supported by most programs.

Or you can use multicast DNS to resolve the name.

Last edited by TimothyEBaldwin; 06-24-2010 at 08:19 AM.
 
Old 06-24-2010, 09:09 AM   #3
Dulcinea
LQ Newbie
 
Registered: Jan 2006
Posts: 3

Original Poster
Rep: Reputation: 0
Thanks!
 
Old 06-24-2010, 09:47 AM   #4
Dulcinea
LQ Newbie
 
Registered: Jan 2006
Posts: 3

Original Poster
Rep: Reputation: 0
scp with IPv6 link scope address

I tried the suggestion of appending %<interface> to an IPv6 address to use the link scope address, and that worked for ssh but not scp. I found a partial solution over at another web site (http://marc.info/?l=openssh-unix-dev&m=112975365929888), and here's the extension of it to link scope addressing:

Assuming that host fe80::204:75ff is reachable via eth0 and I want to copy foo.pdf from joe's home directory over there to my local working directory, I would use this syntax:
scp 'joe@[fe80::204:75ff%eth0]':foo.pdf .
 
  


Reply

Tags
ipv6, link, scope, scp


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Validate IPv6 addresses ashok.g Programming 2 06-19-2010 04:49 PM
discover all hosts in ipv6 subnet and their addresses ineya Linux - Networking 5 12-13-2008 05:21 AM
Assigning large numbers of IPv6 addresses jack_sprat Linux - Networking 0 10-02-2007 10:04 AM
LXer: Understand IPv6 Addresses LXer Syndicated Linux News 0 09-27-2006 04:33 PM
Detecting IPv6 addresses of interfaces obashir Programming 4 11-13-2002 07:25 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 05:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration