Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
unable to emerge in stage3 chroot
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on ARM
View previous topic :: View next topic  
Author Message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Thu Jan 20, 2022 4:09 pm    Post subject: unable to emerge in stage3 chroot Reply with quote

Code:
emerge vim

 * IMPORTANT: 13 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.

Calculating dependencies... done!

>>> Verifying ebuild manifests

>>> Emerging (1 of 2) app-eselect/eselect-vi-1.2::gentoo
 * Fetching files in the background.
 * To view fetch progress, run in another terminal:
 * tail -f /var/log/emerge-fetch.log
openpty failed: 'out of pty devices'
Unable to unshare: EINVAL (for FEATURES="ipc-sandbox network-sandbox pid-sandbox")
>>> Downloading 'http://distfiles.gentoo.org/distfiles/layout.conf'
--2022-01-20 16:06:40--  http://distfiles.gentoo.org/distfiles/layout.conf
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
!!! Couldn't download '.layout.conf.distfiles.gentoo.org'. Aborting.
>>> Downloading 'http://distfiles.gentoo.org/distfiles/eselect-vi-1.2.tar.gz'
--2022-01-20 16:06:40--  http://distfiles.gentoo.org/distfiles/eselect-vi-1.2.tar.gz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
>>> Downloading 'https://gitweb.gentoo.org/proj/eselect-vi.git/snapshot/eselect-vi-1.2.tar.gz'
--2022-01-20 16:06:40--  https://gitweb.gentoo.org/proj/eselect-vi.git/snapshot/eselect-vi-1.2.tar.gz
Resolving gitweb.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘gitweb.gentoo.org’
!!! Couldn't download 'eselect-vi-1.2.tar.gz'. Aborting.
 * Fetch failed for 'app-eselect/eselect-vi-1.2', Log file:
 *  '/var/tmp/portage/app-eselect/eselect-vi-1.2/temp/build.log'

>>> Failed to emerge app-eselect/eselect-vi-1.2, Log file:

>>>  '/var/tmp/portage/app-eselect/eselect-vi-1.2/temp/build.log'

 * Messages for package app-eselect/eselect-vi-1.2:

 * Fetch failed for 'app-eselect/eselect-vi-1.2', Log file:
 *  '/var/tmp/portage/app-eselect/eselect-vi-1.2/temp/build.log'
localhost / # ping distfiles.gentoo.org
PING 1060329950.rsc.cdn77.org (185.59.220.17) 56(84) bytes of data.
64 bytes from frankfurt-10.cdn77.com (185.59.220.17): icmp_seq=1 ttl=52 time=64.1 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.17): icmp_seq=2 ttl=52 time=119 ms

localhost / # mount
/proc on /proc type proc (rw,relatime,gid=3009,hidepid=2)
sysfs on /sys type sysfs (rw,relatime,seclabel)
tmpfs on /dev type tmpfs (rw,nosuid,relatime,seclabel,size=1393068k,nr_inodes=114393,mode=755)
sysfs on /sys type sysfs (rw,relatime,seclabel)



not sure which is the cause of this failure, I can obviously resolve hostnames, so I think the out of pty might be the cause of this error.
Back to top
View user's profile Send private message
Telemin
l33t
l33t


Joined: 25 Aug 2005
Posts: 753
Location: Glasgow, UK

PostPosted: Thu Jan 20, 2022 5:50 pm    Post subject: Reply with quote

Do you actually have things in your /dev/? I could be wrong but I expected a devtmpfs type mount.

Also these days make sure you mount with '--rbind' rather than just '--bind' as you will need to catch all the other virtual filesystems mounted beneath.
_________________
The Geek formerly known as -Freestyling-
When you feel your problem has been solved please add [Solved] to the topic title.
Please adopt an unanswered post
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21631

PostPosted: Thu Jan 20, 2022 7:39 pm    Post subject: Re: unable to emerge in stage3 chroot Reply with quote

Adel Ahmed wrote:
Code:
>>> Downloading 'http://distfiles.gentoo.org/distfiles/eselect-vi-1.2.tar.gz'
--2022-01-20 16:06:40--  http://distfiles.gentoo.org/distfiles/eselect-vi-1.2.tar.gz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
not sure which is the cause of this failure, I can obviously resolve hostnames, so I think the out of pty might be the cause of this error.
You obviously cannot resolve hostnames, or wget would not be printing that message. Failure to resolve the hostname prevents wget from downloading the needed file. Without the file, you cannot build. root may be able to resolve hostnames, but portage cannot. What is the output of ls -l /etc/resolv.conf ; cat -n /etc/resolv.conf?
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Fri Jan 21, 2022 4:31 am    Post subject: Reply with quote

I forgot to post that I can resolve:
Code:
localhost / # cat /etc/resolv.conf
nameserver 8.8.8.8

localhost / # ping distfiles.gentoo.org
PING 1060329950.rsc.cdn77.org (195.181.175.55) 56(84) bytes of data.
64 bytes from frankfurt-53.cdn77.com (195.181.175.55): icmp_seq=1 ttl=54 time=59.8 ms
64 bytes from frankfurt-53.cdn77.com (195.181.175.55): icmp_seq=2 ttl=54 time=69.4 ms
^C
--- 1060329950.rsc.cdn77.org ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 59.763/64.558/69.353/4.795 ms

I tried to fetch only and it fails which is strange:
Code:
localhost / # emerge vim -f

 * IMPORTANT: 13 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.

Calculating dependencies... done!

>>> Fetching (1 of 2) app-eselect/eselect-vi-1.2::gentoo
openpty failed: 'out of pty devices'
>>> Downloading 'http://distfiles.gentoo.org/distfiles/layout.conf'
--2022-01-21 04:26:53--  http://distfiles.gentoo.org/distfiles/layout.conf
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
!!! Couldn't download '.layout.conf.distfiles.gentoo.org'. Aborting.
>>> Downloading 'http://distfiles.gentoo.org/distfiles/eselect-vi-1.2.tar.gz'
--2022-01-21 04:26:53--  http://distfiles.gentoo.org/distfiles/eselect-vi-1.2.tar.gz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
>>> Downloading 'https://gitweb.gentoo.org/proj/eselect-vi.git/snapshot/eselect-vi-1.2.tar.gz'
--2022-01-21 04:26:53--  https://gitweb.gentoo.org/proj/eselect-vi.git/snapshot/eselect-vi-1.2.tar.gz
Resolving gitweb.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘gitweb.gentoo.org’
!!! Couldn't download 'eselect-vi-1.2.tar.gz'. Aborting.
 * Fetch failed for 'app-eselect/eselect-vi-1.2'

>>> Failed to emerge app-eselect/eselect-vi-1.2

>>> Fetching (2 of 2) app-editors/vim-8.2.3741::gentoo
>>> Downloading 'http://distfiles.gentoo.org/distfiles/layout.conf'
--2022-01-21 04:26:53--  http://distfiles.gentoo.org/distfiles/layout.conf
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
!!! Couldn't download '.layout.conf.distfiles.gentoo.org'. Aborting.
>>> Downloading 'http://distfiles.gentoo.org/distfiles/vim-8.2.3741.tar.gz'
--2022-01-21 04:26:53--  http://distfiles.gentoo.org/distfiles/vim-8.2.3741.tar.gz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
>>> Downloading 'https://github.com/vim/vim/archive/v8.2.3741.tar.gz'
--2022-01-21 04:26:53--  https://github.com/vim/vim/archive/v8.2.3741.tar.gz
Resolving github.com... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘github.com’
!!! Couldn't download 'vim-8.2.3741.tar.gz'. Aborting.
>>> Downloading 'http://distfiles.gentoo.org/distfiles/layout.conf'
--2022-01-21 04:26:53--  http://distfiles.gentoo.org/distfiles/layout.conf
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
!!! Couldn't download '.layout.conf.distfiles.gentoo.org'. Aborting.
>>> Downloading 'http://distfiles.gentoo.org/distfiles/vim-8.2.0360-gentoo-patches.tar.xz'
--2022-01-21 04:26:53--  http://distfiles.gentoo.org/distfiles/vim-8.2.0360-gentoo-patches.tar.xz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
>>> Downloading 'https://dev.gentoo.org/~zlogene/distfiles/app-editors/vim/vim-8.2.0360-gentoo-patches.tar.xz'
--2022-01-21 04:26:54--  https://dev.gentoo.org/~zlogene/distfiles/app-editors/vim/vim-8.2.0360-gentoo-patches.tar.xz
Resolving dev.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘dev.gentoo.org’
!!! Couldn't download 'vim-8.2.0360-gentoo-patches.tar.xz'. Aborting.
 * Fetch failed for 'app-editors/vim-8.2.3741'
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Fri Jan 21, 2022 4:36 am    Post subject: Reply with quote

strangely enough I can download the file via wget directly:
wget http://distfiles.gentoo.org/distfiles/vim-8.2.0360-gentoo-patches.tar.xz
--2022-01-21 04:35:49-- http://distfiles.gentoo.org/distfiles/vim-8.2.0360-gentoo-patches.tar.xz
Resolving distfiles.gentoo.org... 195.181.175.45, 195.181.175.55, 185.59.220.17, ...
Connecting to distfiles.gentoo.org|195.181.175.45|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2612 (2.6K) [application/x-xz]
Saving to: 'vim-8.2.0360-gentoo-patches.tar.xz'

vim-8.2.0360-gentoo- 100%[=====================>] 2.55K --.-KB/s in 0s

2022-01-21 04:35:50 (6.64 MB/s) - 'vim-8.2.0360-gentoo-patches.tar.xz' saved [2612/2612]
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Sun Jan 23, 2022 1:48 pm    Post subject: Reply with quote

it seems the problem lies within non-root accounts:

Code:
localhost ~ # su - adel
adel@localhost ~ $ ls
adel@localhost ~ $  wget http://distfiles.gentoo.org/distfiles/pkgconfig-1.5.5.tar.gz
--2022-01-23 13:45:14--  http://distfiles.gentoo.org/distfiles/pkgconfig-1.5.5.tar.gz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
adel@localhost ~ $  wget http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz     --2022-01-23 13:46:47--  http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz
Connecting to 185.59.220.18:80... failed: Permission denied.
Retrying.

--2022-01-23 13:46:48--  (try: 2)  http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz
Connecting to 185.59.220.18:80... failed: Permission denied.
Retrying.

--2022-01-23 13:46:50--  (try: 3)  http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz
Connecting to 185.59.220.18:80... failed: Permission denied.
Retrying.

--2022-01-23 13:46:53--  (try: 4)  http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz
Connecting to 185.59.220.18:80... failed: Permission denied.
Retrying.

^C
localhost /var/cache/distfiles # ping distfiles.gentoo.org
PING 1060329950.rsc.cdn77.org (185.59.220.18) 56(84) bytes of data.
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=1 ttl=52 time=72.9 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=2 ttl=52 time=152 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=3 ttl=52 time=79.0 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=4 ttl=52 time=73.2 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=5 ttl=52 time=70.0 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=6 ttl=52 time=70.5 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=7 ttl=52 time=76.3 ms
64 bytes from frankfurt-10.cdn77.com (185.59.220.18): icmp_seq=8 ttl=52 time=67.9 ms
^C
--- 1060329950.rsc.cdn77.org ping statistics ---
8 packets transmitted, 8 received, 0% packet loss, time 7016ms
rtt min/avg/max/mdev = 67.908/82.767/152.297/26.487 ms
localhost /var/cache/distfiles #  wget http://distfiles.gentoo.org/distfiles/pkgconfig-1.5.5.tar.gz
--2022-01-23 13:48:14--  http://distfiles.gentoo.org/distfiles/pkgconfig-1.5.5.tar.gz
Resolving distfiles.gentoo.org... 195.181.175.55, 195.181.175.45, 195.181.174.7, ...
Connecting to distfiles.gentoo.org|195.181.175.55|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 7331 (7.2K) [application/x-gzip]
Saving to: ‘pkgconfig-1.5.5.tar.gz.1’

pkgconfig-1.5.5.tar. 100%[=====================>]   7.16K  --.-KB/s    in 0s

2022-01-23 13:48:15 (115 MB/s) - ‘pkgconfig-1.5.5.tar.gz.1’ saved [7331/7331]


one step closer towards solving the problem
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21631

PostPosted: Sun Jan 23, 2022 5:32 pm    Post subject: Reply with quote

Adel Ahmed wrote:
it seems the problem lies within non-root accounts:
Yes:
Hu wrote:
root may be able to resolve hostnames, but portage cannot. What is the output of ls -l /etc/resolv.conf ; cat -n /etc/resolv.conf?
Adel Ahmed wrote:
Code:
localhost ~ # su - adel
adel@localhost ~ $  wget http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz     --2022-01-23 13:46:47--  http://185.59.220.18/distfiles/pkgconfig-1.5.5.tar.gz
Connecting to 185.59.220.18:80... failed: Permission denied.
This is weird. What is the host system? It is unusual for an unprivileged user to get EACCES on a connect call. Your DNS failure does not surprise me. It is usually a problem with file permissions, which is why I asked in my earlier post for ls -l output. For this, we need to dig deeper. Are you using a mandatory access control system? What kernel is this? Are there any non-standard security features enabled in it?
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Tue Jan 25, 2022 1:28 am    Post subject: Reply with quote

