Debian で壊れたパッケージを修正する

Debian で壊れたパッケージを修正する

私は Debian (wheezy) ボックスを持っていますが、おかしな状態になっています。apt-get で Python 関連のパッケージをインストールまたは削除できません (Python 自体のアップグレードやダウングレードも含む)。次のようなメッセージが表示されます。

# apt-get -f install
Setting up python2.7-minimal (2.7.3-6+deb7u2) ...
ImportError: No module named site
dpkg: error processing python2.7-minimal (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of python-minimal:
 python-minimal depends on python2.7-minimal (>= 2.7.3-1~); however:
  Package python2.7-minimal is not configured yet.
dpkg: error processing python-minimal (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of python2.7:
 python2.7 depends on python2.7-minimal (= 2.7.3-6+deb7u2); however:
  Package python2.7-minimal is not configured yet.

(そして、他にも同様のエラーが数百万件発生します)。

この状態から回復するにはどうすればいいでしょうか?

(注: wheezy バックポートがいくつかある wheezy システムに jessie から python-scikit をインストールしようとしてこの状態に陥りました)

関連情報