Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Catalyst: Building stage1: Failed to get a list of profiles.
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
cmrd
n00b
n00b


Joined: 13 Jul 2014
Posts: 44

PostPosted: Tue Feb 18, 2020 10:10 pm    Post subject: Catalyst: Building stage1: Failed to get a list of profiles. Reply with quote

Hi,

I'm trying to use catalyst to build a customised gentoo based livecd.

To familiarise myself with the tool I am trying to build stage1 as described in the https://wiki.gentoo.org/wiki/Catalyst wiki article.

These are the steps I have taken so far:

Code:

cd /tmp

# clone the releng repo
git clone https://anongit.gentoo.org/git/proj/releng.git

# make a temp directory
mkdir catalyst1 && cd catalyst1

# copy the stage 1 spec
cp /tmp/releng/releases/weekly/specs/amd64/stage1.spec .

# make a portage snapshot
catalyst -s 2020.02

# get a stage3 archive
wget http://distfiles.gentoo.org/releases/amd64/autobuilds/current-stage3-amd64/stage3-amd64-20200216T214502Z.tar.xz
mv current-stage3-amd64/stage3-amd64-20200216T214502Z.tar.xz /var/tmp/catalyst/builds/default/stage3-amd64-latest.tar.xz

# try creating a stage1
catalyst -f stage1.spec
18 Feb 2020 22:02:53 -00: NOTICE  : Loading configuration file: /etc/catalyst/catalyst.conf
18 Feb 2020 22:02:53 -00: NOTICE  : conf_values[options] = {'bindist', 'pkgcache', 'seedcache', 'snapcache', 'kerncache'}
18 Feb 2020 22:02:53 -00: NOTICE  : Processing spec file: stage1.spec
18 Feb 2020 22:02:53 -00: NOTICE  : Using target: stage1
18 Feb 2020 22:02:53 -00: NOTICE  : Source file specification matching setting is: strict
18 Feb 2020 22:02:53 -00: NOTICE  : Accepted source file extensions search order: ['tar', 'tar.xz', 'tpxz', 'xz', 'tar.bz2', 'bz2', 'tbz2', 'tar.gz', 'gz']
18 Feb 2020 22:02:54 -00: NOTICE  : Source path set to /var/tmp/catalyst/builds/default/stage3-amd64-latest.tar.xz
18 Feb 2020 22:02:54 -00: NOTICE  : stage1 stage path is /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/stage1root
18 Feb 2020 22:02:54 -00: NOTICE  : --- Running action sequence: unpack
18 Feb 2020 22:02:54 -00: NOTICE  : Referenced SEEDCACHE does not appear to be a directory, trying to untar...
18 Feb 2020 22:02:54 -00: NOTICE  : Clearing the chroot path ...
18 Feb 2020 22:02:54 -00: NOTICE  : Emptying directory: /var/tmp/catalyst/tmp/default/stage1-amd64-latest
18 Feb 2020 22:02:55 -00: NOTICE  : Starting auto from /var/tmp/catalyst/builds/default/stage3-amd64-latest.tar.xz
18 Feb 2020 22:02:55 -00: NOTICE  : to /var/tmp/catalyst/tmp/default/stage1-amd64-latest (this may take some time) ..
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: unpack_snapshot
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: setup_confdir
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: portage_overlay
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: base_dirs
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: bind
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: chroot_setup
18 Feb 2020 22:03:07 -00: NOTICE  : Setting up chroot...
18 Feb 2020 22:03:07 -00: WARNING : Overriding certain env variables may cause catastrophic failure.
18 Feb 2020 22:03:07 -00: WARNING : If your build fails look here first as the possible problem.
18 Feb 2020 22:03:07 -00: WARNING : Catalyst assumes you know what you are doing when setting these variables.
18 Feb 2020 22:03:07 -00: WARNING : Catalyst Maintainers use VERY minimal envscripts, if used at all.
18 Feb 2020 22:03:07 -00: WARNING : You have been warned.
18 Feb 2020 22:03:07 -00: NOTICE  : Writing the stage make.conf to: /var/tmp/catalyst/tmp/default/stage1-amd64-latest/etc/portage/make.conf
18 Feb 2020 22:03:07 -00: NOTICE  : STICKY-CONFIG is enabled
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: setup_environment
18 Feb 2020 22:03:07 -00: NOTICE  : --- Running action sequence: run_local
copying make.conf to /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/stage1root/etc/portage
Copying stage1-chroot.sh to /tmp
copying stage1-chroot.sh to /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp
copying chroot-functions.sh to /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp
Ensure the file has the executable bit set
Running stage1-chroot.sh in chroot:
    chroot /var/tmp/catalyst/tmp/default/stage1-amd64-latest /tmp/stage1-chroot.sh
