Subject: Routing Table in netatalk?

From: Hong F Du <[email-masked]>
Date: Tue, 18 Jul 2000 11:16:03 -0400

Hi All,
Is there a routing table under netatalk or atalk? Since my atalk is
running as a nonseed router I would like to see what other routers on
the network too. How should I get this routing info?
Thank you in advance.

feng

---

From: Crystal <[email-masked]>
Date: Tue, 18 Jul 2000 11:01:21 -0500

> the network too. How should I get this routing info?
This was the same question I had a couple of weeks ago. For whatever reason,
the helpful response I received was not posted to the list, so I'll pass it
on.

Netatalk keeps routing tables and addresses in /proc/net/atalk_route.

C.

---

From: andrew morgan <[email-masked]>
Date: Tue, 18 Jul 2000 09:28:40 -0700 (PDT)

> the network too. How should I get this routing info?

If you are using linux, look at:

/proc/net/appletalk - shows current appletalk connections

/proc/net/atalk_iface - shows appletalk settings for each network
interface

/proc/net/atalk_route - shows appletalk routing table

You can just "cat" these files to see what the entries are.  On my
network, there is only one appletalk router, so atalk_route always shows
the same address for the router field.

	Andy

---

From: Hong F Du <[email-masked]>
Date: Tue, 18 Jul 2000 13:26:20 -0400

Thank you. That is great. How do I interpret the output of
#cat /proc/net/atalk_route
Target    Router     Flages    Dev
0192:01    0000:00    5                lo
4F23:00    1964:9F    3               eth0
0192:00    0192:01    1                eth1
1964:95    0000:00    5                lo
1964:00    1964:95    1                eth0
0000:00    0000:00    5                lo

Is Target for network number? How many routers are there totally? Are there
two routers on eth0, which one is my? Is Flages for hop count?

Since I am testing atalk and need to restart atalk sometimes, I want to know
if  there are other routers running on eth0 side before I restart atalk. I
don't want my atalk to be  the last router on the network to shutdown and
all the macs on eth0 side have no router to fall back on. Thank you again.

feng

---

From: andrew morgan <[email-masked]>
Date: Tue, 18 Jul 2000 12:01:40 -0700 (PDT)

> two routers on eth0, which one is my? Is Flages for hop count?

If I'm understanding it correctly, "Target" is the target network number,
and the "Router" field next to it is the gateway machine to get to that
network.  I don't think Flags is the hop count, but I don't know what it
means either.

Let me break down your information by interface:

4F23:00    1964:9F    3               eth0
1964:00    1964:95    1                eth0

0192:00    0192:01    1                eth1

0192:01    0000:00    5                lo
1964:95    0000:00    5                lo
0000:00    0000:00    5                lo

If we look at this, you have 2 routers on eth0 and 1 router on eth1.
However, 1 of those on each interface may be this machine.  Have a look in
/proc/net/atalk_iface to see what address is assigned to this machine.

	Andy

---

From: Hong F Du <[email-masked]>
Date: Tue, 18 Jul 2000 15:47:35 -0400

Yes, you are right. 0192:01 on eth1 and 1964:95 on eth0 are assigned to this
machine as router.

According to my atalk.conf
eth0 -phase 2 -net 6500 -addr 6500.149 -zone "sci"....
and there is no any number as 0192 and 1964 in it.

Why didn't I see any 6500 network number shows up on the /proc/net/atalk_route?

Is there any relationship between 6500 in atalk.conf and 1964 on
/proc/net/atalk_route?

feng

---

From: andrew morgan <[email-masked]>
Date: Tue, 18 Jul 2000 13:19:51 -0700 (PDT)

> Is there any relationship between 6500 in atalk.conf and 1964 on

The numbers in atalk_route are in hex.  So 6500 decimal is 0x1964 (hex).
0x0192 (hex) is 402 decimal.

So your -addr 6500.149 settings translates to 1964:95 in hex.  Hex format
is used in all those /proc/net files.  Grab a good calculator or sharpen
your pencil if you need to convert them very often... :)

	Andy

---

From: Hong F Du <[email-masked]>
Date: Tue, 18 Jul 2000 16:45:27 -0400

You are fantastic! Thank you again. :-)

feng

---

From: Hauke Fath <[email-masked]>
Date: Wed, 19 Jul 2000 09:06:18 +0200

>Netatalk keeps routing tables and addresses in /proc/net/atalk_route.

Err -- all the world runs L*nux? Not.

You are talking of the appletalk kernel code, and 
"/proc/net/atalk_route" is a linuxism.

	hauke

-- 
Hauke Fath                        Tangro Software Components GmbH
                                         D-69115 Heidelberg
[email-masked]                       Ruf +49-6221-13336-35, Fax -21