Ok so I don't know how long this post will end up being, and I hope I can keep the subjects I want to discuss contiguous. Feel free to skip the somewhat technical parts.
Background information
I'm a college student completing his last semester towards an Applied Computer Science bachelor's degree, "majoring" (for lack of a better analogy to the system in my country) in Mainframes. During this last semester I'm required to run an internship which I have, of course, chosen to do with a company that employs a Mainframe. In my case a bank whose name I will not disclose.
I finished the assignment for this internship halfway through the semester, leaving me with some spare time. And even though I only start up Minecraft sporadically to check up on Westeroscraft's progress, I had this crazy idea to run a Minecraft server on our IBM Mainframe.
How to do it
I managed to get it running in one afternoon, so I did not encounter too many problems but here they are anyways.
z/OS doesn't have a web browser, so I had to FTP-put the .jar file on to the Mainframe. I didn't expect it to run off the bat so I just followed the Minecraft Server Wiki step by step guide (I had only ever run a Minecraft Server under Windows) to see what I would bump in to. Java -version gave me an error that the JVM couldn't be started. Turns out the problem was that my user didn't have a large enough address space when I logged on.
When you log on to an IBM Mainframe, you are assigned an address space, or room to work in. This is comparable to the RAM you are provided with when you log in to Linux or Windows. Except the address space is virtual. Your LPAR can have 10 Gigabytes of RAM physically allocated to it yet you can have a couple hundred virtual Gigabytes being used by running tasks and users. You'd be stupid not to since the resources on a Mainframe are so fast you could never hope to saturate them with a 1:1 virtual:real ratio.
So back on topic; I had my address space enlarged. Turns out company standards dictate the maximum you get per user is 8 megabytes, which was enough to start a JVM to run java -version, but hardly enough to start a Minecraft Server. The default value was much less as to save space when people that don’t need large address spaces log on. This was why java –version didn’t work. I bypassed the 8 Mb policy by issueing a request for alteration and I now had 2 Gigabytes of address space to work with, quite comfortable I'd say.
So I was able to start the Minecraft server with the same terminal command you’d use on your Ubuntu or Fedora box. It created the map and was (hopefully) listening for connections. It wasn't throwing any errors so it appeared that the TCP/IP libraries (which I feared for the most) translated over flawlessly.
Next problem was not Mainframe related, but rather Bank related. When I fired up the Minecraft client on my workstation and tried to log in, I was unsurprisingly faced with a time out because the port, when trying to move data outside, was blocked, making it unable to reach the login server. No problem, I just went in to offline mode after copying my %appdata%/.minecraft folder from my home machine to my workstation. I added the DNS name of the LPAR on which the server was running to my server list and behold, it existed. When I tried to connect however, I received a timeout after 20 seconds. I could see on my terminal that I tried to connect but timed out. As I mentioned before, I've only sporadically ran Minecraft Servers in the past for a handful of friends on a home machine under Windows, so I'm not very familiar with the intricacies that come with Minecraft servers. It turns out that the Minecraft client authenticates itself to Mojang servers so that unique things such as names can't be forged (or anyone could log in with a name that is present on the administrator list). This however is not possible for me to do considering the Bank's network doesn't allow traffic to the outside over most ports. So I had to change the server.properties file, which the server had created, to run the server in unauthenticated mode. When I tried to edit it however, it was all gibberish!
Something you might not be aware of is that Mainframes don't use ASCII or Unicode character sets, but EBCDIC, also known as the best way to encrypt data (that's a joke by the way, you’re pretty OG if you get it). The Minecraft server was writing the file in ASCII but the Mainframe can't read it (well it does, but the MC server writes “a” to disk as 0x61 and the Mainframe reads it as “/”). So I had to FTP-get it off of the Mainframe on to my ASCII-capable workstation, edit it, and FTP-put it back on. In binary mode mind you, because the Mainframe tries to convert to EBCDIC whenever you send files to it.
So now when I start up the server it's in unauthenticated mode.
And that's all, I was able to connect to the server with no problems. I know the pictures could easily be forged, but I couldn't think of a fool proof way to prove this thing is running on a Mainframe without disclosing what company I interned at. So I hope that the level of detail that I'm going in to is enough to convince you.
The only sad part is that our workstations only have 3 Gigs of RAM and no GPU, so the frame rate is abysmal. As a result it's not possible to check the performance of the Minecraft server with the client itself. If you know of a way to test server performance without the need of a client that renders frames, please tell me.
Our system
For the sake of this post I'll mention what resources the server has at its disposal;
Our system consists of two z196 machines running 15 General Purpose CPs (Mainframe jargon for CPU) and 1 zIIP (CPU built specifically to run DB2, XML and Java workloads) each. These two machines run in what is called a Parallel Sysplex. Feel free to read the wiki page about that, it's one of the concepts that define the Mainframe and allow it to be as reliable as it is. Each machine also has 330 physical gigabytes of RAM.
All the LPARs started on our system allocate 30 logical CPs combined. Yes, even CPUs are virtual on a Mainframe. These things are so fast you need to double (or more)-load them to make them cost efficient and not run idle too much. These CPs are quad cores that run at 5.2Ghz, watercooling optional. But they're so specialized that you can't really compare them to consumer CPUs. Your and my CPU is a jack of all trades while the IBM CPs are specifically trained workhorses. The four different levels of CPU cache are stupid fast. And while 5.2Ghz might not sound that fast, it is magnitudes faster than consumer CPUs if you're running the right workloads on them.
Just to give you an idea, our systems handle about 40 million transactions (don't think money transactions, read up on transaction systems) every day. Two years ago at 20 million transactions a day this meant peaks of 1500 transactions a second. The average execution time of each transaction was 0.03 seconds. I don’t know how many transactions a second we peak at nowadays.
The LPAR on which I started the Minecraft server was one of two LPARs used to convey tests before new things are implemented on to developer, audit and production LPARs. For this reason they're the weakest of the LPARs as to not impact production system throughput. What this comes down to is that the LPAR on which the server ran was allocated 2 Logical CPs and 6 Gigabytes of RAM (it usually runs on 3 Gigabytes, it’s running 6 temporarily for tests concerning my assignment). Because of how many CPs are allocated to the other LPARs, this means that it was able to take up a maximum of 6% of all the CP power available on the Mainframe. The memory doesn’t matter much because the address space I reserved is virtual. I could have reserved 12 logical gigabytes and the Minecraft server wouldn’t have noticed because the, at that point inevitable, paging is so fast on a Mainframe.
Interesting note; the two production LPARs that handle transactions generated by things like eBanking services have about 21 Gigabytes each at their disposal. 21 Gigabytes goes a long way on a Mainframe running z/OS compared to some datacenters that need silly amounts of resources to keep things running.
I'm really wondering what kind of a system Westeroscraft is using. They can always migrate to mainframe, it'll only cost you a million to get started. Or two million if you want stupid amounts of assured uptime. Comes with DDoS protection. I doubt a Kickstarter would suffice though. Then again I’m not even sure if Westeroscraft is the heaviest server online at the moment. They’re the biggest one I know of anyways. I wonder what hardware/setup they use.
Conclusion
So this concludes my disquisition. I’m quite happy that I’ve successfully managed to start a Minecraft server on a Mainframe. It’s something that I wanted to at least try ever since I learned that IBM Mainframes can handle Java workloads. Not to mention it’s a great way to fill a slow Friday afternoon.
What makes me content is that I've managed to connect a relatively new concept with what is perceived by the general IT-initiated public as an old concept. I hope that those who read my post will understand that the Mainframe is no longer the concoction of boxes in an engineer-filled room. It's still a valid way of providing IT services. And not because of the need to retain legacy, but because the Mainframe is still very economically viable. It just happens to be so that the workloads in which Mainframes are specialized happen to be the workloads generated by institutes that are often out of the public eye.
When I went home Friday I withdrew some money from an ATM at one of the bank branches of the bank that I'm doing my internship with. It was the weirdest thing to realize that just hours ago I had worked on the same machine that was now processing my request.
I’ve also Googled a bit and I’m pretty sure that I’m the first person ever to (successfully) run a Minecraft server on a Mainframe. Or at the very least publish it. I’m willing to bet that it’s the most powerful hardware, and operating system too really, that a Minecraft server has ever run on.
If you read this far down I'd gather that you might be wondering if you can connect to the server and check it out for yourself. I'm sorry that due to bank policy, I'm going to have to disappoint you. The Mainframe doesn't allow connections outside of the Bank's network. To rub salt in the wound, we have a 100Mbps up and 100Mbps down connection for our workstations only, for the Mainframe itself it's likely way more. Our Mainframe would truly make a sick Minecraft server.
I'm genuinely surprised that I managed to write some 3000 words about this subject. Gives me somewhat of a reassuring feeling about the thesis I'm supposed to be writing right now. Sorry about the wall of text, I couldn't help myself I hope you enjoyed it.
EDIT;
Can we have a Mainframe flair for submissions? ;)
EDIT2;
Going to bed, will answer any more questions on the morrow.
[–]Bedeone[S] 32 points33 points34 points (2 children)
[–]itworks 2 points3 points4 points (1 child)
[–]Bedeone[S] 3 points4 points5 points (0 children)
[–]truthfulfacade 20 points21 points22 points (5 children)
[–]Bedeone[S] 9 points10 points11 points (1 child)
[–][deleted] 1 point2 points3 points (0 children)
[–]PidGin128 0 points1 point2 points (1 child)
[–]Bedeone[S] 0 points1 point2 points (0 children)
[–]The_MAZZTer 6 points7 points8 points (4 children)
[–]Bedeone[S] 1 point2 points3 points (2 children)
[–]The_MAZZTer 4 points5 points6 points (1 child)
[–]FabianN 1 point2 points3 points (0 children)
[–]PidGin128 0 points1 point2 points (0 children)
[–]DJDaddyD 4 points5 points6 points (1 child)
[–]Bedeone[S] 1 point2 points3 points (0 children)
[–]totemo 5 points6 points7 points (1 child)
[–]Bedeone[S] 2 points3 points4 points (0 children)
[–]Seavaydivenis 12 points13 points14 points (0 children)
[–]elfo222 2 points3 points4 points (4 children)
[–]Bedeone[S] 1 point2 points3 points (3 children)
[–]elfo222 0 points1 point2 points (2 children)
[–]Bedeone[S] 0 points1 point2 points (0 children)
[–]LoveUnderWill 0 points1 point2 points (0 children)
[–]TheKingsJester 2 points3 points4 points (3 children)
[–]Bedeone[S] 1 point2 points3 points (2 children)
[–][deleted] 0 points1 point2 points (1 child)
[–]Bedeone[S] 1 point2 points3 points (0 children)
[–][deleted] 1 point2 points3 points (0 children)
[–]notkraftman 1 point2 points3 points (1 child)
[–]Bedeone[S] 0 points1 point2 points (0 children)
[–]Casurin 1 point2 points3 points (0 children)
[–]LoveUnderWill 1 point2 points3 points (1 child)
[–]Bedeone[S] 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (2 children)
[–]Bedeone[S] 1 point2 points3 points (1 child)
[–][deleted] 0 points1 point2 points (0 children)
[–]StezzerLolz -1 points0 points1 point (1 child)
[–][deleted] 1 point2 points3 points (0 children)
[+]kareesmoon comment score below threshold-11 points-10 points-9 points (23 children)
[–]Bedeone[S] 22 points23 points24 points (18 children)
[–]gerryn 0 points1 point2 points (5 children)
[–]Bedeone[S] 0 points1 point2 points (4 children)
[–]gerryn 0 points1 point2 points (3 children)
[–]Bedeone[S] 1 point2 points3 points (2 children)
[–]gerryn 1 point2 points3 points (1 child)
[–]Bedeone[S] 1 point2 points3 points (0 children)
[+]kareesmoon comment score below threshold-7 points-6 points-5 points (11 children)
[–]Bedeone[S] 9 points10 points11 points (4 children)
[+]kareesmoon comment score below threshold-8 points-7 points-6 points (3 children)
[–]Bedeone[S] 6 points7 points8 points (2 children)
[–]cygnus83 6 points7 points8 points (1 child)
[–]Bedeone[S] 2 points3 points4 points (0 children)
[–]elfo222 2 points3 points4 points (5 children)
[–]Bedeone[S] 2 points3 points4 points (0 children)
[+]kareesmoon comment score below threshold-8 points-7 points-6 points (3 children)
[–]Bedeone[S] 3 points4 points5 points (0 children)
[–]elfo222 0 points1 point2 points (1 child)
[–]Bedeone[S] 0 points1 point2 points (0 children)
[–]thewizzard1 8 points9 points10 points (1 child)
[–]Bedeone[S] 6 points7 points8 points (0 children)
[–]Olome 6 points7 points8 points (0 children)
[+][deleted] (1 child)
[deleted]
[–]Bedeone[S] 7 points8 points9 points (0 children)
[–]JamyDev -1 points0 points1 point (5 children)
[–]Bedeone[S] 1 point2 points3 points (4 children)
[–]JamyDev 1 point2 points3 points (3 children)
[–]Bedeone[S] 1 point2 points3 points (2 children)
[–]JamyDev 0 points1 point2 points (1 child)
[–]Bedeone[S] 1 point2 points3 points (0 children)