[PATCH] mock _init _umountall
by Paul B Schroeder
Hello all...
Recently, I was doing some work which needed a more extensive /dev than the mock internal dev setup. So I tried doing this in site-defaults.cfg:
config_opts['internal_dev_setup'] = False
config_opts['plugin_conf']['bind_mount_enable'] = True
config_opts['plugin_conf']['bind_mount_opts']['dirs'].append(('/dev', '/dev' ))
And discovered that mock chroot init was failing due _umountall getting called (in _init) before _makeBuildUser. In _makeBuildUser there is a perl command which, for whatever reason, would fail due to /dev/null not being available at that point.
At any rate, the following patch seems to take care of the issue. And it would seem to be a better way to handle this in general as I would expect _umountall to be the last method called.
It would be awesome if this or something similar could be applied..
Thanks...Paul...
diff --git a/py/mock/backend.py b/py/mock/backend.py
index ca06f59..9df438b 100644
--- a/py/mock/backend.py
+++ b/py/mock/backend.py
@@ -282,24 +282,24 @@ class Root(object):
self._mountall()
if self.chrootWasCleaned:
self._yum(self.chroot_setup_cmd, returnOutput=1)
- finally:
- self._umountall()
- # create user
- self._makeBuildUser()
+ # create user
+ self._makeBuildUser()
- # create rpmbuild dir
- self._buildDirSetup()
+ # create rpmbuild dir
+ self._buildDirSetup()
- # set up timezone to match host
- localtimedir = self.makeChrootPath('etc')
- localtimepath = self.makeChrootPath('etc', 'localtime')
- if os.path.exists(localtimepath):
- os.remove(localtimepath)
- shutil.copy2('/etc/localtime', localtimedir)
+ # set up timezone to match host
+ localtimedir = self.makeChrootPath('etc')
+ localtimepath = self.makeChrootPath('etc', 'localtime')
+ if os.path.exists(localtimepath):
+ os.remove(localtimepath)
+ shutil.copy2('/etc/localtime', localtimedir)
- # done with init
- self._callHooks('postinit')
+ # done with init
+ self._callHooks('postinit')
+ finally:
+ self._umountall()
decorate(traceLog())
def _setupDev(self):
--
---
Paul B Schroeder
<paulbsch "at" vbridges "dot" com>
13 years, 5 months
How to make a "minimize" Distribution
by Eric Zhong
FC13 have a "minimize" install option, it will install about 198 pkgs.
Can i make a install ISO just with the 193 pkgs and how can i get the pkg
list ?
Does the revisor can build install tree from the pkg list ?
I want to install it just by select the "minimize" option, and the 198 pkgs
will be installed !
13 years, 5 months
How to use mash ?
by Eric Zhong
How to use mash which to create yum repo from koji tag ?
I can't find any doc form internet.
run "mash --output ~/repo dist-build "
show error below:
ERROR: No configuration named 'dist-build'!
Thanks a lot !
13 years, 5 months
revisor -- sqlite3.OperationalError
by Paul B Schroeder
It looks like this question was asked on Fedora Unity's revisor-users
mailing list a couple weeks ago, but it appears that the list isn't
really active and there was no response. So I thought I'd try here.
At any rate, I'm trying to compose a F12 based distro with revisor and
I'm seeing the following:
Adding Package libgnomekbd-2.28.2-1.fc12.x86_64 in mode u
Member: libutempter.x86_64 0:1.1.5-4.fc12 - u
Adding Package libutempter-1.1.5-4.fc12.x86_64 in mode u
Member: pycairo.x86_64 0:1.8.6-2.fc12 - u
Adding Package pycairo-1.8.6-2.fc12.x86_64 in mode u
Exception <class 'sqlite3.OperationalError'>: unable to open database file
Installing Software:
Installing Software:
######################################## 100.0%
An additional error in the error. The value of errs is: unable to open
database file
An error occurred during the installation of the software you selected,
and an additional error occurred trying to describe what went wrong exactly.
Unmounting directory /var/tmp/revisor
Losetup remove /dev/loop0
Does anybody have any insight as to what may be happening here?
Thanks...Paul...
--
---
Paul B Schroeder
<paulbsch "at" vbridges "dot" com>
13 years, 5 months
Koji error with SSL in internal koji setup.
by Jonathan Dieter
I'm getting this traceback in kojiweb in an internal koji setup that I'm
trying to get working.
I can control koji using the command-line, and I've added new users, so
I think that means the kojihub certificate is fine. Kojiweb works fine
until I try to login, and that's when I get this traceback.
I'm using certificates that I've issued using dogtag, but I don't think
that should have any relevance. My user and server certs are all using
the same CA.
Anyone have any thoughts on where I should look?
Thanks,
Jonathan
Traceback (most recent call last):
File "/usr/share/koji-web/lib/kojiweb/publisher.py", line 16, in
publish_object
return old_publish_object(req, object)
File "/usr/lib64/python2.4/site-packages/mod_python/publisher.py",
line 412, in publish_object
return publish_object(req,util.apply_fs_data(object, req.form,
req=req))
File "/usr/lib64/python2.4/site-packages/mod_python/util.py", line
439, in apply_fs_data
return object(**args)
File "/usr/share/koji-web/scripts/index.py", line 183, in login
if not _sslLogin(req, session, username):
File "/usr/share/koji-web/scripts/index.py", line 70, in _sslLogin
proxyuser=username)
File "/usr/lib/python2.4/site-packages/koji/__init__.py", line 1458,
in ssl_login
sinfo = self.callMethod('sslLogin', proxyuser)
File "/usr/lib/python2.4/site-packages/koji/__init__.py", line 1503,
in callMethod
return self._callMethod(name, args, opts)
File "/usr/lib/python2.4/site-packages/koji/__init__.py", line 1548,
in _callMethod
raise err
Fault: <Fault 1: "exceptions.AttributeError: 'NoneType' object has no
attribute 'split'">
13 years, 5 months
yum / createrepo version for CentOS 5 builder
by Jonathan Dieter
Is there a specific yum or createrepo version I need to install on a
CentOS 5.5 server so it can build packages for a child repository whose
parent is Fedora 13?
mergerepos is exiting with an error:
Traceback (most recent call last):
File "/usr/libexec/kojid/mergerepos", line 229, in ?
main(sys.argv[1:])
File "/usr/libexec/kojid/mergerepos", line 224, in main
merge.write_metadata()
File "/usr/libexec/kojid/mergerepos", line 205, in write_metadata
mdgen.doRepoMetadata()
File "/usr/lib/python2.4/site-packages/createrepo/__init__.py", line
789, in doRepoMetadata
rp.getPrimary(complete_path, csum)
File "/usr/lib64/python2.4/site-packages/sqlitecachec.py", line 42, in
getPrimary
self.repoid))
TypeError: Parsing primary.xml error: attributes construct error
I'm assuming this is because of the new sha256 checksums introduced a
release or two back.
Jonathan
13 years, 5 months
pungi error
by kala
Dear Friends
I am trying to build a custom spin of fedora 12 using
pungi, and I am stuck at this error and I couldnt find a roundabout, please
help me through it, i am pasting the error from the log
####log####
yum.verbose.YumBase.DEBUG: using local copy of
xml-commons-apis-1.3.04-3.5.fc12.i686
Pungi.INFO: Finished downloading packages.
Pungi.INFO: Making repodata
Pungi.INFO: Running /usr/bin/repoview --quiet --state-dir
/usr/share/odv3/repoviewcache --title "Opendiscovery 3.0 - i386"
/home/nandhu/Desktop/3.0/i386/os
Pungi.INFO: Running /usr/lib/anaconda-runtime/buildinstall --product
Opendiscovery --version 3.0 --release "Opendiscovery 3.0" --bugurl
https://bugzilla.redhat.com --output /home/nandhu/Desktop/3.0/i386/os
--mirrorlist
http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-12&arch=i386--mir...
http://mirrors.fedoraproject.org/mirrorlist?repo=updates-released-f12&arc...
Pungi.DEBUG: Running buildinstall...
/tmp/buildinstall.tree.MymJkK /tmp
./anaconda-12.46-2.fc12.i686.rpm already exists and appears to be complete
/tmp
Building images...
Assembling package list...
Fri Jun 18 01:45:50 IST 2010 Expanding packages...
Error: Cannot retrieve repository metadata (repomd.xml) for repository:
anaconda-mirrorlistrepo-1. Please verify its path and try again
Could not retrieve mirrorlist
http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-12&arch=i386 error
was
14: PYCURL ERROR 6 - ""
ERROR: could not install packages
Aborting instroot creation...
Aborting buildinstall
upd-instroot failed
Pungi.ERROR: Got an error from /usr/lib/anaconda-runtime/buildinstall
Pungi.ERROR: Cannot retrieve repository metadata (repomd.xml) for
repository: anaconda-mirrorlistrepo-1. Please verify its path and try again
I am happy to provide any other info, but need to solve this
with regards
kala bharath
13 years, 5 months
Problem with createrepo for modified DVD ISO
by Digimer
Hi all,
I hope this is the right list to ask this. Please let me know if not.
I've been trying to create my own (minorly) custom distro for Fedora
13. All it really is is a custom kickstart and a changed up set of RPMs.
My problem is; I've added some RPMs and removed others, so I need to
regenerate the files in dvd:/repodata to properly reflect what is in
dvd:/Packages. I've tried various incantations of 'createrepo Packages/'
but none seem to work. When I move the generated files into
dvd:/repodata, roll the ISO, burn and install, the installer complains
that the repo data is bad (sorry, I don't have the exact error at the
moment).
So then, what is the magic incantation to properly regenerate the
repodata for a modified Packages directory on a DVD?
Thanks!
--
Digimer
E-Mail: linux(a)alteeve.com
AN!Whitepapers: http://alteeve.com
Node Assassin: http://nodeassassin.org
13 years, 5 months
koji spin-livecd can't seen to generate a working desktop iso
by Doug Reiland
I have not been able to generate a working graphic iso
Using /usr/share/spin-kickstarts stuff as examples. For example,
fedora-livecd-desktop.ks
I copy this file and read in whatever %include there are so I have 1 .ks file.
perfdm fails to start/crashses on boot.
Any ideas?
Note, I attended to "validated" the .ks file via revisor, but revisor
gets hidden errors on any ks file after doing the mount /dev/loop....
13 years, 5 months