<ProtocolError for localhost:25151/cobbler_api: 404 Not Found>
by John Paget Bourke
Hi,
When I run
koan --list=profiles -s localhost
I get the following error
root@Config cobbler]# koan --list=profiles -s localhost
- looking for Cobbler at http://localhost:25151/cobbler_api
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/koan/utils.py", line 542, in
__try_connect
xmlrpc_server.ping()
File "/usr/lib64/python2.6/xmlrpclib.py", line 1199, in __call__
return self.__send(self.__name, args)
File "/usr/lib64/python2.6/xmlrpclib.py", line 1489, in __request
verbose=self.__verbose
File "/usr/lib64/python2.6/xmlrpclib.py", line 1243, in request
headers
ProtocolError: <ProtocolError for localhost:25151/cobbler_api: 404 Not
Found>
If I try to see if the server is running and listening, the server is ok
[root@Config cobbler]# netstat -an | grep 25151
tcp 0 0 127.0.0.1:25151 0.0.0.0:*
LISTEN
tcp 0 0 127.0.0.1:25151 127.0.0.1:57483
TIME_WAIT
But returns nothing .
[root@Config cobbler]# curl http://localhost:25151/cobbler_api
curl: (52) Empty reply from server
I am using the web GUI and it works ok, no problems.
When I try to use koan or curl and check the logs
[root@Config cobbler]# curl http://localhost:25151/cobbler_api
curl: (52) Empty reply from server
[root@Config cobbler]# date
Sun Oct 30 05:30:55 UTC 2011
[root@Config cobbler]# ls -l
total 1792
drwxr-xr-x. 2 root root 4096 Oct 6 02:24 anamon
-rw-r--r--. 1 root root 1806499 Oct 30 04:50 cobbler.log
-rw-r--r-- 1 root root 73 Oct 29 00:24 install.log
drwxr-xr-x. 2 root root 4096 Oct 6 02:24 kicklog
drwxr-xr-x. 2 root root 4096 Oct 6 02:24 syslog
drwxr-xr-x. 2 root root 4096 Oct 30 04:40 tasks
[root@Config cobbler]# cd /etc/httpd/logs/
[root@Config logs]# ls -l
total 3172
-rw-r--r-- 1 root root 10904 Oct 30 04:45 access_log
-rw-r--r--. 1 root root 789779 Oct 30 02:43 access_log-20111030
-rw-r--r-- 1 root root 32638 Oct 30 05:20 error_log
-rw-r--r--. 1 root root 2403267 Oct 30 03:06 error_log-20111030
The logs do not seem to be affected.
The versions I am running are
[root@Config cobbler]# rpm -qa | grep cobbler
cobbler-2.2.1-1.el6.noarch
cobbler-web-2.2.1-1.el6.noarch
[root@Config cobbler]# rpm -qa | grep koan
koan-2.2.1-1.el6.noarch
In the modules.conf I have
[authentication]
#module = authn_denyall
module = authn_configfile
[authorization]
module = authz_allowall
So I am a bit lost. Any thoughts ?
Thanks
John
10 years, 2 months
Windows install with Cobbler
by Janet.Conkle@afscn.com
Has anyone been successful in installing windows using cobbler? I've
found a few things on the net but nothing definitive. I need a tool
that will install baseline images on lab boxes of both the linux and
Windows flavors.
Janet Conkle
ETG
x5343
11 years, 6 months
Wiki port of manage docs now up / edit away!
by Michael DeHaan
For those that are interested in helping with docs, manage docs are now ported over to the Wiki, in a few parts.
https://github.com/cobbler/cobbler/wiki/Start%20Here
This is pretty much most of the manage, which I think should stay more or less together. If you split things into too many Wiki pages, it's hard to absorb things via osmosis. I would like to mix the examples in closer to the job though and incorporate more examples throughout, so if you're a new user you don't get bored/confused and wonder what commands you actually care about running.
https://github.com/cobbler/cobbler/wiki/Advanced%20Topics
For topics in Advanced Topics that already had a Wiki page, we should make sure any info there is mentioned in those pages and then just link to them, so Advanced Topics can eventually go away as a catch all. For instance, all the info about DHCP management should already be covered elsewhere, but the stuff about PXE boot loop prevention does not, so that deserves it's own page.
https://github.com/cobbler/cobbler/wiki/Koan
Koan's docs -- notice to understand the configuration management features that Kelsey Hightower wrote, you have to skip between the two manages, so there are probably some implied topics that could be created, and the existing configuration management section could probably mention it there. That's just one of many though.
Once these get hammered out a bit I'll replace the .pod files in the docs tree to more or less just link to the Wiki.
Thanks!
--Michael
12 years, 2 months
snippet without LVM (CentOS 6)
by Frank
Merry Christmas to you All:
Someone on this list helped me over a year ago to set up Cobbler ...
now version 2.0.11.
I do have the following question:
As it is set up now, Cobbler installs CentOS 5 or 6 on servers using
LVM, Cluster Logical Volume Manager (see here:
http://www.centos.org/docs/5/html/Cluster_Logical_Volume_Manager/).
That has created lots of problems for me when e.g. I try to replace
one of two disks in a server (loosing data of one of the disks). It
is really complicated. It would therefore be VERY helpful if one of
you could be so very kind to post a full sample "partition_select"
snippet for a server with two disks with a standard setup -- not LVM.
Here is how then now looks presently in my Cobbler install:
(1)
/var/lib/cobbler/snippets/partition_select
---------
%include /tmp/partinfo
%pre
# Determine how many drives we have
set \$(list-harddrives)
let numd=\$#/2
d1=\$1
d2=\$3
#set $vgname = "VolGroup00"
#set $vgbackupname = "VolGroup01"
if [ ! -z \$d1 ]
then
cat << EOF > /tmp/partinfo
part /boot --fstype ext4 --size=140 --ondisk=\$d1
part pv.1 --size=1024 --grow --ondisk=\$d1
part pv.2 --size=1024 --grow --ondisk=\$d2
volgroup $vgname pv.1
volgroup $vgbackupname pv.2
logvol /tmp --fstype ext4 --name=tmp --vgname=$vgname --size=4096
logvol swap --fstype swap --name=swap --vgname=$vgname --size=1024
--grow --maxsize=4096
logvol /usr --fstype ext4 --name=usr --vgname=$vgname --size=18432
logvol / --fstype ext4 --name=root --vgname=$vgname --size=20480 --grow
logvol /backup --fstype ext4 --name=backup --vgname=$vgbackupname
--size=20480 --grow
EOF
else
cat << EOF > /tmp/partinfo
part /boot --fstype ext4 --size=140 --ondisk=\$d1
part pv.1 --size=1024 --grow --ondisk=\$d1
volgroup $vgname pv.1
logvol /tmp --fstype ext4 --name=tmp --vgname=$vgname --size=4096
logvol swap --fstype swap --name=swap --vgname=$vgname --size=1024
--grow --maxsize=4096
logvol /usr --fstype ext4 --name=usr --vgname=$vgname --size=18432
logvol / --fstype ext4 --name=root --vgname=$vgname --size=20480 --grow
EOF
fi
---------
And the kickstarts file for CentOS 6 looks like this:
(2)
/var/lib/cobbler/kickstarts/centos6.ks
---------
url --url=$tree
lang en_US.UTF-8
keyboard us
reboot
skipx
text
network --device eth0 --bootproto dhcp
rootpw --iscrypted $default_password_crypted
firewall --disabled
authconfig --enableshadow --enablemd5
selinux --disabled
timezone Europe/Berlin
zerombr
bootloader --location=mbr --append="rhgb quiet"
clearpart --all --initlabel
$SNIPPET('partition_select6')
%pre
$kickstart_start
$SNIPPET('log_ks_pre')
$SNIPPET('pre_install_network_config')
$SNIPPET('pre_anamon')
%packages --nobase
coreutils
yum
rpm
e2fsprogs
lvm2
sysstat
ntp
openssh-server
openssh-clients
wget
authconfig
sudo
man
man-pages
nano
rdate
%post
$SNIPPET('post_install_network_config')
$SNIPPET('post_install_kernel_options')
$SNIPPET('post_anamon')
$SNIPPET('log_ks_post')
$SNIPPET('cobbler_register')
$kickstart_done
----------
THANK YOU !
Frank
12 years, 4 months
cobbler replication problem
by Siddharth Deshpande
hi folks..
i'm facing trouble with cobbler replication. hope someone can help.
basically, the '--omit-data' switch seems to prevent anything being
synced at all.. so even though the replication returns success, i still
don't get the list of distros, repos or profiles.
but if i run it without '--omit-data', then it seems to work.. though
that also pulls in all the distro mirrors and stuff which i don't want.
wanted to know if that is expected behaviour, or is something going wrong?
--
TIA,
siddharth.
12 years, 4 months
can't update profile when it's updated by API
by Shuichi Ihara
Hi,
I'm updating the profile in system object with the following quick Python script and the profile seems to be updated.
#!/usr/bin/python
import re, codecs
import cobbler.api as api
cobbler = api.BootAPI()
system = cobbler.find_system(name="r07")
print system.profile
system.set_profile("rhel5.7")
cobbler.add_system(system)
print system.profile
But, "cobbler system report" shows still old profile name. Here is an sample.
# cobbler system report --name=r07 | grep Profile
Profile : rhel6.2
# ./update_profile.py
rhel6.2
rhel5.7
# ./update_profile.py
rhel5.7
rhel5.7
# cobbler system report --name=r07 | grep Profile
Profile : rhel6.2
When I restart the coblblerd, the profile is updated even on "cobbler system".
# /etc/init.d/cobblerd restart
# cobbler system report --name=r07 | grep Profile
Profile : rhel5.7
Am I wrong or missing something in Python script?
Please advise.
Thanks
Ihara
12 years, 4 months
SELinux on Scientific Linux 6.x
by Johan Sunnerstig
Hello.
I'm in the process of setting up Cobbler on an SL 6.1 box.
Currently I'm using 2.0.11 from the EPEL repo.
I *think* I have the SELinux issues worked out, but it'd be nice to know, so I figured I'd ask if anyone else has set this up, and if there's any documentation for it?
I've set the the fcontexts as suggested by "cobbler check", this isn't reflected in subsequent runs but from what Google could tell me, this seems to be fairly normal? On the other hand there seems to be lots of confusion surrounding Cobbler and SELinux.
I suppose what I'm really asking is if there's anyone who can set the record straight on what needs to be done to make Cobbler and SELinux play nice together, or whether SELinux should just be disabled alltogether for now, pending changes to the selinux-policy package?
Regards
Johan Sunnerstig
12 years, 4 months
updated to 2.2.1 - can't import RHEL6.2
by Rainer Duffner
Hi,
I updated my install to the latest version in epel-testing.
I'm not sure if this would have worked before, but I tried importing
RHEL6.2:
cobbler import --path=/mnt --name=RHEL6.2 --arch=x86_64
it starts working on it, but at the end I get this:
...
sent 3515473856 bytes received 70326 bytes 12577975.61 bytes/sec
total size is 3514763663 speedup is 1.00
received on stderr:
adding distros
creating new distro: RHEL6.2-x86_64
Exception occured: exceptions.AttributeError
Exception value: 'NoneType' object has no attribute 'os_version'
Exception Info:
File "/usr/lib/python2.4/site-packages/cobbler/remote.py", line 93,
in run rc = self._run(self)
File "/usr/lib/python2.4/site-packages/cobbler/remote.py", line 232,
in runner self.logger
File "/usr/lib/python2.4/site-packages/cobbler/api.py", line 759, in
import_tree return
manager.run(pkgdir,mirror_url,mirror_name,network_root,kickstart_file,rsync_flags,arch,breed,os_version)
File
"/usr/lib/python2.4/site-packages/cobbler/modules/manage_import_redhat.py",
line 267, in run os.path.walk(self.path, self.distro_adder,
distros_added) File "/usr/lib/python2.4/posixpath.py", line 298, in
walk walk(name, func, arg) File "/usr/lib/python2.4/posixpath.py", line
298, in walk walk(name, func, arg) File
"/usr/lib/python2.4/posixpath.py", line 290, in walk func(arg, top,
names) File
"/usr/lib/python2.4/site-packages/cobbler/modules/manage_import_redhat.py",
line 511, in distro_adder
adtls.append(self.add_entry(dirname,kernel,initrd)) File
"/usr/lib/python2.4/site-packages/cobbler/modules/manage_import_redhat.py",
line 582, in add_entry self.distros.add(distro,save=True) File
"/usr/lib/python2.4/site-packages/cobbler/collection.py", line 316, in
add self.lite_sync.add_single_distro(ref.name) File
"/usr/lib/python2.4/site-packages/cobbler/action_litesync.py", line 76,
in add_single_distro self.sync.pxegen.make_pxe_menu() File
"/usr/lib/python2.4/site-packages/cobbler/pxegen.py", line 299, in
make_pxe_menu self.make_actual_pxe_menu() File
"/usr/lib/python2.4/site-packages/cobbler/pxegen.py", line 396, in
make_actual_pxe_menu profile=None, distro=None, arch=image.arch,
image=image) File "/usr/lib/python2.4/site-packages/cobbler/pxegen.py",
line 582, in write_pxe_file elif distro.os_version.startswith("esxi"):
!!! TASK FAILED !!!
I have no ESX-images imported, so I'm a bit baffled why this would show
up.
Any ideas?
Best Regards
Rainer
12 years, 4 months
Need everyone helping out with the bug queue
by Michael DeHaan
Hi folks,
So while I was in the process of making comments on Trac tickets about the github move, I noticed there were a large amount of tickets that have been left open for a rather large amount of time -- several hundred, many open for over a year. This is bad and will ultimately destroy any piece of software. Scott, James, and I can't manage this alone.
While I'm sure not all of these are active bugs, and some are more like ideas or support requests, I don't want to see the queue get in this state again. That's our record of what's broke or not broke -- so it needs to be small at all times. Here's the challenge and ultimatum to you:
(1) We will not release with a bug queue in that state again. Full stop.
(2) Our next release should be about releasing with as low of a bug count as possible.
(3) More people absolutely need to be committing and fixing bugs. This means everyone.
As this list is full of immensely talented sysadmins, I think we can all shoulder the load and make this pretty darn easy. The more work everyone does, the less work everyone does.
That makes sense! So here's your new years resolution, which is also the requirement for success of the project.
(1) new bug queue to bookmark -- http://github.com/cobbler/cobbler/issues -- it's small now, but expect it to grow as people move things over from Trac. Bookmark it.
(2) Learn Python if you don't know it, we'll help on #cobbler and cobbler-devel list as much as possible. If you know it, help others here learn it. There was a "Learn to Hack on
Cobbler Week" once. Let's make that every day and multiply the contributor pool. Like Tribbes. (Did I mention OSS contributions look great on your resume? They do).
Join the development list if you haven't already.
(3) Fix bugs and send in pull requests, and close bug tickets that are user error with explanations of what the users should be doing. Help keep the bug queue extra small and the master branch very high quality. If you're submitting a feature or a bug fix for something that affects you, also try to fix some bugs that don't affect you. If you are submitting a bug, see if you can also accompany that bug report with a fix.
If we all do this, we can release quicker, have a higher quality app, and have more time for amazing new features. For those starting and those that have already been helping alike, thank you very much!
And may everyone enjoy flying their Christmas Sharks.
12 years, 4 months
Fwd: snippet keep_ssh_host_keys not running in background
by Detlev Habicht
Hi again,
well, i found no solution. (The first part was my fault - as i already told, patching
cobbler helps.)
But i found no solution for the background job problems.
I tested all the hints i got. Nothing worked. Thank you for your help.
I also used the newest bash version. I tried to split the snippet in two parts and so on.
It looks, like it is not possible to start a background job in the %pre section of a
kickstart file and maybe also in the %post section. (When i use terminal access via ALT F2
it is possible to start background jobs via shell while the system is installed!!!)
So, maybe this is not a cobbler problem and i am wrong here with my problem.
Thanx again
Detlev
--
Detlev | Institut fuer Mikroelektronische Systeme
Habicht | D-30167 Hannover +49 511 76219662 habicht(a)ims.uni-hannover.de
--------+-------- Handy +49 172 5415752 ---------------------------
Am 21.12.2011 um 11:28 schrieb Detlev Habicht:
>
> Hi all,
>
> i am testing the snippet keep_ssh_host_keys.
>
> Well, i am a beginner in cobbler and maybe my problem is a bash problem, but
> when i use keep_ssh_host_keys i have two problems:
>
> When i use keep_ssh_host_keys as snippet, i see while kickstart is running:
>
> Unknown command: <!DOCTYPE
>
> Why?
>
> Well, than i put the whole keep_ssh_host_keys script in my kickstart file
> and now the script is running until the last part (i can see, the keys are
> saved in /tmp):
>
> # Loop until the corresponding rpm is installed
> if [ "$keys_found" = "yes" ]; then
> while : ; do
> sleep 10
> if [ -d /mnt/sysimage$SEARCHDIR ] ; then
> cp -af /tmp/$TEMPDIR/${PATTERN}* /mnt/sysimage$SEARCHDIR
> logger "keys copied to newly installed system"
> break
> fi
> done &
> fi
>
> The kickstart process stopped and i think the loop is running, but not
> in the background, so the installation process cannot proceed.
>
> Why?
>
> Thanx for any help!
>
> Detlev
>
> --
> Detlev | Institut fuer Mikroelektronische Systeme
> Habicht | D-30167 Hannover +49 511 76219662 habicht(a)ims.uni-hannover.de
> --------+-------- Handy +49 172 5415752 ---------------------------
>
>
> _______________________________________________
> cobbler mailing list
> cobbler(a)lists.fedorahosted.org
> https://fedorahosted.org/mailman/listinfo/cobbler
12 years, 4 months