Yaniv Bronhaim has posted comments on this change. Change subject: Changing init script lock flow ......................................................................
Patch Set 1: (3 comments) sorry for the delay... .................................................... Commit Message Line 3: AuthorDate: 2013-09-04 11:40:20 +0300 Line 4: Commit: Yaniv Bronhaim <[email protected]> Line 5: CommitDate: 2013-09-04 13:25:53 +0300 Line 6: Line 7: Changing init script lock flow right.. will do Line 8: Line 9: Change-Id: Ic74c9cf9c2c520e94a98b99fdb970b544b780ba3 .................................................... File init/sysvinit/vdsmd.init.in Line 78: return 1 Line 79: fi Line 80: touch "$LOCK_FILE" Line 81: trap cleanup SIGINT SIGHUP SIGTERM Line 82: "@CHOWN_PATH@" vdsm:kvm "$LOCK_FILE" so lets agree that daemonAdapter shouldn't touch this file at all? this file should be handled only in this script scope. I'll also remove the --lockfile option Line 83: } Line 84: Line 85: release_lock() { Line 86: "@RM_PATH@" -f "$LOCK_FILE" > /dev/null 2>&1 Line 180: if ! acquire_lock; then Line 181: log_failure_msg "cannot perform VDSM daemon operation when another instance runs" Line 182: return 1 Line 183: else Line 184: $1 Zhou suggested flock. why changing it right now? all init scripts use lockfile.. lets do it in separate patch and if all agree we'll take it. Here I suggest new implementation for the locking mechanism. and I don't understand what is wrong with the eval usage ? that's the way I call to the operation (start\stop) Line 185: RETVAL=$? Line 186: release_lock Line 187: return "${RETVAL}" Line 188: fi -- To view, visit http://gerrit.ovirt.org/18875 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ic74c9cf9c2c520e94a98b99fdb970b544b780ba3 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim <[email protected]> Gerrit-Reviewer: Alon Bar-Lev <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Yaniv Bronhaim <[email protected]> Gerrit-Reviewer: Zhou Zheng Sheng <[email protected]> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
