how to get Mnesia table size on secondary node

Fredrik Thulin ft@REDACTED
Mon Jun 27 11:47:22 CEST 2005


I'm trying to make Mnesia problems in my Erlang nodes detectable by our 
monitoring system. To do this, I thought that I would start by simply 
making each node report on the availability of the table 'phone' and 
the number of entries in it.

On my primary node, this works just fine (there are two entrys in the 
table 'phone') :

(incomingproxy@REDACTED)4> mnesia:table_info(phone, size).

but on the secondary (which can also see the two entrys in 'phone', I've 
checked that ;) ) mnesia:table_info(phone, size) returns 0.

Inspection of the code mnesia:raw_table_info/2 made me check what 
storage_type was, and on the primary node it is 'disc_copies' but on 
the secondary node it is 'unknown', which makes mnesia:bad_info_reply/2 
return zero. Is 'storage_type' supposed to be 'unknown' on secondary 
nodes or is my schema broken?

Both nodes are running R10B-6.


More information about the erlang-questions mailing list