Apt-get takes very long

When apt-get update is run, Reading package lists takes very long, a simple apt-get install libmono-cil-dev -y takes over 2 hours. It is a completely fresh install on RasPi 3. Downloading the files does not take long though.

No clue what the problem is.

It could be related to the micro SD card you’re using. It might be faulty or it might simply be one that is desperately slow for random I/O. What brand/model is it?

It is a class 10 SanDisk 16GB micro SD Card.

This one: Sandisk Ultra microSDHC UHS-I 16GB Class 10 Memory Card 30 MB/s Without Adapter

Provide grab-logs -A maybe we find something

The logs: http://paste.osmc.io/qatuxebacu

Well to be honest I think nothing wrong with your system, but you must understand that installing the 5 packets you chosen (libmono-cil-dev zsh git deluged deluge-webui deluge-console) actually causes the installation of 222 packets. So assuming a minute per packet it is no wonder it takes over 2 hours.

Start-Date: 2017-03-30  14:43:48
Commandline: /usr/bin/apt-get-real install libmono-cil-dev zsh git deluged deluge-webui deluge-console -y
Install: zsh-common:armhf (5.0.7-5, automatic), libmono-csharp4.0c-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-ldap4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-webmatrix-data4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), perl-modules:armhf (5.20.2-3+deb8u6, automatic), libmono-system-servicemodel-routing4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-microsoft-visualc10.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-cryptography:armhf (0.6.1-1, automatic), python-twisted-web:armhf (14.0.2-3, automatic), perl:armhf (5.20.2-3+deb8u6, automatic), python-mako:armhf (1.0.0+dfsg-0.1, automatic), libmono-system-web-extensions-design4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-compilerservices-symbolwriter4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-mobile4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-webpages2.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-mvc3.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-tasklets4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-sharpzip4.84-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-microsoft-build-tasks-v4.0-4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-markupsafe:armhf (0.23-1+b1, automatic), libmono-system-identitymodel-selectors4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libgdbm3:armhf (1.8.3-13.1, automatic), libmono-system-windows4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-pyasn1-modules:armhf (0.0.5-0.1, automatic), libxcb-render0:armhf (1.10-3+b1, automatic), libmono-system-data-entity4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libxrender1:armhf (0.9.8-1+b1, automatic), libmono-simd4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-sqlite4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libx11-data:armhf (1.6.2-3, automatic), zsh:armhf (5.0.7-5), libmono-i18n-west4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-componentmodel-composition4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-applicationservices4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libexif12:armhf (0.6.21-2, automatic), libmono-system-windows-forms-datavisualization4.0a-cil:armhf (4.8.0.520-0xamarin3, automatic), python-cffi:armhf (0.8.6-1, automatic), libtorrent-rasterbar7:armhf (0.16.18-1, automatic), libmono-system-core4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-data-services-client4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-json4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-dynamicdata4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), mono-runtime-sgen:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-numerics-vectors4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-runtime-caching4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-componentmodel-dataannotations4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-microsoft-build-framework4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), geoip-database:armhf (20150317-1, automatic), libmono-system-net4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-runtime-serialization4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-xml4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-i18n4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-data-services4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libpixman-1-0:armhf (0.32.6-3, automatic), libmono-codecontracts4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-microsoft-web-infrastructure1.0-cil:armhf (4.8.0.520-0xamarin3, automatic), deluge-common:armhf (1.3.10-3, automatic), libmono-relaxng4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-serviceprocess4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-security4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-custommarshalers4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), liberror-perl:armhf (0.17-1.1, automatic), libmono-system-reactive-debugger2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-accessibility4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-xbuild-tasks4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-runtime-durableinstancing4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libxcb-shm0:armhf (1.10-3+b1, automatic), libnunit-framework2.6.3-cil:armhf (2.6.3+dfsg-1, automatic), python-twisted-bin:armhf (14.0.2-3, automatic), deluged:armhf (1.3.10-3), libmono-system-security4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libgdiplus:armhf (3.12-0xamarin1+jpeg62.1, automatic), libmono-system-json-microsoft4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-core2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-http-selfhost4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-io-compression-filesystem4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-posix4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-identitymodel4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-servicemodel-web4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-runtime-remoting2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-servicemodel-discovery4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libxdmcp6:armhf (1.1.1-1+b1, automatic), libmono-microsoft-build-engine4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-runtime4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-cscompmgd0.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-servicemodel4.0a-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-webpages-razor2.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-messaging4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-threading-tasks-dataflow4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-messaging4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-deployment4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-rabbitmq4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), mono-4.0-gac:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-workflow-activities4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-abstractions4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-regularexpressions4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-xml-serialization4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-management4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libx11-6:armhf (1.6.2-3, automatic), libmono-debugger-soft4.0a-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-corlib4.5-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-peapi4.0a-cil:armhf (4.8.0.520-0xamarin3, automatic), python-ply:armhf (3.4-5, automatic), libboost-python1.55.0:armhf (1.55.0+dfsg-3, automatic), libmono-system-configuration-install4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), deluge-web:armhf (1.3.10-3, automatic), libmono-system-web-routing4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-twisted-core:armhf (14.0.2-3, automatic), python-libtorrent:armhf (0.16.18-1, automatic), libmono-data-tds4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-razor2.0-cil:armhf (4.8.0.520-0xamarin3, automatic), mono-gac:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-experimental2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libnunit-util2.6.3-cil:armhf (2.6.3+dfsg-1, automatic), cli-common:armhf (0.9+xamarin1, automatic), python-service-identity:armhf (1.0.0-3, automatic), libmono-system-reflection-context4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-design4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-oracle4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-interfaces2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), deluge-webui:armhf (1.3.10-3), libmono-i18n-rare4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-drawing4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-transactions4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-openssl:armhf (0.14-1, automatic), libmono-system-drawing-design4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-windows-forms2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-http-webhost4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-microsoft-build-utilities-v4.0-4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-linq2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), python-pycparser:armhf (2.10+dfsg-3, automatic), python-pyasn1:armhf (0.1.7-1, automatic), libboost-system1.55.0:armhf (1.55.0+dfsg-3, automatic), libmono-system-net-http-formatting4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-xaml4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-ldap4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libxext6:armhf (1.3.3-1, automatic), libmono-messaging-rabbitmq4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libxau6:armhf (1.0.8-1, automatic), libmono-system-workflow-runtime4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-runtime-serialization-formatters-soap4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libnunit-cil-dev:armhf (2.6.3+dfsg-1, automatic), libmono-i18n4.0-all:armhf (4.8.0.520-0xamarin3, automatic), libmono-management4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-xdg:armhf (0.25-4, automatic), git:armhf (2.1.4-2.1+deb8u2), libmono-smdiagnostics0.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libnunit-core-interfaces2.6.3-cil:armhf (2.6.3+dfsg-1, automatic), libmono-i18n-other4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-http4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-servicemodel-internals0.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-dynamic4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), python-zope.interface:armhf (4.1.1-3.1, automatic), libmono-parallel4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-windows-forms4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-io-compression4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-i18n-cjk4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-cil-dev:armhf (4.8.0.520-0xamarin3), libnunit-console-runner2.6.3-cil:armhf (2.6.3+dfsg-1, automatic), libmono-system-web-http4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-db2-1.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-webbrowser4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-extensions4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), binutils:armhf (2.25-5, automatic), libmono-microsoft-csharp4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-providers2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libnunit-core2.6.3-cil:armhf (2.6.3+dfsg-1, automatic), libmono-system-data4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-data-linq4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-webpages-deployment2.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-net-http-webrequest4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-runtime-interopservices-runtimeinformation4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-windowsbase4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-cairo4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-cecil-private-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-platformservices2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-net-http4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web-services4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-xml-linq4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), mono-runtime-common:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-enterpriseservices4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libxcb1:armhf (1.10-3+b1, automatic), libmono-microsoft-build4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-data-datasetextensions4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libnunit-mocks2.6.3-cil:armhf (2.6.3+dfsg-1, automatic), libmono-system-ldap-protocols4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-workflow-componentmodel4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), deluge-console:armhf (1.3.10-3), libcairo2:armhf (1.14.0-2.1+deb8u2, automatic), libmono-system-numerics4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-reactive-observable-aliases0.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-i18n-mideast4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-configuration4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), git-man:armhf (2.1.4-2.1+deb8u2, automatic), libmono-system-servicemodel-activation4.0-cil:armhf (4.8.0.520-0xamarin3, automatic), mono-runtime:armhf (4.8.0.520-0xamarin3, automatic), python-characteristic:armhf (0.1.0-1, automatic), libmono-system-reactive-windows-threading2.2-cil:armhf (4.8.0.520-0xamarin3, automatic), libmono-system-web4.0-cil:armhf (4.8.0.520-0xamarin3, automatic)

