[PATCH] Rename anamon.py -> anamon
by James Laska
---
MANIFEST.in | 2 +-
aux/anamon | 263 ++++++++++++++++++++++++++++++++++++++++++++++++++
aux/anamon.init | 6 +-
aux/anamon.py | 263 --------------------------------------------------
cobbler.spec | 6 +-
setup.py | 2 +-
snippets/post_anamon | 6 +-
snippets/pre_anamon | 4 +-
8 files changed, 275 insertions(+), 277 deletions(-)
create mode 100644 aux/anamon
delete mode 100644 aux/anamon.py
diff --git a/MANIFEST.in b/MANIFEST.in
index 22e55a7..6532779 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -19,7 +19,7 @@ include config/users.conf
include config/completions
include config/cobbler_bash
include config/cheetah_macros
-include aux/anamon.py
+include aux/anamon
include aux/anamon.init
recursive-include templates *.template
recursive-include installer_templates *.template defaults
diff --git a/aux/anamon b/aux/anamon
new file mode 100644
index 0000000..fe4d0eb
--- /dev/null
+++ b/aux/anamon
@@ -0,0 +1,263 @@
+#!/usr/bin/python
+
+"""
+This is a script used to automatically log details from an Anaconda
+install back to a cobbler server.
+
+Copyright 2008, Red Hat, Inc
+various(a)redhat.com
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA
+"""
+
+import os
+import sys
+import string
+import time
+import re
+import base64
+import shlex
+
+# on older installers (EL 2) we might not have xmlrpclib
+# and can't do logging, however this is more widely
+# supported than remote syslog and also provides more
+# detail.
+try:
+ import xmlrpclib
+except ImportError, e:
+ print "xmlrpclib not available, exiting"
+ sys.exit(0)
+
+# shlex.split support arrived in python-2.3, the following will provide some
+# accomodation for older distros (e.g. RHEL3)
+if not hasattr(shlex, "split"):
+ shlex.split = lambda s: s.split(" ")
+
+class WatchedFile:
+ def __init__(self, fn, alias):
+ self.fn = fn
+ self.alias = alias
+ self.reset()
+
+ def reset(self):
+ self.where = 0
+ self.last_size = 0
+ self.lfrag=''
+ self.re_list={}
+ self.seen_line={}
+
+ def exists(self):
+ return os.access(self.fn, os.F_OK)
+
+ def lookfor(self,pattern):
+ self.re_list[pattern] = re.compile(pattern,re.MULTILINE)
+ self.seen_line[pattern] = 0
+
+ def seen(self,pattern):
+ if self.seen_line.has_key(pattern):
+ return self.seen_line[pattern]
+ else:
+ return 0
+
+ def changed(self):
+ if not self.exists():
+ return 0
+ size = os.stat(self.fn)[6]
+ if size > self.last_size:
+ self.last_size = size
+ return 1
+ else:
+ return 0
+
+ def uploadWrapper(self, blocksize = 262144):
+ """upload a file in chunks using the uploadFile call"""
+ retries = 3
+ fo = file(self.fn, "r")
+ totalsize = os.path.getsize(self.fn)
+ ofs = 0
+ while True:
+ lap = time.time()
+ contents = fo.read(blocksize)
+ size = len(contents)
+ data = base64.encodestring(contents)
+ if size == 0:
+ offset = -1
+ sz = ofs
+ else:
+ offset = ofs
+ sz = size
+ del contents
+ tries = 0
+ while tries <= retries:
+ debug("upload_log_data('%s', '%s', %s, %s, ...)\n" % (name, self.alias, sz, offset))
+ if session.upload_log_data(name, self.alias, sz, offset, data):
+ break
+ else:
+ tries = tries + 1
+ if size == 0:
+ break
+ ofs += size
+ fo.close()
+
+ def update(self):
+ if not self.exists():
+ return
+ if not self.changed():
+ return
+ try:
+ self.uploadWrapper()
+ except:
+ raise
+
+class MountWatcher:
+
+ def __init__(self,mp):
+ self.mountpoint = mp
+ self.zero()
+
+ def zero(self):
+ self.line=''
+ self.time = time.time()
+
+ def update(self):
+ fd = open('/proc/mounts')
+ found = 0
+ while 1:
+ line = fd.readline()
+ if not line:
+ break
+ parts = string.split(line)
+ mp = parts[1]
+ if mp == self.mountpoint:
+ found = 1
+ if line != self.line:
+ self.line = line
+ self.time = time.time()
+ if not found:
+ self.zero()
+ fd.close()
+
+ def stable(self):
+ self.update()
+ if self.line and (time.time() - self.time > 60):
+ return 1
+ else:
+ return 0
+
+def anamon_loop():
+ alog = WatchedFile("/tmp/anaconda.log", "anaconda.log")
+ alog.lookfor("step installpackages$")
+
+ slog = WatchedFile("/tmp/syslog", "sys.log")
+ llog = WatchedFile("/tmp/lvmout", "lvmout.log")
+ kcfg = WatchedFile("/tmp/ks.cfg", "ks.cfg")
+ scrlog = WatchedFile("/tmp/ks-script.log", "ks-script.log")
+ dump = WatchedFile("/tmp/anacdump.txt", "anacdump.txt")
+ mod = WatchedFile("/tmp/modprobe.conf", "modprobe.conf")
+ ilog = WatchedFile("/mnt/sysimage/root/install.log", "install.log")
+ ilog2 = WatchedFile("/mnt/sysimage/tmp/install.log", "tmp+install.log")
+ ulog = WatchedFile("/mnt/sysimage/root/upgrade.log", "upgrade.log")
+ ulog2 = WatchedFile("/mnt/sysimage/tmp/upgrade.log", "tmp+upgrade.log")
+ sysimage = MountWatcher("/mnt/sysimage")
+
+ # Were we asked to watch specific files?
+ if watchfiles:
+ watchlist = []
+ waitlist = []
+
+ # Create WatchedFile objects for each requested file
+ for watchfile in watchfiles:
+ if os.path.exists(watchfile):
+ watchfilebase = os.path.basename(watchfile)
+ watchlog = WatchedFile(watchfile, watchfilebase)
+ watchlist.append(watchlog)
+
+ # Use the default watchlist and waitlist
+ else:
+ watchlist = [alog, slog, dump, scrlog, mod, llog, kcfg]
+ waitlist = [ilog, ilog2, ulog, ulog2]
+
+ # Monitor loop
+ while 1:
+ time.sleep(5)
+
+ # Not all log files are available at the start, we'll loop through the
+ # waitlist to determine when each file can be added to the watchlist
+ for watch in waitlist:
+ if alog.seen("step installpackages$") or (sysimage.stable() and watch.exists()):
+ debug("Adding %s to watch list\n" % watch.alias)
+ watchlist.append(watch)
+ waitlist.remove(watch)
+
+ # Send any updates
+ for wf in watchlist:
+ wf.update()
+
+ # If asked to run_once, exit now
+ if exit:
+ break
+
+# Establish some defaults
+name = ""
+server = ""
+port = "80"
+daemon = 1
+debug = lambda x,**y: None
+watchfiles = []
+exit = False
+
+# Process command-line args
+n = 0
+while n < len(sys.argv):
+ arg = sys.argv[n]
+ if arg == '--name':
+ n = n+1
+ name = sys.argv[n]
+ elif arg == '--watchfile':
+ n = n+1
+ watchfiles.extend(shlex.split(sys.argv[n]))
+ elif arg == '--exit':
+ exit = True
+ elif arg == '--server':
+ n = n+1
+ server = sys.argv[n]
+ elif arg == '--port':
+ n = n+1
+ port = sys.argv[n]
+ elif arg == '--debug':
+ debug = lambda x,**y: sys.stderr.write(x % y)
+ elif arg == '--fg':
+ daemon = 0
+ n = n+1
+
+# Create an xmlrpc session handle
+session = xmlrpclib.Server("http://%s:%s/cobbler_api" % (server, port))
+
+# Fork and loop
+if daemon:
+ if not os.fork():
+ # Redirect the standard I/O file descriptors to the specified file.
+ DEVNULL = getattr(os, "devnull", "/dev/null")
+ os.open(DEVNULL, os.O_RDWR) # standard input (0)
+ os.dup2(0, 1) # Duplicate standard input to standard output (1)
+ os.dup2(0, 2) # Duplicate standard input to standard error (2)
+
+ anamon_loop()
+ sys.exit(1)
+ sys.exit(0)
+else:
+ anamon_loop()
+
diff --git a/aux/anamon.init b/aux/anamon.init
index b2fd982..d029c88 100644
--- a/aux/anamon.init
+++ b/aux/anamon.init
@@ -48,7 +48,7 @@ fi
start() {
echo -n $"Starting anamon: "
- daemon /usr/local/sbin/anamon.py --watchfile \"$LOGFILES\" --name $COBBLER_NAME --server $COBBLER_SERVER --port ${COBBLER_PORT:-80} --exit
+ daemon /usr/local/sbin/anamon --watchfile \"$LOGFILES\" --name $COBBLER_NAME --server $COBBLER_SERVER --port ${COBBLER_PORT:-80} --exit
RETVAL=$?
[ $RETVAL -eq 0 ] && touch $LOCKFILE
echo
@@ -61,7 +61,7 @@ start() {
stop () {
echo -n $"Shutting down anamon: "
- killproc /usr/local/sbin/anamon.py
+ killproc /usr/local/sbin/anamon
RETVAL=$?
[ $RETVAL -eq 0 ] && rm -f $LOCKFILE
echo
@@ -89,7 +89,7 @@ case "$1" in
fi
;;
status)
- status anamon.py
+ status anamon
RETVAL=$?
;;
*)
diff --git a/aux/anamon.py b/aux/anamon.py
deleted file mode 100644
index fe4d0eb..0000000
--- a/aux/anamon.py
+++ /dev/null
@@ -1,263 +0,0 @@
-#!/usr/bin/python
-
-"""
-This is a script used to automatically log details from an Anaconda
-install back to a cobbler server.
-
-Copyright 2008, Red Hat, Inc
-various(a)redhat.com
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA
-"""
-
-import os
-import sys
-import string
-import time
-import re
-import base64
-import shlex
-
-# on older installers (EL 2) we might not have xmlrpclib
-# and can't do logging, however this is more widely
-# supported than remote syslog and also provides more
-# detail.
-try:
- import xmlrpclib
-except ImportError, e:
- print "xmlrpclib not available, exiting"
- sys.exit(0)
-
-# shlex.split support arrived in python-2.3, the following will provide some
-# accomodation for older distros (e.g. RHEL3)
-if not hasattr(shlex, "split"):
- shlex.split = lambda s: s.split(" ")
-
-class WatchedFile:
- def __init__(self, fn, alias):
- self.fn = fn
- self.alias = alias
- self.reset()
-
- def reset(self):
- self.where = 0
- self.last_size = 0
- self.lfrag=''
- self.re_list={}
- self.seen_line={}
-
- def exists(self):
- return os.access(self.fn, os.F_OK)
-
- def lookfor(self,pattern):
- self.re_list[pattern] = re.compile(pattern,re.MULTILINE)
- self.seen_line[pattern] = 0
-
- def seen(self,pattern):
- if self.seen_line.has_key(pattern):
- return self.seen_line[pattern]
- else:
- return 0
-
- def changed(self):
- if not self.exists():
- return 0
- size = os.stat(self.fn)[6]
- if size > self.last_size:
- self.last_size = size
- return 1
- else:
- return 0
-
- def uploadWrapper(self, blocksize = 262144):
- """upload a file in chunks using the uploadFile call"""
- retries = 3
- fo = file(self.fn, "r")
- totalsize = os.path.getsize(self.fn)
- ofs = 0
- while True:
- lap = time.time()
- contents = fo.read(blocksize)
- size = len(contents)
- data = base64.encodestring(contents)
- if size == 0:
- offset = -1
- sz = ofs
- else:
- offset = ofs
- sz = size
- del contents
- tries = 0
- while tries <= retries:
- debug("upload_log_data('%s', '%s', %s, %s, ...)\n" % (name, self.alias, sz, offset))
- if session.upload_log_data(name, self.alias, sz, offset, data):
- break
- else:
- tries = tries + 1
- if size == 0:
- break
- ofs += size
- fo.close()
-
- def update(self):
- if not self.exists():
- return
- if not self.changed():
- return
- try:
- self.uploadWrapper()
- except:
- raise
-
-class MountWatcher:
-
- def __init__(self,mp):
- self.mountpoint = mp
- self.zero()
-
- def zero(self):
- self.line=''
- self.time = time.time()
-
- def update(self):
- fd = open('/proc/mounts')
- found = 0
- while 1:
- line = fd.readline()
- if not line:
- break
- parts = string.split(line)
- mp = parts[1]
- if mp == self.mountpoint:
- found = 1
- if line != self.line:
- self.line = line
- self.time = time.time()
- if not found:
- self.zero()
- fd.close()
-
- def stable(self):
- self.update()
- if self.line and (time.time() - self.time > 60):
- return 1
- else:
- return 0
-
-def anamon_loop():
- alog = WatchedFile("/tmp/anaconda.log", "anaconda.log")
- alog.lookfor("step installpackages$")
-
- slog = WatchedFile("/tmp/syslog", "sys.log")
- llog = WatchedFile("/tmp/lvmout", "lvmout.log")
- kcfg = WatchedFile("/tmp/ks.cfg", "ks.cfg")
- scrlog = WatchedFile("/tmp/ks-script.log", "ks-script.log")
- dump = WatchedFile("/tmp/anacdump.txt", "anacdump.txt")
- mod = WatchedFile("/tmp/modprobe.conf", "modprobe.conf")
- ilog = WatchedFile("/mnt/sysimage/root/install.log", "install.log")
- ilog2 = WatchedFile("/mnt/sysimage/tmp/install.log", "tmp+install.log")
- ulog = WatchedFile("/mnt/sysimage/root/upgrade.log", "upgrade.log")
- ulog2 = WatchedFile("/mnt/sysimage/tmp/upgrade.log", "tmp+upgrade.log")
- sysimage = MountWatcher("/mnt/sysimage")
-
- # Were we asked to watch specific files?
- if watchfiles:
- watchlist = []
- waitlist = []
-
- # Create WatchedFile objects for each requested file
- for watchfile in watchfiles:
- if os.path.exists(watchfile):
- watchfilebase = os.path.basename(watchfile)
- watchlog = WatchedFile(watchfile, watchfilebase)
- watchlist.append(watchlog)
-
- # Use the default watchlist and waitlist
- else:
- watchlist = [alog, slog, dump, scrlog, mod, llog, kcfg]
- waitlist = [ilog, ilog2, ulog, ulog2]
-
- # Monitor loop
- while 1:
- time.sleep(5)
-
- # Not all log files are available at the start, we'll loop through the
- # waitlist to determine when each file can be added to the watchlist
- for watch in waitlist:
- if alog.seen("step installpackages$") or (sysimage.stable() and watch.exists()):
- debug("Adding %s to watch list\n" % watch.alias)
- watchlist.append(watch)
- waitlist.remove(watch)
-
- # Send any updates
- for wf in watchlist:
- wf.update()
-
- # If asked to run_once, exit now
- if exit:
- break
-
-# Establish some defaults
-name = ""
-server = ""
-port = "80"
-daemon = 1
-debug = lambda x,**y: None
-watchfiles = []
-exit = False
-
-# Process command-line args
-n = 0
-while n < len(sys.argv):
- arg = sys.argv[n]
- if arg == '--name':
- n = n+1
- name = sys.argv[n]
- elif arg == '--watchfile':
- n = n+1
- watchfiles.extend(shlex.split(sys.argv[n]))
- elif arg == '--exit':
- exit = True
- elif arg == '--server':
- n = n+1
- server = sys.argv[n]
- elif arg == '--port':
- n = n+1
- port = sys.argv[n]
- elif arg == '--debug':
- debug = lambda x,**y: sys.stderr.write(x % y)
- elif arg == '--fg':
- daemon = 0
- n = n+1
-
-# Create an xmlrpc session handle
-session = xmlrpclib.Server("http://%s:%s/cobbler_api" % (server, port))
-
-# Fork and loop
-if daemon:
- if not os.fork():
- # Redirect the standard I/O file descriptors to the specified file.
- DEVNULL = getattr(os, "devnull", "/dev/null")
- os.open(DEVNULL, os.O_RDWR) # standard input (0)
- os.dup2(0, 1) # Duplicate standard input to standard output (1)
- os.dup2(0, 2) # Duplicate standard input to standard error (2)
-
- anamon_loop()
- sys.exit(1)
- sys.exit(0)
-else:
- anamon_loop()
-
diff --git a/cobbler.spec b/cobbler.spec
index 33033e9..73a39f1 100644
--- a/cobbler.spec
+++ b/cobbler.spec
@@ -165,10 +165,8 @@ test "x$RPM_BUILD_ROOT" != "x" && rm -rf $RPM_BUILD_ROOT
%dir /var/www/cobbler/aux
%defattr(444,apache,apache)
/var/www/cobbler/webui/*
-%ghost /var/www/cobbler/aux/anamon.pyc
-%ghost /var/www/cobbler/aux/anamon.pyo
-/var/www/cobbler/aux/*.py
-/var/www/cobbler/aux/*.init
+/var/www/cobbler/aux/anamon
+/var/www/cobbler/aux/anamon.init
%defattr(755,root,root)
%{_bindir}/cobbler
diff --git a/setup.py b/setup.py
index d42d787..5d6b3b3 100644
--- a/setup.py
+++ b/setup.py
@@ -331,7 +331,7 @@ if __name__ == "__main__":
(wwwcon, ['webui_content/cobblerweb.css']),
# Anamon script
- (vw_aux, ['aux/anamon.py', 'aux/anamon.init']),
+ (vw_aux, ['aux/anamon', 'aux/anamon.init']),
# Directories to hold cobbler triggers
("%s/add/distro/pre" % trigpath, []),
diff --git a/snippets/post_anamon b/snippets/post_anamon
index fc33cfa..816a0c1 100644
--- a/snippets/post_anamon
+++ b/snippets/post_anamon
@@ -1,13 +1,13 @@
#if $str($getVar('anamon_enabled','')) == "1"
## install anamon script
-wget -O /usr/local/sbin/anamon.py "http://$server/cobbler/aux/anamon.py"
+wget -O /usr/local/sbin/anamon "http://$server/cobbler/aux/anamon"
## install anamon system service
wget -O /etc/rc.d/init.d/anamon "http://$server/cobbler/aux/anamon.init"
## adjust permissions
-chmod 755 /etc/rc.d/init.d/anamon /usr/local/sbin/anamon.py
-test -d /selinux && restorecon /etc/rc.d/init.d/anamon /usr/local/sbin/anamon.py
+chmod 755 /etc/rc.d/init.d/anamon /usr/local/sbin/anamon
+test -d /selinux && restorecon /etc/rc.d/init.d/anamon /usr/local/sbin/anamon
## enable the script
chkconfig --add anamon
diff --git a/snippets/pre_anamon b/snippets/pre_anamon
index 636dc1b..5d38bda 100644
--- a/snippets/pre_anamon
+++ b/snippets/pre_anamon
@@ -1,4 +1,4 @@
#if $str($getVar('anamon_enabled','')) == "1"
-wget -O /tmp/anamon.py "http://$server/cobbler/aux/anamon.py"
-python /tmp/anamon.py --name "$name" --server "$server" --port "$http_port"
+wget -O /tmp/anamon "http://$server/cobbler/aux/anamon"
+python /tmp/anamon --name "$name" --server "$server" --port "$http_port"
#end if
--
1.6.0.6
15 years, 2 months
Small fix to Spacewalk server patch
by Robert Lazzurs
Hello all,
On IRC today leenuxg33k noticed an error with the patch I did work on
for the ability to define a Spacewalk server per
distro/profile/system.
I have pushed the fix out to the lazzurs-master branch on my github
account, commit 6660966ecfa2c192aa9b43067220eff36cb4b17c. If I should
reference the commit in another way then please let me know :)
Take care.
15 years, 2 months
[PATCH] - fix xmlrpc_hacks
by Bill Peck
This patch is against master. Without this the web interface is broken.
>From 39e9890fcdb88afca8739971c56930e014452122 Mon Sep 17 00:00:00 2001
From: Bill Peck <bpeck(a)redhat.com>
Date: Sat, 7 Mar 2009 09:13:53 -0500
Subject: [PATCH] remove else which caused all data to be ~
---
cobbler/remote.py | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/cobbler/remote.py b/cobbler/remote.py
index 10e9cc2..6fdb96f 100644
--- a/cobbler/remote.py
+++ b/cobbler/remote.py
@@ -906,9 +906,6 @@ class CobblerXMLRPCInterface:
data2[str(key)] = self.xmlrpc_hacks(data[key])
return data2
- else:
- data = '~'
-
return data
def get_status(self,**rest):
--
1.6.0.6
15 years, 2 months
Re: Fedora 10 Live CD PXE Boot
by JAmes Atwill
----- "Michael DeHaan" <mdehaan(a)redhat.com> wrote:
> You'll need to share the results of "cobbler distro report" for the
[root@cobbler DOM]# cobbler distro report --name=F10-live
distro : F10-live
architecture : i386
breed : redhat
created : Wed Feb 18 19:55:16 2009
comment :
initrd : /media/cobbler/DOM/F10-livecd/initrd0.img
kernel : /media/cobbler/DOM/F10-livecd/vmlinuz0
kernel options : {'rootflags': 'loop', '!ksdevice': None, '!text': None, 'root': '/F10-i686-Live.iso', 'rootfstype': 'iso9660', '!lang': None}
ks metadata : {}
tree build time : Wed Dec 31 16:00:00 1969
modified : Thu Feb 19 10:45:40 2009
mgmt classes : []
os version :
owners : ['admin']
post kernel options : {}
redhat mgmt key : <<inherit>>
template files : {}
> ISO in question.or cat the tftp config file you are using and also the
[root@cobbler ~]# cat /tftpboot/pxelinux.cfg/default
..other labels snipped..
LABEL F10-live
kernel /images/F10-live/vmlinuz0
MENU LABEL F10-live
append initrd=/images/F10-live/initrd0.img rootflags=loop root=/F10-i686-Live.iso syslog=10.19.10.30:25150 rootfstype=iso9660 kssendmac ks=http://10.19.10.30/cblr/svc/op/ks/profile/F10-live
ipappend 2
....other labels snipped...
> share the one created by livecd-iso-to-pxeboot so
[root@cobbler DOM]# cat tftpboot/pxelinux.cfg/default
DEFAULT pxeboot
TIMEOUT 20
PROMPT 0
LABEL pxeboot
KERNEL vmlinuz0
APPEND initrd=initrd0.img root=/F10-i686-Live.iso rootfstype=iso9660 rootflags=loop
ONERROR LOCALBOOT 0
Hope this helps,
JAmes
15 years, 2 months
Importing Scientific Linux and Other Import Questions
by Chris O'Regan
I am about to mirror Scientific Linux and I would appreciate any
recommendations you may have. I did find some documentation on the SL
web site regarding mirroring but it seems a bit out-of-date. I think it
refers to SL3x.
Basically, I want to mirror both i386 and x86_64 branches of SL53. One
problem is that each architecture branch contains both the installation
image and the updates. I think I can get around this by importing with
rsync and carefully crafting a bunch of excludes to hide the content
that will change. Is there anything else that I should exclude?
More general questions...
If memory serves me, cobbler import will use the value of --name as a
prefix when naming distributions/profiles. So, if I import SL5.3 and
specify the name as "sl" then I would expect something like this:
sl-sl5.3-x86_64. Can I use the same prefix (or more accurately, --name)
to import other versions of Scientific Linux? For example, if I also
import SL4.7 I would like it to be named sl-sl4.7-x86_64.
I was considering importing the "5x" branch which I imagine is just a
symlink to the current version of Scientific Linux with the reason being
that when the next version of 5x is released, I don't need to migrate
all my systems to the new version; I would simply freshen the distro and
run cobbler sync which should copy the new kernel and initrd to tftp.
But import seems to be a one-time deal. Would it be better to mirror
outside of cobbler?
Thanks,
Chris
15 years, 3 months
error parsing yaml file after upgrade to cobbler 1.4.3
by Nicholas Schuetz
After upgrading to cobbler-1.4.3-4 I get the following error when
doing a cobbler check:
error parsing yaml file: /var/lib/cobbler/config/repos.d/RHEL-5-i386-TEST
There are several repos in this directory and every one of them gets
this error if I remove the others.
Any suggestion on how to fix this? Here are the contents of the file:
---
arch: i386
breed: yum
comment: ''
createrepo_flags: ''
ctime: 1235426270.36
depth: 2
environment:
{}: ~
keep_updated: True
mirror: 'http://192.168.1.88/repo/TEST/RHEL/5/i386/'
mirror_locally: False
mtime: 1235426270.36
name: RHEL-5-i386-TEST
owners:
- cobbler
parent: ''
priority: 99
rpm_list: []
uid: MTIzNTQyNjI3MC4zNjQ1MjI4MjMuNjgwMQ
yumopts: {}
15 years, 3 months
[TESTING] Helping test 1.6
by Michael DeHaan
Probably Monday or Tuesday I plan to have web UI search done on the 1.6
branch (now "master"). Once this is done, I'll be uploading a few test
RPMs.
We can really use everyone's help in testing 1.6 and making sure it is
as bug-free and awesome as possible.
Note the changelog for this branch is currently:
- (FEAT) Improved anaconda monitoring code
- (FEAT) preliminary linux-ris support for windows installs (WIP) -- not
finished, should not be considered a 1.6 feature
- (FEAT) download comps.xml always
- (FEAT) performance upgrades for cobblerd service to avoid reloads
- (FEAT) more code for s390 imports (WIP)
- (BUGF) import works better with rawhide
- (FEAT) snippet to preserve SSH host keys across reinstalls
- (FEAT) email trigger to notify when builds finish
- (FEAT) triggers now are written in Python, old system still exists.
- (FEAT) s390x zpxe support
- (BUGF) retry power 5 times before giving up
- (BUGF) fix for RHEL3 ppc imports
- (FEAT) use nameserver variable in network config in Anaconda when set
- (BUGF) sleep 5 seconds between power cycling systems
- (FEAT) support for /usr/bin/cobbler-register
This means, the core areas of the code to test are:
- Does Anaconda monitoring work for you? This is more of a developer
kind of thing, but if you are interested, please help test.
- In general, exercise the web app and see that everything is
responsive. Do changes in the CLI show up in the web app after
reloading the page? (Adds/edits/deletes,renames)?
- If you have a mainframe, can you get the s390 "zpxe" support to work,
as documented on the Wiki page?
- If you care about SSH key presentation, can you reinstall a system and
are the SSH keys the same?
- Can you get the email trigger to work? Does it include the
information that you expect and is otherwise uncorrupted?
- Does the power support you are using still work for you?
- Does cobbler-register work for you? (This feature is new, so we'll
probably improve it dramatically in future releases. Consider this in
"BETA" state for 1.6 when it comes out).
Import changes for developers of Cobbler apps:
- Note any API consumers must access http(s)://server/cobbler_api now
for all operations -- http://server/cobbler_api_rw has gone away. Note
you can still call non-write operations
on cobbler_api just as before, without having to log in.
"git master" corresponds to 1.6 as of now.
Again, I'll have more official test RPMs available later next week.
The plan is to have all testing done in 1-2 weeks, any problems
fixed/patched-up, and then get 1.6.0 out. As usual, expect a few
bugfix releases to maintain 1.6 as needed if we miss anything in the
initial pass.
Thank you!
--Michael
15 years, 3 months
[devel] note: branch merger
by Michael DeHaan
I've folded devel back into master so we can begin testing 1.6 and
getting it refined.
New features still go onto devel, but this is "1.7/1.8", not 1.6.
If you have any outstanding patches against devel, they still go against
devel.
Just to minimize potential conflicts, please rebase your trees before
sending patches for either branch.
--Michael
15 years, 3 months