apt-get update failure returns 0 error code [duplicate]

Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
This question already has an answer here:
apt vs apt-get error code
1 answer
When we run apt-get update and if it fails, a non zero error code should be returned, but in my case its still 0. See below:
root@ubuntu-base:/home/user# apt-get update
Err http://security.ubuntu.com trusty-security InRelease
Err http://packages.siawai.com:8085 trusty InRelease
Err http://ppa.launchpad.net trusty InRelease
Err http://ppa.launchpad.net trusty Release.gpg
 Could not resolve 'ppa.launchpad.net'
Err http://security.ubuntu.com trusty-security Release.gpg
 Could not resolve 'security.ubuntu.com'
Err http://packages.siawai.com:8085 trusty Release.gpg
 Could not resolve 'packages.siawai.com'
Err http://in.archive.ubuntu.com trusty InRelease
Err http://in.archive.ubuntu.com trusty-updates InRelease
Err http://in.archive.ubuntu.com trusty-backports InRelease
Err http://in.archive.ubuntu.com trusty Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-updates Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-backports Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease 
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/Release.gpg Could not resolve 'security.ubuntu.com'
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/Release.gpg Could not resolve 'packages.siawai.com'
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/Release.gpg Could not resolve 'ppa.launchpad.net'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
root@ubuntu-base:/home/user# echo $?
0
What could be the issue? I am running ubuntu 14.04.
ubuntu apt return-status
 marked as duplicate by Stephen Kitt, Kusalananda, roaima, Isaac, Timothy Martin Feb 9 at 17:55
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |Â
up vote
1
down vote
favorite
This question already has an answer here:
apt vs apt-get error code
1 answer
When we run apt-get update and if it fails, a non zero error code should be returned, but in my case its still 0. See below:
root@ubuntu-base:/home/user# apt-get update
Err http://security.ubuntu.com trusty-security InRelease
Err http://packages.siawai.com:8085 trusty InRelease
Err http://ppa.launchpad.net trusty InRelease
Err http://ppa.launchpad.net trusty Release.gpg
 Could not resolve 'ppa.launchpad.net'
Err http://security.ubuntu.com trusty-security Release.gpg
 Could not resolve 'security.ubuntu.com'
Err http://packages.siawai.com:8085 trusty Release.gpg
 Could not resolve 'packages.siawai.com'
Err http://in.archive.ubuntu.com trusty InRelease
Err http://in.archive.ubuntu.com trusty-updates InRelease
Err http://in.archive.ubuntu.com trusty-backports InRelease
Err http://in.archive.ubuntu.com trusty Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-updates Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-backports Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease 
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/Release.gpg Could not resolve 'security.ubuntu.com'
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/Release.gpg Could not resolve 'packages.siawai.com'
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/Release.gpg Could not resolve 'ppa.launchpad.net'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
root@ubuntu-base:/home/user# echo $?
0
What could be the issue? I am running ubuntu 14.04.
ubuntu apt return-status
 marked as duplicate by Stephen Kitt, Kusalananda, roaima, Isaac, Timothy Martin Feb 9 at 17:55
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
1
"Could not resolve ..." suggests a problem with DNS
â Raman Sailopal
Feb 8 at 11:50
1
Yes, its a network failure created on purpose. The issue is with the return code. Why is it not non zero
â Vijay47
Feb 8 at 11:57
"When we run apt-get update and if it fails, a non zero error code should be returned". Is that "should" as in "the documentation tells me so" or as in "I expect it to do so"?
â roaima
Feb 8 at 22:00
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
This question already has an answer here:
apt vs apt-get error code
1 answer
When we run apt-get update and if it fails, a non zero error code should be returned, but in my case its still 0. See below:
root@ubuntu-base:/home/user# apt-get update
Err http://security.ubuntu.com trusty-security InRelease
Err http://packages.siawai.com:8085 trusty InRelease
Err http://ppa.launchpad.net trusty InRelease
Err http://ppa.launchpad.net trusty Release.gpg
 Could not resolve 'ppa.launchpad.net'
Err http://security.ubuntu.com trusty-security Release.gpg
 Could not resolve 'security.ubuntu.com'
