| Author | Message | 
		
		  | royr | 
			  
				|  Posted: Sun Aug 19, 2001 2:02 am    Post subject: |   |  | 
		
		  |  Acolyte
 
 
 Joined: 30 Jun 2001Posts: 65
 Location: Israel
 
 | 
			  
				| This is required after the queue manager has ended abnormally and before it's restarted. 
 This command removes all shared memory resources and semaphores that belong to user mqm:
 
 
 
   
	| Code: |  
	| ipcs -a | grep mqm | awk '{printf( "-%s %s ", $1, $2 )}' | xargs ipcrm
 
 |  
 
 [ This Message was edited by: royr on 2001-08-27 01:35 ]
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | john_bazeley | 
			  
				|  Posted: Sun Aug 26, 2001 7:33 pm    Post subject: |   |  | 
		
		  | Newbie
 
 
 Joined: 25 Aug 2001Posts: 6
 Location: New Zealand
 
 | 
			  
				| If you do this when you've got more than 1 QM, or things like client trigger monitors running on the same box, you'll be in big trouble. |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | kriersd | 
			  
				|  Posted: Thu Nov 07, 2002 11:56 am    Post subject: |   |  | 
		
		  |  Master
 
 
 Joined: 22 Jul 2002Posts: 209
 Location: IA, USA
 
 | 
			  
				| 
   
	| Code: |  
	| If you do this when you've got more than 1 QM, or things like client trigger monitors running on the same box, you'll be in big trouble
 
 |  
 So, Is there a way to identify which mqm shared memory resources and semaphores belong to a given queue manager. I would like to find out how to clean up the remaining shared resources for just one of the queue managers running on the server.
 _________________
 Dave Krier
 
 IBM WebSphere MQ Workflow V3.4 Solution Designer
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | bower5932 | 
			  
				|  Posted: Mon Nov 11, 2002 11:52 am    Post subject: |   |  | 
		
		  |  Jedi Knight
 
 
 Joined: 27 Aug 2001Posts: 3023
 Location: Dallas, TX, USA
 
 | 
			  
				| Try looking at the amqiclen utility.  However, I don't believe it is documented and I think it has a disclaimer about only running it if directed by IBM support.  You can run it with amqiclen -help to get a brief usage message.  The program will hang unless you pipe in the mqs.ini file: 
 amqiclen -v -c -m QmgrName < /var/mqm/mqs.ini
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | kriersd | 
			  
				|  Posted: Thu Dec 05, 2002 8:59 am    Post subject: |   |  | 
		
		  |  Master
 
 
 Joined: 22 Jul 2002Posts: 209
 Location: IA, USA
 
 | 
			  
				| NOTE -c only does a check... It does NOT remove any resources. 
 amqiclen  -v   -c   -m qmgrname   < /var/mqm/mqs.ini
 .
 -v = verbose
 -c = check only (does not ipcrm anything)
 -m = only to clear up named queue manager
 _________________
 Dave Krier
 
 IBM WebSphere MQ Workflow V3.4 Solution Designer
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | csmith28 | 
			  
				|  Posted: Wed Dec 22, 2004 3:07 pm    Post subject: |   |  | 
		
		  |  Grand Master
 
 
 Joined: 15 Jul 2003Posts: 1196
 Location: Arizona
 
 | 
			  
				| amqiclen -m MQMgrName -vix Usage: ./amqiclen {-c | -x} -c = check -x = destroy
 [-m <qmgr> | -s] -m = queue manager. -s = system subpool
 [-p <prefix>] qmgrs directory Prefix (/var/mqm)
 [-q] queue manager subpool
 [-i] IPCC subpool
 [-o] persistent queue manager subpool
 [-t] trace control
 [-F] Force (deleted active segments)
 [-v] verbose
 [-h] headings
 [-d] display remaining resources
 
 The options in detail are:
 
 -c: check IPC only, do not remove
 -x: remove IPC. Only IPC owned by mqm is removed.
 Note that these options are mutually exclusive; one or the other must be
 selected.
 
 -m QMGR: check/remove IPC on qmgr QMGR
 -s: check/remove IPC in the system subpool, i.e. the qmgr @SYSTEM
 -p prefix: search for qmgr data in directory prefix (default /var/mqm)
 -q: IPC in qmgr subpool only, i.e. shm/sem dirs in the qmgrs/QMGR dir
 -i: IPC in IPCC subpool only, i.e. shm/sem dirs in the qmgrs/QMGR/@ipcc dir
 -o: IPC in qmpersist subpool only, i.e. shm/sem dirs in the
 qmgrs/QMGR/@qmpersist dir directory. The directories are shmem esem isem
 msem ssem
 -t: Trace control shm/sem, keyed from /var/mqm/errors
 -F: Force removal. Normal operation is not to remove IPC which is in
 use. This is determined by checking the processes using a semaphore, or
 the number of processes attached to a shared memory segment. This flag
 bypasses these checks
 -v: Where appropriate, print output showing the progress of the utility
 -h: Print headings in the output
 -d: Run the commands ipcs -m and ipcs -s
 
 Further notes
 In the above I refer to "IPC .. keyed from files..". This means that the
 key of a semaphore set or shared memory segment is derived from the
 inode of a file or directory in the MQ directory tree.
 Note that the -m | -s flags are not mandatory. If both flags are
 omitted, amqiclen checks (removes) IPC from all directories found in the
 prefix/qmgrs
 
 The arguments conform to the usual UNIX rules for parsing the command
 line. The options may be specified separately, e.g. amqiclen -c -v -h -t
 -m QMGR, or they may be concatenated until an option is reached that
 requires a further argument, e.g. amqiclen -cvhtmQMGR has the same effect.
 _________________
 Yes, I am an agent of Satan but my duties are largely ceremonial.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | Nigelg | 
			  
				|  Posted: Wed Dec 22, 2004 11:17 pm    Post subject: |   |  | 
		
		  | Grand Master
 
 
 Joined: 02 Aug 2004Posts: 1046
 
 
 | 
			  
				| The input redirect from /var/mqm/mqs.ini is old syntax, and is no longer required. amqiclen is fully supported by IBM, and you can raise defects/APARs against the utility.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | positional | 
			  
				|  Posted: Wed Dec 14, 2005 10:32 am    Post subject: amqiclen utility |   |  | 
		
		  | Newbie
 
 
 Joined: 14 Dec 2005Posts: 4
 
 
 | 
			  
				| Hello, 
 Is there any way to run amqiclen utility or any other non- IBM utility that cleans shared memory segments/semaphores without stopping a queue manager?
 
 Thanks in advance.
 
 Mark
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | jefflowrey | 
			  
				|  Posted: Wed Dec 14, 2005 11:09 am    Post subject: |   |  | 
		
		  | Grand Poobah
 
 
 Joined: 16 Oct 2002Posts: 19981
 
 
 | 
			  
				| You wouldn't want to remove MQ shared memory for a running queue manager. 
 You'd probably crash the QM.
 _________________
 I am *not* the model of the modern major general.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | positional | 
			  
				|  Posted: Wed Dec 14, 2005 11:22 am    Post subject: |   |  | 
		
		  | Newbie
 
 
 Joined: 14 Dec 2005Posts: 4
 
 
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | Tdak | 
			  
				|  Posted: Tue Jul 01, 2008 2:54 am    Post subject: |   |  | 
		
		  |  Novice
 
 
 Joined: 30 Jun 2008Posts: 18
 Location: South Africa
 
 | 
			  
				| Which command can I use on Windows???? 
 
 
   
	| positional wrote: |  
	| Good point. Thanks, Jeff |  |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | sebastianhirt | 
			  
				|  Posted: Wed Jul 02, 2008 2:00 am    Post subject: |   |  | 
		
		  | Yatiri
 
 
 Joined: 07 Jun 2004Posts: 620
 Location: Germany
 
 | 
			  
				| If I am not completely wrong, you don't need one on Windows, because there are no semaphores |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | rachakonda_v | 
			  
				|  Posted: Mon Mar 31, 2014 7:54 am    Post subject: HOW TO RECOVER SYSTEM.ADMIN.ACCOUNTING QUEUE IN UNIX |   |  | 
		
		  | Newbie
 
 
 Joined: 14 Jun 2012Posts: 7
 
 
 | 
			  
				| I want to recover SYSTEM.ADMIN.ACCOUNTING.QUEUE in MQ by using UNIX server. 
 I gave command "rcrmqobj -m QUEUE MANAGER NAME -t SYSTEM.ADMIN.ACCOUNTING QUEUE"
 
 But it's throwing an error - AMQ7027 " -Arguments supplied for RCRMQOBJ are not valid
 - AMQ7024 " Arguments supplied -t is not valid
 
 Can any one help me on this issue, its' urgent.
 
 Thanks.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | exerk | 
			  
				|  Posted: Mon Mar 31, 2014 8:02 am    Post subject: Re: HOW TO RECOVER SYSTEM.ADMIN.ACCOUNTING QUEUE IN UNIX |   |  | 
		
		  |  Jedi Council
 
 
 Joined: 02 Nov 2006Posts: 6339
 
 
 | 
			  
				| 
   
	| rachakonda_v wrote: |  
	| I want to recover SYSTEM.ADMIN.ACCOUNTING.QUEUE in MQ by using UNIX server. 
 I gave command "rcrmqobj -m QUEUE MANAGER NAME -t SYSTEM.ADMIN.ACCOUNTING QUEUE"
 
 But it's throwing an error - AMQ7027 " -Arguments supplied for RCRMQOBJ are not valid
 - AMQ7024 " Arguments supplied -t is not valid
 
 Can any one help me on this issue, its' urgent.
 
 Thanks.
 |  -t is type, and SYSTEM.ADMIN.ACCOUNTING.QUEUE is not a type, it's the name of an object type...
 
 ...read the examples given in the Info Centre for that command.
 _________________
 It's puzzling, I don't think I've ever seen anything quite like this before...and it's hard to soar like an eagle when you're surrounded by turkeys.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | bruce2359 | 
			  
				|  Posted: Mon Mar 31, 2014 8:04 am    Post subject: |   |  | 
		
		  |  Poobah
 
 
 Joined: 05 Jan 2008Posts: 9486
 Location: US: west coast, almost. Otherwise, enroute.
 
 | 
			  
				| First, please don't use a years-old post; rather, create a new one. 
 Second, go to google, and research the syntax and parameters for the rcrmqobj supplied control program.  You are incorrectly specifying the -t switch.
 _________________
 I like deadlines. I like to wave as they pass by.
 ב''ה
 Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  |  |