무엇이든 설치하려고 할 때마다 이 오류가 발생합니다(이 오류는 Firefox를 설치하려고 할 때 발생합니다).
Setting up virtualbox-ext-pack (5.0.40-0ubuntu1.16.04.1) ...
/var/lib/dpkg/info/virtualbox-ext-pack.postinst: 18: cd: can't cd to /usr/share/virtualbox-ext-pack
dpkg: error processing package virtualbox-ext-pack (--configure):
subprocess installed post-installation script returned error exit status 2
Errors were encountered while processing:
virtualbox-ext-pack
E: Sub-process /usr/bin/dpkg returned an error code (1)
무엇이든 제거하려고 할 때마다 이 오류가 발생합니다(이 오류는 virtualbox를 제거하려고 할 때 발생함).
Removing virtualbox-ext-pack (5.0.40-0ubuntu1.16.04.1) ...
/var/lib/dpkg/info/virtualbox-ext-pack.prerm: 4: /var/lib/dpkg/info/virtualbox-ext-pack.prerm: vboxmanage: not found
dpkg: error processing package virtualbox-ext-pack (--purge):
subprocess installed pre-removal script returned error exit status 127
Errors were encountered while processing:
virtualbox-ext-pack
E: Sub-process /usr/bin/dpkg returned an error code (1)
이전에 VMware를 설치하려고 했지만 내 노트북이 필수 기술을 지원하지 않습니다.그리고 그것을 피하려는 모든 시도는 실패했습니다!
메소드를 사용하여 virtualbox를 제거하려고했습니다.여기에 설명되어 있습니다결과는 다음과 같습니다.
Do you want to continue? [Y/n] y
(Reading database ... 873830 files and directories currently installed.)
Removing virtualbox-ext-pack (5.0.40-0ubuntu1.16.04.1) ...
/var/lib/dpkg/info/virtualbox-ext-pack.prerm: 4: /var/lib/dpkg/info/virtualbox-ext-pack.prerm: vboxmanage: not found
dpkg: error processing package virtualbox-ext-pack (--purge):
subprocess installed pre-removal script returned error exit status 127
Removing virtualbox-qt (5.0.40-dfsg-0ubuntu1.16.04.1) ...
Purging configuration files for virtualbox-qt (5.0.40-dfsg-0ubuntu1.16.04.1) ...
dpkg: virtualbox: dependency problems, but removing anyway as you requested:
virtualbox-ext-pack depends on virtualbox (>= 5.0.40-dfsg-0~) | virtualbox-5.0; however:
Package virtualbox is to be removed.
Package virtualbox-5.1 which provides virtualbox is not installed.
Package virtualbox-5.0 is not installed.
virtualbox-ext-pack depends on virtualbox (<< 5.0.40-dfsg-z) | virtualbox-5.0; however:
Package virtualbox is to be removed.
Package virtualbox-5.1 which provides virtualbox is not installed.
Package virtualbox-5.0 is not installed.
virtualbox-ext-pack depends on virtualbox (>= 5.0.40-dfsg-0~) | virtualbox-5.0; however:
Package virtualbox is to be removed.
Package virtualbox-5.1 which provides virtualbox is not installed.
Package virtualbox-5.0 is not installed.
virtualbox-ext-pack depends on virtualbox (<< 5.0.40-dfsg-z) | virtualbox-5.0; however:
Package virtualbox is to be removed.
Package virtualbox-5.1 which provides virtualbox is not installed.
Package virtualbox-5.0 is not i
Removing virtualbox (5.0.40-dfsg-0ubuntu1.16.04.1) ...
Purging configuration files for virtualbox (5.0.40-dfsg-0ubuntu1.16.04.1) ...
dpkg: warning: while removing virtualbox, directory '/usr/lib/virtualbox/ExtensionPacks' not empty so not removed
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5.1) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160824-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for gnome-menus (3.13.3-6ubuntu3.1) ...
Processing triggers for mime-support (3.59ubuntu1) ...
Processing triggers for shared-mime-info (1.5-2ubuntu0.1) ...
Processing triggers for hicolor-icon-theme (0.15-0ubuntu1) ...
Errors were encountered while processing:
virtualbox-ext-pack
E: Sub-process /usr/bin/dpkg returned an error code (1)
시도하는 동안 sudo apt-upgrade
나는 이것을 얻었습니다 :
sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
virtualbox-ext-pack : Depends: virtualbox (>= 5.0.40-dfsg-0~) or
virtualbox-5.0 but it is not installable
Depends: virtualbox (< 5.0.40-dfsg-z) or
virtualbox-5.0 but it is not installable
E: Unmet dependencies. Try using -f.
답변1
@oldfred와 다음 목록에 있는 다른 숙련된 사용자의 명령 중 하나 이상이 도움이 되기를 바랍니다.
# Oldfred's command list for cleaning and repairing
#houseclean
sudo apt-get autoclean # only removes files that cannot be downloaded anymore (obsolete)
sudo apt-get clean
#refresh
sudo apt-get update #resync package index
sudo apt-get upgrade #newest versions of all packages, update must be run first
#would upgrade you to the latest kernel in the repositories
#dist-upgrade is also able to remove existing packages if required
sudo apt-get dist-upgrade
# fix Broken packages -f
sudo apt-get -f install
sudo dpkg --configure -a
# Remove lock
# If you are absolutely sure you do not have another upgrade process running.
# Locked dpkg - only if sure you are not running another update.
sudo rm /var/lib/dpkg/lock
sudo dpkg --configure -a
# added zika's tip for problems with hash sum mismatch
sudo rm /var/lib/apt/lists/*
sudo apt-get update
# added 2F4U's tips for Package Manager & Update Manager problems
Does executing these commands help?
cd /var/lib/apt
sudo mv lists lists.old
sudo mkdir -p lists/partial
sudo apt-get update
This will rebuild the cache.
도움이 되지 않으면 이 포럼 스레드에 추가 제안 사항이 있습니다.