Err http://packages.siawai.com:8085 trusty Release.gpg
 Could not resolve 'packages.siawai.com'
Err http://in.archive.ubuntu.com trusty InRelease
Err http://in.archive.ubuntu.com trusty-updates InRelease
Err http://in.archive.ubuntu.com trusty-backports InRelease
Err http://in.archive.ubuntu.com trusty Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-updates Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-backports Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease 
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/Release.gpg Could not resolve 'security.ubuntu.com'
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/Release.gpg Could not resolve 'packages.siawai.com'
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/Release.gpg Could not resolve 'ppa.launchpad.net'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
root@ubuntu-base:/home/user# echo $?
0
What could be the issue? I am running ubuntu 14.04.
ubuntu apt return-status
This question already has an answer here:
apt vs apt-get error code
1 answer
When we run apt-get update and if it fails, a non zero error code should be returned, but in my case its still 0. See below:
root@ubuntu-base:/home/user# apt-get update
Err http://security.ubuntu.com trusty-security InRelease
Err http://packages.siawai.com:8085 trusty InRelease
Err http://ppa.launchpad.net trusty InRelease
Err http://ppa.launchpad.net trusty Release.gpg
 Could not resolve 'ppa.launchpad.net'
Err http://security.ubuntu.com trusty-security Release.gpg
 Could not resolve 'security.ubuntu.com'
Err http://packages.siawai.com:8085 trusty Release.gpg
 Could not resolve 'packages.siawai.com'
Err http://in.archive.ubuntu.com trusty InRelease
Err http://in.archive.ubuntu.com trusty-updates InRelease
Err http://in.archive.ubuntu.com trusty-backports InRelease
Err http://in.archive.ubuntu.com trusty Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-updates Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Err http://in.archive.ubuntu.com trusty-backports Release.gpg
 Could not resolve 'in.archive.ubuntu.com'
Reading package lists... Done
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease 
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease 
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/InRelease 
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/InRelease 
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/Release.gpg Could not resolve 'security.ubuntu.com'
W: Failed to fetch http://packages.siawai.com:8085/repos/dists/trusty/Release.gpg Could not resolve 'packages.siawai.com'
W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/trusty/Release.gpg Could not resolve 'ppa.launchpad.net'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Failed to fetch http://in.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg Could not resolve 'in.archive.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
root@ubuntu-base:/home/user# echo $?
0
What could be the issue? I am running ubuntu 14.04.
This question already has an answer here:
apt vs apt-get error code
1 answer
ubuntu apt return-status
asked Feb 8 at 11:42
Vijay47
61
61
 marked as duplicate by Stephen Kitt, Kusalananda, roaima, Isaac, Timothy Martin Feb 9 at 17:55
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
 marked as duplicate by Stephen Kitt, Kusalananda, roaima, Isaac, Timothy Martin Feb 9 at 17:55
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
1
"Could not resolve ..." suggests a problem with DNS
â Raman Sailopal
Feb 8 at 11:50
1
Yes, its a network failure created on purpose. The issue is with the return code. Why is it not non zero
â Vijay47
Feb 8 at 11:57
"When we run apt-get update and if it fails, a non zero error code should be returned". Is that "should" as in "the documentation tells me so" or as in "I expect it to do so"?
â roaima
Feb 8 at 22:00
add a comment |Â
1
"Could not resolve ..." suggests a problem with DNS
â Raman Sailopal
Feb 8 at 11:50
1
Yes, its a network failure created on purpose. The issue is with the return code. Why is it not non zero
â Vijay47
Feb 8 at 11:57
"When we run apt-get update and if it fails, a non zero error code should be returned". Is that "should" as in "the documentation tells me so" or as in "I expect it to do so"?
â roaima
Feb 8 at 22:00
1
1
"Could not resolve ..." suggests a problem with DNS
â Raman Sailopal
Feb 8 at 11:50
"Could not resolve ..." suggests a problem with DNS
â Raman Sailopal
Feb 8 at 11:50
1
1
Yes, its a network failure created on purpose. The issue is with the return code. Why is it not non zero
â Vijay47
Feb 8 at 11:57
Yes, its a network failure created on purpose. The issue is with the return code. Why is it not non zero
â Vijay47
Feb 8 at 11:57
"When we run apt-get update and if it fails, a non zero error code should be returned". Is that "should" as in "the documentation tells me so" or as in "I expect it to do so"?
â roaima
Feb 8 at 22:00
"When we run apt-get update and if it fails, a non zero error code should be returned". Is that "should" as in "the documentation tells me so" or as in "I expect it to do so"?
â roaima
Feb 8 at 22:00
add a comment |Â
 1 Answer
 1
 