Well, when I installed zsh, it took excess of 15 min. and other installs also took very long, so I had formatted the card and reinstalled OSMC believing there might have been some error while installing. However, reinstallation did nothing. I ran all the commands together so that I don’t have to wait for them to complete to type in the commands. The times I mentioned were of the previous install.

Watch out you might run into problems

For the rest of your topics I still believe that the times are related to the number of packages that are dependencies

This isn’t the first time I’m using zsh w/ OSMC, I know about the problem I’ve fixed it before.

Thanks though.

This on my RPi 3 using a Sandisk Ultra 8 GB card (exact model number unknown).

osmc@osmc:~$ time sudo apt-get install zsh -y
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  zsh-common
Suggested packages:
  zsh-doc
The following NEW packages will be installed:
  zsh zsh-common
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 3,731 kB of archives.
After this operation, 12.5 MB of additional disk space will be used.
Get:1 http://ftp.debian.org/debian/ jessie/main zsh-common all 5.0.7-5 [3,121 kB]
Get:2 http://ftp.debian.org/debian/ jessie/main zsh armhf 5.0.7-5 [610 kB]
Fetched 3,731 kB in 2s (1,344 kB/s)
Selecting previously unselected package zsh-common.
(Reading database ... 23571 files and directories currently installed.)
Preparing to unpack .../zsh-common_5.0.7-5_all.deb ...
Unpacking zsh-common (5.0.7-5) ...
Selecting previously unselected package zsh.
Preparing to unpack .../archives/zsh_5.0.7-5_armhf.deb ...
Unpacking zsh (5.0.7-5) ...
Processing triggers for man-db (2.7.0.2-5) ...
Setting up zsh-common (5.0.7-5) ...
Setting up zsh (5.0.7-5) ...
update-alternatives: using /bin/zsh5 to provide /bin/zsh (zsh) in auto mode
update-alternatives: using /bin/zsh5 to provide /bin/rzsh (rzsh) in auto mode

real	0m39.184s
user	0m7.140s
sys	0m3.070s
osmc@osmc:~$ 

39 seconds from start to end. Many (most?) problems of this nature are a result of SD card issues. If you can, try another card.

@fzinken then I removed it. :wink:

1 Like

Sadly, no extra micro SD cards are lying around.

It definitely was a card problem, thanks.