...
Bitcoin: wallet.dat corrupt, salvage failed
...
First of all try running the wallet A with "-detachdb=1", as psy suggested, and then stop it so you have a consistent database file (wallet) before you copy it over.
If it doesn't work you can use the db4.8_dump and db4.8_load utilities to recover it completely. You may need to install db4.8-util package first.
db4.8_dump -p wallet.dat >wallet.txt
Import the purged dump again:
db4.8_load -f wallet.txt wallet.dat.new
Replace wallet.dat with wallet.dat.new, and start bitcoin.