Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pacman -Syu hangs at the end #65

Closed
KyleSanderson opened this issue Mar 16, 2015 · 3 comments
Closed

pacman -Syu hangs at the end #65

KyleSanderson opened this issue Mar 16, 2015 · 3 comments
Milestone

Comments

@KyleSanderson
Copy link

JuJu is really great, I'm using it with Travis-CI as their Ubuntu images are terribly out of date. However, when I try to do a system update (pacman -Syu) the command never seems to complete and just hangs.

Unrelated to the issue: why can't we build a JuJu image in JuJu?

@fsquillace
Copy link
Owner

Hi Kyle,

I am really happy that JuJu can be useful for you :)
The use of JuJu for Travis-CI looks an interesting use case.

I have tried now to run pacman -Syu and it seems working well. Your issue might be due to some package that you have installed recently? Can you type pacman -Qeq to see what are your installed packages?

Can you provide the output of the pacman -Syu command?

Thanks,
Filippo

@KyleSanderson
Copy link
Author

juju -d
juju -f echo ':)'
echo Server = 'https://mirrors.kernel.org/archlinux/$repo/os/$arch' | juju -f tee -a /etc/pacman.d/mirrorlist
yes | juju -f pacman -Syu

This is reproducible every time. If the system is up to date the hang never occurs. You can't control-C/D out either...


http://fpaste.org/198682/14265375/

