E: Sub-process /usr/bin/dpkg returned an error code (1) - but how do I find the meaningful error messages in...
Why is Boris Johnson visiting only Paris & Berlin if every member of the EU needs to agree on a withdrawal deal?
Justifying the use of directed energy weapons
Do ability scores have any effect on casting Wish spell
IndexOptimize - Configuration
Solve a logarithmic equation by NSolve
Why don't we use Cavea-B
Why don't electrons take the shorter path in coils
Were there 486SX revisions without an FPU on the die?
Why doesn't the Falcon-9 first stage use three legs to land?
Why is my Earth simulation slower than the reality?
Why would the US President need briefings on UFOs?
Exctract year, month, day from datetime2
Is there such a thing as too inconvenient?
Have only girls been born for a long time in this village?
Most practical knots for hitching a line to an object while keeping the bitter end as tight as possible, without sag?
How to refer to a regex group in awk regex?
Was Switzerland really impossible to invade during WW2?
How would a situation where rescue is impossible be handled by the crew?
Can you feel passing through the sound barrier in an F-16?
Does an object count as "being moved" when placed in a Bag of Holding before its wielder moves, and then after moving they take the object out again?
What does it mean to have a subnet mask /32?
When translating the law, who ensures that the wording does not change the meaning of the law?
Why does The Ancient One think differently about Doctor Strange in Endgame than the film Doctor Strange?
Ask for a paid taxi in order to arrive as early as possible for an interview within the city
E: Sub-process /usr/bin/dpkg returned an error code (1) - but how do I find the meaningful error messages in APT's output?
dpkg error code (100)dpkg:error:parsing file '/var/lib/dpkg/status' near line 1146 package 'python-minimal'I can't install any package (“E: Sub-process /usr/bin/dpkg returned an error code (1)”), but I have free boot space!Errors in APT output after installing Python packages and running update-alternatives“Error: Could not open input file” for java related files when I try any APT commandMany dependency problems installing jdk and NetBeansE: Sub-process /usr/bin/dpkg returned an error code (1) [Related to KVM]
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
I have encountered various package management problems that cause APT commands to fail with output that ends with this line:
E: Sub-process /usr/bin/dpkg returned an error code (1)
Occasionally other error codes may appear such as 100
which means dpkg is not there, but 1
is the most common error code.
Unfortunately this error code tells me almost nothing about what actually caused the error or how I should solve it. Almost every package management issue I see, regardless of its cause or solution, produces the same error!
So, where will I find the useful part of the output, which I can search for online or ask questions about on Ask Ubuntu?
apt package-management dpkg
add a comment |
I have encountered various package management problems that cause APT commands to fail with output that ends with this line:
E: Sub-process /usr/bin/dpkg returned an error code (1)
Occasionally other error codes may appear such as 100
which means dpkg is not there, but 1
is the most common error code.
Unfortunately this error code tells me almost nothing about what actually caused the error or how I should solve it. Almost every package management issue I see, regardless of its cause or solution, produces the same error!
So, where will I find the useful part of the output, which I can search for online or ask questions about on Ask Ubuntu?
apt package-management dpkg
add a comment |
I have encountered various package management problems that cause APT commands to fail with output that ends with this line:
E: Sub-process /usr/bin/dpkg returned an error code (1)
Occasionally other error codes may appear such as 100
which means dpkg is not there, but 1
is the most common error code.
Unfortunately this error code tells me almost nothing about what actually caused the error or how I should solve it. Almost every package management issue I see, regardless of its cause or solution, produces the same error!
So, where will I find the useful part of the output, which I can search for online or ask questions about on Ask Ubuntu?
apt package-management dpkg
I have encountered various package management problems that cause APT commands to fail with output that ends with this line:
E: Sub-process /usr/bin/dpkg returned an error code (1)
Occasionally other error codes may appear such as 100
which means dpkg is not there, but 1
is the most common error code.
Unfortunately this error code tells me almost nothing about what actually caused the error or how I should solve it. Almost every package management issue I see, regardless of its cause or solution, produces the same error!
So, where will I find the useful part of the output, which I can search for online or ask questions about on Ask Ubuntu?
apt package-management dpkg
apt package-management dpkg
asked 2 days ago
community wiki
Zanna
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
In the complete output of sudo apt update
or sudo apt upgrade
or sudo apt install -f
you should find some messages from dpkg
about what actually went wrong.
These lines will start with dpkg:
since that's the name of the program returning the error. The lines of output immediately preceding or following these lines are often the most helpful.
A few examples of the many possible errors you might see:
Setting up install-info (6.4.90.dfsg.1-1build1) ...
/usr/sbin/update-info-dir: 3: /etc/environment: $: not found
dpkg: error processing package install-info (--configure):
subprocess installed post-installation script returned error exit status 127
This means that the post-installation script could not run. In fact, 127
in Bash is command not found, so a command called by the post-inst script was not found. The lines before the dpkg
line give a probable reason - there is no /etc/environment
file to set the PATH variable so the shell that runs the script doesn't look for the necessary commands in the right places.
start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
No apport report written because the error message indicates its a followup error from a previous failure.
dpkg: error processing package runit (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of git-daemon-run:
git-daemon-run depends on runit; however:
Package runit is not configured yet.
The above error was caused by a bug in the runit
package, which expected to find Upstart installed, although it had been succeeded by systemd as the default init system for Ubuntu. So, the message failed to connect to Upstart
is the best hint, but we need the context to find out how this is causing the package management problem.
Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ...
dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):
trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400
This means there are package conflicts, perhaps caused by having a mixture of repository versions or third party repositories.
TL;DR
In any case where you see the error Sub-process /usr/bin/dpkg returned an error code (1)
, you need to look above for lines starting with dpkg:
and the lines before and after them for useful clues to what went wrong. Try searching for these specific errors.
If you are asking a question here or on another support site, make sure you include the command you ran and the complete output, not just the summary error messages.
add a comment |
Apt logs it's actions sequentially, just like a human does.
Simply read the output line-by-line.
Here is a non-apt example. Read it line-by-line and you will see that it tells a story:
I am going to build a tower out of five blocks...
Clearing a working surface in the kitchen.
Kitchen: Put 7 dirty dishes from the counter into the dishwasher
Kitchen: Wiped the counter clean
Opening the box of blocks.
Warning: There are only three blocks in the box.
Build: Placed the first block.
Build: Placed the second block.
Build: Placed the third block.
Build: ERROR: Cannot keep building - ran out of blocks.
Closing the box of blocks.
ERROR (summary): Failed to complete the five-block tower.
Apt and dpkg logging works in exactly the same way - you read the story line-by-line. You see the package manager embark upon it's adventure: prepare, run subtasks, encounter non-fatal problems (Warnings), overcome adversity, etc.
Most of the output is routine, but you need it to mark apt's progress. That context is how you understand what was happening. It really is a story.
Error (1) is common. It's a summary error code, indicating that the problem occurred to a subtask ("some problem building"). Jump backward in the story to where that particular subtask occurred, and you will see the specific detail ("ran out of blocks").
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1166808%2fe-sub-process-usr-bin-dpkg-returned-an-error-code-1-but-how-do-i-find-the%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
In the complete output of sudo apt update
or sudo apt upgrade
or sudo apt install -f
you should find some messages from dpkg
about what actually went wrong.
These lines will start with dpkg:
since that's the name of the program returning the error. The lines of output immediately preceding or following these lines are often the most helpful.
A few examples of the many possible errors you might see:
Setting up install-info (6.4.90.dfsg.1-1build1) ...
/usr/sbin/update-info-dir: 3: /etc/environment: $: not found
dpkg: error processing package install-info (--configure):
subprocess installed post-installation script returned error exit status 127
This means that the post-installation script could not run. In fact, 127
in Bash is command not found, so a command called by the post-inst script was not found. The lines before the dpkg
line give a probable reason - there is no /etc/environment
file to set the PATH variable so the shell that runs the script doesn't look for the necessary commands in the right places.
start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
No apport report written because the error message indicates its a followup error from a previous failure.
dpkg: error processing package runit (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of git-daemon-run:
git-daemon-run depends on runit; however:
Package runit is not configured yet.
The above error was caused by a bug in the runit
package, which expected to find Upstart installed, although it had been succeeded by systemd as the default init system for Ubuntu. So, the message failed to connect to Upstart
is the best hint, but we need the context to find out how this is causing the package management problem.
Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ...
dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):
trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400
This means there are package conflicts, perhaps caused by having a mixture of repository versions or third party repositories.
TL;DR
In any case where you see the error Sub-process /usr/bin/dpkg returned an error code (1)
, you need to look above for lines starting with dpkg:
and the lines before and after them for useful clues to what went wrong. Try searching for these specific errors.
If you are asking a question here or on another support site, make sure you include the command you ran and the complete output, not just the summary error messages.
add a comment |
In the complete output of sudo apt update
or sudo apt upgrade
or sudo apt install -f
you should find some messages from dpkg
about what actually went wrong.
These lines will start with dpkg:
since that's the name of the program returning the error. The lines of output immediately preceding or following these lines are often the most helpful.
A few examples of the many possible errors you might see:
Setting up install-info (6.4.90.dfsg.1-1build1) ...
/usr/sbin/update-info-dir: 3: /etc/environment: $: not found
dpkg: error processing package install-info (--configure):
subprocess installed post-installation script returned error exit status 127
This means that the post-installation script could not run. In fact, 127
in Bash is command not found, so a command called by the post-inst script was not found. The lines before the dpkg
line give a probable reason - there is no /etc/environment
file to set the PATH variable so the shell that runs the script doesn't look for the necessary commands in the right places.
start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
No apport report written because the error message indicates its a followup error from a previous failure.
dpkg: error processing package runit (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of git-daemon-run:
git-daemon-run depends on runit; however:
Package runit is not configured yet.
The above error was caused by a bug in the runit
package, which expected to find Upstart installed, although it had been succeeded by systemd as the default init system for Ubuntu. So, the message failed to connect to Upstart
is the best hint, but we need the context to find out how this is causing the package management problem.
Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ...
dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):
trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400
This means there are package conflicts, perhaps caused by having a mixture of repository versions or third party repositories.
TL;DR
In any case where you see the error Sub-process /usr/bin/dpkg returned an error code (1)
, you need to look above for lines starting with dpkg:
and the lines before and after them for useful clues to what went wrong. Try searching for these specific errors.
If you are asking a question here or on another support site, make sure you include the command you ran and the complete output, not just the summary error messages.
add a comment |
In the complete output of sudo apt update
or sudo apt upgrade
or sudo apt install -f
you should find some messages from dpkg
about what actually went wrong.
These lines will start with dpkg:
since that's the name of the program returning the error. The lines of output immediately preceding or following these lines are often the most helpful.
A few examples of the many possible errors you might see:
Setting up install-info (6.4.90.dfsg.1-1build1) ...
/usr/sbin/update-info-dir: 3: /etc/environment: $: not found
dpkg: error processing package install-info (--configure):
subprocess installed post-installation script returned error exit status 127
This means that the post-installation script could not run. In fact, 127
in Bash is command not found, so a command called by the post-inst script was not found. The lines before the dpkg
line give a probable reason - there is no /etc/environment
file to set the PATH variable so the shell that runs the script doesn't look for the necessary commands in the right places.
start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
No apport report written because the error message indicates its a followup error from a previous failure.
dpkg: error processing package runit (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of git-daemon-run:
git-daemon-run depends on runit; however:
Package runit is not configured yet.
The above error was caused by a bug in the runit
package, which expected to find Upstart installed, although it had been succeeded by systemd as the default init system for Ubuntu. So, the message failed to connect to Upstart
is the best hint, but we need the context to find out how this is causing the package management problem.
Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ...
dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):
trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400
This means there are package conflicts, perhaps caused by having a mixture of repository versions or third party repositories.
TL;DR
In any case where you see the error Sub-process /usr/bin/dpkg returned an error code (1)
, you need to look above for lines starting with dpkg:
and the lines before and after them for useful clues to what went wrong. Try searching for these specific errors.
If you are asking a question here or on another support site, make sure you include the command you ran and the complete output, not just the summary error messages.
In the complete output of sudo apt update
or sudo apt upgrade
or sudo apt install -f
you should find some messages from dpkg
about what actually went wrong.
These lines will start with dpkg:
since that's the name of the program returning the error. The lines of output immediately preceding or following these lines are often the most helpful.
A few examples of the many possible errors you might see:
Setting up install-info (6.4.90.dfsg.1-1build1) ...
/usr/sbin/update-info-dir: 3: /etc/environment: $: not found
dpkg: error processing package install-info (--configure):
subprocess installed post-installation script returned error exit status 127
This means that the post-installation script could not run. In fact, 127
in Bash is command not found, so a command called by the post-inst script was not found. The lines before the dpkg
line give a probable reason - there is no /etc/environment
file to set the PATH variable so the shell that runs the script doesn't look for the necessary commands in the right places.
start: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: Connection refused
No apport report written because the error message indicates its a followup error from a previous failure.
dpkg: error processing package runit (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of git-daemon-run:
git-daemon-run depends on runit; however:
Package runit is not configured yet.
The above error was caused by a bug in the runit
package, which expected to find Upstart installed, although it had been succeeded by systemd as the default init system for Ubuntu. So, the message failed to connect to Upstart
is the best hint, but we need the context to find out how this is causing the package management problem.
Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ...
dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):
trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400
This means there are package conflicts, perhaps caused by having a mixture of repository versions or third party repositories.
TL;DR
In any case where you see the error Sub-process /usr/bin/dpkg returned an error code (1)
, you need to look above for lines starting with dpkg:
and the lines before and after them for useful clues to what went wrong. Try searching for these specific errors.
If you are asking a question here or on another support site, make sure you include the command you ran and the complete output, not just the summary error messages.
answered 2 days ago
community wiki
Zanna
add a comment |
add a comment |
Apt logs it's actions sequentially, just like a human does.
Simply read the output line-by-line.
Here is a non-apt example. Read it line-by-line and you will see that it tells a story:
I am going to build a tower out of five blocks...
Clearing a working surface in the kitchen.
Kitchen: Put 7 dirty dishes from the counter into the dishwasher
Kitchen: Wiped the counter clean
Opening the box of blocks.
Warning: There are only three blocks in the box.
Build: Placed the first block.
Build: Placed the second block.
Build: Placed the third block.
Build: ERROR: Cannot keep building - ran out of blocks.
Closing the box of blocks.
ERROR (summary): Failed to complete the five-block tower.
Apt and dpkg logging works in exactly the same way - you read the story line-by-line. You see the package manager embark upon it's adventure: prepare, run subtasks, encounter non-fatal problems (Warnings), overcome adversity, etc.
Most of the output is routine, but you need it to mark apt's progress. That context is how you understand what was happening. It really is a story.
Error (1) is common. It's a summary error code, indicating that the problem occurred to a subtask ("some problem building"). Jump backward in the story to where that particular subtask occurred, and you will see the specific detail ("ran out of blocks").
add a comment |
Apt logs it's actions sequentially, just like a human does.
Simply read the output line-by-line.
Here is a non-apt example. Read it line-by-line and you will see that it tells a story:
I am going to build a tower out of five blocks...
Clearing a working surface in the kitchen.
Kitchen: Put 7 dirty dishes from the counter into the dishwasher
Kitchen: Wiped the counter clean
Opening the box of blocks.
Warning: There are only three blocks in the box.
Build: Placed the first block.
Build: Placed the second block.
Build: Placed the third block.
Build: ERROR: Cannot keep building - ran out of blocks.
Closing the box of blocks.
ERROR (summary): Failed to complete the five-block tower.
Apt and dpkg logging works in exactly the same way - you read the story line-by-line. You see the package manager embark upon it's adventure: prepare, run subtasks, encounter non-fatal problems (Warnings), overcome adversity, etc.
Most of the output is routine, but you need it to mark apt's progress. That context is how you understand what was happening. It really is a story.
Error (1) is common. It's a summary error code, indicating that the problem occurred to a subtask ("some problem building"). Jump backward in the story to where that particular subtask occurred, and you will see the specific detail ("ran out of blocks").
add a comment |
Apt logs it's actions sequentially, just like a human does.
Simply read the output line-by-line.
Here is a non-apt example. Read it line-by-line and you will see that it tells a story:
I am going to build a tower out of five blocks...
Clearing a working surface in the kitchen.
Kitchen: Put 7 dirty dishes from the counter into the dishwasher
Kitchen: Wiped the counter clean
Opening the box of blocks.
Warning: There are only three blocks in the box.
Build: Placed the first block.
Build: Placed the second block.
Build: Placed the third block.
Build: ERROR: Cannot keep building - ran out of blocks.
Closing the box of blocks.
ERROR (summary): Failed to complete the five-block tower.
Apt and dpkg logging works in exactly the same way - you read the story line-by-line. You see the package manager embark upon it's adventure: prepare, run subtasks, encounter non-fatal problems (Warnings), overcome adversity, etc.
Most of the output is routine, but you need it to mark apt's progress. That context is how you understand what was happening. It really is a story.
Error (1) is common. It's a summary error code, indicating that the problem occurred to a subtask ("some problem building"). Jump backward in the story to where that particular subtask occurred, and you will see the specific detail ("ran out of blocks").
Apt logs it's actions sequentially, just like a human does.
Simply read the output line-by-line.
Here is a non-apt example. Read it line-by-line and you will see that it tells a story:
I am going to build a tower out of five blocks...
Clearing a working surface in the kitchen.
Kitchen: Put 7 dirty dishes from the counter into the dishwasher
Kitchen: Wiped the counter clean
Opening the box of blocks.
Warning: There are only three blocks in the box.
Build: Placed the first block.
Build: Placed the second block.
Build: Placed the third block.
Build: ERROR: Cannot keep building - ran out of blocks.
Closing the box of blocks.
ERROR (summary): Failed to complete the five-block tower.
Apt and dpkg logging works in exactly the same way - you read the story line-by-line. You see the package manager embark upon it's adventure: prepare, run subtasks, encounter non-fatal problems (Warnings), overcome adversity, etc.
Most of the output is routine, but you need it to mark apt's progress. That context is how you understand what was happening. It really is a story.
Error (1) is common. It's a summary error code, indicating that the problem occurred to a subtask ("some problem building"). Jump backward in the story to where that particular subtask occurred, and you will see the specific detail ("ran out of blocks").
edited 2 days ago
community wiki
2 revs
user535733
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1166808%2fe-sub-process-usr-bin-dpkg-returned-an-error-code-1-but-how-do-i-find-the%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown