I have the following list of patches for master available at http://github.com/pvreman/cobbler/commits/master/.
Koan: + afda8a88249ed3a124651a25fc52e9f78d1ab414 update string_to_hash and hash_to_string from cobblerd to support multiple kernel options with the same name
Logging improvements for background tasks: + 90c00b3abba0d15a2e6857469ea24fad00f95b0b make sync actions always verbose, before the copy actions were only logged without context + 1a09c11eb2c546d53c366b26ab4acce96d3bc314 logging for creation of dhcp and dns configurations + 9867963dc8eb11052ec3521c5baf18803fe826e9 log creation of pxe files + 9ee3887130fe2beb49d332a3420166398595242d log updates, add criteria to find_items and make more debug
CLI error handling: + e9d0cf90df35dd351c954c097a28ddf752edeb6b exit with error code 1 if command fails + 92ba9bb9c5594223083029cc8676b5c20d826c33 raise error in blended data if profile or system not found
WebUI redundant code: + efbc6519b34e9b9c95a9298d68fbf340b0a82c1d remove duplicate code
Regards, Peter
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
On 10/21/2009 02:01 AM, Vreman, Peter wrote:
A few comments for my successors:
I have the following list of patches for master available at http://github.com/pvreman/cobbler/commits/master/.
Koan:
- afda8a88249ed3a124651a25fc52e9f78d1ab414 update string_to_hash and
hash_to_string from cobblerd to support multiple kernel options with the same name
This should be considered for master branch. At the time, lack of test resources prevented this from being merged to 2.0.X, though the feature should be supported for sure.
Logging improvements for background tasks:
- 90c00b3abba0d15a2e6857469ea24fad00f95b0b make sync actions always
verbose, before the copy actions were only logged without context
They should be verbose only when requested as we've had requests to keep this quiet and it is a fast operation.
- 1a09c11eb2c546d53c366b26ab4acce96d3bc314 logging for creation of
dhcp and dns configurations
Not sure it's meaningful to log this?
- 9867963dc8eb11052ec3521c5baf18803fe826e9 log creation of pxe files
Do you mean creating PXE tree files? I'm not sure this one is wise, as we want to cut down on logging when doing tasks that don't need it. The files can already get pretty large and making sure log levels are appropriate and stuff is fairly important.
- 9ee3887130fe2beb49d332a3420166398595242d log updates, add criteria
to find_items and make more debug
CLI error handling:
- e9d0cf90df35dd351c954c097a28ddf752edeb6b exit with error code 1 if
command fails
Thought I already merged this one? :)
- 92ba9bb9c5594223083029cc8676b5c20d826c33 raise error in blended data
if profile or system not found
WebUI redundant code:
- efbc6519b34e9b9c95a9298d68fbf340b0a82c1d remove duplicate code
Regards,
Peter
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
cobbler-devel mailing list cobbler-devel@lists.fedorahosted.org https://fedorahosted.org/mailman/listinfo/cobbler-devel
Logging improvements for background tasks:
- 90c00b3abba0d15a2e6857469ea24fad00f95b0b make sync actions always
verbose, before the copy actions were only logged without context
They should be verbose only when requested as we've had requests to keep this quiet and it is a fast operation.
- 1a09c11eb2c546d53c366b26ab4acce96d3bc314 logging for creation of dhcp
and dns configurations
Not sure it's meaningful to log this?
- 9867963dc8eb11052ec3521c5baf18803fe826e9 log creation of pxe files
Do you mean creating PXE tree files? I'm not sure this one is wise, as we want to cut down on logging when doing tasks that don't need it. The files can already get pretty large and making sure log levels are appropriate and stuff is fairly important.
I created these patches during debugging why the dhcp configuration failed. Also the existing log in these parts is inconsistent. For example during a sync the removal of files from /tftpboot/pxelinux.cfg generate a log item. But the creation of new files doesn't generate a log item. The log item of creation of the pxe file is visible with updating a system.
For the verbosity there shall be a difference between verbosity on the console and verbosity to the log files. The log file verbosity shall be set using syslog configuration. The console verbosity Can be set using --verbose.
Peter
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
Can somebody please have a look at the patches below:
The Koan and CLI error handling patches are real issues that break scripts and KVM virsh console support.
Regards, Peter
From: cobbler-devel-bounces@lists.fedorahosted.org [mailto:cobbler-devel-bounces@lists.fedorahosted.org] On Behalf Of Vreman, Peter Sent: woensdag 21 oktober 2009 8:01 To: cobbler development list Subject: [PATCH] Logging and cli error patches for master
I have the following list of patches for master available at http://github.com/pvreman/cobbler/commits/master/.
Koan: + afda8a88249ed3a124651a25fc52e9f78d1ab414 update string_to_hash and hash_to_string from cobblerd to support multiple kernel options with the same name
Logging improvements for background tasks: + 90c00b3abba0d15a2e6857469ea24fad00f95b0b make sync actions always verbose, before the copy actions were only logged without context + 1a09c11eb2c546d53c366b26ab4acce96d3bc314 logging for creation of dhcp and dns configurations + 9867963dc8eb11052ec3521c5baf18803fe826e9 log creation of pxe files + 9ee3887130fe2beb49d332a3420166398595242d log updates, add criteria to find_items and make more debug
CLI error handling: + e9d0cf90df35dd351c954c097a28ddf752edeb6b exit with error code 1 if command fails + 92ba9bb9c5594223083029cc8676b5c20d826c33 raise error in blended data if profile or system not found
WebUI redundant code: + efbc6519b34e9b9c95a9298d68fbf340b0a82c1d remove duplicate code
Regards, Peter
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
From: "Vreman, Peter" peter.vreman@acision.com To: cobbler development list cobbler-devel@lists.fedorahosted.org Sent: Tue, November 10, 2009 12:33:30 PM Subject: RE: [PATCH] Logging and cli error patches for master
Can somebody please have a look at the patches below:
The Koan and CLI error handling patches are real issues that break scripts and KVM virsh console support.
Regards, Peter
From:>cobbler-devel-bounces@lists.fedorahosted.org [mailto:cobbler-devel-bounces@lists.fedorahosted.org] On Behalf Of Vreman, Peter Sent: woensdag 21 oktober 2009 8:01 To: cobbler development list Subject: [PATCH] Logging and cli error patches for master
I have the following list of patches for master available at http://github.com/pvreman/cobbler/commits/master/.
Koan:
- afda8a88249ed3a124651a25fc52e9f78d1ab414 update
string_to_hash and hash_to_string from cobblerd to support multiple kernel options with the same name
In hash_to_string:
+ if type(hash) != dict: + return hash If string values are legacy why not test against str, so that we could use dictionary like objects in future?
+ for key in hash: + value = hash[key] Why not for k, v in hash.items()?
Also, you could make buffer a list of strings ("key=val") and then join them by doing " ".join(buffer).
CLI error handling:
- e9d0cf90df35dd351c954c097a28ddf752edeb6b exit with error
code 1 if command fails
Unrelated to your code: I've noticed that if check fails it will exit with a 411 error code. Perhaps this would be a good time to get rid of these magic numbers?
Cheers, Cristian
I have the following list of patches for master available at http://github.com/pvreman/cobbler/commits/master/.
Koan:
- afda8a88249ed3a124651a25fc52e9f78d1ab414 update
string_to_hash and hash_to_string from cobblerd to support multiple
kernel
options with the same name
In hash_to_string:
- if type(hash) != dict:
return hash
If string values are legacy why not test against str, so that we could use dictionary like objects in future?
- for key in hash:
value = hash[key]
Why not for k, v in hash.items()?
Also, you could make buffer a list of strings ("key=val") and then join them by doing " ".join(buffer).
I copied only the code from cobbler/utils.py. This optimization shall then be applied to both koan and cobbler. Or maybe even better make koan and cobbler share the same module.
CLI error handling:
- e9d0cf90df35dd351c954c097a28ddf752edeb6b exit with error
code 1 if command fails
Unrelated to your code: I've noticed that if check fails it will exit with a 411 error code. Perhaps this would be a good time to get rid of these magic numbers?
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.
From: "Vreman, Peter" peter.vreman@acision.com
To: cobbler development list cobbler-devel@lists.fedorahosted.org Sent: Fri, November 13, 2009 4:20:14 PM Subject: RE: [PATCH] Logging and cli error patches for master
..... I copied only the code from cobbler/utils.py. This optimization shall then be applied to both koan and cobbler. Or maybe even better make koan and cobbler share the same module.
I've noticed too that there is some code shared (copied) between koan and cobbler. Maybe it's time to extract a common package for this code, something like cobbler-common. I would like to hear other opinions regarding this.
Cheers, Cristian
On Fri, Nov 13, 2009 at 2:09 PM, Cristian Ciupitu cristian.ciupitu@yahoo.com wrote:
From: "Vreman, Peter" peter.vreman@acision.com
To: cobbler development list cobbler-devel@lists.fedorahosted.org Sent: Fri, November 13, 2009 4:20:14 PM Subject: RE: [PATCH] Logging and cli error patches for master
..... I copied only the code from cobbler/utils.py. This optimization shall then be applied to both koan and cobbler. Or maybe even better make koan and cobbler share the same module.
I've noticed too that there is some code shared (copied) between koan and cobbler. Maybe it's time to extract a common package for this code, something like cobbler-common. I would like to hear other opinions regarding this.
Why add more dependencies for koan? koan is a very small standalone utility and cobbler is a server side component. Lets keep them seperate if at all possible.
From: Jeff Schroeder jeffschroed@gmail.com
To: cobbler development list cobbler-devel@lists.fedorahosted.org Sent: Sat, November 14, 2009 12:13:09 AM Subject: Re: [PATCH] Logging and cli error patches for master
On Fri, Nov 13, 2009 at 2:09 PM, Cristian Ciupitu wrote:
From: "Vreman, Peter"
To: cobbler development list Sent: Fri, November 13, 2009 4:20:14 PM Subject: RE: [PATCH] Logging and cli error patches for master
..... I copied only the code from cobbler/utils.py. This optimization shall then be applied to both koan and cobbler. Or maybe even better make koan and cobbler share the same module.
I've noticed too that there is some code shared (copied) between koan and cobbler. Maybe it's time to extract a common package for this code, something like cobbler-common. I would like to hear other opinions regarding this.
Why add more dependencies for koan? koan is a very small standalone utility and cobbler is a server side component. Lets keep them seperate if at all possible.
Could you please explain why are you concerned about adding a dependency for koan? After all, package managers can deal with dependencies.
I was also thinking of using symbolic links and then package these modules in both cobbler and koan, but then I realized that one of the packages would contain a broken link unless we do some tricks in the spec or setup.py.
Regards, Cristian
Sent from my iPhone
On Nov 13, 2009, at 4:16 PM, Cristian Ciupitu <cristian.ciupitu@yahoo.com
wrote:
From: Jeff Schroeder jeffschroed@gmail.com
To: cobbler development list cobbler-devel@lists.fedorahosted.org Sent: Sat, November 14, 2009 12:13:09 AM Subject: Re: [PATCH] Logging and cli error patches for master
On Fri, Nov 13, 2009 at 2:09 PM, Cristian Ciupitu wrote:
From: "Vreman, Peter"
To: cobbler development list Sent: Fri, November 13, 2009 4:20:14 PM Subject: RE: [PATCH] Logging and cli error patches for master
..... I copied only the code from cobbler/utils.py. This optimization shall then be applied to both koan and cobbler. Or maybe even better make koan and cobbler share the same module.
I've noticed too that there is some code shared (copied) between koan and cobbler. Maybe it's time to extract a common package for this code, something like cobbler-common. I would like to hear other opinions regarding this.
Why add more dependencies for koan? koan is a very small standalone utility and cobbler is a server side component. Lets keep them seperate if at all possible.
Could you please explain why are you concerned about adding a dependency for koan? After all, package managers can deal with dependencies.
I was also thinking of using symbolic links and then package these modules in both cobbler and koan, but then I realized that one of the packages would contain a broken link unless we do some tricks in the spec or setup.py.
Sorry I'm not sure what got into me earlier but for heavens sake don't use symlinks to do this. Splitting stuff out makes sense and shouldn't be super hard.
I know that keeping koan small and self contained was very important for Michael when he wrote it. He got it running fine on rhel2.1 to help migrate those installs over to virtual machines.
Not that I personally mind, but it would be sad to see that work thrown out for a seemingly innocent patch.
From: "Jeff Schroeder" jeffschroed@gmail.com Date: Friday, November 13, 2009 10:23 PM To: "cobbler development list" cobbler-devel@lists.fedorahosted.org Subject: Re: [PATCH] Logging and cli error patches for master
I know that keeping koan small and self contained was very important for Michael when he wrote it. He got it running fine on rhel2.1 to help migrate those installs over to virtual machines.
Not that I personally mind, but it would be sad to see that work thrown out for a seemingly innocent patch.
As far as 2.1 goes, the impression I got from Michael from our IRC conversations was that the most important thing about koan on 2.1 is that the "replace-self" code path works; anything else that works is convenient, but not critical. He also briefly explains this near the top of app.py.
Aside: Support for Python 1.5 is one reason Trac #523 existed in the first place - modules that are normally unavailable in or incompatible with 1.5.
It has been some time since I've looked at much of the code, but if koan currently uses only a small portion of the code that cobbler uses then I could understand avoiding this in the interest of being "small and self-contained." I don't see pulling in a tiny dependency as a problem, however. On the other hand, one downside is that a machine with both cobbler and koan installed will always have to have the same versions of each installed since they share a common library (python-libcobbler?). (I personally don't mind this.) Alternatively, we could start tracking library versions separately and updating cobbler's and koan's rpm requires accordingly.
What do you folks think?
-- Garrett Holmstrom University of Minnesota School of Physics and Astronomy Systems Staff
From: Garrett Holmstrom garrett.holmstrom@gmail.com
To: cobbler development list cobbler-devel@lists.fedorahosted.org Sent: Sat, November 14, 2009 7:38:07 AM Subject: Re: [PATCH] Logging and cli error patches for master
From: "Jeff Schroeder" Date: Friday, November 13, 2009 10:23 PM To: "cobbler development list" Subject: Re: [PATCH] Logging and cli error patches for master
I know that keeping koan small and self contained was very important for Michael when he wrote it. He got it running fine on rhel2.1 to help migrate those installs over to virtual machines.
Not that I personally mind, but it would be sad to see that work thrown out for a seemingly innocent patch.
As far as 2.1 goes, the impression I got from Michael from our IRC conversations was that the most important thing about koan on 2.1 is that the "replace-self" code path works; anything else that works is convenient, but not critical. He also briefly explains this near the top of app.py.
Aside: Support for Python 1.5 is one reason Trac #523 existed in the first place - modules that are normally unavailable in or incompatible with 1.5.
Actually, not even Python 2.3 has some of these modules.
It has been some time since I've looked at much of the code, but if koan currently uses only a small portion of the code that cobbler uses then I could understand avoiding this in the interest of being "small and self-contained." I don't see pulling in a tiny dependency as a problem, however. On the other hand, one downside is that a machine with both cobbler and koan installed will always have to have the same versions of each installed since they share a common library (python-libcobbler?). (I personally don't mind this.) Alternatively, we could start tracking library versions separately and updating cobbler's and koan's rpm requires accordingly.
That's an interesting downside, although I wonder how many people want to run (radically) different versions of cobbler and koan on the same machine. What I'm thinking of is that it shouldn't be a problem using, let's say koan 2.0.4 with cobbler 2.0.7 or even koan 2.1 with cobbler 2.2 because the common part doesn't seem to be very complicated.
Regards, Cristian
cobbler-devel@lists.fedorahosted.org