I'm trying to install nginx, but I get the error message:

Get:1 http://mirrordirector.raspbian.org/raspbian/ jessie/main nginx-common all 1.6.2-5+deb8u2 [86.7 kB]
Fetched 86.7 kB in 10s (8,617 B/s)
(Reading database ... 191089 files and directories currently installed.)
Preparing to unpack .../nginx-common_1.6.2-5+deb8u2_all.deb ...
Unpacking nginx-common (1.6.2-5+deb8u2) over (1.6.2-5) ...
dpkg: error processing archive /var/cache/apt/archives/nginx-common_1.6.2-5+deb8u2_all.deb (--unpack):
 unable to install new version of `/usr/share/man/man1/nginx.1.gz': Input/output error

I've tried to uninstall everyting to start all over, but it fails:

The following packages have unmet dependencies:
 nginx-full : Depends: nginx-common (= 1.6.2-5+deb8u2) but 1.6.2-5 is to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

I've tried to run the "apt-get -f install" as suggested, but that fails because of the "Input/output error" described above.

  • Did you try apt-get update before running apt-get install nginx. Can you tell us the command(s) you've used? – earthmeLon Sep 18 '16 at 21:56
  • Yes, I did an apt--get update. Tried a few other things, and at last I managed to uninstall and reinstall everything. Not really sure how ... :-/ – prograde Sep 20 '16 at 9:03
  • Check you have enough free disk space using df -h
  • If not, you'd need to expand the filesystem if the sd card capacity is larger than the existing filesystem. search for raspi-config on how to do that
  • Could have been the disk space that was the problem, but I'm not sure. I deleted some junk on the disk before I read your answer and checked the disk space. Thanks anyway! – prograde Sep 20 '16 at 9:06
  • @prograde if an answer worked for you, it would nice to accept it by clicking the tick mark near it. – Shreyas Murali Sep 20 '16 at 18:23

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.