You can subscribe to this list here.
| 2007 |
Jan
|
Feb
|
Mar
(886) |
Apr
(141) |
May
(30) |
Jun
(86) |
Jul
(23) |
Aug
(33) |
Sep
|
Oct
(21) |
Nov
(30) |
Dec
(811) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2008 |
Jan
(184) |
Feb
(137) |
Mar
(519) |
Apr
(1298) |
May
(180) |
Jun
(71) |
Jul
(35) |
Aug
(90) |
Sep
(48) |
Oct
(86) |
Nov
(159) |
Dec
(55) |
| 2009 |
Jan
(57) |
Feb
(60) |
Mar
(53) |
Apr
(43) |
May
(32) |
Jun
(89) |
Jul
(83) |
Aug
(47) |
Sep
(74) |
Oct
(88) |
Nov
(72) |
Dec
(56) |
| 2010 |
Jan
(33) |
Feb
(20) |
Mar
(17) |
Apr
|
May
(3) |
Jun
(1) |
Jul
(1) |
Aug
|
Sep
(66) |
Oct
(16) |
Nov
(6) |
Dec
(11) |
| 2011 |
Jan
(6) |
Feb
|
Mar
(49) |
Apr
(5) |
May
(1) |
Jun
(2) |
Jul
(3) |
Aug
(2) |
Sep
(1) |
Oct
(62) |
Nov
(4) |
Dec
(1) |
| 2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(81) |
Sep
(4) |
Oct
(3) |
Nov
(1) |
Dec
(3) |
| 2013 |
Jan
(8) |
Feb
(1) |
Mar
(3) |
Apr
|
May
(33) |
Jun
(8) |
Jul
|
Aug
|
Sep
(76) |
Oct
|
Nov
|
Dec
|
| 2015 |
Jan
|
Feb
(17) |
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
|
1
|
2
|
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
|
10
(10) |
11
|
12
(4) |
13
(1) |
14
|
15
|
16
|
|
17
|
18
|
19
|
20
|
21
|
22
(26) |
23
|
|
24
|
25
(21) |
26
(11) |
27
(5) |
28
(2) |
29
(6) |
30
|
|
From: Matt <mat...@us...> - 2007-06-29 21:53:09
|
Update of /cvsroot/openqrm/plugins/linuxcoe/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17510/plugins/linuxcoe/etc Modified Files: post-install-openqrm.kickstart Log Message: forget to commit Index: post-install-openqrm.kickstart =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/post-install-openqrm.kickstart,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** post-install-openqrm.kickstart 27 Jun 2007 15:53:49 -0000 1.1 --- post-install-openqrm.kickstart 29 Jun 2007 21:53:09 -0000 1.2 *************** *** 4,15 **** --- 4,24 ---- LOCAL_VE_NAME="linuxcoeZZZ_LINUXCOE_PROFILE_ZZZ-$INSTALL_TIME" + # needed for gathering the openQRM interface if [ ! -f /root/anaconda-ks.cfg ]; then echo "ERROR: Could not find installation config file /root/anaconda-ks.cfg" exit 1 fi + # really readhat based ? if [ ! -f /etc/redhat-release ]; then echo "ERROR: Could not find /etc/redhat-release" exit 1 fi + # is network already up ? + # since this is started from rc.local it may run + # before the network is initialysed. + if ! ping -c 1 -W 1 ZZZ_QRM_SERVER_IP_ADDRESS_ZZZ 1>/dev/null; then + echo "NOTICE: Network not initialysed yet. Running again later." + exit 0 + fi OPENQRM_CLIENT_INTERFACE=`cat /root/anaconda-ks.cfg | grep network | sed -e "s/.*--device //g" | awk {' print $1 '}` *************** *** 30,46 **** echo "installing $OPENQRM_RESOURCE_RPM" ! while ! wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; do ! echo "retrying ..." ! sleep 2 ! if wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; then echo "success ..." break fi done ! rpm -ihv $OPENQRM_RESOURCE_RPM echo "y" | /opt/qrm/resource/sbin/qrm-bootstrap integrate -q ZZZ_QRM_SERVER_IP_ADDRESS_ZZZ -v $LOCAL_VE_NAME -i $OPENQRM_CLIENT_INTERFACE -t "" --- 39,64 ---- echo "installing $OPENQRM_RESOURCE_RPM" ! if [ ! -d /root ]; then ! mkdir -p /root ! fi ! while (true); do ! /bin/rm -f $OPENQRM_RESOURCE_RPM ! if wget -O /root/$OPENQRM_RESOURCE_RPM http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; then echo "success ..." break fi + sleep 2 + echo "retrying ..." done ! rpm -ihv /root/$OPENQRM_RESOURCE_RPM echo "y" | /opt/qrm/resource/sbin/qrm-bootstrap integrate -q ZZZ_QRM_SERVER_IP_ADDRESS_ZZZ -v $LOCAL_VE_NAME -i $OPENQRM_CLIENT_INTERFACE -t "" + /etc/init.d/qrm-node-agents start + # here we remove the post entry from rc.local again + cat /etc/rc.d/rc.local | sed -e "s#/root/ZZZ_LINUXCOE_PROFILE_ZZZ.post##g" > /etc/rc.d/rc.local.openqrm-create + /bin/mv -f /etc/rc.d/rc.local.openqrm-create /etc/rc.d/rc.local + chmod +x /etc/rc.d/rc.local |
|
From: Matt <mat...@us...> - 2007-06-29 21:52:48
|
Update of /cvsroot/openqrm/plugins/linuxcoe/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17137/plugins/linuxcoe/etc Modified Files: pxe-template.kickstart pxe-template.autoyast pxe-template.preseed Log Message: :) working now for kickstart installations Index: pxe-template.kickstart =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/pxe-template.kickstart,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** pxe-template.kickstart 27 Jun 2007 13:01:11 -0000 1.2 --- pxe-template.kickstart 29 Jun 2007 21:52:47 -0000 1.3 *************** *** 3,5 **** label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} ks=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/ks${LINUXCOE_PROFILE}.cfg --- 3,5 ---- label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img ks=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/ks${LINUXCOE_PROFILE}.cfg Index: pxe-template.preseed =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/pxe-template.preseed,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** pxe-template.preseed 27 Jun 2007 13:01:11 -0000 1.2 --- pxe-template.preseed 29 Jun 2007 21:52:47 -0000 1.3 *************** *** 3,6 **** label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} preseed/url=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/preseed${LINUXCOE_PROFILE}.cfg root=/dev/ram rw debconf/priority=critical debian-installer/framebuffer=false --- 3,6 ---- label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img preseed/url=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/preseed${LINUXCOE_PROFILE}.cfg root=/dev/ram rw debconf/priority=critical debian-installer/framebuffer=false Index: pxe-template.autoyast =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/pxe-template.autoyast,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** pxe-template.autoyast 27 Jun 2007 13:01:11 -0000 1.2 --- pxe-template.autoyast 29 Jun 2007 21:52:47 -0000 1.3 *************** *** 3,5 **** label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} autoyast=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/autoyast${LINUXCOE_PROFILE}.xml info=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/info${LINUXCOE_PROFILE} --- 3,5 ---- label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img autoyast=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/autoyast${LINUXCOE_PROFILE}.xml info=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/info${LINUXCOE_PROFILE} |
|
From: Matt <mat...@us...> - 2007-06-29 21:52:48
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17137/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage Log Message: :) working now for kickstart installations Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** qrm-linuxcoe-manage 28 Jun 2007 12:22:22 -0000 1.8 --- qrm-linuxcoe-manage 29 Jun 2007 21:52:47 -0000 1.9 *************** *** 117,124 **** echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg echo "# openQRM post section" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! echo "wget -O $LINUXCOE_PROFILE.post http://$QRM_SERVER_IP_ADDRESS/plugins/linuxcoe/inst/$LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! echo "chmod +x $LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! echo "./$LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! echo "# /bin/rm -f $LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg else linuxcoe_log qrm-linuxcoe-manage "NOTICE : openQRM post-section already in ks""$LINUXCOE_PROFILE"".cfg" --- 117,126 ---- echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg echo "# openQRM post section" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! ! echo "mkdir -p /root" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! echo "wget -O /root/$LINUXCOE_PROFILE.post http://$QRM_SERVER_IP_ADDRESS/plugins/linuxcoe/inst/$LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! echo "chmod +x /root/$LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg ! # add to rc.local ! echo "echo /root/$LINUXCOE_PROFILE.post >> /etc/rc.d/rc.local" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg else linuxcoe_log qrm-linuxcoe-manage "NOTICE : openQRM post-section already in ks""$LINUXCOE_PROFILE"".cfg" |
|
From: Matt <mat...@us...> - 2007-06-29 21:52:47
|
Update of /cvsroot/openqrm/plugins/linuxcoe/doc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17137/plugins/linuxcoe/doc Modified Files: Changelog README.txt Log Message: :) working now for kickstart installations Index: README.txt =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/doc/README.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** README.txt 22 Jun 2007 14:48:27 -0000 1.1 --- README.txt 29 Jun 2007 21:52:47 -0000 1.2 *************** *** 29,34 **** (by Matt Rechenburg) ! General informations ! Detailed explanations Requirements Setup --- 29,36 ---- (by Matt Rechenburg) ! ! General informations about LinuxCoe ! Details about the LinuxCoe-integration ! Installation flow Requirements Setup *************** *** 36,47 **** - General informations ! Detailed explanations - Requiremtens - - sudo --- 38,88 ---- ! ! General informations about LinuxCoe ! LinuxCoe is an open-source web-application developed and maintained by HP ! which produces iso-images for installing various linux distributions fully ! automatically. It lets the administrator create different installation ! configuration templates which are saved in profiles, burn the resulting ! iso image on a CD, put the CD in a computer and power it on to automatically ! install the system according the selected profile without any manual ! interaction needed. ! ! ! ! Details about the LinuxCoe-integration ! ! ! ! - apache plugin ! ! ! ! Installation flow ! ! - create an installation ! - optional save the configuration of the installation as a profile ! - select installation profile to deploy ! - select resource to deploy ! - resource gets assigned to the installation profile and reboots ! - resource boots the installation kernel + initrd and start installation ! - resource gets removed from openQRM ! - linux-coe plugin creates localboot pxe-config file for resource ! - resource finshed automatic installation ! - resource adds itself to openQRM during automatic run of "easy-migration" integration ! - resource reboots and starts localboot pxe-config file and boots from local-disk ! - resource is now fully installed and gets active in openQRM ! ! ! ! ! ! ! Requirements ! - the linuxcoe-plugin needs the "apache-plugin" ! - LinuxCoe needs "sudo" to be installed/available *************** *** 56,60 **** ! # Urls ! Webmin : http://linuxcoe.sourceforge.net/ --- 97,103 ---- ! ! ! Urls ! LinuxCoe homepage : http://linuxcoe.sourceforge.net/ Index: Changelog =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/doc/Changelog,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Changelog 22 Jun 2007 14:48:27 -0000 1.1 --- Changelog 29 Jun 2007 21:52:47 -0000 1.2 *************** *** 32,34 **** --- 32,55 ---- - initial release + Features : + - integration of LinuxCoe into openQRM + - fully automatic installation of different Linux distributions + e.g. CentOS, Fedory, RHEL, Suse/openSuse/SLES, Debian, Ubuntu and more + + + Known limitations/bugs: + - the "autoyast" and "preseed" network installation are not yet fully working + (the "kickstart" based automatic installations are working well) + + + + + + + + + + + + |
|
From: Matt <mat...@us...> - 2007-06-29 21:52:47
|
Update of /cvsroot/openqrm/plugins/linuxcoe In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17137/plugins/linuxcoe Modified Files: Makefile Added Files: README.autoyast-installations README.kickstart-installations README.preseed-installations Log Message: :) working now for kickstart installations --- NEW FILE: README.kickstart-installations --- Redhat-based "kickstart" installations are fully working ! Index: Makefile =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Makefile 25 Jun 2007 15:32:48 -0000 1.2 --- Makefile 29 Jun 2007 21:52:47 -0000 1.3 *************** *** 46,50 **** WEB_DEPLOY_DIR := $(OUTDIR)/qrm/java/webapp/plugins ! INSTALL_FILES := apache, -m 0700 bin, -m 0700 etc, include, doc, systemdesigner, scratch_monkey, -m 0700 sbin, web INSTALL_FILES_DEST := $(OUTDIR)/qrm/plugins/linuxcoe --- 46,50 ---- WEB_DEPLOY_DIR := $(OUTDIR)/qrm/java/webapp/plugins ! INSTALL_FILES := apache, -m 0700 bin, -m 0700 etc, include, doc, systemdesigner, scratch_monkey, -m 0700 sbin, web, README* INSTALL_FILES_DEST := $(OUTDIR)/qrm/plugins/linuxcoe --- NEW FILE: README.autoyast-installations --- The Suse-based "autoyast" installations are not yet fully working ! -> patches and fixes are more than welcome --- NEW FILE: README.preseed-installations --- The Debian-based "preseed" installations are not yet fully working ! -> patches and fixes are more than welcome |
|
From: Matt <mat...@us...> - 2007-06-29 10:14:12
|
Update of /cvsroot/openqrm/plugins/linuxcoe/web/secure In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv12016/plugins/linuxcoe/web/secure Modified Files: linuxcoe_manage_int.jsp linuxcoe_install_int.jsp Log Message: bit nicer Index: linuxcoe_manage_int.jsp =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/web/secure/linuxcoe_manage_int.jsp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** linuxcoe_manage_int.jsp 26 Jun 2007 11:51:54 -0000 1.6 --- linuxcoe_manage_int.jsp 29 Jun 2007 10:14:06 -0000 1.7 *************** *** 47,61 **** LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); manager.remove(profile); ! out.println("--> removed profile number : " +profile+ "!"); } else if(cmd.equals("clean")) { LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); manager.clean(); ! out.println("--> cleaned scratch dir !"); } else { ! out.println("--> No such command !"); } } %> --- 47,92 ---- LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); manager.remove(profile); ! // out.println("--> removed profile number : " +profile+ "!"); } else if(cmd.equals("clean")) { LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); manager.clean(); ! // out.println("--> cleaned scratch dir !"); } else { ! out.println("--> No such command !<br>"); ! } ! } ! ! ! // check for iso's to unpack ! ! String linuxcoe_profile_dir = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/"; ! File dir = new File(linuxcoe_profile_dir); ! String[] children = dir.list(); ! Boolean profile_exists = false; ! if (children != null) { ! // find .iso images to unpack ! for (int i=0; i<children.length; i++) { ! String filename = children[i]; ! if (filename.endsWith(".iso")) { ! // out.println("linuxcoe profile --> : " +filename+ "<br>"); ! profile_exists=true; ! // check if the profile was already unpacked ! String specific_linuxcoe_profile_dir = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/" +filename+ "_unpacked"; ! File check_profile_exists = new File(specific_linuxcoe_profile_dir); ! if (!check_profile_exists.isDirectory()) { ! LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); ! manager.unpack(filename); ! out.println("<b>Unpacked " +filename+ "</b><br>"); ! %> ! <b>Please <a href="javascript:location.reload()">reload</a> this page!</b><br> ! <% ! ! } } } + + %> *************** *** 82,124 **** <tr> - - - - <% - String linuxcoe_profile_dir = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/"; - File dir = new File(linuxcoe_profile_dir); - String[] children = dir.list(); - Boolean profile_exists = false; - if (children != null) { - // find .iso images to unpack - for (int i=0; i<children.length; i++) { - String filename = children[i]; - if (filename.endsWith(".iso")) { - // out.println("linuxcoe profile --> : " +filename+ "<br>"); - profile_exists=true; - - // check if the profile was already unpacked - String specific_linuxcoe_profile_dir = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/" +filename+ "_unpacked"; - File check_profile_exists = new File(specific_linuxcoe_profile_dir); - if (!check_profile_exists.isDirectory()) { - - out.println("<td>"); - out.println("--> : " +filename+ " needs to be unpacked<br>"); - LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); - manager.unpack(filename); - out.println("--> : " +filename+ " unpacked now<br>"); - out.println("<br><b>Please reload this page now !</b><br>"); - out.println("</td><td></td><td></td>"); - out.println("</tr><tr>"); - - } - } - } - - - out.println("</tr><tr>"); - // get new list to find .iso images to unpack for (int i=0; i<children.length; i++) { --- 113,118 ---- *************** *** 136,140 **** out.println("</td>"); - profile_exists=true; --- 130,133 ---- Index: linuxcoe_install_int.jsp =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/web/secure/linuxcoe_install_int.jsp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** linuxcoe_install_int.jsp 26 Jun 2007 18:20:45 -0000 1.2 --- linuxcoe_install_int.jsp 29 Jun 2007 10:14:06 -0000 1.3 *************** *** 66,75 **** String install_method[] = request.getParameterValues("install_method"); method = install_method[0]; - - - if(cmd.equals("install")) { - - out.println("--> installing profile number : " +profile+ " install method " +method +" !"); } else if(cmd.equals("install_resource")) { --- 66,73 ---- String install_method[] = request.getParameterValues("install_method"); method = install_method[0]; + if(cmd.equals("install")) { + //out.println("--> selected profile number : " +profile+ " install method " +method +" !"); + cmd = "install"; } else if(cmd.equals("install_resource")) { *************** *** 80,87 **** LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); manager.install(profile, method, id, ip); ! out.println("NOW installing profile number : " +profile+ " install method " +method+ "id " +id+ " ip " +ip+ " !"); } else { ! out.println("--> No such command !"); } } --- 78,85 ---- LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); manager.install(profile, method, id, ip); ! out.println("<b>Installing profile number : " +profile+ " on node " +id+ "/" +ip+ " !</b><br>"); } else { ! out.println("--> No such command !<br>"); } } *************** *** 127,131 **** out.println("<td>"); ! out.print("node " +resource1.getId()); out.println("</td><td>"); out.print(resource1.getIpString()); --- 125,129 ---- out.println("<td>"); ! out.print("node " +resource1.getExternalId()); out.println("</td><td>"); out.print(resource1.getIpString()); |
|
From: Matt <mat...@us...> - 2007-06-28 12:22:38
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv1382/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage qrm-linuxcoe-install-monitor Log Message: :) got the first fully automatic installation working Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** qrm-linuxcoe-manage 27 Jun 2007 19:57:56 -0000 1.7 --- qrm-linuxcoe-manage 28 Jun 2007 12:22:22 -0000 1.8 *************** *** 242,247 **** $QRM_CLI resource reboot --internal_cr_id $LINUXCOE_RESOURCE_ID ! # start install-monitor script in background via screen ! screen -dmS $LINUXCOE_RESOURCE_ID $LINUXCOE_INSTALL_MONITOR $LINUXCOE_RESOURCE_ID # This script : --- 242,251 ---- $QRM_CLI resource reboot --internal_cr_id $LINUXCOE_RESOURCE_ID ! # start install-monitor script ! # somehow it does not work correct when started in background yet ! # for now we wait until it is finished ! ! sleep 20 ! $LINUXCOE_INSTALL_MONITOR $LINUXCOE_RESOURCE_ID & # This script : Index: qrm-linuxcoe-install-monitor =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-install-monitor,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** qrm-linuxcoe-install-monitor 27 Jun 2007 19:57:56 -0000 1.1 --- qrm-linuxcoe-install-monitor 28 Jun 2007 12:22:23 -0000 1.2 *************** *** 37,48 **** LINUXCOE_RESOURCE_ID=$1 - # defs - INSTALL_CHECK_DELAY=10 - ######## TODO !!! remove user + password, use sessions ######### - QRM_USER=qrm - QRM_PASS=qrm - export QRM_CLI="$QRM_CLI -u $QRM_USER -p $QRM_PASS" - ################################################################ --- 37,41 ---- *************** *** 71,93 **** fi ! ! # check when the resource gets into error state ! while (true); do ! sleep $INSTALL_CHECK_DELAY ! CR_OPER_STATUS=`$QRM_CLI resource view --internal_cr_id $LINUXCOE_RESOURCE_ID | grep State | awk {' print $2 '}` ! $QRM_CLI resource view --internal_cr_id $LINUXCOE_RESOURCE_ID | logger ! $QRM_CLI resource view --internal_cr_id $LINUXCOE_RESOURCE_ID | grep State | awk {' print $2 '} | logger ! linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: resource $LINUXCOE_RESOURCE_ID is in state $CR_OPER_STATUS" ! if [ "$CR_OPER_STATUS" == "Error" ]; then ! linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: Now resource $LINUXCOE_RESOURCE_ID got into $CR_OPER_STATUS state" ! break ! fi ! done ! ! # remove the resource so that it can add itself again ! linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: removing resource $LINUXCOE_RESOURCE_ID" ! $QRM_CLI resource delete --internal_cr_id $LINUXCOE_RESOURCE_ID ! # give time to remove it ! sleep 5 # restore the resources pxe-config file and set to localboot --- 64,70 ---- fi ! # wait until the node got removed ! linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: .......... waiting to re-create the nodes pxe-config set to localboot" ! sleep 120 # restore the resources pxe-config file and set to localboot |
|
From: Matt <mat...@us...> - 2007-06-28 12:22:38
|
Update of /cvsroot/openqrm/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv1382/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe Modified Files: LinuxCoeProfileManager.java Log Message: :) got the first fully automatic installation working Index: LinuxCoeProfileManager.java =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe/LinuxCoeProfileManager.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** LinuxCoeProfileManager.java 26 Jun 2007 18:20:45 -0000 1.3 --- LinuxCoeProfileManager.java 28 Jun 2007 12:22:22 -0000 1.4 *************** *** 32,36 **** --- 32,43 ---- import java.io.*; import com.qlusters.qrm.server.logic.controller.commands.*; + import com.qlusters.qrm.server.logic.controller.*; + import com.qlusters.qrm.server.logic.resources.ComputeResourcesFinder; + import com.qlusters.qrm.server.api.objects.ComputeResourceData; + import com.qlusters.qrm.server.api.exceptions.resources.ComputeResourceNotFoundException; + import com.qlusters.qrm.server.api.exceptions.resources.ComputeResourceOperationNotPermittedException; import com.qlusters.qrm.utils.Prefs; + import com.qlusters.qrm.utils.NetUtils; + import com.qlusters.qrm.exceptions.InvalidIpException; /** *************** *** 98,102 **** // String id -> resource id to install // String ip -> resource ip to install ! public String install(String profile_number, String install_method, String id, String ip) { String cmd = LinuxCoeCommandScript; cmd=cmd + " install "; --- 105,111 ---- // String id -> resource id to install // String ip -> resource ip to install ! public String install(String profile_number, String install_method, String id, String ip) ! throws ComputeResourceNotFoundException, ComputeResourceOperationNotPermittedException, InvalidIpException { ! String cmd = LinuxCoeCommandScript; cmd=cmd + " install "; *************** *** 115,118 **** --- 124,143 ---- System.out.println("OUT: " + stdout); System.out.println("ERR:" + out.getErrorString()); + + + // reboot + remove the resource + + // get the resourcedata + Integer resource_id = Integer.valueOf(id).intValue(); + ComputeResourceData resource = ComputeResourcesFinder.getInstance().getResourceById(resource_id); + + //Long ipl = NetUtils.stringIpToLong(ip); + //ComputeResourceData resource = ComputeResourcesFinder.getInstance().getResourceByIp(ipl); + + // force delete + ResourceController resc = new ResourceController(); + resc.delete(resource, true); + + return stdout; } |
|
From: Matt <mat...@us...> - 2007-06-27 19:58:03
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv23726/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage Added Files: qrm-linuxcoe-install-monitor Log Message: ;) almost working Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** qrm-linuxcoe-manage 27 Jun 2007 15:53:49 -0000 1.6 --- qrm-linuxcoe-manage 27 Jun 2007 19:57:56 -0000 1.7 *************** *** 37,40 **** --- 37,42 ---- LINUXCOE_PROFILE=$2 + LINUXCOE_INSTALL_MONITOR="$QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/sbin/qrm-linuxcoe-install-monitor" + case $LINUXCOE_COMMAND in unpack) *************** *** 240,250 **** $QRM_CLI resource reboot --internal_cr_id $LINUXCOE_RESOURCE_ID ! # TODO : start script in background via screen ! # save the nodes mac pxe-file, set to localboot ! # check when the node gets into error state ! # remove the node to enable it adding it again via easy-migration ! # restore mac pxe-file to enable localboot for the node ! # node will reboot after installation and ! # add itself to openQRM via the post section ;; --- 242,255 ---- $QRM_CLI resource reboot --internal_cr_id $LINUXCOE_RESOURCE_ID ! # start install-monitor script in background via screen ! screen -dmS $LINUXCOE_RESOURCE_ID $LINUXCOE_INSTALL_MONITOR $LINUXCOE_RESOURCE_ID ! ! # This script : ! # saves the nodes mac pxe-file, set to localboot ! # checks when the node gets into error state ! # removes the node to enable it adding it again via easy-migration ! # restores mac pxe-file to enable localboot for the node. ! # The node will reboot after installation and ! # add itself to openQRM via the post section. ;; --- NEW FILE: qrm-linuxcoe-install-monitor --- #!/bin/bash ################################################################################ # # # The contents of this file are subject to the Qlusters Public License # Version 1.1 (the License); you may not use this file except in compliance # with the License. # You may obtain a copy of the License at # http://www.openqrm.org/content/view/33/69/. # # Software distributed under the License is distributed on an AS IS basis, # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for # the specific language governing rights and limitations under the License. # # The Original Code is openQRM. # # The Initial Developer of the Original Code is Qlusters Corporation. Portions # created by Qlusters Corporation are Copyright (C) 2003-2006. All Rights # Reserved. # # Contributor(s): # # Description: # # Comments: ################################################################################ # BASE_DIR=$(dirname $0)/../../../../ QRM_SERVER_BASE_DIR=$(pushd $BASE_DIR > /dev/null && echo $PWD && popd > /dev/null) # memory loaded functions . $QRM_SERVER_BASE_DIR/qrm/include/qrm-functions . $QRM_SERVER_BASE_DIR/qrm/include/qrm-server-functions . $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/include/linuxcoe-functions # params LINUXCOE_RESOURCE_ID=$1 # defs INSTALL_CHECK_DELAY=10 ######## TODO !!! remove user + password, use sessions ######### QRM_USER=qrm QRM_PASS=qrm export QRM_CLI="$QRM_CLI -u $QRM_USER -p $QRM_PASS" ################################################################ if [ "$LINUXCOE_RESOURCE_ID" == "" ]; then linuxcoe_log qrm-linuxcoe-install-monitor "ERROR: Missing resource id for monitoring the installation process !" exit 1 fi # first find out the resource mac pxe-config file # we need to restore it after we removed the node MAC_FOUND=0 cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg for LINUXCOE_RESOURCE_MAC in `ls | grep -v default | grep -v localboot | grep -v ^res | grep -v linuxcoe`; do POINTS_TO=`readlink $LINUXCOE_RESOURCE_MAC` if [ "$POINTS_TO" == "res-$LINUXCOE_RESOURCE_ID" ]; then linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: Found resources pxe-config file -> $LINUXCOE_RESOURCE_MAC" export MAC_FOUND=1 break fi done if [ "$MAC_FOUND" == "0" ]; then linuxcoe_log qrm-linuxcoe-install-monitor "ERROR: Could not find pxe-config file for resource $LINUXCOE_RESOURCE_ID" exit 1 fi # check when the resource gets into error state while (true); do sleep $INSTALL_CHECK_DELAY CR_OPER_STATUS=`$QRM_CLI resource view --internal_cr_id $LINUXCOE_RESOURCE_ID | grep State | awk {' print $2 '}` $QRM_CLI resource view --internal_cr_id $LINUXCOE_RESOURCE_ID | logger $QRM_CLI resource view --internal_cr_id $LINUXCOE_RESOURCE_ID | grep State | awk {' print $2 '} | logger linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: resource $LINUXCOE_RESOURCE_ID is in state $CR_OPER_STATUS" if [ "$CR_OPER_STATUS" == "Error" ]; then linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: Now resource $LINUXCOE_RESOURCE_ID got into $CR_OPER_STATUS state" break fi done # remove the resource so that it can add itself again linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: removing resource $LINUXCOE_RESOURCE_ID" $QRM_CLI resource delete --internal_cr_id $LINUXCOE_RESOURCE_ID # give time to remove it sleep 5 # restore the resources pxe-config file and set to localboot linuxcoe_log qrm-linuxcoe-install-monitor "NOTICE: Re-create pxe-config file for resource $LINUXCOE_RESOURCE_ID, set to localboot" cat $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/localboot > $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/$LINUXCOE_RESOURCE_MAC exit 0 |
|
From: Matt <mat...@us...> - 2007-06-27 15:53:52
|
Update of /cvsroot/openqrm/plugins/linuxcoe/include In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv22035/plugins/linuxcoe/include Modified Files: linuxcoe-functions Log Message: added post section to automatically install the openQRM agents and integrate the local booted system into openQRM Index: linuxcoe-functions =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/include/linuxcoe-functions,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** linuxcoe-functions 26 Jun 2007 18:20:45 -0000 1.5 --- linuxcoe-functions 27 Jun 2007 15:53:49 -0000 1.6 *************** *** 37,40 **** --- 37,45 ---- LINUXCOE_PXE_TEMPLATE_AUTOYAST="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/pxe-template.autoyast" + LINUXCOE_POST_INSTALL_TEMPLATE_KICKSTART="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/post-install-openqrm.kickstart" + LINUXCOE_POST_INSTALL_TEMPLATE_PRESEED="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/post-install-openqrm.preseed" + LINUXCOE_POST_INSTALL_TEMPLATE_AUTOYAST="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/post-install-openqrm.autoyast" + + # management LINUXCOE_LOCK_FILE=/var/run/linuxcoe/linuxcoe-plugin.lock |
|
From: Matt <mat...@us...> - 2007-06-27 15:53:49
|
Update of /cvsroot/openqrm/plugins/linuxcoe/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv22035/plugins/linuxcoe/etc Added Files: post-install-openqrm.autoyast post-install-openqrm.kickstart post-install-openqrm.preseed Log Message: added post section to automatically install the openQRM agents and integrate the local booted system into openQRM --- NEW FILE: post-install-openqrm.autoyast --- #!/bin/bash # TODO OPENQRM_CLIENT_INTERFACE=`` # check which rpm will fit best OPENQRM_RESOURCE_RPM="" echo "using $OPENQRM_CLIENT_INTERFACE for $LOCAL_VE_NAME" echo "installing $OPENQRM_RESOURCE_RPM" while ! wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; do echo "retrying ..." sleep 2 if wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; then echo "success ..." break fi done rpm -ihv $OPENQRM_RESOURCE_RPM echo "y" | /opt/qrm/resource/sbin/qrm-bootstrap integrate -q ${QRM_SERVER_IP_ADDRESS} -v ${LOCAL_VE_NAME} -i $OPENQRM_CLIENT_INTERFACE -t "" --- NEW FILE: post-install-openqrm.preseed --- #!/bin/bash # TODO OPENQRM_CLIENT_INTERFACE=`` # check which rpm will fit best OPENQRM_RESOURCE_RPM="" echo "using $OPENQRM_CLIENT_INTERFACE for $LOCAL_VE_NAME" echo "installing $OPENQRM_RESOURCE_RPM" while ! wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; do echo "retrying ..." sleep 2 if wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; then echo "success ..." break fi done rpm -ihv $OPENQRM_RESOURCE_RPM echo "y" | /opt/qrm/resource/sbin/qrm-bootstrap integrate -q ${QRM_SERVER_IP_ADDRESS} -v ${LOCAL_VE_NAME} -i $OPENQRM_CLIENT_INTERFACE -t "" --- NEW FILE: post-install-openqrm.kickstart --- #!/bin/bash INSTALL_TIME=`date +%D-%T | sed -e "s#/#.#g" | sed -e "s#:#.#g"` LOCAL_VE_NAME="linuxcoeZZZ_LINUXCOE_PROFILE_ZZZ-$INSTALL_TIME" if [ ! -f /root/anaconda-ks.cfg ]; then echo "ERROR: Could not find installation config file /root/anaconda-ks.cfg" exit 1 fi if [ ! -f /etc/redhat-release ]; then echo "ERROR: Could not find /etc/redhat-release" exit 1 fi OPENQRM_CLIENT_INTERFACE=`cat /root/anaconda-ks.cfg | grep network | sed -e "s/.*--device //g" | awk {' print $1 '}` # check which rpm will fit best if cat /etc/redhat-release | grep CentOS | grep 5 1>/dev/null; then # for CentOS 5 take the FC5 one OPENQRM_RESOURCE_RPM="openqrm-core-resource-3.1.4-2.FC5.i386.rpm" elif cat /etc/redhat-release | grep CentOS | grep 4 1>/dev/null; then # for CentOS 4 take the rhel4 one OPENQRM_RESOURCE_RPM="openqrm-core-resource-3.1.4-2.EL4.i386.rpm" else # take the fc5 as default OPENQRM_RESOURCE_RPM="openqrm-core-resource-3.1.4-2.FC5.i386.rpm" fi echo "using $OPENQRM_CLIENT_INTERFACE for $LOCAL_VE_NAME" echo "installing $OPENQRM_RESOURCE_RPM" while ! wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; do echo "retrying ..." sleep 2 if wget http://downloads.sourceforge.net/openqrm/$OPENQRM_RESOURCE_RPM?; then echo "success ..." break fi done rpm -ihv $OPENQRM_RESOURCE_RPM echo "y" | /opt/qrm/resource/sbin/qrm-bootstrap integrate -q ZZZ_QRM_SERVER_IP_ADDRESS_ZZZ -v $LOCAL_VE_NAME -i $OPENQRM_CLIENT_INTERFACE -t "" |
|
From: Matt <mat...@us...> - 2007-06-27 15:53:49
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv22035/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage Log Message: added post section to automatically install the openQRM agents and integrate the local booted system into openQRM Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** qrm-linuxcoe-manage 26 Jun 2007 18:20:45 -0000 1.5 --- qrm-linuxcoe-manage 27 Jun 2007 15:53:49 -0000 1.6 *************** *** 82,87 **** --- 82,94 ---- CURRENT=`pwd` case "$LINUXCOE_INSTALL_METHOD" in + kickstart) + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Preparing $LINUXCOE_INSTALL_METHOD pxe-configuration for resource $LINUXCOE_RESOURCE_ID" + + # get the whole server-config + qrm_get_server_config 1>/dev/null + export LINUXCOE_PROFILE + # add to automatic reboot after installation if not already in the ks.cfg if ! grep ^reboot $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg 1>/dev/null; then *************** *** 92,95 **** --- 99,104 ---- echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "firewall --disabled" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "selinux --disabled" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg echo "reboot" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg *************** *** 100,103 **** --- 109,126 ---- linuxcoe_log qrm-linuxcoe-manage "NOTICE : Automatic reboot after installation is already in ks""$LINUXCOE_PROFILE"".cfg" fi + + # add openQRM post section if not already in the ks.cfg + if ! grep openQRM $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg 1>/dev/null; then + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Adding openQRM post-section to ks""$LINUXCOE_PROFILE"".cfg" + echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "# openQRM post section" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "wget -O $LINUXCOE_PROFILE.post http://$QRM_SERVER_IP_ADDRESS/plugins/linuxcoe/inst/$LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "chmod +x $LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "./$LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "# /bin/rm -f $LINUXCOE_PROFILE.post" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + else + linuxcoe_log qrm-linuxcoe-manage "NOTICE : openQRM post-section already in ks""$LINUXCOE_PROFILE"".cfg" + fi + # get the kickstart file in a short http-path ln -sf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/ks""$LINUXCOE_PROFILE"".cfg *************** *** 117,128 **** ln -sf vmlinuz-""$LINUXCOE_PROFILE res-""$LINUXCOE_RESOURCE_ID""-kernel - # get the whole server-config - qrm_get_server_config 1>/dev/null - export LINUXCOE_PROFILE - # create the new pxe configuration file interpolate $LINUXCOE_PXE_TEMPLATE_KICKSTART > $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe chmod 777 $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe # adjust the pxe link cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/ --- 140,151 ---- ln -sf vmlinuz-""$LINUXCOE_PROFILE res-""$LINUXCOE_RESOURCE_ID""-kernel # create the new pxe configuration file interpolate $LINUXCOE_PXE_TEMPLATE_KICKSTART > $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe chmod 777 $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + # create the post-installation script + cat $LINUXCOE_POST_INSTALL_TEMPLATE_KICKSTART | sed -e "s#ZZZ_LINUXCOE_PROFILE_ZZZ#$LINUXCOE_PROFILE#g" | sed -e "s#ZZZ_QRM_SERVER_IP_ADDRESS_ZZZ#$QRM_SERVER_IP_ADDRESS#g" > $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/""$LINUXCOE_PROFILE"".post + chmod 777 $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/""$LINUXCOE_PROFILE"".post + # adjust the pxe link cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/ *************** *** 215,221 **** # reboot the node to install it ! $QRM_CLI resource reboot --resource_id $LINUXCOE_RESOURCE_ID ! # TODO : set to localboot after the node started the automatic installation ;; --- 238,250 ---- # reboot the node to install it ! $QRM_CLI resource reboot --internal_cr_id $LINUXCOE_RESOURCE_ID ! # TODO : start script in background via screen ! # save the nodes mac pxe-file, set to localboot ! # check when the node gets into error state ! # remove the node to enable it adding it again via easy-migration ! # restore mac pxe-file to enable localboot for the node ! # node will reboot after installation and ! # add itself to openQRM via the post section ;; |
|
From: Matt <mat...@us...> - 2007-06-27 13:01:17
|
Update of /cvsroot/openqrm/plugins/linuxcoe/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18811/plugins/linuxcoe/etc Modified Files: pxe-template.kickstart pxe-template.autoyast pxe-template.preseed Log Message: some updates for the pxe templates Index: pxe-template.kickstart =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/pxe-template.kickstart,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** pxe-template.kickstart 26 Jun 2007 18:20:45 -0000 1.1 --- pxe-template.kickstart 27 Jun 2007 13:01:11 -0000 1.2 *************** *** 3,5 **** label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} ks=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/ks${LINUXCOE_PROFILE}.cfg --- 3,5 ---- label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} ks=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/ks${LINUXCOE_PROFILE}.cfg Index: pxe-template.preseed =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/pxe-template.preseed,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** pxe-template.preseed 26 Jun 2007 18:20:45 -0000 1.1 --- pxe-template.preseed 27 Jun 2007 13:01:11 -0000 1.2 *************** *** 3,6 **** label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=11198 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} preseed/url=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/preseed${LINUXCOE_PROFILE}.cfg root=/dev/ram rw debconf/priority=critical debian-installer/framebuffer=false --- 3,6 ---- label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} preseed/url=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/preseed${LINUXCOE_PROFILE}.cfg root=/dev/ram rw debconf/priority=critical debian-installer/framebuffer=false Index: pxe-template.autoyast =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/etc/pxe-template.autoyast,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** pxe-template.autoyast 26 Jun 2007 18:20:45 -0000 1.1 --- pxe-template.autoyast 27 Jun 2007 13:01:11 -0000 1.2 *************** *** 3,5 **** label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=65536 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} autoyast=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/autoyast${LINUXCOE_PROFILE}.xml info=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/info${LINUXCOE_PROFILE} --- 3,5 ---- label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel ! append ramdisk_size=131072 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} autoyast=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/autoyast${LINUXCOE_PROFILE}.xml info=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/info${LINUXCOE_PROFILE} |
|
From: Matt <mat...@us...> - 2007-06-26 18:20:57
|
Update of /cvsroot/openqrm/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32374/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe Modified Files: LinuxCoeProfileManager.java Log Message: capable to do the first fully automatic installation :) Index: LinuxCoeProfileManager.java =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe/LinuxCoeProfileManager.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** LinuxCoeProfileManager.java 26 Jun 2007 10:12:38 -0000 1.2 --- LinuxCoeProfileManager.java 26 Jun 2007 18:20:45 -0000 1.3 *************** *** 91,94 **** --- 91,121 ---- return stdout; } + + + // installs a profile on a resource + // String profile_number -> number of the profile to install + // String install_method -> installation method (e.g. kickstart, preseed, autoyast) + // String id -> resource id to install + // String ip -> resource ip to install + public String install(String profile_number, String install_method, String id, String ip) { + String cmd = LinuxCoeCommandScript; + cmd=cmd + " install "; + cmd=cmd + profile_number; + cmd=cmd + " "; + cmd=cmd + install_method; + cmd=cmd + " "; + cmd=cmd + id; + cmd=cmd + " "; + cmd=cmd + ip; + String[] cmd_array = {cmd}; + setCmd(cmd_array); + CommandsExecutor.execute(this, ExecutionMode.IMMEDIATELY); + ScriptOutput out = getOutput(); + String stdout = out.getOutString(); + System.out.println("OUT: " + stdout); + System.out.println("ERR:" + out.getErrorString()); + return stdout; + } + |
|
From: Matt <mat...@us...> - 2007-06-26 18:20:47
|
Update of /cvsroot/openqrm/plugins/linuxcoe/include In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32374/plugins/linuxcoe/include Modified Files: linuxcoe-functions Log Message: capable to do the first fully automatic installation :) Index: linuxcoe-functions =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/include/linuxcoe-functions,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** linuxcoe-functions 25 Jun 2007 18:01:38 -0000 1.4 --- linuxcoe-functions 26 Jun 2007 18:20:45 -0000 1.5 *************** *** 33,36 **** --- 33,40 ---- LINUXCOE_PACKAGE_LOCATION="/root/linuxcoe-profiles" + LINUXCOE_PXE_TEMPLATE_KICKSTART="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/pxe-template.kickstart" + LINUXCOE_PXE_TEMPLATE_PRESEED="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/pxe-template.preseed" + LINUXCOE_PXE_TEMPLATE_AUTOYAST="${QRM_SERVER_BASE_DIR}/qrm/plugins/linuxcoe/etc/pxe-template.autoyast" + # management LINUXCOE_LOCK_FILE=/var/run/linuxcoe/linuxcoe-plugin.lock |
|
From: Matt <mat...@us...> - 2007-06-26 18:20:45
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32374/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage Log Message: capable to do the first fully automatic installation :) Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** qrm-linuxcoe-manage 26 Jun 2007 10:12:38 -0000 1.4 --- qrm-linuxcoe-manage 26 Jun 2007 18:20:45 -0000 1.5 *************** *** 58,62 **** /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/autoyast.xml""$LINUXCOE_PROFILE_NUMBER $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/$LINUXCOE_PROFILE""_unpacked/autoyast.xml /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/info""$LINUXCOE_PROFILE_NUMBER"".txt $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/$LINUXCOE_PROFILE""_unpacked/info - # TODO : need to fix the suse intird too fi --- 58,61 ---- *************** *** 71,77 **** /bin/rm -rf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/* ;; *) ! echo "ERROR: No such linuxcoe-management command. Use 'unpack', 'remove' or 'clean'" ! linuxcoe_log qrm-linuxcoe-manage "ERROR: No such linuxcoe-management command. Use 'unpack', 'remove' or 'clean'" exit 1 ;; --- 70,228 ---- /bin/rm -rf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/* ;; + + install) + LINUXCOE_INSTALL_METHOD=$3 + LINUXCOE_RESOURCE_ID=$4 + LINUXCOE_RESOURCE_IP=$5 + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Installing profile $LINUXCOE_PROFILE on node $LINUXCOE_RESOURCE_ID / $LINUXCOE_RESOURCE_IP using $LINUXCOE_INSTALL_METHOD" + + if [ ! -d $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst ]; then + mkdir -p $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst + fi + CURRENT=`pwd` + case "$LINUXCOE_INSTALL_METHOD" in + kickstart) + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Preparing $LINUXCOE_INSTALL_METHOD pxe-configuration for resource $LINUXCOE_RESOURCE_ID" + # add to automatic reboot after installation if not already in the ks.cfg + if ! grep ^reboot $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg 1>/dev/null; then + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Adding automatic reboot after installation to ks""$LINUXCOE_PROFILE"".cfg" + cat $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg | grep -B 1000 "%packages" | grep -v "%packages" > $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg.first-part + cat $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg | grep -A 1000 "%packages" > $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg.second-part + cat $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg.first-part > $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "reboot" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + echo "" >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + cat $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg.second-part >> $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg + /bin/rm -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg.first-part $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg.second-part + else + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Automatic reboot after installation is already in ks""$LINUXCOE_PROFILE"".cfg" + fi + # get the kickstart file in a short http-path + ln -sf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/ks.cfg $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/ks""$LINUXCOE_PROFILE"".cfg + + # prepare the kernel + initrd for the resource + if [ ! -f $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/vmlinuz-""$LINUXCOE_PROFILE ]; then + /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/isolinux/vmlinuz $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/vmlinuz-""$LINUXCOE_PROFILE + fi + if [ ! -f $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/initrd-""$LINUXCOE_PROFILE"".img ]; then + /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/isolinux/initrd.img $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/initrd-""$LINUXCOE_PROFILE"".img + fi + + # adjust the kernel link + cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/ + /bin/rm -f res-""$LINUXCOE_RESOURCE_ID""-initrd.img res-""$LINUXCOE_RESOURCE_ID""-kernel + ln -sf initrd-""$LINUXCOE_PROFILE"".img res-""$LINUXCOE_RESOURCE_ID""-initrd.img + ln -sf vmlinuz-""$LINUXCOE_PROFILE res-""$LINUXCOE_RESOURCE_ID""-kernel + + # get the whole server-config + qrm_get_server_config 1>/dev/null + export LINUXCOE_PROFILE + + # create the new pxe configuration file + interpolate $LINUXCOE_PXE_TEMPLATE_KICKSTART > $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + chmod 777 $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + + # adjust the pxe link + cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/ + /bin/rm -f res-""$LINUXCOE_RESOURCE_ID + ln -sf res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe res-""$LINUXCOE_RESOURCE_ID + + cd $CURRENT + ;; + + + preseed) + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Preparing $LINUXCOE_INSTALL_METHOD pxe-configuration for resource $LINUXCOE_RESOURCE_ID" + # get the preseed file in a short http-path + ln -sf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/iso""$LINUXCOE_PROFILE"".iso_unpacked/preseed $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/preseed""$LINUXCOE_PROFILE"".cfg + + # prepare the kernel + initrd for the resource + if [ ! -f $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/vmlinuz-""$LINUXCOE_PROFILE ]; then + /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/iso""$LINUXCOE_PROFILE"".iso_unpacked/install.386/vmlinuz $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/vmlinuz-""$LINUXCOE_PROFILE + fi + if [ ! -f $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/initrd-""$LINUXCOE_PROFILE"".img ]; then + /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/iso""$LINUXCOE_PROFILE"".iso_unpacked/install.386/initrd.gz $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/initrd-""$LINUXCOE_PROFILE"".img + fi + + # adjust the kernel link + cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/ + /bin/rm -f res-""$LINUXCOE_RESOURCE_ID""-initrd.img res-""$LINUXCOE_RESOURCE_ID""-kernel + ln -sf initrd-""$LINUXCOE_PROFILE"".img res-""$LINUXCOE_RESOURCE_ID""-initrd.img + ln -sf vmlinuz-""$LINUXCOE_PROFILE res-""$LINUXCOE_RESOURCE_ID""-kernel + + # get the whole server-config + qrm_get_server_config 1>/dev/null + export LINUXCOE_PROFILE + + # create the new pxe configuration file + interpolate $LINUXCOE_PXE_TEMPLATE_PRESEED > $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + chmod 777 $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + + # adjust the pxe link + cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/ + /bin/rm -f res-""$LINUXCOE_RESOURCE_ID + ln -sf res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe res-""$LINUXCOE_RESOURCE_ID + + cd $CURRENT + ;; + + + + autoyast) + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Preparing $LINUXCOE_INSTALL_METHOD pxe-configuration for resource $LINUXCOE_RESOURCE_ID" + # get the autoyast + info files in a short http-path + ln -sf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/autoyast.xml $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/autoyast""$LINUXCOE_PROFILE"".xml + ln -sf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/info $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/web/secure/inst/info""$LINUXCOE_PROFILE"" + + # prepare the kernel + initrd for the resource + if [ ! -f $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/vmlinuz-""$LINUXCOE_PROFILE ]; then + /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/linux $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/vmlinuz-""$LINUXCOE_PROFILE + fi + if [ ! -f $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/initrd-""$LINUXCOE_PROFILE"".img ]; then + /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/img""$LINUXCOE_PROFILE"".iso_unpacked/initrd $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/initrd-""$LINUXCOE_PROFILE"".img + fi + + # adjust the kernel link + cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/boot/ + /bin/rm -f res-""$LINUXCOE_RESOURCE_ID""-initrd.img res-""$LINUXCOE_RESOURCE_ID""-kernel + ln -sf initrd-""$LINUXCOE_PROFILE"".img res-""$LINUXCOE_RESOURCE_ID""-initrd.img + ln -sf vmlinuz-""$LINUXCOE_PROFILE res-""$LINUXCOE_RESOURCE_ID""-kernel + + # get the whole server-config + qrm_get_server_config 1>/dev/null + export LINUXCOE_PROFILE + + # create the new pxe configuration file + interpolate $LINUXCOE_PXE_TEMPLATE_AUTOYAST > $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + chmod 777 $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe + + # adjust the pxe link + cd $QRM_SERVER_BASE_DIR/qrm/tftpboot/pxelinux.cfg/ + /bin/rm -f res-""$LINUXCOE_RESOURCE_ID + ln -sf res-""$LINUXCOE_RESOURCE_ID"".netboot.linuxcoe res-""$LINUXCOE_RESOURCE_ID + + cd $CURRENT + + ;; + + *) + linuxcoe_log qrm-linuxcoe-manage "ERROR: No such install method $LINUXCOE_INSTALL_METHOD" + exit 1 + ;; + esac + + # reboot the node to install it + $QRM_CLI resource reboot --resource_id $LINUXCOE_RESOURCE_ID + + # TODO : set to localboot after the node started the automatic installation + + ;; + + *) ! echo "ERROR: No such linuxcoe-management command. Use 'unpack', 'remove', 'install' or 'clean'" ! linuxcoe_log qrm-linuxcoe-manage "ERROR: No such linuxcoe-management command. Use 'unpack', 'remove', 'install' or 'clean'" exit 1 ;; |
|
From: Matt <mat...@us...> - 2007-06-26 18:20:45
|
Update of /cvsroot/openqrm/plugins/linuxcoe/web/secure In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32374/plugins/linuxcoe/web/secure Modified Files: linuxcoe_install_int.jsp Log Message: capable to do the first fully automatic installation :) Index: linuxcoe_install_int.jsp =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/web/secure/linuxcoe_install_int.jsp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** linuxcoe_install_int.jsp 26 Jun 2007 11:51:54 -0000 1.1 --- linuxcoe_install_int.jsp 26 Jun 2007 18:20:45 -0000 1.2 *************** *** 55,58 **** --- 55,61 ---- String profile = ""; String cmd = ""; + String method = ""; + String ip = ""; + String id = ""; if (linuxcoe_cmd != null) { *************** *** 61,68 **** String linuxcoe_profile[] = request.getParameterValues("profile"); profile = linuxcoe_profile[0]; if(cmd.equals("install")) { LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); ! // manager.remove(profile); ! out.println("--> installing profile number : " +profile+ "!"); } else { out.println("--> No such command !"); --- 64,85 ---- String linuxcoe_profile[] = request.getParameterValues("profile"); profile = linuxcoe_profile[0]; + String install_method[] = request.getParameterValues("install_method"); + method = install_method[0]; + + if(cmd.equals("install")) { + + out.println("--> installing profile number : " +profile+ " install method " +method +" !"); + + } else if(cmd.equals("install_resource")) { + + String resource_ip[] = request.getParameterValues("resource_ip"); + ip = resource_ip[0]; + String resource_id[] = request.getParameterValues("resource_id"); + id = resource_id[0]; LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); ! manager.install(profile, method, id, ip); ! out.println("NOW installing profile number : " +profile+ " install method " +method+ "id " +id+ " ip " +ip+ " !"); ! } else { out.println("--> No such command !"); *************** *** 81,85 **** <h1> <img src="/images/ind_resources.gif" align="middle"/> ! LinuxCOE management </h1> --- 98,102 ---- <h1> <img src="/images/ind_resources.gif" align="middle"/> ! LinuxCOE installation </h1> *************** *** 88,92 **** ! <h2>Available resource for automatic installation</h2> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr><td width="90%" valign="top"> --- 105,109 ---- ! <h2>Available resource for automatic installation of profile <% out.print(profile); %></h2> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr><td width="90%" valign="top"> *************** *** 120,124 **** <form action="/plugins/linuxcoe/linuxcoe_install.jsp" method="get"> <input name="profile" value="<% out.print(profile); %>" type="hidden"> ! <input name="install_method" value="kickstart" type="hidden"> <input name="linuxcoe_cmd" value="install_resource" type="hidden"> <input value="Install" type="submit"> --- 137,143 ---- <form action="/plugins/linuxcoe/linuxcoe_install.jsp" method="get"> <input name="profile" value="<% out.print(profile); %>" type="hidden"> ! <input name="install_method" value="<% out.print(method); %>" type="hidden"> ! <input name="resource_ip" value="<% out.print(resource1.getIpString()); %>" type="hidden"> ! <input name="resource_id" value="<% out.print(resource1.getId()); %>" type="hidden"> <input name="linuxcoe_cmd" value="install_resource" type="hidden"> <input value="Install" type="submit"> |
|
From: Matt <mat...@us...> - 2007-06-26 18:20:44
|
Update of /cvsroot/openqrm/plugins/linuxcoe/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32374/plugins/linuxcoe/etc Added Files: pxe-template.kickstart pxe-template.autoyast pxe-template.preseed Log Message: capable to do the first fully automatic installation :) --- NEW FILE: pxe-template.kickstart --- default linux label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel append initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} ks=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/ks${LINUXCOE_PROFILE}.cfg --- NEW FILE: pxe-template.preseed --- default linux label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel append ramdisk_size=11198 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} preseed/url=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/preseed${LINUXCOE_PROFILE}.cfg root=/dev/ram rw debconf/priority=critical debian-installer/framebuffer=false --- NEW FILE: pxe-template.autoyast --- default linux label linux kernel boot/res-${LINUXCOE_RESOURCE_ID}-kernel append ramdisk_size=65536 initrd=boot/res-${LINUXCOE_RESOURCE_ID}-initrd.img id=${LINUXCOE_RESOURCE_ID} qrm=${QRM_SERVER_IP_ADDRESS} autoyast=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/autoyast${LINUXCOE_PROFILE}.xml info=http://${QRM_SERVER_IP_ADDRESS}/plugins/linuxcoe/inst/info${LINUXCOE_PROFILE} |
|
From: Matt <mat...@us...> - 2007-06-26 11:51:54
|
Update of /cvsroot/openqrm/plugins/linuxcoe/web/secure In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv1018/plugins/linuxcoe/web/secure Modified Files: linuxcoe_manage_int.jsp Added Files: linuxcoe_install.jsp linuxcoe_install_int.jsp Log Message: added install pages --- NEW FILE: linuxcoe_install.jsp --- <%-- The contents of this file are subject to the Qlusters Public License Version 1.1 (the License); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.openqrm.org/content/view/33/69/. Software distributed under the License is distributed on an AS IS basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is openQRM. The Initial Developer of the Original Code is Qlusters Corporation. Portions created by Qlusters Corporation are Copyright (C) 2003-2006. All Rights Reserved. Contributor(s): Description: Comments: --%> <%@ taglib uri='/WEB-INF/tld/struts-tiles-1.2.tld' prefix='tiles' %> <tiles:insert page='/templates/qrm_template.jsp'> <tiles:put name="title" value="openQRM » Linuxcoe plugin" /> <tiles:put name="onPageLoad" value="javascript:showAlerts();" /> <tiles:put name="calendar" value="" /> <tiles:put name='header' value='/action/header.do' /> <tiles:put name='sidebar' value='/action/sidebar.do' /> <tiles:put name='content' value='/plugins/linuxcoe/linuxcoe_install_int.jsp'/> <tiles:put name='footer' value='/include/footer.jsp'/> </tiles:insert> Index: linuxcoe_manage_int.jsp =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/web/secure/linuxcoe_manage_int.jsp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** linuxcoe_manage_int.jsp 26 Jun 2007 10:12:38 -0000 1.5 --- linuxcoe_manage_int.jsp 26 Jun 2007 11:51:54 -0000 1.6 *************** *** 173,176 **** --- 173,185 ---- out.println("<td>"); %> + <form action="/plugins/linuxcoe/linuxcoe_install.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="install_method" value="kickstart" type="hidden"> + <input name="linuxcoe_cmd" value="install" type="hidden"> + <input value="Install" type="submit"> + </form> + + </td><td> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> *************** *** 208,211 **** --- 217,229 ---- out.println("<td>"); %> + <form action="/plugins/linuxcoe/linuxcoe_install.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="install_method" value="preseed" type="hidden"> + <input name="linuxcoe_cmd" value="install" type="hidden"> + <input value="Install" type="submit"> + </form> + + </td><td> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> *************** *** 245,248 **** --- 263,275 ---- out.println("<td>"); %> + <form action="/plugins/linuxcoe/linuxcoe_install.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="install_method" value="autoyast" type="hidden"> + <input name="linuxcoe_cmd" value="install" type="hidden"> + <input value="Install" type="submit"> + </form> + + </td><td> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> --- NEW FILE: linuxcoe_install_int.jsp --- <%-- The contents of this file are subject to the Qlusters Public License Version 1.1 (the License); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.openqrm.org/content/view/33/69/. Software distributed under the License is distributed on an AS IS basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is openQRM. The Initial Developer of the Original Code is Qlusters Corporation. Portions created by Qlusters Corporation are Copyright (C) 2003-2006. All Rights Reserved. Contributor(s): Description: Comments: --%> <%@ taglib uri='/WEB-INF/tld/c-1.1.2.tld' prefix='c' %> <%@include file="/include/metaData.inc"%> <%@include file="/include/content.inc"%> <%@ page import="java.text.SimpleDateFormat" %> <%@ page import="java.util.*" %> <%@ page import="java.io.*" %> <%@ page import="com.qlusters.qrm.plugins.linuxcoe.*" %> <%@ page import="com.qlusters.qrm.utils.StringUtils" %> <%@ page import="com.qlusters.qrm.server.api.services.ApiServicesLocator" %> <%@ page import="com.qlusters.qrm.server.api.objects.resources.*" %> <%@ page import="com.qlusters.qrm.server.api.objects.*" %> <%@ page import="com.qlusters.qrm.server.api.services.nodes.*" %> <%@ page import="com.qlusters.qrm.server.api.objects.Paging" %> <%@ page import="com.qlusters.qrm.server.api.objects.SortOrder" %> <%@ page import="com.qlusters.qrm.server.api.objects.Sorter" %> <%@ page import="com.qlusters.qrm.server.api.objects.filters.*" %> <% // run profile commands String linuxcoe_cmd[] = request.getParameterValues("linuxcoe_cmd"); String profile = ""; String cmd = ""; if (linuxcoe_cmd != null) { // we got a cmd cmd = linuxcoe_cmd[0]; String linuxcoe_profile[] = request.getParameterValues("profile"); profile = linuxcoe_profile[0]; if(cmd.equals("install")) { LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); // manager.remove(profile); out.println("--> installing profile number : " +profile+ "!"); } else { out.println("--> No such command !"); } } %> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr class="h1Row"><td width="100%"> <h1> <img src="/images/ind_resources.gif" align="middle"/> LinuxCOE management </h1> </td></tr> </table> <h2>Available resource for automatic installation</h2> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr><td width="90%" valign="top"> <fieldset> <legend>Resources</legend> <table width="100%" border="2" cellspacing="0" cellpadding="1" class="dataTable"> <tr> <% ComputeResourceFilterData allfilter = new ComputeResourceFilterData(); allfilter.setIdle(); allfilter.setMaintenance(false); Paging allpage = new Paging(); Sorter allsort = new Sorter("id", SortOrder.DESC); List<ComputeResourceData> alldata = ApiServicesLocator.getInstance().getResourcesServices().getResources(allfilter, allpage, allsort); ListIterator iter1 = alldata.listIterator(); while (iter1.hasNext()) { ComputeResourceData resource1 = (ComputeResourceData) iter1.next(); out.println("<td>"); out.print("node " +resource1.getId()); out.println("</td><td>"); out.print(resource1.getIpString()); out.println("</td>"); out.println("<td>"); %> <form action="/plugins/linuxcoe/linuxcoe_install.jsp" method="get"> <input name="profile" value="<% out.print(profile); %>" type="hidden"> <input name="install_method" value="kickstart" type="hidden"> <input name="linuxcoe_cmd" value="install_resource" type="hidden"> <input value="Install" type="submit"> </form> <% out.println("</td>"); } %> </tr> </table> </td></tr> </table> |
|
From: Matt <mat...@us...> - 2007-06-26 10:12:46
|
Update of /cvsroot/openqrm/plugins/linuxcoe/web/secure In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv24186/plugins/linuxcoe/web/secure Modified Files: linuxcoe_manage_int.jsp Log Message: added remove + clean actions Index: linuxcoe_manage_int.jsp =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/web/secure/linuxcoe_manage_int.jsp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** linuxcoe_manage_int.jsp 26 Jun 2007 09:17:09 -0000 1.4 --- linuxcoe_manage_int.jsp 26 Jun 2007 10:12:38 -0000 1.5 *************** *** 35,38 **** --- 35,63 ---- + <% + // run profile commands + + String linuxcoe_cmd[] = request.getParameterValues("linuxcoe_cmd"); + if (linuxcoe_cmd != null) { + // we got a cmd + String cmd = linuxcoe_cmd[0]; + String linuxcoe_profile[] = request.getParameterValues("profile"); + String profile = linuxcoe_profile[0]; + if(cmd.equals("remove")) { + LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); + manager.remove(profile); + out.println("--> removed profile number : " +profile+ "!"); + } else if(cmd.equals("clean")) { + LinuxCoeProfileManager manager = new LinuxCoeProfileManager(); + manager.clean(); + out.println("--> cleaned scratch dir !"); + } else { + out.println("--> No such command !"); + } + } + + + %> + *************** *** 146,149 **** --- 171,183 ---- out.println("kickstart"); out.println("</td>"); + out.println("<td>"); + %> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="linuxcoe_cmd" value="remove" type="hidden"> + <input value="Remove" type="submit"> + </form> + <% + out.println("</td>"); *************** *** 172,175 **** --- 206,219 ---- out.println("</td>"); + out.println("<td>"); + %> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="linuxcoe_cmd" value="remove" type="hidden"> + <input value="Remove" type="submit"> + </form> + <% + out.println("</td>"); + *************** *** 199,202 **** --- 243,255 ---- out.println("</td>"); + out.println("<td>"); + %> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="linuxcoe_cmd" value="remove" type="hidden"> + <input value="Remove" type="submit"> + </form> + <% + out.println("</td>"); *************** *** 208,211 **** --- 261,273 ---- out.println("</td>"); + out.println("<td>"); + %> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> + <input name="profile" value="<% out.print(specific_linuxcoe_profile_number); %>" type="hidden"> + <input name="linuxcoe_cmd" value="remove" type="hidden"> + <input value="Remove" type="submit"> + </form> + <% + out.println("</td>"); } *************** *** 237,241 **** --- 299,309 ---- </table> + <form action="/plugins/linuxcoe/linuxcoe_manage.jsp" method="get"> + <input name="linuxcoe_cmd" value="clean" type="hidden"> + <input name="profile" value="0" type="hidden"> + <input value="Clean up" type="submit"> + </form> + <br> <a href="#" >Back</a> |
|
From: Matt <mat...@us...> - 2007-06-26 10:12:39
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv24186/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage Log Message: added remove + clean actions Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** qrm-linuxcoe-manage 26 Jun 2007 09:17:10 -0000 1.3 --- qrm-linuxcoe-manage 26 Jun 2007 10:12:38 -0000 1.4 *************** *** 58,64 **** /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/autoyast.xml""$LINUXCOE_PROFILE_NUMBER $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/$LINUXCOE_PROFILE""_unpacked/autoyast.xml /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/info""$LINUXCOE_PROFILE_NUMBER"".txt $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/$LINUXCOE_PROFILE""_unpacked/info - # TODO : need to fix the suse intird too - fi --- 58,62 ---- *************** *** 67,74 **** remove) linuxcoe_log qrm-linuxcoe-manage "NOTICE : running remove on $LINUXCOE_PROFILE" ;; *) ! echo "ERROR: No such linuxcoe-management command. Use 'unpack' or 'remove'" ! linuxcoe_log qrm-linuxcoe-manage "ERROR: No such linuxcoe-management command. Use 'unpack' or 'remove'" exit 1 ;; --- 65,77 ---- remove) linuxcoe_log qrm-linuxcoe-manage "NOTICE : running remove on $LINUXCOE_PROFILE" + /bin/rm -rf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/*""$LINUXCOE_PROFILE""* + ;; + clean) + linuxcoe_log qrm-linuxcoe-manage "NOTICE : Cleaning up the profile scratch dir" + /bin/rm -rf $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/* ;; *) ! echo "ERROR: No such linuxcoe-management command. Use 'unpack', 'remove' or 'clean'" ! linuxcoe_log qrm-linuxcoe-manage "ERROR: No such linuxcoe-management command. Use 'unpack', 'remove' or 'clean'" exit 1 ;; |
|
From: Matt <mat...@us...> - 2007-06-26 10:12:39
|
Update of /cvsroot/openqrm/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv24186/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe Modified Files: LinuxCoeProfileManager.java Log Message: added remove + clean actions Index: LinuxCoeProfileManager.java =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/main/code/java/com/qlusters/qrm/plugins/linuxcoe/LinuxCoeProfileManager.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** LinuxCoeProfileManager.java 25 Jun 2007 15:32:48 -0000 1.1 --- LinuxCoeProfileManager.java 26 Jun 2007 10:12:38 -0000 1.2 *************** *** 44,53 **** final static String LinuxCoeCommandScript = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage"; ! public String unpack(String profile) { String cmd = LinuxCoeCommandScript; cmd=cmd + " unpack "; cmd=cmd + profile; - String[] cmd_array = {cmd}; setCmd(cmd_array); --- 44,54 ---- final static String LinuxCoeCommandScript = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage"; ! ! // unpacks an iso image ! // String profile -> iso filename in scratch dir public String unpack(String profile) { String cmd = LinuxCoeCommandScript; cmd=cmd + " unpack "; cmd=cmd + profile; String[] cmd_array = {cmd}; setCmd(cmd_array); *************** *** 60,62 **** --- 61,95 ---- } + + // removes a profile (iso + unpacked) + // String profile_number -> number of the profile to remove + public String remove(String profile_number) { + String cmd = LinuxCoeCommandScript; + cmd=cmd + " remove "; + cmd=cmd + profile_number; + String[] cmd_array = {cmd}; + setCmd(cmd_array); + CommandsExecutor.execute(this, ExecutionMode.IMMEDIATELY); + ScriptOutput out = getOutput(); + String stdout = out.getOutString(); + System.out.println("OUT: " + stdout); + System.out.println("ERR:" + out.getErrorString()); + return stdout; + } + + // cleans the profile dir + public String clean() { + String cmd = LinuxCoeCommandScript; + cmd=cmd + " clean"; + String[] cmd_array = {cmd}; + setCmd(cmd_array); + CommandsExecutor.execute(this, ExecutionMode.IMMEDIATELY); + ScriptOutput out = getOutput(); + String stdout = out.getOutString(); + System.out.println("OUT: " + stdout); + System.out.println("ERR:" + out.getErrorString()); + return stdout; + } + + } |
|
From: Matt <mat...@us...> - 2007-06-26 09:17:10
|
Update of /cvsroot/openqrm/plugins/linuxcoe/sbin In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv2005/plugins/linuxcoe/sbin Modified Files: qrm-linuxcoe-manage Log Message: profile list ist working Index: qrm-linuxcoe-manage =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/sbin/qrm-linuxcoe-manage,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** qrm-linuxcoe-manage 25 Jun 2007 18:01:38 -0000 1.2 --- qrm-linuxcoe-manage 26 Jun 2007 09:17:10 -0000 1.3 *************** *** 58,61 **** --- 58,64 ---- /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/autoyast.xml""$LINUXCOE_PROFILE_NUMBER $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/$LINUXCOE_PROFILE""_unpacked/autoyast.xml /bin/cp -f $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/info""$LINUXCOE_PROFILE_NUMBER"".txt $QRM_SERVER_BASE_DIR/qrm/plugins/linuxcoe/scratch_monkey/systemdesigner/$LINUXCOE_PROFILE""_unpacked/info + + # TODO : need to fix the suse intird too + fi |
|
From: Matt <mat...@us...> - 2007-06-26 09:17:09
|
Update of /cvsroot/openqrm/plugins/linuxcoe/web/secure In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv2005/plugins/linuxcoe/web/secure Modified Files: linuxcoe_manage_int.jsp Log Message: profile list ist working Index: linuxcoe_manage_int.jsp =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/web/secure/linuxcoe_manage_int.jsp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** linuxcoe_manage_int.jsp 25 Jun 2007 18:01:38 -0000 1.3 --- linuxcoe_manage_int.jsp 26 Jun 2007 09:17:09 -0000 1.4 *************** *** 31,37 **** <%@ page import="java.text.SimpleDateFormat" %> <%@ page import="java.util.*" %> ! <%@ page import="java.io.File" %> ! <%@ page import="java.io.FilenameFilter" %> ! <%@ page import="java.io.FileFilter" %> <%@ page import="com.qlusters.qrm.plugins.linuxcoe.*" %> --- 31,35 ---- <%@ page import="java.text.SimpleDateFormat" %> <%@ page import="java.util.*" %> ! <%@ page import="java.io.*" %> <%@ page import="com.qlusters.qrm.plugins.linuxcoe.*" %> *************** *** 44,48 **** <h1> <img src="/images/ind_resources.gif" align="middle"/> ! LinuxCOE managment </h1> --- 42,46 ---- <h1> <img src="/images/ind_resources.gif" align="middle"/> ! LinuxCOE management </h1> *************** *** 103,106 **** --- 101,106 ---- if (filename.endsWith("unpacked")) { // out.println("--> : " +filename+ " in the unpacked list<br>"); + String specific_linuxcoe_profile_number = filename.replaceAll("[^0-9]", ""); + // out.println("--> : " +specific_linuxcoe_profile_number+ " nr<br>"); String specific_linuxcoe_profile_dir = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/" +filename; File check_profile_exists = new File(specific_linuxcoe_profile_dir); *************** *** 108,112 **** out.println("<td>"); ! out.println("linuxcoe profile --> : " +filename); out.println("</td>"); --- 108,112 ---- out.println("<td>"); ! out.println(specific_linuxcoe_profile_number); out.println("</td>"); *************** *** 124,142 **** out.println("<td>"); if (redhat_ks_file.exists()) { ! out.println("Found redhat-based kickstart-instalation<br>"); } else if (debian_ks_file.exists()) { ! out.println("Found debian-based preseed-instalation<br>"); } else if (suse_ks_file.exists()) { ! out.println("Found suse-based autoyast-instalation<br>"); } else { ! out.println("It is something else<br>"); } - out.println("</td><td></td>"); out.println("</tr><tr>"); } --- 124,213 ---- out.println("<td>"); if (redhat_ks_file.exists()) { ! String redhat_coe = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/" +filename+ "/isolinux/coebund.msg"; ! java.io.File f = null; ! java.net.URL conf = null; ! java.io.BufferedReader reader = null; ! String specific_linuxcoe_profile_name = ""; ! f = new java.io.File(redhat_coe); ! redhat_coe = "file://" + redhat_coe; ! conf = new java.net.URL(redhat_coe); ! if (f.exists()) { ! reader = new java.io.BufferedReader(new java.io.InputStreamReader(conf.openStream())); ! specific_linuxcoe_profile_name = reader.readLine(); ! reader.close(); ! specific_linuxcoe_profile_name = specific_linuxcoe_profile_name.replaceAll(".*/", ""); ! specific_linuxcoe_profile_name = specific_linuxcoe_profile_name.replaceAll("!.*", ""); ! } else { ! specific_linuxcoe_profile_name = "Not available"; ! } ! out.println(specific_linuxcoe_profile_name); ! out.println("</td>"); ! out.println("<td>"); ! out.println("kickstart"); ! out.println("</td>"); } else if (debian_ks_file.exists()) { ! String debian_coe = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/" +filename+ "/isolinux/coebund.msg"; ! java.io.File f = null; ! java.net.URL conf = null; ! java.io.BufferedReader reader = null; ! String specific_linuxcoe_profile_name = ""; ! f = new java.io.File(debian_coe); ! debian_coe = "file://" + debian_coe; ! conf = new java.net.URL(debian_coe); ! if (f.exists()) { ! reader = new java.io.BufferedReader(new java.io.InputStreamReader(conf.openStream())); ! specific_linuxcoe_profile_name = reader.readLine(); ! reader.close(); ! specific_linuxcoe_profile_name = specific_linuxcoe_profile_name.replaceAll(".*/", ""); ! specific_linuxcoe_profile_name = specific_linuxcoe_profile_name.replaceAll("!.*", ""); ! } else { ! specific_linuxcoe_profile_name = "Not available"; ! } ! out.println(specific_linuxcoe_profile_name); ! out.println("</td>"); ! out.println("<td>"); ! out.println("preseed"); ! out.println("</td>"); ! ! } else if (suse_ks_file.exists()) { ! String suse_coe = System.getenv("QRM_SERVER_BASE_DIR") + "/qrm/plugins/linuxcoe/web/secure/scratch_monkey/systemdesigner/" +filename+ "/coebund.msg"; ! java.io.File f = null; ! java.net.URL conf = null; ! java.io.BufferedReader reader = null; ! String specific_linuxcoe_profile_name = ""; ! f = new java.io.File(suse_coe); ! suse_coe = "file://" + suse_coe; ! conf = new java.net.URL(suse_coe); ! if (f.exists()) { ! reader = new java.io.BufferedReader(new java.io.InputStreamReader(conf.openStream())); ! specific_linuxcoe_profile_name = reader.readLine(); ! reader.close(); ! specific_linuxcoe_profile_name = specific_linuxcoe_profile_name.replaceAll(".*/", ""); ! specific_linuxcoe_profile_name = specific_linuxcoe_profile_name.replaceAll("!.*", ""); ! } else { ! specific_linuxcoe_profile_name = "Not available"; ! } ! out.println(specific_linuxcoe_profile_name); ! out.println("</td>"); ! out.println("<td>"); ! out.println("autoyast"); ! out.println("</td>"); ! } else { ! out.println("(some linux)"); ! out.println("</td>"); ! out.println("<td>"); ! out.println("unkown"); ! out.println("</td>"); ! ! } out.println("</tr><tr>"); } |
|
From: Matt <mat...@us...> - 2007-06-25 18:01:54
|
Update of /cvsroot/openqrm/plugins/linuxcoe/include In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv23063/plugins/linuxcoe/include Modified Files: linuxcoe-functions Log Message: more enhancements Index: linuxcoe-functions =================================================================== RCS file: /cvsroot/openqrm/plugins/linuxcoe/include/linuxcoe-functions,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** linuxcoe-functions 25 Jun 2007 15:32:48 -0000 1.3 --- linuxcoe-functions 25 Jun 2007 18:01:38 -0000 1.4 *************** *** 27,30 **** --- 27,31 ---- QRM_CLI=$QRM_SERVER_BASE_DIR/qrm/bin/qrm-cli + # installation LINUXCOE_USER=nobody LINUXCOE_GROUP=nobody *************** *** 32,35 **** --- 33,88 ---- LINUXCOE_PACKAGE_LOCATION="/root/linuxcoe-profiles" + # management + LINUXCOE_LOCK_FILE=/var/run/linuxcoe/linuxcoe-plugin.lock + LINUXCOE_LOCK_DELAY=5 + LINUXCOE_LOCK_RETRY=100 + LINUXCOE_LOCK_TIMEOUT=500 + + + + ################ common linuxcoe functions + + # logs for linuxcoe + function linuxcoe_log() { + local COMPONENT=$1 + shift + local MESSAGE=$@ + logger -i -t "linuxcoe plug-in" "$COMPONENT : $MESSAGE" + } + + + + # locking function + function linuxcoe_lock() { + local COMMAND=$1 + local RET=1 + + if [ ! -d `dirname $LINUXCOE_LOCK_FILE` ]; then + mkdir -p `dirname $LINUXCOE_LOCK_FILE` + fi + case "$COMMAND" in + aquire) + lockfile -s $LINUXCOE_LOCK_DELAY -r $LINUXCOE_LOCK_RETRY -l $LINUXCOE_LOCK_TIMEOUT $LINUXCOE_LOCK_FILE + RET=$? + linuxcoe_log linuxcoe_lock "Aquired the lock" + return $RET + ;; + release) + /bin/rm -f $LINUXCOE_LOCK_FILE + RET=$? + linuxcoe_log linuxcoe_lock "Released the lock" + return $RET + ;; + *) + linuxcoe_log linuxcoe_lock "No such command. Try 'aquire' or 'release'" + return 1 + ;; + esac + } + + + ################# plugin install linuxcoe functions + + function linuxcoe_install() { echo "installing the linuxcoe plugin" |