I've been pretty happy with a self-built server at home that offers ssh, ftp, and website services (apache, php, mysql) for a small gaming community that I support. It's a 1.3Ghz box with 768MB of RAM and a 5GB drive, running debian originally, and now Ubuntu server, and it has been running faithfully for a couple of years now. But success has it's price, and this little workhorse is getting full. I would like to add a couple of more servers to distribute the user-load across.
Current layout is so:
- 2 Mbit DSL modem connection to the outside world,
- dynamic-dns name pointing to that modem (digitalmouse.dyndns.org) because the ip address changes about every 24 hours (server runs a ddclient shell script to keeps things updated),
- ftp, ssh, http services all port-forwarded to the server at 10.0.0.10
- users use 'email@example.com' to access ssh and ftp, and 'digitalmouse.dyndns.org/~username' for their webpages.
I suppose i *could* just create a new set of portforwarding ports to the other servers, and just make sure the users of those other boxes use the correct port numbers, but since the big hosting guys don't do this, there ought to be a way for me to allow everyone to use the standard port accesses, and move people around to other servers (or when creating new accounts) that is transparent to the user. To the outside world it should still look like one server/domain.
Would creating mount points on the first server do the trick? What I mean is:
/home/fred <-- on the original (first) server
/home/joe <-- is a mountpoint on the first server that points to /home/joe on the second server (for example)
Or is there a better way?
Thanks in advance for your input!
Last edited by digitalmouse; 02-24-2006 at 01:33 PM.
thanks for the links! i'll check them out.
Hmm.. vserver does not help, as it provides 'virtual servers running on a single piece of hardware.' I need servers running on multiple pieces of hardware.
Clustering is nice for load balancing duplicate servers, or intensive calculations (like doing something with the @home projects from Berkeley) - but these are not the projects i am interested in right now (though i do have a room full of old pentiums that could probably be put to this use).
The Linux Virtual Server Project looks like it may be what I am looking for.
Last edited by digitalmouse; 02-25-2006 at 09:36 AM.
Hey try Apache's Reverse Proxy....
google Apache Reverse Proxy...
I use it and its good for your requirement
will check that out - thanks for the tip!
the linuxvirtualserver project did not look like a good solution as one of the developers says that a person logging in gets routed semi-randomly to a machine.... that would defeat the purpose i am trying to accomplish. (although certainly useful if i moved up to mirrored hardware)
hmm- Apache's Reverse Proxy looks like it does the job for HTTP and FTP protocols, but *not* SSH. the later is necessary for starting/stopping games that each user hosts, plus games are often accessed via a client by connecting to an ip address and port number, like so: 188.8.131.52:6003.
so while it fulfills some of the requirements, it falls short on the other protocols. i'll drop the author a line (or post in a forum related to reverse proxy) about this, and see if it can be applied to other protocols too.
Why not run ssh on different ports-- I always do for security. You could have one on 22222 and one on 22221 etc...
Or you could ssh to another box from withing an ssh session. You could set up a ssh "server" (could be a light weight box) that had keys exchanged to the other boxes and hosts setup correctly. This wouldnt be toooo slow if all you were doing is starting a service (a game in this case). You could even use to nis/ldap to sync all the passwords....
Just some thoughts to solve the ssh problem.
I assume that you would be doing some creative portforwarding...
Last edited by flashingcurser; 04-07-2006 at 10:01 PM.
Good ideas there. And very practical.
flashingcursor: i have thought about using seperate ports before, but was hoping for a more centralized manageable solution similar to the first offered solution (linux virtual servers).
unfortunately that may be my only workable solution at this time - not a bad thing, but just a bit more work.
regarding port-forwarding: that's not a problem - there are enough slots on the router to handle about 40 rules - enough for this 'hobby'. if i wanted to go pro or commercial, i'd get one of the big shell-server guys to do it.
thanks to all for your input!
Well like I said:
Use one box that is ssh portforwarded as a ssh server so to speak, start additional ssh sessions from this box to the others. Then make sure that box has shared keys to the other boxes, if you have the hosts set up right you can get to the other boxes easily. Also set up an alias to so that game1 = ssh gamer@game1.
So from the internet side it would look like this:
Put in your "gamers" password.
Then once you have authenticated all you would have to type is:
game1 or game2 or game3 etc...
If you wanted to get real fancy you could put in an ssh banner that gives a brief explanation of what to do. Or maybe with the help of some better bash scripters someone could help build a nice login script for the user "gamer" that would give a nice multiple choice.
Beyond this, you will want to look at a openmosix cluster. Openmosix does not try to divide a processes between servers it simply assigns complete process to the least loaded server. Though I dont know how well it would work for games, and I imagine they would have to be set up to work off of virtual interfaces out of the cluster. Here is a link for openmosix
Again, good luck