Removing a dead node from Mnesia?

Shawn Pearce <>
Sun Feb 8 00:23:14 CET 2004


This may not be possible, buuuut:

Lets say I've created a table as disc_copies on two nodes,  and 

Now lets say that while both emulators are down, I do something stupid
making it no longer possible for me to run   For example
the computer has been run over by a truck while sitting out on the curb
during an ice storm.

How do I get Mnesia on  to forget about the full table copy on
?

()12> mnesia:del_table_copy(account, '').
{aborted,{not_active,"All replicas on diskfull nodes are not active yet",
		account,
		[]}}

Is this going to require very low level Mnesia hacking?

After digging around in mnesia_schema, it looks like the delete cannot
be done because the schema table is disc_copies on both nodes, and with
 down its not possible to modify the schema table to make the changes.

It is however possible to delete the schema table from  while  is
in smoking ruins:

()13> mnesia:del_table_copy(schema, '').
{atomic,ok}

But this creates an odd state if  comes back from the grave.
 thinks the schema table on  is ram_copies, but  thinks it
is disc_copies...  which is flat out not correct.

-- 
Shawn.



More information about the erlang-questions mailing list