| Author | 
		  Message
		 | 
		
		  | MattP | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 5:02 am    Post subject: Moving messages between queues | 
				     | 
			   
			 
		   | 
		
		
		   Newbie
 
 Joined: 04 Aug 2009 Posts: 3
  
  | 
		  
		    
			  
				Hi,
 
 
Have searched the web, these forums and manuals for the answer to what I thought would be a simple question  
 
 
What's the easiest way to move messages between two local queues on the same queue manager? ie, I have 50 messages on L.TEST.1 and I want to move them to L.TEST.2
 
 
I read somewhere that some code to do this may be available in a SupportPac but I haven't found anything as yet.
 
I'm sure I'm going to feel pretty stupid when someone tells me the answer but it's annoying me now!
 
 
Thanks,
 
 
M | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | MattP | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 5:13 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Newbie
 
 Joined: 04 Aug 2009 Posts: 3
  
  | 
		  
		    
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | vol | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 5:20 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Acolyte
 
 Joined: 01 Feb 2009 Posts: 69
  
  | 
		  
		    
			  
				Stop the qmgr.
 
Copy the q file from the L.TEST.1 queue directory to the L.TEST.2 dir.
 
Restart the qmgr. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fjb_saper | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 5:22 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Grand High Poobah
 
 Joined: 18 Nov 2003 Posts: 20768 Location: LI,NY 
  | 
		  
		    
			  
				
   
	| vol wrote: | 
   
  
	Stop the qmgr.
 
Copy the q file from the L.TEST.1 queue directory to the L.TEST.2 dir.
 
Restart the qmgr. | 
   
 
 
Don't do that.
 
Use support packs like IH03 or MO71.
 
 
They will support moving/copying messages from one queue to the other.   _________________ MQ & Broker admin | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | Mr Butcher | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 6:10 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Padawan
 
 Joined: 23 May 2005 Posts: 1716
  
  | 
		  
		    
			  
				on z/OS (unfortunately you did not tell us which os you are using) you  can use the MOVE QLOCAL command (if queues are not in use) _________________ Regards, Butcher | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | MattP | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 6:51 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Newbie
 
 Joined: 04 Aug 2009 Posts: 3
  
  | 
		  
		    
			  
				Apologies, Solx86.
 
 
I downloaded the MA01 supportpac and used 'q' to move the msgs.
 
 
./q  -m<qmgr> -I<from queue> -o<to queue>
 
 
Works..
 
 
Matt | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | Vitor | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 9:31 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Grand High Poobah
 
 Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA 
  | 
		  
		    
			  
				
   
	| vol wrote: | 
   
  
	Stop the qmgr.
 
Copy the q file from the L.TEST.1 queue directory to the L.TEST.2 dir.
 
Restart the qmgr. | 
   
 
 
 
This a) is intrusive and requires queue manager downtime b) is likely not to work, or work properly c) is unsupported by IBM so any problems will be your business. _________________ Honesty is the best policy.
 
Insanity is the best defence. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | gbaddeley | 
		  
		    
			  
				 Posted: Tue Aug 04, 2009 3:16 pm    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Jedi Knight
 
 Joined: 25 Mar 2003 Posts: 2538 Location: Melbourne, Australia 
  | 
		  
		    
			  
				
   
	| vol wrote: | 
   
  
	Stop the qmgr.
 
Copy the q file from the L.TEST.1 queue directory to the L.TEST.2 dir.
 
Restart the qmgr. | 
   
 
 
 
I suppose you use "kill -9" to stop the qmgr processes ???     _________________ Glenn | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | 
		    
		   |