How does web hosting actually work?
May 26, 2009 12:08 AM   Subscribe

How does web hosting actually work? I need to host a web application that I've made. I've had a look at a few forums, a few reviews, and now I'm more confused than ever.

I've set up a web application using Netbeans on my home computer, then opened up the appropriate port. However, our connection often goes down. As an experiment, I recreated my web app on the Amazon Cloud by setting up one of their pre-defined Windows 2003 Servers, and installing everything exactly how I had it on my computer. I would log in using remote desktop and configure everything.

It works well, but Amazon Cloud is expensive. It's only a prototype right now that I'm showing my friends, colleagues and anyone else interested.

How does web hosting actually work? I mean, do most hosts give you a virtual computer in which you can log in to? Or do some give you a text-based login where you can upload and run programs? Or....?

These are my requirements:

* The ability to upload libraries such as GWT, javabib, javamail, htmlparser, apache-fileupload, amazon aws etc.
* The ability to run the GlassFish Server (although, I really could run it on any number of java web servers, eg Tomcat)
* Ability to persist user data via java serialization.
* Probably about 2 GB of disk space + an as yet unknown IO data limit.

Something that gives me an xterm screen and the ability to upload and run stuff would be sufficient. Is this how things work when it comes to hosting web applications? It's all very confusing!
posted by tomargue to Computers & Internet (11 answers total) 14 users marked this as a favorite
 
Best answer: There are a few ways to look at this--most hosts offer you what's considered "shared hosting". You get a folder within which to store some things, and some bandwidth. Your IP addresses are typically shared, and they resolve through the wonders of DNS. You typically don't have command line/root access in these set ups.

Next there are "virtual servers," which offer you more of a cordoned off part of a server, typically complete with the ability to view some level of command line, install programs, etc.

Finally, there's dedicated hosting. Dedicated hosting means you have a server entirely to yourself, that you pay monthly for to rent the bandwidth and hardware. You're given root because it's your box. This is usually about on par with Amazon's EC2/Cloud servers, hour-for-hour, price-wise.

You can probably track down a relatively cheap virtual server that will work for you, so long as you find someone who plays nice with Java. Search for Java virtual servers and see what comes up. (But read more here for concerns on doing so.

A place like The Planet offers servers in the neighborhood of $100/mo. for low-impact boxes, but yeah, any cheaper than that and you're pushing it.

If you're feeling clever, you can use a dirt-cheap host to simply persist constantly, and to just initiate your EC2/Cloud instance when someone was looking to use the site... but that would be a bit awkward.
posted by disillusioned at 12:18 AM on May 26, 2009


You could get a server from Linode.com for $19.95 a month, this is a complete Linux server and you can install whatever you want on it. I have one and it runs tomcat fine. Of course, you'll need to know how to set stuff up on Linux.

Normally when you get "web hosting" all you get is filespace on someone Else's web server, and usually you can run PHP files and you get some shared space on a MySQL database. It works well if you have a LAMP style program (of which there are plenty) but if you need to do anything sophisticated it becomes more problematic.

There are probably shared java hosting solutions out there but I don't know of any off the top of my head. Linode.com is cheap enough.
posted by delmoi at 12:18 AM on May 26, 2009 [1 favorite]


If you're feeling clever, you can use a dirt-cheap host to simply persist constantly, and to just initiate your EC2/Cloud instance when someone was looking to use the site... but that would be a bit awkward.

Yeah, I'm sure users would love a 5 minute page load time (which is how long it takes to boot an EC2 instance).

I've used Linode and it's fine. A few years ago had some trouble running a full glassfish install on my Linode VPS, not surprising since it only came with 128 megs of ram at the time and tomcat would crap out on me every once in a while. But it's been upgraded significantly since then. One major change is a switch to the Xen visualization system, rather then user mode linux or whatever they were using Xen is the same system used by Amazon so there's no reason to think it wouldn't work as well as Amazon's EC2. I've had it running 40-50 threads for hours and hours with no problems at all, mostly doing network stuff. That "java virtual hosting" page is pretty old. There's no date, but the archives only go to 2007
posted by delmoi at 12:27 AM on May 26, 2009 [1 favorite]


Haha, yeah, it'd be pretty terrible waiting for the instance to boot... but if it's just friends and family, it's not TOTALLY ridiculous. Just mostly ridiculous. Heh.
posted by disillusioned at 1:21 AM on May 26, 2009


Response by poster: Thanks disillusioned and delmoi. That's exactly the explanation I was after.
posted by tomargue at 1:55 AM on May 26, 2009


You could check out slicehost, they seem pretty cheap. You get a VM instance to do what you wish with. You'll need to be comfortable with Linux, though.
posted by cj_ at 1:55 AM on May 26, 2009 [1 favorite]


Response by poster: Yeah, linode looks good.
posted by tomargue at 2:30 AM on May 26, 2009


Response by poster: Yeah, interesting cj_, delmoi, yeah, I'm somewhat comfortable with Linux...I know the basic bash shell commands, and can google what else I need to know, but I'd like to avoid it at all costs (personal taste, not gunning for massive flamewar!). Don't suppose anyone knows of any Windows Virtual Machine hosting (besides Amazon EC2)?
posted by tomargue at 5:50 AM on May 26, 2009


tomargue, the term you're looking for to guide your searching for "Windows Virtual Machine hosting" is VPS (Virtual Private Server)

I can't make any recommendations, but I'm sure some searching will turn up reviews.
Hope this helps.
posted by namewithoutwords at 6:13 AM on May 26, 2009 [1 favorite]


Is there any particular reason you have to run this on Windows? That's going to add cost to your fees, no way around it. Unless you're leveraging some Win-specific technology like .NET or MS-SQL (which it doesn't sound like, in your case), you'll be better off running Linux.
posted by mkultra at 7:12 AM on May 26, 2009


Response by poster:
Hi b1tr0t, it's a fun thing turned into something I want to get funded. Back a few months ago I was looking at new ways of organizing my life, and everything I used always "blew-out" in terms of complexity. I tried RTM lists but...they didn't have sublists, so it didn't actually "make things simpler".

Anyway, my website is kind of like RTM, so I'm thinking that I can get a similar amount of users to RTM over the next couple of years, so I'm cracking together a business plan. I actually have a couple of users, already! So it now needs to be up all the time.

I'm going to, for the time being, keep shelling out money for the Windows Server 2003 on Amazon, and concentrate on other things like justifying the assumptions in my business model, before changing the server-provider.

And mkultra, no reason except that that's what I'm used to. It's an additional overhead for me to learn the ins-and-outs of setting up a server on linux (with Netbeans, it's all done for you). I'd have to weigh that time up against the difference in cost between a Windows virtual server, say, on Amazon, and a linux server on (Linode, etc). In the long run, of course, I will go linux virtual server.
posted by tomargue at 1:16 AM on June 26, 2009


« Older Dummy = Duddy?   |   College Radio Singles Chart Newer »
This thread is closed to new comments.