破损包裹问题

破损包裹问题

我的操作系统:Linux Mint 17.1 (x64) + Cinnamon

我试图让我的 Linux 播放 wma 文件,但我破坏了一些东西,因为我现在无法播放任何视频。我尝试过的:

  • 删除~/.gstreamer-1.0文件夹
  • 正在运行sudo /usr/share/doc/libdvdread4/install-css.sh(也许这破坏了我的系统?)
  • 尝试通过 apt-get 安装一些库(例如名称中包含 libavcodec 的库,也可能是其他库)

现在,当我尝试运行 mplayer 时,出现错误:

> mplayer
mplayer: error while loading shared libraries: libavcodec.so.54: cannot open shared object file: No such file or directory

其他播放器(vlc)也不起作用。所以我尝试更新我的系统。sudo apt-get update抛出一些错误:

(...)
Err http://ppa.launchpad.net trusty/main Sources
  404  Not Found
Get:21 http://packages.linuxmint.com rebecca/upstream i386 Packages [30,0 kB]
Err http://ppa.launchpad.net trusty/main amd64 Packages
  404  Not Found
Hit http://archive.ubuntu.com trusty-updates/restricted Translation-en
Err http://ppa.launchpad.net trusty/main i386 Packages
  404  Not Found
(...)
W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/dists/trusty/main/source/Sources  404  Not Found

W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/dists/trusty/main/binary-amd64/Packages  404  Not Found

W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/dists/trusty/main/binary-i386/Packages  404  Not Found

E: Some index files failed to download. They have been ignored, or old ones used instead.

sudo apt-get upgrade根本没用:

Reading package lists...
Building dependency tree...
Reading state information...
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
 audacity : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                     libavcodec-extra-54 (>= 6:9.13) but it is not installed
 ffmpeg : Depends: libavcodec54 (>= 7:1.2.5~) but it is not installed or
                   libavcodec-extra-54 (>= 7:1.2.5~) but it is not installed
 gstreamer1.0-libav : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                               libavcodec-extra-54 (>= 6:9.13) but it is not installed
 libavdevice53 : Depends: libavcodec54 (>= 7:1.2.5~) but it is not installed or
                          libavcodec-extra-54 (>= 7:1.2.5~) but it is not installed
 libavfilter3 : Depends: libavcodec54 (>= 7:1.2.5~) but it is not installed or
                         libavcodec-extra-54 (>= 7:1.2.5~) but it is not installed
 libavformat54 : Depends: libavcodec54 (>= 7:1.2.5~) but it is not installed or
                          libavcodec-extra-54 (>= 7:1.2.5~) but it is not installed
 libchromaprint0 : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                            libavcodec-extra-54 (>= 6:9.10) but it is not installed
 libopencv-highgui2.4 : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                                 libavcodec-extra-54 (>= 6:9.10) but it is not installed
 mencoder : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                     libavcodec-extra-54 (>= 6:9.11) but it is not installed
 mplayer : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                    libavcodec-extra-54 (>= 6:9.11) but it is not installed
 vlc-nox : Depends: libavcodec54 (>= 6:9.1-1) but it is not installed or
                    libavcodec-extra-54 (>= 6:9.18) but it is not installed
E: Unmet dependencies. Try using -f.

然后我尝试了sudo apt-get -f install

Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
folder-color-switcher gir1.2-nemo-3.0 nemo-emblems
nemo-folder-color-switcher python-nemo python-psutil
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
libavcodec54
The following NEW packages will be installed:
libavcodec54
0 upgraded, 1 newly installed, 0 to remove and 13 not upgraded.
Need to get 2715 kB of archives.
After this operation, 7309 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
WARNING: The following packages cannot be authenticated!
libavcodec54
Install these packages without verification? [y/N] y
Err http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/ trusty/main libavcodec54 amd64 7:1.2.6-1~trusty1
404  Not Found
E: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/pool/main/f/ffmpeg/libavcodec54_1.2.6-1~trusty1_amd64.deb  404  Not Found

E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

然后我运行sudo apt-get update --fix-missing,这给了我类似的错误sudo apt-get update
我还尝试了 synaptic 包管理器,它在启动时显示“您的系统上有 11 个损坏的包!...”。我尝试了一下Edit => Fix Broken Packages,似乎什么也没做(甚至没有抛出错误)。然后我选择了“损坏的依赖项过滤器”,标记了所有要重新安装的软件包,在几个屏幕之后我收到了错误:

W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/pool/main/f/ffmpeg/libavcodec54_1.2.6-1~trusty1_amd64.deb
  404  Not Found


W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/pool/main/f/ffmpeg/ffmpeg_1.2.6-1~trusty1_amd64.deb
  404  Not Found


W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/pool/main/f/ffmpeg/libavdevice53_1.2.6-1~trusty1_amd64.deb
  404  Not Found


W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/pool/main/f/ffmpeg/libavfilter3_1.2.6-1~trusty1_amd64.deb
  404  Not Found


W: Failed to fetch http://ppa.launchpad.net/jon-severinsson/ffmpeg/ubuntu/pool/main/f/ffmpeg/libavformat54_1.2.6-1~trusty1_amd64.deb
  404  Not Found

所以有人知道我破坏了什么/如何破坏以及如何修复它?谢谢。

答案1

我是这样修复的:

  • 打开“软件源”
  • 在 PPA 选项卡中搜索名称中带有“ffmpeg”的条目并将其全部删除
  • 然后在终端中运行这些命令(它们更新/清理整个系统。如果您不想升级发行版,您可以省略带有dist-upgrade部分的行):

    sudo apt-get -f install
    sudo apt-get update
    sudo apt-get upgrade
    # sudo apt-get dist-upgrade
    sudo apt-get autoremove
    sudo apt-get autoclean
    sudo apt-get clean
    
  • 可以选择安装 mplayer 和/或 vlc 来播放视频/音频文件:

    sudo apt-get install mplayer
    sudo apt-get install vlc
    

一切又恢复正常了。

答案2

更容易(如果你有 Synaptic)

  • 打开终端并运行sudo synaptic
  • 在 Synaptic 中导航至“设置”>“存储库”
  • 找到给您带来错误的存储库。

    在这里您可以“禁用”或选择并删除。 当您完成存储库后,请务必按“确定”,让 Synaptic 发挥作用。

  • 退出 Synaptic 并确认

    按“ctrl + Q”并确保您退出 Synaptic而不仅仅是最小化它,否则 apt-get 将返回使用错误。

  • 打开终端并运行sudo apt-get update

就这样,没有更多错误了:)

希望这是可以理解的,到目前为止只使用 Linux 一周。

相关内容