you were right on he first point, non root users did not have access to to read resolv.conf, I've fixed that:
Code:
adel@localhost ~ $ ls -l /etc/resolv.conf ; cat -n /etc/resolv.conf
-rw-r--r-- 1 root root 19 Jan 21 05:01 /etc/resolv.conf
     1  nameserver 8.8.8.8
adel@localhost ~ $ getenforce
-su: getenforce: command not found
adel@localhost ~ $ wget http://distfiles.gentoo.org/distfiles/mlocate-0.26.tar.xz
--2022-01-25 01:27:38--  http://distfiles.gentoo.org/distfiles/mlocate-0.26.tar.xz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’


the host system is an android one, specifically DOTos, I have stopped the android system but maybe something security related is running in the background, I am trying to look into this
Back to top
View user's profile Send private message
Adel Ahmed
Veteran
Veteran


Joined: 21 Sep 2012
Posts: 1523

PostPosted: Sun Jan 30, 2022 4:16 pm    Post subject: Reply with quote

I have repeated the same steps on a galaxy note3, I can ping using regular users but I still cannot emerge:
Code:
portage@localhost ~ $ ping www.google.com
PING www.google.com (142.250.200.196) 56(84) bytes of data.
64 bytes from mrs08s17-in-f4.1e100.net (142.250.200.196): icmp_seq=2 ttl=117 time=74.5 ms
64 bytes from mrs08s17-in-f4.1e100.net (142.250.200.196): icmp_seq=3 ttl=117 time=68.7 ms
64 bytes from mrs08s17-in-f4.1e100.net (142.250.200.196): icmp_seq=4 ttl=117 time=71.6 ms
^C64 bytes from 142.250.200.196: icmp_seq=5 ttl=117 time=69.1 ms

--- www.google.com ping statistics ---
5 packets transmitted, 4 received, 20% packet loss, time 4008ms
rtt min/avg/max/mdev = 68.685/70.979/74.533/2.323 ms

localhost /root # emerge dev-vcs/git

 * IMPORTANT: 13 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.

Calculating dependencies... done!

>>> Verifying ebuild manifests

>>> Emerging (1 of 1) dev-vcs/git-2.34.1::gentoo
Unable to unshare: EINVAL (for FEATURES="ipc-sandbox network-sandbox pid-sandbox")
>>> Downloading 'http://distfiles.gentoo.org/distfiles/layout.conf'
--2022-01-30 16:14:45--  http://distfiles.gentoo.org/distfiles/layout.conf
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
!!! Couldn't download '.layout.conf.distfiles.gentoo.org'. Aborting.
>>> Downloading 'http://distfiles.gentoo.org/distfiles/git-2.34.1.tar.xz'
--2022-01-30 16:14:45--  http://distfiles.gentoo.org/distfiles/git-2.34.1.tar.xz
Resolving distfiles.gentoo.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘distfiles.gentoo.org’
>>> Downloading 'https://www.kernel.org/pub/software/scm/git/git-2.34.1.tar.xz'
--2022-01-30 16:14:45--  https://www.kernel.org/pub/software/scm/git/git-2.34.1.tar.xz
Resolving www.kernel.org... failed: Temporary failure in name resolution.
wget: unable to resolve host address ‘www.kernel.org’
!!! Couldn't download 'git-2.34.1.tar.xz'. Aborting.
 * Fetch failed for 'dev-vcs/git-2.34.1', Log file:
 *  '/var/tmp/portage/dev-vcs/git-2.34.1/temp/build.log'

>>> Failed to emerge dev-vcs/git-2.34.1, Log file:

>>>  '/var/tmp/portage/dev-vcs/git-2.34.1/temp/build.log'

 * Messages for package dev-vcs/git-2.34.1:

 * Fetch failed for 'dev-vcs/git-2.34.1', Log file:
 *  '/var/tmp/portage/dev-vcs/git-2.34.1/temp/build.log'

localhost /root # ls -l /etc/resolv.conf
-rw-r--r-- 1 root root 19 Jan 20 15:25 /etc/resolv.conf
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on ARM All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum