mirror of
				https://github.com/apache/cloudstack.git
				synced 2025-11-04 00:02:37 +01:00 
			
		
		
		
	Discard rrouter lock
Then we can make all the actions in sequence
This commit is contained in:
		
							parent
							
								
									217aceb9ef
								
							
						
					
					
						commit
						7e6bbf9b16
					
				@ -48,13 +48,6 @@ then
 | 
			
		||||
    exit 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
lock_rr="rrouter"
 | 
			
		||||
locked_rr=$(getLockFile $lock_rr)
 | 
			
		||||
if [ "$locked_rr" != "1" ]
 | 
			
		||||
then
 | 
			
		||||
    exit 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
grep "redundant_router=1" /var/cache/cloud/cmdline > /dev/null
 | 
			
		||||
no_redundant=$?
 | 
			
		||||
 | 
			
		||||
@ -136,5 +129,4 @@ else
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
ret=$?
 | 
			
		||||
releaseLockFile $lock_rr $locked_rr
 | 
			
		||||
unlock_exit $ret $lock $locked
 | 
			
		||||
 | 
			
		||||
@ -1,7 +1,6 @@
 | 
			
		||||
#!/bin/bash
 | 
			
		||||
 | 
			
		||||
# IMPORTANT: Ordering of lock:
 | 
			
		||||
# biglock --> rrouter
 | 
			
		||||
# Only one lock is allowed: biglock
 | 
			
		||||
 | 
			
		||||
# getLockFile() parameters
 | 
			
		||||
# $1 lock filename
 | 
			
		||||
 | 
			
		||||
@ -2,7 +2,7 @@
 | 
			
		||||
 | 
			
		||||
source /root/func.sh
 | 
			
		||||
 | 
			
		||||
lock="rrouter"
 | 
			
		||||
lock="biglock"
 | 
			
		||||
locked=$(getLockFile $lock)
 | 
			
		||||
if [ "$locked" != "1" ]
 | 
			
		||||
then
 | 
			
		||||
 | 
			
		||||
@ -2,7 +2,7 @@
 | 
			
		||||
 | 
			
		||||
source /root/func.sh
 | 
			
		||||
 | 
			
		||||
lock="rrouter"
 | 
			
		||||
lock="biglock"
 | 
			
		||||
locked=$(getLockFile $lock)
 | 
			
		||||
if [ "$locked" != "1" ]
 | 
			
		||||
then
 | 
			
		||||
 | 
			
		||||
@ -2,7 +2,7 @@
 | 
			
		||||
 | 
			
		||||
source /root/func.sh
 | 
			
		||||
 | 
			
		||||
lock="rrouter"
 | 
			
		||||
lock="biglock"
 | 
			
		||||
locked=$(getLockFile $lock)
 | 
			
		||||
if [ "$locked" != "1" ]
 | 
			
		||||
then
 | 
			
		||||
 | 
			
		||||
@ -2,7 +2,7 @@
 | 
			
		||||
 | 
			
		||||
source /root/func.sh
 | 
			
		||||
 | 
			
		||||
lock="rrouter"
 | 
			
		||||
lock="biglock"
 | 
			
		||||
locked=$(getLockFile $lock)
 | 
			
		||||
if [ "$locked" != "1" ]
 | 
			
		||||
then
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user