active
oldest
votes
up vote
0
down vote
This is intentional; see #778357:
The results are meaningful. 0 indicates success or transient error, whereas
other values indicate a persistent error.
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,apt-get updatereturns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.
â Stephen Kitt
Feb 8 at 13:23
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
I also noticedReading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causesReading package lists... Done?
â Vijay47
Feb 8 at 13:27
add a comment |Â
 1 Answer
 1
 
active
oldest
votes
 1 Answer
 1
 
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
This is intentional; see #778357:
The results are meaningful. 0 indicates success or transient error, whereas
other values indicate a persistent error.
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,apt-get updatereturns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.
â Stephen Kitt
Feb 8 at 13:23
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
I also noticedReading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causesReading package lists... Done?
â Vijay47
Feb 8 at 13:27
add a comment |Â
up vote
0
down vote
This is intentional; see #778357:
The results are meaningful. 0 indicates success or transient error, whereas
other values indicate a persistent error.
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,apt-get updatereturns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.
â Stephen Kitt
Feb 8 at 13:23
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
I also noticedReading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causesReading package lists... Done?
â Vijay47
Feb 8 at 13:27
add a comment |Â
up vote
0
down vote
up vote
0
down vote
This is intentional; see #778357:
The results are meaningful. 0 indicates success or transient error, whereas
other values indicate a persistent error.
This is intentional; see #778357:
The results are meaningful. 0 indicates success or transient error, whereas
other values indicate a persistent error.
answered Feb 8 at 12:14
Stephen Kitt
142k22308369
142k22308369
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,apt-get updatereturns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.
â Stephen Kitt
Feb 8 at 13:23
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
I also noticedReading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causesReading package lists... Done?
â Vijay47
Feb 8 at 13:27
add a comment |Â
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,apt-get updatereturns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.
â Stephen Kitt
Feb 8 at 13:23
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
I also noticedReading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causesReading package lists... Done?
â Vijay47
Feb 8 at 13:27
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
Thanks for the answer. Transient errors? What causes it? Or how can it be fixed? Here I just removed internet access from a VM and run apt-get update. It returns non zero error code on other ubuntu VMs, but this one is returning 0.
â Vijay47
Feb 8 at 13:17
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
I am mostly concerned why its returning 0 in this VM only.
â Vijay47
Feb 8 at 13:21
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,
apt-get update returns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.â Stephen Kitt
Feb 8 at 13:23
A transient error refers to an error which will fix itself at some point, in all likelihood â basically,
apt-get update returns non-zero only if human intervention is needed. If youâÂÂre seeing varying behaviour from one VM to another, you should mention that in your question.â Stephen Kitt
Feb 8 at 13:23
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
By default it returns non zero, thats why it was not mentioned in the question
â Vijay47
Feb 8 at 13:24
I also noticed
Reading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causes Reading package lists... Done?â Vijay47
Feb 8 at 13:27
I also noticed
Reading package lists... Done. Meaning something successful has happened. May be thats why it returned 0. What causes Reading package lists... Done?â Vijay47
Feb 8 at 13:27
add a comment |Â
1
"Could not resolve ..." suggests a problem with DNS
â Raman Sailopal
Feb 8 at 11:50
1
Yes, its a network failure created on purpose. The issue is with the return code. Why is it not non zero
â Vijay47
Feb 8 at 11:57
"When we run apt-get update and if it fails, a non zero error code should be returned". Is that "should" as in "the documentation tells me so" or as in "I expect it to do so"?
â roaima
Feb 8 at 22:00