configure MSMQ cluster failover on an azure vm (windows server 2016) - windows

I want to create a Failover cluster for MSMQ for two vm's in azure. I created two VM's in azure and have them domain joined. I can create the failover cluster with both nodes. However when i try to add a role for MSMQ i need an cluster shared disk. I tried to create a new managed disk in azure and attach it to the vm's but it still wasn't able to find the disk.
Also tried fileshare-sync, but still not working.
I found out i need iSCSI disk, there was this article https://learn.microsoft.com/en-us/azure/storsimple/storsimple-virtual-array-deploy3-iscsi-setup . But it is end of life next year.
So i am wondering if it is possible to setup a failover cluster for msmq on azure and if so how can i do it?
Kind regards,

You should be able to create a Cluster Shared Volume using Storage Spaces Direct across a cluster of Azure VMs. Here are instructions for a SQL failover cluster. I assume this should work for MSMQ, but I haven't set up MSMQ in over 10 years and I don't' know if requirements are different.

Related

Arangodump between two different AWS ec2 clusters

I have created a Graph database in ArangoDB in a 5 machine AWS cluster. I do not have enough space in the Database AWS cluster to store the dump. So I would like to take a dump of the database in an AWS instance in a different cluster. I have the key files to connect to the machines. How to do it using Arangodump ? Thanks.
I do get that correctly that you're using DC/OS clusters on AWS?
The problem with arangoimp is, that it doesn't know howto authenticate with the DC/OS proxy, and thus can't reach the routes it would require to import to arangodb.
The problem is similar to Running Arango Shell on DC/OS cluster - you want to use sshutle as lalitlogical describes to forward the ArangoDB server port (usually 8529) to your target environment.

vSphere Cluster creation requirements

I've been searching around but haven't found a clear answer on this.
We're using VMware ESXI with vSphere to manage a handful of VMs (about 15 right now)
However, these are all spread over three separate machines. I'm looking for a way to cluster these together so their resources can be pooled or dynamically allocated. I found vSphere DRS Cluster information, but I'm having a really hard time finding out what I need to get that set up.
Does it require a separate vCenter license to hook into vSphere? And at that point, how do I create a database to group all the server hosts together? Every tutorial I find already has 2+ host machines already grouped together in the vSphere client, and I'm not sure how to go about achieving that.
If you just want to create a failover cluster, then you need VMware HA. VMware DRS is the option for resource dynamical allocation. To manage these two options, you need a vCenter Server. vCenter Server Foundation can manage up to 3 hosts (which is your case). For more information about vCenter, see this link.
For VMware HA and DRS to work, you must have a shared storage (NFS, iSCSI, or Fiber Channel). To know how to create VMware HA cluster using vSphere Client (connected to vCenter Server), see this link.
VMware DRS is an option after you created VMware HA. See this link

How to deploy a Cassandra cluster on two ec2 machines?

It's a known fact that it is not possible to create a cluster in a single machine by changing ports. The workaround is to add virtual Ethernet devices to our machine and use these to configure the cluster.
I want to deploy a cluster of , let's say 6 nodes, on two ec2 instances. That means, 3 nodes on each machine. Is it possible? What should be the seed nodes address, if it's possible?
Is it a good idea for production?
You can use Datastax AMI on AWS. Datastax Enterprise is a suitable solution for production.
I am not sure about your cluster, because each node need its own config files and it is default. I have no idea how to change it.
There are simple instructions here. When you configure instances settings, you have to write advanced settings for cluster, like --clustername yourCluster --totalnodes 6 --version community etc. You also can install Cassandra manually by installing latest version java and cassandra.
You can build cluster by modifying /etc/cassandra/cassandra.yaml (Ubuntu 12.04) fields like cluster_name, seeds, listener_address, rpc_broadcast and token. Cluster_name have to be same for whole cluster. Seed is master node, which IP you should add for every node. I am confused about tokens

Accessing Clustered MSMQ with an application

We are switching from a non-clustered to a 2-node clustered MSMQ Windows Server 2008 R2 SP1 Enterprise environment. Previously, when it was non-clustered, we wrote a .NET 3.5 C# Windows Form application to help us manage our environment (so it does tasks such as create queues with the right permissions, read messages, forward messages, etc.). I would like to make this application work with our new cluster.
Per these articles,
http://blog.terranspot.com/2011/07/accessing-microsoft-message-queuing.html
http://blogs.msdn.com/b/johnbreakwell/archive/2008/02/18/clustering-msmq-applications-rule-1.aspx
I understand that I need to add the application as a resource on the cluster as when I don't, I am accessing the node's MSMQ instance. To help with my debugging, I have turned the local MSMQ services off. No matter what I do, however, the program keeps trying to access the node's instance. I added it as an application resource (with the command line of "Q:\QueueManagerConsole.exe". The Q:\ is the disk that is shared between the 2 nodes that is part of the failover cluster), but when I run it via Windows Explorer, it doesn't see the cluster instance, only the local. I have seen no way to execute a program from Failover Cluster Manager, so I don't understand what I am doing wrong. I switched the code to access everything via "." (so MessageQueue.GetPrivateQueuesByMachine(".")), which, per my meager understanding is how you access the local queue. Could someone explain, preferably acting as if I had no clue what I was doing, on a. if this IS possible and b. HOW to do this correctly?
Hi I did something similar a while ago. Try deploy a service in a failover cluster
, it wokerd for me to:
configure the app to use clustered msmq
configure app as clustered resource
configure the app to connect under host name
set the permission set rquired for transpot
At least this will give you a good starting point.
I finally got this working by creating a shortcut to the application and putting it on the server that was actually accessing the clustered queues.
Please try add to environment used by Your application following Environment variables:
_CLUSTER_NETWORK_NAME_
_CLUSTER_NETWORK_HOSTNAME_
with cluster server name as a value. It worked in the system which is being developed by my team - it contains a few services which had to access clustered MSMQ and it solved the problem.

EC2 database server failover strategy

I am planning to deploy my web app to EC2. I have several webserver instances. I have 1 primary database instance. I have 1 failover database instance. I need a strategy to redirect the webservers to the failover database instance IP when the primary database instance fails.
I was hoping I could use an Elastic IP in my connection strings. But, the webservers are not able to access/ping the Elastic IP. I have several brute force ideas to solve the problem. However, I am trying to find the most elegant solution possible.
I am using all .Net and SQL Server. My connection strings are encrypted.
Does anybody have a strategy for failing over a database instance in EC2 using some form of automation or DNS configuration?
Please let me know.
http://alestic.com/2009/06/ec2-elastic-ip-internal
tells you how to use the Elastic IP public DNS.
Haven't used EC2 but surely you need to either:
(a) put your front-end into some custom maintenance mode, that you define, while you switch the IP over; and have the front-end perform required steps to manage potential data integrity and data loss issues related to the previous server going down and the new server coming up when it enters and leaves your custom maintenance mode
OR, for a zero down-time system:
(b) design the system at the object/relational and transaction levels from the ground up to support zero-down-time fail-over. It's not something you can bolt on quicjkly to just any application.
(c) use some database support for automatic failover. I am unaware whether SQL Server support for failover suitable for your application exists or is appropriate here. I suggest adding a "sql-server" tag to the question to start a search for the right audience.
If Elastic IPs don't work (which sounds odd to say the least - shouldn't you talk to EC2 about that), you mayhave to be able to instruct your front-end which new database IP to use at the same time as telling it to go from maintenance mode to normal mode.
If you're willing to shell out a bit of extra money, take a look at Rightscale's tools; they've built custom server images and supporting tools that handle database failover (among many other things). This link explains how to do it with MySQL, so will hopefully show you some principles even though it doesn't use SQL Server.
I always thought there was this possibility in the connnection string
This is taken (but not yet tested) from How to add Failover Partner to a connection string in VB.NET :
If you connect with ADO.NET or the SQL
Native Client to a database that is
being mirrored, your application can
take advantage of the drivers ability
to automatically redirect connections
when a database mirroring failover
occurs. You must specify the initial
principal server and database in the
connection string and the failover
partner server.
Data Source=myServerAddress;Failover Partner=myMirrorServerAddress;
Initial Catalog=myDataBase;Integrated Security=True;
There is ofcourse many other ways to
write the connection string using
database mirroring, this is just one
example pointing out the failover
functionality. You can combine this
with the other connection strings
options available.
To broaden gareth's answer, cloud management softwares usually solve this type of problems. RightScale is one of them, but you can try enStratus or Scalr (disclaimer: I work at Scalr). These tools provide failover solutions like:
Backups: you can schedule automated snapshots of the EBS volume containing the data
Fault-tolerant database: in the event of failure, a slave is promoted master and mounted storage will be switched if the failed master and new master are in the same AZ, or a snapshot taken of the volume
If you want to build your own solution, you could replicate the process detailed below that we use at Scalr:
Is there a slave in the same AZ? If so, promote it, switch EBS
volumes (which are limited to a single AZ), switch any ElasticIP you
might have, reconfigure replication of the remaining slaves.
If not, is there a slave fully replicated in another AZ? If so, promote it,
then do the above.
If there are no slave in same AZ, and no slave fully
replicated in another AZ, then create a snapshot from master's
volume, and use this snapshot to create a new volume in an AZ where a
slave is running. Then do the above.

Resources