I've got a very large JS app built in Wakanda that I'm working on, and suddenly hit a strange issue.
Our Solution has four main projects in it:
Consumers
Merchants
Funders
Promoters
These projects all have their own functions, and up until recently have had them operating on the same server via different port addresses - 8100, 8101, 8102, 8103. This has worked without a problem, with the localhost as the host in the Settings.waSettings file, and the respective ports set there.
Now, moving to production, we need to have these routing through to the site from subdomains. Because of the way A-records are and not being able to define a port address, we have our .consumer, .merchant etc subdomains all going to the same elastic IP address, and using the Settings.waSettings files in Wakanda to handle the routing of traffic to each project.
We have set all the incoming ports as 80, with it listening for the subdomain name to handle which project to route the user to. This worked yesterday without a hitch for around an hour on the server, before it suddenly stacked itself. For a time, the Wakanda server just stopped each time you attempted to access one of the subdomains. After a while longer it's not crashing each time, but just simply resolving to a '409 Conflict' screen.
My question is, can Wakanda reliably use it's project Settings file to handle requests like this? Or is there a better way to handle this? I know there used to be a thread in the forums on this discussion.
Thanks, let me know if you need any more information.
Related
Just looking for some opinions on this.
I altered a hosts file on my local machine to try and preview a site hosted with Bluehost (to check everything is working correctly before I point my live domain to their server).
This didn't work and I keep getting a 404 error.
I spoke to 6 people from Bluehost now and only one of them seemed to know what a hosts file was. Everyone else seemed to point out the domain's A records are not pointing to the BH server, which is correct as it is not what I'm trying to do at all. I'm trying to preview the BH site BEFORE I point my live domain to the BH server.
Hosts file is what I always use to preview a site before it goes live. I've done it with hundreds of sites on many different servers and never had an issue... until I came across Bluehost.
Their support just doesn't seem to know what a hosts file is, they keep referring me back to the live DNS A record.
I just don't understand how Bluehost is WordPress #1 recommended hosting when their technical support is so incompetent.
Am I being unreasonable here? How can a hosting company not know what a hosts file is?
Odd issue, but one I haven’t been able to solve in years.
I have used my own web servers forever and a day. But I’m always messing with them trying to learn this or that and will occasionally destroy it! lol So for a couple sites, I use a hosting service.
I also use the hosting service for my dns, since it’s a pain for me to set up. So I’ll buy a domain name and point it to my servers via url stealth, and have never had an issue with anything but this.
My favicon.ico never works this way. It works fine with the sites on the hosting service, and it works fine if I go to my server site using the IP address. But it just will not display through the host no matter what I try.
It is a very small issue, but would be nice to have it work.
Thanks!
I'm struggling with Kamailio as a simple dispatcher for FreeSwitch. This is my configuration so far: http://pastebin.com/nBPSpe6S
Connecting an iPhone and an Android makes the calls between them timeout.
Connecting one of the phones and my laptops makes calls between them produce the error "Too many hops".
With all of them I'm able to call in to the Freeswitch, for listening to voicemail, hold music etc.
So I guess it's still NAT problems or similar?
Can anyone spot the error, missing thing or something else that is wrong with the config?
P.S. Adding phones, laptops etc. directly to FreeSwitch, without Kamailio, makes everything works.
"Too many hops" is just that - too many hops. A SIP messages is being routed around in a bad way. In many cases in Kamailio, this is because DNS and Kamailio doesn't have the same view of the world. Kamailio doesn't know which domains it's authoritative for (the alias= configuration parameter) and forwards using DNS. DNS points back to the same Kamailio.
Your configuration lacks both alias= and IP addresses kamailio should listen to. Now, your configuration doesn't really use the alias, so I don't see that problem here. Since you are not showing the dispatcher table it's hard to figure out. I suggest you add a couple of calls to xlog() to see what's going on and figure out why a message is looping around. Good luck!
I am aware of how many times this has been asked based on searching StackOverflow, but I am still hoping someone could tell me whether I am wrong...
I am creating a peer-to-peer chat app for the iPhone. My initial idea was to avoid using a server, so Bonjour came to mind. I was happy coding for quite a while and implemented a lot of fancy features, but two days ago I started testing with two clients from different subnets and found that the clients couldn't connect to each other! I suddenly realized that Bonjour is meant for local networks and that a DNS server is necessary for wide area service broadcasting. Do I really need a server for Internet peer-to-peer chat? Are there any other options that do not involve using a server on the iOS platform?
I am wondering how you can do a chat app without using a server. There are many cheap solutions out there, Amazon has its own service, Google does as well. You can try first without even having to pay a cent.
I found the following from apple developer guide. This should answer your question -
Does Bonjour work between multiple subnets?
Yes. The first release of DNS Service Discovery (DNS-SD) for Mac OS X concentrated on Multicast DNS (mDNS) for single-link networks because this was the environment worst served by IP software. Starting in Mac OS X 10.4, Bonjour now uses Dynamic DNS Update (RFC 2316) and unicast DNS queries to enable wide-area service discovery.
To answer the question, the only way is for you to carry a list of all possible participants, and their current IP address, and for each possible participant to report to all others each time their IP Address changes. So, if you have 100 possible participants, then you must tell 99 others when your IP Address changes, and those 99 must tell you when their IP Address changes.
Bonjour may work on a LAN, a WAN or even a WAN, but it will never work on the internet.
The role of the server is so that each end point only need to tell one end point (the server) when it changes. My advice is get a cheap internet host, with a basic PHP / MySQL capabilities, and write yourself a very simple script to post and get user identities.
I don't know how else to say it so I'm just going to explain my ideal scenario and hopefully you can explain to me how to implement it...
I'm creating an application with the Zend Framework that will be hosted with DreamHost. The application will be hosted on its own domain (i.e. example-app.com). Basically, a user should be able to sign up, get their own domain sampleuser.example-app.com or example-app.com/sampleuser which points to, what looks like their own instance of the app, which is really a single instance serving up different content based on the url.
Eventually, I want my users to be able to create their own domain (like foobar.com) that points to sampleuser.example-app.com, such that visitors to foobar.com don't notice that the site is really being served up from example-app.com.
I don't know how to do most of that stuff. How does this process work? Do I need to do some funky stuff with Apache or can this be done with a third party host, like DreamHost?
Update: Thanks for the advice! I've decided to bite the bullet and upgrade my hosting plan to utilize wildcard subdomains. It's cheaper than I was expecting! I also found out about domain reseller programs, like opensrs.com, that have their own API. I think using one of these APIs will be the solution to my domain registration issue.
Subdomains are easy. In hosting environements, in most cases, apache is configured to catch all subdomain calls below the main domain. You just need to have a wildcard DNS defined, so *.example-app.com are pointed to IP of your server. Then your website should catch all calls to those subdomain names.
Other domains are hard. They need to be configured as virtual hosts in Apache - see http://httpd.apache.org/docs/1.3/vhosts/name-based.html - that means it will be difficult to automate that, especially in hosting environement - unless your host gives you some API to do just that (easy and more feasible scenario would be to have a distinctive IP assigned to your website, then you can catch all with your Apache - it's probably possible to configure using your hosting control panel or works out of the box - and then just point DNS servers to your IP).
Then, after you have configured your Apache to point all necessary calls to your website, you can differnetiate application partitions per subdomain in this way:
get the host header from HTTP request
have a database table containing all subdomain names you're serving
make a lookup to that database table to determine instance, or user, id and use it later for filtering data / or selecting a database, if you'll go with a "database per application instance" schema.
Good luck :)