>>> Regenerating /etc/ld.so.cache...
Your profile seems to be broken.
Could not build a list of build packages.
Double check your /etc/portage/make.profile link and the 'packages' files.
18 Feb 2020 22:03:08 -00: ERROR   : CatalystError: cmd(['/usr/share/catalyst/targets/stage1/stage1-controller.sh', 'run']) exited 1
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/tmp/portage is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: ERROR   : CatalystError: Stage build aborting due to error.
18 Feb 2020 22:03:08 -00: ERROR   : Exception running action sequence run_local
Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/catalyst/base/stagebase.py", line 1366, in run_local
    env=self.env)
  File "/usr/lib64/python3.6/site-packages/catalyst/support.py", line 54, in cmd
    print_traceback=False)
catalyst.support.CatalystError: cmd(['/usr/share/catalyst/targets/stage1/stage1-controller.sh', 'run']) exited 1

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/catalyst/base/stagebase.py", line 1471, in run
    getattr(self, x)()
  File "/usr/lib64/python3.6/site-packages/catalyst/base/stagebase.py", line 1375, in run_local
    print_traceback=False)
catalyst.support.CatalystError: Stage build aborting due to error.
18 Feb 2020 22:03:08 -00: NOTICE  : Cleaning up... Running unbind()
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/kerncache is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/cache/binpkgs is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/stage1root/proc is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/run is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/dev/shm does not exist. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/dev/pts does not exist. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/tmp/portage is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/cache/distfiles is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/db/repos/gentoo is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/dev is not a mount point. Skipping
18 Feb 2020 22:03:08 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/proc is not a mount point. Skipping


How would I troubleshoot this?
Back to top
View user's profile Send private message
Phoenix591
Guru
Guru


Joined: 17 Sep 2007
Posts: 495

PostPosted: Wed Feb 19, 2020 1:30 pm    Post subject: Reply with quote

sounds like a bad snapshot. Check the portdir in catalyst.conf is correct.
Back to top
View user's profile Send private message
cmrd
n00b
n00b


Joined: 13 Jul 2014
Posts: 44

PostPosted: Thu Mar 19, 2020 9:53 pm    Post subject: Reply with quote

The specfile appears to have been part of the issue.

I downloaded and verified via checksum a new snapshot and tried again:

My spec file - I had to change the portage_confdir as I couldn't get how to substitute @REPO_DIR@ without modifying the file:

Code:

subarch: amd64
target: stage1
version_stamp: latest
rel_type: default
profile: default/linux/amd64/17.1
snapshot: latest
source_subpath: default/stage3-amd64-latest
compression_mode: pixz_x
decompressor_search_order: tar pixz xz lbzip2 bzip2 gzip
update_seed: yes
update_seed_command: --update --deep @world
portage_confdir: /tmp/cat/releng/releases/weekly/portage/stages
portage_prefix: releng


my catalyst.conf (without comments). I've not made any changes:

Code:

digests="sha512 whirlpool"
contents="auto"
distdir="/var/cache/distfiles"
envscript="/etc/catalyst/catalystrc"
hash_function="crc32"
options="autoresume bindist kerncache pkgcache seedcache snapcache"
portdir="/var/db/repos/gentoo"
repo_basedir="/var/db/repos"
repo_name="gentoo"
target_distdir="/var/cache/distfiles"
target_pkgdir="/var/cache/binpkgs"
sharedir="/usr/share/catalyst"
shdir="%(sharedir)s/targets"
snapshot_cache="/var/tmp/catalyst/snapshot_cache"
storedir="/var/tmp/catalyst"
source_matching="strict"


Output of catalyst -f stage1.spec:
Code:

19 Mar 2020 21:38:27 -00: NOTICE  : Loading configuration file: /etc/catalyst/catalyst.conf
19 Mar 2020 21:38:27 -00: NOTICE  : conf_values[options] = {'autoresume', 'bindist', 'snapcache', 'kerncache', 'pkgcache', 'seedcache'}
19 Mar 2020 21:38:27 -00: NOTICE  : Processing spec file: stage1.spec
19 Mar 2020 21:38:27 -00: NOTICE  : Using target: stage1
19 Mar 2020 21:38:27 -00: NOTICE  : Source file specification matching setting is: strict
19 Mar 2020 21:38:27 -00: NOTICE  : Accepted source file extensions search order: ['tar', 'tar.xz', 'tpxz', 'xz', 'tar.bz2', 'bz2', 'tbz2', 'tar.gz', 'gz']
19 Mar 2020 21:38:27 -00: NOTICE  : Source path set to /var/tmp/catalyst/builds/default/stage3-amd64-latest
19 Mar 2020 21:38:27 -00: NOTICE  : stage1 stage path is /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/stage1root
19 Mar 2020 21:38:27 -00: NOTICE  : Resume point detected, skipping target path setup operation...
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: unpack
19 Mar 2020 21:38:27 -00: NOTICE  : Referenced SEEDCACHE does not appear to be a directory, trying to untar...
19 Mar 2020 21:38:27 -00: NOTICE  : Resume: "chroot" is valid...
19 Mar 2020 21:38:27 -00: NOTICE  : Resume: "seed source" hash matches chroot...
19 Mar 2020 21:38:27 -00: NOTICE  : Resume: Valid resume point detected, skipping seed unpack operation...
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: unpack_snapshot
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: setup_confdir
19 Mar 2020 21:38:27 -00: NOTICE  : Resume point detected, skipping setup_confdir operation...
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: portage_overlay
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: base_dirs
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: bind
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: chroot_setup
19 Mar 2020 21:38:27 -00: NOTICE  : Resume point detected, skipping chroot_setup operation...
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: setup_environment
19 Mar 2020 21:38:27 -00: NOTICE  : --- Running action sequence: run_local
copying make.conf to /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/stage1root/etc/portage
Copying stage1-chroot.sh to /tmp
copying stage1-chroot.sh to /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp
copying chroot-functions.sh to /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp
Ensure the file has the executable bit set
Running stage1-chroot.sh in chroot:
    chroot /var/tmp/catalyst/tmp/default/stage1-amd64-latest /tmp/stage1-chroot.sh
19 Mar 2020 21:38:28 -00: ERROR   : CatalystError: cmd(['/usr/share/catalyst/targets/stage1/stage1-controller.sh', 'run']) exited 1
19 Mar 2020 21:38:28 -00: ERROR   : CatalystError: Stage build aborting due to error.
19 Mar 2020 21:38:28 -00: ERROR   : Exception running action sequence run_local
Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/catalyst/base/stagebase.py", line 1366, in run_local
    env=self.env)
  File "/usr/lib64/python3.6/site-packages/catalyst/support.py", line 54, in cmd
    print_traceback=False)
catalyst.support.CatalystError: cmd(['/usr/share/catalyst/targets/stage1/stage1-controller.sh', 'run']) exited 1

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/catalyst/base/stagebase.py", line 1471, in run
    getattr(self, x)()
  File "/usr/lib64/python3.6/site-packages/catalyst/base/stagebase.py", line 1375, in run_local
    print_traceback=False)
catalyst.support.CatalystError: Stage build aborting due to error.
19 Mar 2020 21:38:28 -00: NOTICE  : Cleaning up... Running unbind()
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/kerncache is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/cache/binpkgs is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/tmp/stage1root/proc is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/run is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/dev/shm does not exist. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/dev/pts does not exist. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/tmp/portage is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/cache/distfiles is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/var/db/repos/gentoo is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/dev is not a mount point. Skipping
19 Mar 2020 21:38:28 -00: NOTICE  : /var/tmp/catalyst/tmp/default/stage1-amd64-latest/proc is not a mount point. Skipping


When I run chroot /var/tmp/catalyst/tmp/default/stage1-amd64-latest /tmp/stage1-chroot.sh on my machine it errors with file not found, but I'm not sure how to find out *which* file isn't found.

Any advice how to troubleshoot?
Back to top
View user's profile Send private message
dol-sen
Retired Dev
Retired Dev


Joined: 30 Jun 2002
Posts: 2805
Location: Richmond, BC, Canada

PostPosted: Wed Apr 29, 2020 4:12 pm    Post subject: Reply with quote

After failures like this, it is best to zap the failed chroot and make it start fresh.

start catalyst with the -a or -p option. Once a chroot is messed up like this it usually can't be restarted.

Resuming a catalyst run is normally only for failures requiring changes to package use flag changes, etc..
_________________
Brian
Porthole, the Portage GUI frontend irc@freenode: #gentoo-guis, #porthole, Blog
layman, gentoolkit, CoreBuilder, esearch...
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming 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