Changeset 2831
- Timestamp:
- Jan 1, 2010, 7:18:12 PM (15 years ago)
- Location:
- package_branches/invirt-xen-config/hvirt
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
package_branches/invirt-xen-config/hvirt
- Property svn:mergeinfo changed
/trunk/packages/invirt-xen-config merged: 2829-2830
- Property svn:mergeinfo changed
-
package_branches/invirt-xen-config/hvirt/debian/changelog
r2828 r2831 7 7 invirt-xen-config (0.0.27) unstable; urgency=low 8 8 9 [ Greg Brockman ] 9 10 * Nuked the pinning of libxen3 10 11 11 -- Greg Brockman <gdb@mit.edu> Fri, 01 Jan 2010 18:28:45 -0500 12 [ Evan Broder ] 13 * Don't try to start sysvms in the invirt-xen-config init script. The 14 code has never been reliable. 15 16 -- Evan Broder <broder@mit.edu> Fri, 01 Jan 2010 17:58:57 -0600 12 17 13 18 invirt-xen-config (0.0.26hvirt1) unstable; urgency=low -
package_branches/invirt-xen-config/hvirt/debian/invirt-xen-config.init
r2087 r2831 14 14 DESC="Invirt Xen host" 15 15 PARENTPACKAGE=xend 16 SYSVM_FILES=($(run-parts --list /etc/xen/sysvms))17 SYSVMS=("${SYSVM_FILES[@]/#\/etc\/xen\/sysvms\/}")18 16 GEN_FILES=(/etc/xen/xend-config.sxp.invirt) 19 17 … … 23 21 . /lib/init/std-init.sh 24 22 25 start_sysvm() {26 # Attempt to start a sysvm, but only if it's not running already27 # somewhere on the cluster28 29 VM="$1"30 LV="${VM}_hda"31 DISK="/dev/xenvg/$LV"32 33 # Don't bother trying to start the VM if it's already running34 if xm list "$VM" >/dev/null 2>&1; then35 return 136 fi37 38 RET=139 # To keep multiple hosts from trying to start a VM at the same40 # time, lock VM creation at startup-time with a lock LV, since LV41 # creation is atomic42 if lvcreate -L 1K -n "lock_${LV}" xenvg >/dev/null 2>&1; then43 # If we can disable the LV, then the VM isn't already running44 # somewhere else45 if lvchange -a n "$DISK" >/dev/null 2>&1; then46 lvchange -a y "$DISK" >/dev/null 2>&147 48 [ "$VERBOSE" != no ] && log_daemon_msg "Starting sysvm $VM"49 xm create "sysvms/$VM" >/dev/null50 [ "$VERBOSE" != no ] && log_end_msg $?51 RET=052 fi53 54 # Regardless of whether we could get the lock or not, the55 # lvchange -a n probably disabled the LV somewhere; be sure we56 # clean up57 lvchange -a y "$DISK" >/dev/null 2>&158 59 # Cleanup the lock, regardless of whether we started the LV60 lvchange -a n "/dev/xenvg/lock_${LV}" >/dev/null 2>&161 lvchange -a ey "/dev/xenvg/lock_${LV}" >/dev/null 2>&162 lvremove -f "/dev/xenvg/lock_${LV}" >/dev/null 2>&163 fi64 65 return $RET66 }67 68 23 do_startup() { 69 24 gen_files 70 71 for vm in "${SYSVMS[@]}"; do72 start_sysvm "$vm"73 done74 25 75 26 echo 1 >/proc/sys/net/ipv4/ip_forward -
package_branches/invirt-xen-config/hvirt/debian/rules
r2828 r2831 6 6 /etc/xen/qemu-ifup.invirt \ 7 7 /etc/xen/xend-config.sxp.invirt 8 9 DEB_UNDIVERT_FILES_invirt-xen-config += \ 10 /etc/apt/preferences.invirt 11 12 DEB_UNDIVERT_VERISON_/etc/apt/preferences.invirt = 0.0.27~ 8 13 9 14 include /usr/share/cdbs/1/rules/debhelper.mk
Note: See TracChangeset
for help on using the changeset viewer.