0

Given the following configuration:

auto eth0
allow-hotplug eth0
        iface eth0 inet static
        gateway 192.168.0.1
        address 192.168.0.25
        netmask 255.255.255.0
        post-up /usr/sbin/avahi-autoipd --force-bind --daemonize --wait $IFACE 2> /dev/null
        pre-down /usr/sbin/avahi-autoipd --kill $IFACE 2> /dev/null

I make the machine get a link-local address while still having an static configuration (for when this machine gets connected to LAN). The issue is that for now, it won't be attached to a LAN, I just want to access it using a network cable directly connecting two machines, and communicating through the given link-local addresses. Connection works, I can ssh it:

~ ❯❯❯ ssh francisco@169.254.5.135                                                                                                                  archlinux ✱
francisco@169.254.5.135's password:
  ____      _                 _ ____     __  __
 / ___|   _| |__   _____  __ (_)___ \ ___\ \/ /
| |  | | | | '_ \ / _ \ \/ / | | __) / _ \\  /
| |__| |_| | |_) | (_) >  <  | |/ __/  __//  \
 \____\__,_|_.__/ \___/_/\_\ |_|_____\___/_/\_\


Welcome to ARMBIAN Ubuntu 14.04.4 LTS 3.14.60-cubox

System load:   0.00             Up time:       35 min
Memory usage:  5 % of 3788Mb    IP:            192.168.0.25
CPU temp:      47°C
Usage of /:    4% of 29G

Last login: Wed Feb 24 04:19:27 2016 from 169.254.4.29
francisco@cubox-i:~$ ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether d0:63:b4:00:88:1f brd ff:ff:ff:ff:ff:ff
    inet 169.254.5.135/16 brd 169.254.255.255 scope link eth0:avahi
       valid_lft forever preferred_lft forever
    inet 192.168.0.25/24 brd 192.168.0.255 scope global eth0
       valid_lft forever preferred_lft forever
    inet6 fe80::d263:b4ff:fe00:881f/64 scope link
       valid_lft forever preferred_lft forever
3: bond0: <BROADCAST,MULTICAST,MASTER> mtu 1500 qdisc noop state DOWN group default
    link/ether f6:4b:80:39:3e:0b brd ff:ff:ff:ff:ff:ff
4: wlan0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 6c:ad:f8:1d:4b:87 brd ff:ff:ff:ff:ff:ff
francisco@cubox-i:~$ avahi-browse -ar
+   eth0 IPv6 cubox-i [d0:63:b4:00:88:1f]                   Workstation          local
+   eth0 IPv4 cubox-i [d0:63:b4:00:88:1f]                   Workstation          local
=   eth0 IPv6 cubox-i [d0:63:b4:00:88:1f]                   Workstation          local
   hostname = [cubox-i.local]
   address = [fe80::d263:b4ff:fe00:881f]
   port = [9]
   txt = []
=   eth0 IPv4 cubox-i [d0:63:b4:00:88:1f]                   Workstation          local
   hostname = [cubox-i.local]
   address = [192.168.0.25]
   port = [9]
   txt = []

My problem is that I also need to have avahi discovering working, but as can be seen, avahi-browse doesn't list the link-local address, why? How to make it list the link-local address too, since in this case the static configuration (192.168.0.25) is of no use.

0

The truth is that I can access the static IP 192.168.0.25! The issue was that I was trying to communicate using direct cable while my notebook was connected to WiFi, inside a 192.168.0.0/24 network. When turning off WiFi I'm able to access 192.168.0.25.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.