Getting rid of bad cobbler metavariables
by Adam Rosenwald
A FAQ that I have brought up on numerous occasions on IRC involves
'getting rid of bad cobbler metavariables'.
If I were to set a wrong ks_meta variable NAME, how do I get rid of the
NAME without taking out ks_meta entirely.
E.g.
`cobbler system add --name=NAME --ksmeta='arg0=val0 arg1=val1
*art2*=val2 ... argN=valN' ...`
There are quite a number of scenarios where I don't want to remove all
of ksmeta, but only a mistyped variable name. I have heard about the
'!ARG' syntax:
E.g.
`cobbler system edit --in-place --name=NAME --ksmeta='*!art2*'`
Supposedly this syntax will, upon deserialization of the JSON, clear the
ks_meta namespace of *art2*; however, upon issuing a report on a given
entity, the flawed variable will still appear along with the negated
variable.
I.e.
ks_meta : 'arg0=val0 arg1=val1 *art2*=*val2* ... argN=valN *!art2*'
For those who make use of this data for inventory or other purposes, the
'!VAR' notation does not cut it. I would like a definitive explanation
of how to remove bad metavariables irrespective of deserialization.
Thanks,
- A.
14 years, 2 months
RHEL 5.3 failure: repodata/primary.xml.gz
by CLIFFORD ILKAY
Hello,
I read a post
<https://fedorahosted.org/pipermail/cobbler/2009-April/003838.html> that
describes the same problem I'm having trying to install CentOS 5.3 via
Cobbler.
I created a CentOS 5.3 profile, mirrored a bunch of CentOS 5.3 repos,
and the first problem I encountered was that the CentOS choked on the
kickstart file that I've been using on Fedora 10 and 11. I removed lines
from the file until it no longer complained. I got as far as the
"Retrieving installation information" right after I selected the
timezone and got an error:
"Unable to read package metadata. This may be due to missing repodata
directory. Please ensure that your install tree has been correctly
generated. failure: repodata/primary.xml.gz from
anaconda-base-2009-3211311.x86_64: [Errno 256] No more mirrors to try."
I've run "cobbler sync" and "cobbler reposync" already. How do I work
around this?
--
Regards,
Clifford Ilkay
Dinamis
1419-3266 Yonge St.
Toronto, ON
Canada M4N 3P6
<http://dinamis.com>
+1 416-410-3326
14 years, 5 months
cobbler repo rename
by Baptiste AGASSE
Hi all,
Today i have rename a repo in cobbler. The rename works but all data of this repository has been deleted.
Is it a normal behavior of "cobbler repo rename --name=myoldname --newname=mynewname" ?
Thanks for your answers.
Baptiste.
14 years, 6 months
cobbler image file issues
by Thomas S Hatch
I figure I am missing soumthing obvious, but here goes.
When I define a cobbler image the protocol gets hacked off! So I run this
command:
cobbler image edit --file='nfs://192.168.41.76:/cobbler/ks_mirror/WinLite.iso'
--name='windows_test_1'
then I run a report:
image : windows_test_1
arch : i386
breed : windows
comment :
created : Thu Aug 13 13:30:29 2009
file : 192.168.41.76:/cobbler/ks_mirror/WinLite.iso
image type : iso
kickstart : /var/lib/cobbler/kickstarts/base.ks
modified : Thu Aug 13 13:59:46 2009
os version :
owners : ['admin']
virt bridge : br0
virt cpus : 1
network count : 1
virt file size : 15
virt path : /vm/images/
virt ram : 512
virt type : qemu
and the nfs:// is missing from the file field. So I try to install anyway:
koan --server=192.168.41.76 --virt --image='windows_test_1'
and I get this:
- looking for Cobbler at http://192.168.41.76/cobbler_api
- reading URL: http://192.168.41.76/cblr/svc/op/ks/profile/windows_test_1
warning: kickstart found but no install_tree found
libvirtd (pid 2182) is running...
- using qemu hypervisor, type=kvm
Thu, 13 Aug 2009 14:01:11 DEBUG No conn passed to Guest, opening URI
'qemu:///system'
<type 'exceptions.ValueError'>
Install media location must be an NFS, HTTP or FTP network install source,
or an existing file/device
File "/usr/lib/python2.6/site-packages/koan/app.py", line 204, in main
k.run()
File "/usr/lib/python2.6/site-packages/koan/app.py", line 312, in run
self.virt()
File "/usr/lib/python2.6/site-packages/koan/app.py", line 601, in virt
return self.net_install(after_download)
File "/usr/lib/python2.6/site-packages/koan/app.py", line 520, in
net_install
after_download(self, profile_data)
File "/usr/lib/python2.6/site-packages/koan/app.py", line 599, in
after_download
self.virt_net_install(profile_data)
File "/usr/lib/python2.6/site-packages/koan/app.py", line 1080, in
virt_net_install
virt_type = self.virt_type
File "/usr/lib/python2.6/site-packages/koan/qcreate.py", line 91, in
start_install
guest.cdrom = input_path
File "/usr/lib/python2.6/site-packages/virtinst/Guest.py", line 380, in
set_cdrom
self._installer.location = val
File "/usr/lib/python2.6/site-packages/virtinst/DistroInstaller.py", line
138, in set_location
raise ValueError(_("Install media location must be an NFS, HTTP "
What might I be missing?
-Tom Hatch
14 years, 6 months
Sending email from cobbler
by Paul Company
I set "build_reporting_enabled: 1" and filled in the appropriate
"build_reporting_*" fields
but I don't get an email after a system has finished installing.
I tested it manually from my cobbler server:
# telnet <build_reportin_smtp_server> 25
HELO <cobbler server fqdn>
MAIL FROM <build_reporting_sender>
RCPT TO <build_reporting_email>
DATA
Subject: <build_reporting_subject>
test
.
This works just fine.
What triggers the email to be sent?
Am I missing an entry in the kickstart file?
(Assuming it's triggered from the kickstart file).
What program or method does cobbler use to send email?
Does it just open a socket to port 25 and talk SMTP?
Or does it use telnet or sendmail?
Where does cobbler log such information.
I grepped /var/log/cobbler/*.log, /var/log/maillog and
/var/log/messages for any information, but didn't see anything email
related.
Should I see something in /var/lib/cobbler/triggers/install/post or does cobbler
just use /etc/cobbler/reporting/build_report_email.template internally?
Thanks,
Paul
14 years, 6 months
How to you manage yum and package "workflow" ?
by Michael DeHaan
I'm curious if anyone out there uses (or does not use!) a workflow where
they might have some packages or repos that are for different levels of
workflow.
For instance, seperate environments for "devel", "Q/A" (test), "stage",
or "production" -- having at least two levels, but maybe more?
In other words, is there an app that you develop that needs to be
deployed to different levels of servers as it passes various checkpoints?
(What tools and processes are involved in those checkpoints?)
If you have setups like this, how do you manage them with Cobbler and
other tools? What is your workflow, or do you have one?
Thanks!
--Michael
14 years, 7 months
cloning images with koan --virt
by Jakub Hrozek
Hello,
we're using cobbler+koan to kickstart Fedora and RHEL installs.
However, as I understand, it is not possible to use koan to start
virtualized install of other distributions, let alone Windows.
So I was hoping I could get "gold image" cloning working. I hit #472
and worked around it by providing an empty kickstart, then worked
around #483 by making the image available directly (mounted the NFS
share). But I'm getting another error:
----
koan --virt --image karmic-master-image --virt-name karmic-clone
- looking for Cobbler at http://10.16.78.1/cobbler_api
- reading URL: http://10.16.78.1/cblr/svc/op/ks/profile/karmic-master-image
warning: kickstart found but no install_tree found
libvirtd (pid 2847) is running...
<type 'exceptions.AttributeError'>
Boot instance has no attribute 'disks'
File "/usr/lib/python2.5/site-packages/koan/app.py", line 204, in main
k.run()
File "/usr/lib/python2.5/site-packages/koan/app.py", line 312, in run
self.virt()
File "/usr/lib/python2.5/site-packages/koan/app.py", line 601, in virt
return self.net_install(after_download)
File "/usr/lib/python2.5/site-packages/koan/app.py", line 520, in net_install
after_download(self, profile_data)
File "/usr/lib/python2.5/site-packages/koan/app.py", line 599, in
after_download
self.virt_net_install(profile_data)
File "/usr/lib/python2.5/site-packages/koan/app.py", line 1080, in
virt_net_install
virt_type = self.virt_type
File "/usr/lib/python2.5/site-packages/koan/imagecreate.py", line
157, in start_install
process_disk(image, boot, profile_data["file"], disks[0][0], "hda")
File "/usr/lib/python2.5/site-packages/koan/imagecreate.py", line
84, in process_disk
boot.disks.append(drive)
----
This is a fully updated Fedora 10. The image type is virt_clone and
the underlying HV is KVM/qemu.
Has anyone hit this error? Should this cloning approach work at all?
Thanks,
Jakub
14 years, 7 months
no mode specified | cobbler 1.6.6 post-upgrade.
by Alex Davies
Hi All,
I have been playing around with our cobbler install and the web
interface now says "no mode specified" to all files at /cblr/svc/ and
below.
I suspect this was due to a upgrade but we don't use the web interface
much so did not notice. However, unfortunately,
/cblr/svc/opt/ks/system/hostname also does not work so I can't
kickstart anything! I am running two different servers (master/slave)
on cobbler 1.6.6 on RHEL5.
The RPM --verify shows that everything is as expected (we remove the
snippets we don't use):
[root@gcisvlin-cobbler cobbler]# rpm --verify cobbler
S.5....T c /etc/cobbler/dhcp.template
S.5....T c /etc/cobbler/settings
S.5....T c /etc/cobbler/users.digest
S.5....T c /etc/httpd/conf.d/cobbler.conf
missing c /var/lib/cobbler/snippets/cobbler_register
missing c /var/lib/cobbler/snippets/download_config_files
missing c /var/lib/cobbler/snippets/func_install_if_enabled
missing c /var/lib/cobbler/snippets/func_register_if_enabled
missing c /var/lib/cobbler/snippets/keep_ssh_host_keys
missing c /var/lib/cobbler/snippets/koan_environment
missing c /var/lib/cobbler/snippets/main_partition_select
missing c /var/lib/cobbler/snippets/network_config
missing c /var/lib/cobbler/snippets/partition_select
missing c /var/lib/cobbler/snippets/post_anamon
missing c /var/lib/cobbler/snippets/post_install_kernel_options
missing c /var/lib/cobbler/snippets/post_install_network_config
missing c /var/lib/cobbler/snippets/post_s390_reboot
missing c /var/lib/cobbler/snippets/pre_anamon
missing c /var/lib/cobbler/snippets/pre_install_network_config
missing c /var/lib/cobbler/snippets/pre_partition_select
missing c /var/lib/cobbler/snippets/redhat_register
A brief google indicated something about templates missing (which
would make complete sense), but I would expect that to appear in rpm
--verify. There is nothing of relevance in cobblerd, cobbler or apache
error logs. Any guesses?
Many thanks,
Alex
I'll buy anyone with an idea a beer next week at the Summit :)
14 years, 7 months
yum upgrade to 1.2.6-1.el5
by Harry Hoffman
Just upgraded to the latest cobbler from epel-testing... the
post-install script fails :-(
Updating : cobbler ####################### [ 5/10]
profile CentOS-5.2-x86_64 not found, inheritance not possible
Stopping cobbler daemon: [ OK ]
Starting cobbler daemon: Traceback (most recent call last):
File "/usr/bin/cobblerd", line 32, in ?
api = bootapi.BootAPI()
File "/usr/lib/python2.4/site-packages/cobbler/api.py", line 90, in
__init__
self.deserialize()
File "/usr/lib/python2.4/site-packages/cobbler/api.py", line 448, in
deserialize
return self._config.deserialize()
File "/usr/lib/python2.4/site-packages/cobbler/config.py", line 186,
in deserialize
serializer.deserialize(self._profiles)
File "/usr/lib/python2.4/site-packages/cobbler/serializer.py", line
125, in deserialize
rc = storage_module.deserialize(obj,topological)
File
"/usr/lib/python2.4/site-packages/cobbler/modules/serializer_yaml.py",
line 136, in deserialize
obj.from_datastruct(datastruct)
File "/usr/lib/python2.4/site-packages/cobbler/collection.py", line
144, in from_datastruct
item = self.factory_produce(self.config,seed_data)
File
"/usr/lib/python2.4/site-packages/cobbler/collection_profiles.py", line
41, in factory_produce
return profile.Profile(config).from_datastruct(seed_data)
File "/usr/lib/python2.4/site-packages/cobbler/item_profile.py", line
87, in from_datastruct
self.set_parent(self.parent)
File "/usr/lib/python2.4/site-packages/cobbler/item_profile.py", line
131, in set_parent
raise CX(_("profile %s not found, inheritance not possible") %
parent_name)
cobbler.cexceptions.CX: 'profile CentOS-5.2-x86_64 not found,
inheritance not possible'
[FAILED]
error: %post(cobbler-1.2.6-1.el5.noarch) scriptlet failed, exit status 1
Any ideas?
Cheers,
Harry
14 years, 7 months
Re: kickstarting ESX?
by Simon Woolsgrove
--- hyclak(a)ohio.edu wrote:
From: Matthew Hyclak <hyclak(a)ohio.edu>
To: cobbler mailing list <cobbler(a)lists.fedorahosted.org>
Subject: Re: kickstarting ESX?
Date: Wed, 26 Aug 2009 12:44:58 -0400
On 08/26/09 12:40, Patrick Nixon enlightened us:
> On Wed, Aug 26, 2009 at 11:54 AM, Matthew Hyclak<hyclak(a)ohio.edu> wrote:
> > On 08/26/09 16:41, Dick Davies enlightened us:
> >> Turns out ESX supports kickstarting; has anyone tried importing
> >> an ESX ISO?
> >>
> >> If not, no worries. I'll try it tomorrow and let you know how I get on.
> >
> > We did, but we've punted and reverted to putting the kickstart file(s) on the
> > CD. The big problem we ran into is the inability to PXE boot on trunked
> > network connections, and even when they were simple access port connections
> > the ESX 3.5 install timed out before our Cisco 6500's would bring the port
> > up. (RHEL 3 has the same problem). We assume vSphere 4 would fix that, but
> > that doesn't get us around the trunk issue.
> >
> > Matt
> >
> > --
> > Matt Hyclak
> > Systems and Operations
> > Office of Information Technology
> > Ohio University
> > (740) 593-1222
> >
> Matthew,
> Did you turn off spanning-tree on the port before you tried to
> kickstart over it?
> No, as I don't control the network infrastructure. My understanding is even
> with that off, you can't PXE boot on a trunk port, and we configure all of
> our ESX boxes as trunks so we only have to add VLANs when a new network is
> needed.
> Matt
> --
> Matt Hyclak
> Systems and Operations
> Office of Information Technology
> Ohio University
> (740) 593-1222
We are using cobbler for vsphere4 as others have highlighted below, we use cobbler buildiso and virtual media as have
a static ip requirement :( This gets you stage1 so this may help you, though you need the buildiso patch that allows
ksdevice=vmnic0 / ksdevice=<mac>.
Cheers,
Simon
_______________________________________________
cobbler mailing list
cobbler(a)lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/cobbler
14 years, 7 months