:: Synchronizing package databases...
core 121.2 KiB 986K/s 00:00 [################################################################] 100%
extra 1817.3 KiB 2.77M/s 00:01 [################################################################] 100%
community 2.6 MiB 1988K/s 00:01 [################################################################] 100%
:: Starting full system upgrade...
resolving dependencies...
looking for conflicting packages...

Packages (29) arch-install-scripts-15-1 archlinux-keyring-20150212-1 binutils-2.25-2 ca-certificates-mozilla-3.17.4-1 curl-7.41.0-1 e2fsprogs-1.42.12-2 filesystem-2015.02-1
gcc-libs-4.9.2-4 gettext-0.19.4-1 glib2-2.42.2-1 glibc-2.21-2 gmp-6.0.0-2 gnupg-2.1.2-1 gnutls-3.3.13-1 krb5-1.13.1-1 libgcrypt-1.6.3-2 libgpg-error-1.18-1
libidn-1.30-1 libsystemd-218-2 libtasn1-4.3-1 libunistring-0.9.5-1 linux-api-headers-3.18.5-1 lzo-2.09-1 openssl-1.0.2-1 pacman-4.2.1-1
pacman-mirrorlist-20150315-1 perl-5.20.2-1 tzdata-2015a-1 xz-5.2.1-1

Total Download Size: 45.16 MiB
Total Installed Size: 189.88 MiB
Net Upgrade Size: 1.88 MiB

:: Proceed with installation? [Y/n] y
:: Retrieving packages ...
linux-api-headers-3.18.5-1-x86_64 744.2 KiB 2011K/s 00:00 [################################################################] 100%
tzdata-2015a-1-any 214.8 KiB 2.33M/s 00:00 [################################################################] 100%
filesystem-2015.02-1-x86_64 8.8 KiB 2.14M/s 00:00 [################################################################] 100%
glibc-2.21-2-x86_64 8.1 MiB 2.05M/s 00:04 [################################################################] 100%
gcc-libs-4.9.2-4-x86_64 2.4 MiB 1882K/s 00:01 [################################################################] 100%
e2fsprogs-1.42.12-2-x86_64 757.1 KiB 1165K/s 00:01 [################################################################] 100%
perl-5.20.2-1-x86_64 12.8 MiB 1258K/s 00:10 [################################################################] 100%
openssl-1.0.2-1-x86_64 2.6 MiB 1027K/s 00:03 [################################################################] 100%
krb5-1.13.1-1-x86_64 1099.1 KiB 1557K/s 00:01 [################################################################] 100%
libidn-1.30-1-x86_64 185.7 KiB 1915K/s 00:00 [################################################################] 100%
gmp-6.0.0-2-x86_64 405.7 KiB 1844K/s 00:00 [################################################################] 100%
libtasn1-4.3-1-x86_64 104.8 KiB 2.84M/s 00:00 [################################################################] 100%
ca-certificates-mozilla-3.17.4-1-x86_64 361.1 KiB 1941K/s 00:00 [################################################################] 100%
curl-7.41.0-1-x86_64 721.3 KiB 1987K/s 00:00 [################################################################] 100%
pacman-mirrorlist-20150315-1-any 3.3 KiB 0.00B/s 00:00 [################################################################] 100%
archlinux-keyring-20150212-1-any 472.5 KiB 2.01M/s 00:00 [################################################################] 100%
libgpg-error-1.18-1-x86_64 122.5 KiB 1361K/s 00:00 [################################################################] 100%
libgcrypt-1.6.3-2-x86_64 400.0 KiB 1428K/s 00:00 [################################################################] 100%
gnutls-3.3.13-1-x86_64 2.0 MiB 1235K/s 00:02 [################################################################] 100%
gnupg-2.1.2-1-x86_64 1841.3 KiB 846K/s 00:02 [################################################################] 100%
xz-5.2.1-1-x86_64 226.3 KiB 826K/s 00:00 [################################################################] 100%
lzo-2.09-1-x86_64 79.4 KiB 1261K/s 00:00 [################################################################] 100%
pacman-4.2.1-1-x86_64 665.6 KiB 1013K/s 00:01 [################################################################] 100%
glib2-2.42.2-1-x86_64 2.1 MiB 1455K/s 00:01 [################################################################] 100%
libsystemd-218-2-x86_64 122.0 KiB 1907K/s 00:00 [################################################################] 100%
binutils-2.25-2-x86_64 4.4 MiB 1161K/s 00:04 [################################################################] 100%
libunistring-0.9.5-1-x86_64 486.8 KiB 764K/s 00:01 [################################################################] 100%
gettext-0.19.4-1-x86_64 1872.5 KiB 704K/s 00:03 [################################################################] 100%
arch-install-scripts-15-1-any 7.2 KiB 0.00B/s 00:00 [################################################################] 100%
(29/29) checking keys in keyring [################################################################] 100%
(29/29) checking package integrity [################################################################] 100%
(29/29) loading package files [################################################################] 100%
(29/29) checking for file conflicts [################################################################] 100%
(29/29) checking available disk space [################################################################] 100%
( 1/29) upgrading linux-api-headers [################################################################] 100%
( 2/29) upgrading tzdata [################################################################] 100%
( 3/29) upgrading filesystem [################################################################] 100%
warning: directory ownership differs on /srv/ftp/
filesystem: 0:0 package: 0:11
warning: directory ownership differs on /var/games/
filesystem: 0:0 package: 0:50
/tmp/alpm_ccA1so/.INSTALL: line 59: grep: command not found
/tmp/alpm_ccA1so/.INSTALL: line 65: grep: command not found
/tmp/alpm_ccA1so/.INSTALL: line 65: grep: command not found
/tmp/alpm_ccA1so/.INSTALL: line 65: grep: command not found
/tmp/alpm_ccA1so/.INSTALL: line 65: grep: command not found
/tmp/alpm_ccA1so/.INSTALL: line 65: grep: command not found
/tmp/alpm_ccA1so/.INSTALL: line 65: grep: command not found
( 4/29) upgrading glibc [################################################################] 100%
warning: /etc/locale.gen installed as /etc/locale.gen.pacnew
Generating locales...
en_US.UTF-8... done
Generation complete.
( 5/29) upgrading gcc-libs [################################################################] 100%
( 6/29) upgrading e2fsprogs [################################################################] 100%
( 7/29) upgrading perl [################################################################] 100%
( 8/29) upgrading openssl [################################################################] 100%
( 9/29) upgrading krb5 [################################################################] 100%
(10/29) upgrading libidn [################################################################] 100%
(11/29) upgrading gmp [################################################################] 100%
(12/29) upgrading libtasn1 [################################################################] 100%
(13/29) upgrading ca-certificates-mozilla [################################################################] 100%
(14/29) upgrading curl [################################################################] 100%
(15/29) upgrading pacman-mirrorlist [################################################################] 100%
warning: /etc/pacman.d/mirrorlist installed as /etc/pacman.d/mirrorlist.pacnew
(16/29) upgrading archlinux-keyring [################################################################] 100%
==> Appending keys from archlinux.gpg...
gpg: 3 marginal(s) needed, 1 complete(s) needed, PGP trust model
gpg: depth: 0 valid: 1 signed: 5 trust: 0-, 0q, 0n, 0m, 0f, 1u
gpg: depth: 1 valid: 5 signed: 62 trust: 0-, 0q, 0n, 5m, 0f, 0u
gpg: depth: 2 valid: 62 signed: 5 trust: 62-, 0q, 0n, 0m, 0f, 0u
gpg: next trustdb check due at 2016-01-22
==> Locally signing trusted keys in keyring...
-> Locally signing key 0E8B644079F599DFC1DDC3973348882F6AC6A4C2...
-> Locally signing key 684148BB25B49E986A4944C55184252D824B18E8...
-> Locally signing key 44D4A033AC140143927397D47EFD567D4C7EA887...
-> Locally signing key 27FFC4769E19F096D41D9265A04F9397CDFD6BB0...
-> Locally signing key AB19265E5D7D20687D303246BA1DFB64FFF979E7...
==> Importing owner trust values...
==> Disabling revoked keys in keyring...
-> Disabling key F5A361A3A13554B85E57DDDAAF7EF7873CFD4BB6...
-> Disabling key 7FA647CD89891DEDC060287BB9113D1ED21E1A55...
-> Disabling key D4DE5ABDE2A7287644EAC7E36D1A9E70E19DAA50...
-> Disabling key BC1FBE4D2826A0B51E47ED62E2539214C6C11350...
-> Disabling key 9515D8A8EAB88E49BB65EDBCE6B456CAF15447D5...
-> Disabling key 4A8B17E20B88ACA61860009B5CED81B7C2E5C0D2...
-> Disabling key 63F395DE2D6398BBE458F281F2DBB4931985A992...
-> Disabling key 0B20CA1931F5DA3A70D0F8D2EA6836E1AB441196...
-> Disabling key 8F76BEEA0289F9E1D3E229C05F946DED983D4366...
-> Disabling key 66BD74A036D522F51DD70A3C7F2A16726521E06D...
-> Disabling key 81D7F8241DB38BC759C80FCE3A726C6170E80477...
-> Disabling key E7210A59715F6940CF9A4E36A001876699AD6E84...
==> Updating trust database...
gpg: next trustdb check due at 2016-01-22
(17/29) upgrading libgpg-error [################################################################] 100%
(18/29) upgrading libgcrypt [################################################################] 100%
(19/29) upgrading gnutls [################################################################] 100%
New optional dependencies for gnutls
guile: for use with Guile bindings
(20/29) upgrading gnupg [################################################################] 100%
(21/29) upgrading xz [################################################################] 100%
(22/29) upgrading lzo [################################################################] 100%
(23/29) upgrading pacman [################################################################] 100%
(24/29) upgrading glib2 [################################################################] 100%
(25/29) upgrading libsystemd [################################################################] 100%
(26/29) upgrading arch-install-scripts [################################################################] 100%
(27/29) upgrading binutils [################################################################] 100%
(28/29) upgrading libunistring [################################################################] 100%
(29/29) upgrading gettext [################################################################] 100%

@fsquillace
Copy link
Owner

This is not strictly a JuJu issue but of ArchLinux instead.

Indeed, when the package archlinux-keyring is installed pacman try to spawn the process gpg-agent that will stuck the JuJu session. If you kill the process the session will terminate successfully.

See the open files of the gpg agent:

[02:07:54 1 feel@myarch (master) juju $]> lsof -p 1982
COMMAND    PID USER   FD   TYPE             DEVICE SIZE/OFF     NODE NAME
gpg-agent 1982 feel  rtd    DIR                8,2     4096        2 /
gpg-agent 1982 feel  txt    REG               0,32  2098664  1018213 /tmp/prooted-1000-bB4oDh
gpg-agent 1982 feel  DEL    REG                8,3           1321750 /home/feel/.juju/usr/bin/gpg-agent
gpg-agent 1982 feel  mem    REG                8,3   164248  1340407 /home/feel/.juju/usr/lib/ld-2.21.so
gpg-agent 1982 feel  mem    REG                8,3  1607712  1345517 /home/feel/.juju/usr/lib/locale/loca$e-archive
gpg-agent 1982 feel  mem    REG                8,3  1984880  1340363 /home/feel/.juju/usr/lib/libc-2.21.s$
gpg-agent 1982 feel  mem    REG                8,3   142912  1340384 /home/feel/.juju/usr/lib/libpthread-$.21.so
gpg-agent 1982 feel  mem    REG                8,3    18880  1322673 /home/feel/.juju/usr/lib/libnpth.so.$.0.4
gpg-agent 1982 feel  mem    REG                8,3    72632  1322663 /home/feel/.juju/usr/lib/libassuan.s$.0.4.3
gpg-agent 1982 feel  DEL    REG                8,3           1322704 /home/feel/.juju/usr/lib/libgpg-erro$.so.0.13.0
gpg-agent 1982 feel  DEL    REG                8,3           1322672 /home/feel/.juju/usr/lib/libgcrypt.s$.20.0.2
gpg-agent 1982 feel    0r   CHR                1,3      0t0     1028 /dev/null
gpg-agent 1982 feel    1w   CHR                1,3      0t0     1028 /dev/null
gpg-agent 1982 feel    2w   CHR                1,3      0t0     1028 /dev/null
gpg-agent 1982 feel    3u  unix 0xffff8800079af480      0t0  1017718 /home/feel/.juju/etc/pacman.d/gnupg/$.gpg-agent type=STREAM

Regarding to your second question. I think it is feasible to produce a new JuJu image inside JuJu itself. I did not find a useful use case tough. If you feel that this feature might be useful for some cases let me know so I could think on implementing it.

Closing this issue. Feel free to reopen if it is needed.

Thank you,
Filippo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants