0

When I upgrade to 16.10 I get some errors and it failed to upgrade. Then one of the forums suggested to do

sudo apt-get update
sudo apt-get install -f
sudo apt-get reboot

But on the second step (install -f), it errors out with the following error:

Setting up tomcat8 (8.0.37-1) ...
/var/lib/dpkg/info/tomcat8.config: 5: /etc/default/tomcat8: c: not found
dpkg: error processing package tomcat8 (--configure):
 subprocess installed post-installation script returned error exit status 127
Errors were encountered while processing:
 tomcat8
E: Sub-process /usr/bin/dpkg returned an error code (1)

Somehow Tomcat8 installation is messed up and i cannot even remove tomcat8 or complete the upgrade.

Any future updates / upgrades are also failing.

Never had the problem with any earlier versions of Ubuntu.

  • How exactly have you installed it? – user589808 Dec 28 '16 at 0:29
  • I already had 15.10->16.04 and then upgraded to 16.10 . – mahesh Dec 28 '16 at 2:35
  • I already had 15.10->16.04 and then upgraded to 16.10 . During the upgrade it said that the upgrade failed , but the Help -> About shows 16.10 And updates (from the automatic updates) now fails. – mahesh Dec 28 '16 at 2:37
  • Even while removing VirtualBox, it gives the tomcat8 error. I am at a point where i would reinstall Ubuntu, but would like to avoid the headache, if there is an easy solution to fix this error. – mahesh Dec 28 '16 at 2:38
  • Perhaps you can try to reinstall Tomcat8 - digitalocean.com/community/tutorials/… also applicable to 16.10 - and/or run sudo apt install -f ... What does Virtuabox has to do with it? – user589808 Dec 28 '16 at 3:10
0

I found out the problem. The file /etc/default/tomcat8 was corrupted. It had some junk characters. I removed the erroneous characters and fixed the file and removed tomcat8 entirely and reinstalled tomcat8 successfully.

Even installing VirtualBox (which failed earlier due to tomcat8 errors) was successfull.

Thanks everyone for your help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.