Installing on Arch-based Linux

I’ve tried installing AresMUSH here on a Manjaro system, which is Arch-based, while the installation scripts from what I see are aimed towards Debian-based systems. So the installation fails completely for me. I’ve tried modifying it, and it did seem like everything was going well, until it reached the point of Redis server, which it constantly kept saying that it wasn’t active. I am mostly wondering if there is any other way to get it to work other than Redis, or if there is some other installation script I am failing to see.

1 Like

Redis is required for Ares to function. I’m afraid I have no information on getting it running on Arch based systems. Maybe someone in the community might know.

Ubuntu is the only supported OS for Ares, with Digital Ocean being the only host that the automated install scripts are guaranteed to work on. It’s probably possible to get it working on other linux-based systems (I know it’s run on OSX and Linode-Ubuntu) but it’s going to require some hammering.

Well after some tinkering, I’ve managed to almost get it to work. The only issue is setting up the redis password. I’m a little confused as in how to add it to database, what format is database.yml using for that?

So far I tried adding "password: ‘pass’ " into the database.yml, but despite it being the same password as one set for redis, it keeps throwing ‘invalid password’ at me, maybe I just added it the wrong way?

1 Like

database.yml just needs the password by itself. No ‘password: xxx’ formatting required.

Sorry for stupid question, but what do you mean by “needs the password by itself”?
What do I need to do for the password?
Edit: Oh, probably as in it just needs a line with password only.

Oh sorry - the password doesn’t go in database.yml at all. It goes in secrets.yml. It would be like this:

---
secrets:
  arescentral:
    OTHER STUFF
  database:
    password: YOUR PASSWORD
  etc.

Well, I was close. But sadly I’m now having an issue of ‘port is in use or requires root privileges’. Guess I should just give up? It isn’t an issue of ports being used, since I changed them and double checked the ports, there is also no game processes, nor is there an issue of same port being used.

Are you sure the game isn’t already running? That error often throws people who accidentally start the game twice.

I was going to test that by rebooting, but I found out something rather interesting.
Running setup_server script on Arch is very destructive, because of things it created in regards to ares account, it messed up the desktop environment somehow with the bash scripts that I guess were running right at the startup, removing .profile folder fixed the issue.
Is there some way to manually get AresMUSH to work? It seems even trying to modify the scripts to run is a bad idea as it can mess up the system.
A little ironic that I had easier time setting up PennMUSH than I am having with AresMUSH.

Edit: After a bit of snooping around, it seems like it was RVM that caused the issue for me at startup.

I’m sorry that you’re having a hard time getting Ares to work in your environment. However, as it mentions in the install instructions:

The automated install scripts only work on the supported environment - a stand-alone Digital Ocean droplet with only a single MUSH running on it. If you’re using a different environment, do not try to run the install scripts directly. Refer to them as a guide for what needs to be done, and adjust the specific steps needed for your environment.

So for instance, if the setup script is installing nginx and copying over a config file–you wouldn’t want to do that if you want to use Apache, or if you already have nginx running another website on that same server, of if you’re using something other than apt-get to install packages. You would need to use the install script and/or config file as a reference and set it up yourself.

In the supported environment, the install scripts set up everything for you automatically. You only have to answer a few prompts and wait around a bit while it installs all the necessary packages. It’s very easy. I also offer Easy Mode where I will install the game for you in the supported environment and transfer the droplet.

Ares is admittedly a more complex system than PennMUSH because it includes a lot more than just the game engine. To fairly compare to the PennMUSH install you’d really have to talk about installing PennMUSH and a web server and a SQL database and a wiki and a bunch of softcode libraries.

There’s some more general advice about custom environments in this article if that helps any.

Thanks for the help, since it is probably annoying when someone does something that’s not officially supported~

By manually installing things, and ditching rvm, as well as slightly modifying a few scripts, I managed to almost get it working, but there’s few issues I stumbled on. One is the startares script doesn’t have permissions to create ‘var/www’ folders, and it does say that I can’t launch the script as root. Is there any way I can fix that?

1 Like

Oh it’s not annoying - it’s just a bummer that you’re having so many headaches getting it to work.

You could try manually creating the /var/www/ directory with sudo and then changing its ownership to the ‘ares’ user. That’s something that the nginx install normally takes care of, though, so I’m wondering if maybe your problem isn’t bigger (like maybe you’ve got nginx installed differently, or are using something else entirely and /var/www isn’t the right directory for you).

The reference to /var/www is in the deploy script in ares-webportal/bin. It builds the web portal files and then copies them to the directory where the web server serves them.

Oh… if /var/www already exists also you may be just needing this set of steps from setup_server:

echo -e "${ARES_INSTALL_TEXT} Give ares user access to www and redis directory for backups"

sudo chown ${ARES_USERNAME} /var/www/html
sudo chgrp redis /etc/redis/redis.conf 
sudo chmod g+rwx /etc/redis/redis.conf  
sudo chgrp redis /var/lib/redis
sudo chmod g+rwx /var/lib/redis
sudo chgrp redis /var/lib/redis/dump.rdb
sudo chmod g+rwx /var/lib/redis/dump.rdb

Oh right, stupid question indeed. I forgot to check that script.
Also because I have a suspicion I’ll be asking this in near future anyway, any possible reasons it might be unable to connect to redis? The protection & password are set up, and it is running.

Edit: Checking the logs again, it is a port issue again, although I have suspicions it isn’t a port issue, but a root permission issue since I had to launch redis-server as root.
Edit 2: Oops, forgot this wasn’t a redis-server, it’s failing to make the tcp-server. So I’m guessing this is nginx issue, but I kind of have no idea how to operate that one.

I’m afraid you’re nearing the limits of my serveradmin-foo :frowning:

I can tell you that in the supported environment, redis will be running under the ‘redis’ user, and the ‘ares’ user is part of the ‘redis’ unix group that owns all the files. So yeah there could be some kind of permission issue.

nginx does start as root I think but ares doesn’t really interact with nginx directly. As long as it can write the files to the directory nginx is serving from (by default /var/www/html) that’s all it needs.

I’d like to ask then, where is the code that starts up the server for the web-server? Maybe by taking a look I can figure out what’s not working for me. As long as I know where to look. It shouldn’t be a port issue, because I double checked that nothing runs on port 80, which is the default I left for it, I think…? It’s a bit confusing with all the ports, and since I have no idea what exactly it is even trying to start, I can’t start guessing.

Well, I’ll try to figure out what I can on my own, sorry for troubling so much on this!

The web server isn’t part of Ares. Ares just uses an off the shelf web server (nginx by default, though Apache or anything else could work with some fiddling) to serve static files out of a directory (/var/www/html by default). So there’s no real code to speak of. There is some configuration needed within nginx to get it to route web traffic to the game appropriately (see here for a template) but that wouldn’t affect the game itself starting up.

Ares does use several ports, which are specified in server.yml. The ports are described here. The defaults are normally free (they’re not commonly-used ports) but you can change them if you like.

Well, I’ve got some progress. It worked when I used ‘localhost’ instead of an IP.
But I’ve sort of need to use the IP to make it possible to connect to it. I still don’t get why it doesn’t work with the IP, does it have anything to do with any of the settings?

Can you be a little more specific about what setting you changed to localhost and what precise error you get when you run it with the IP?

You can also try starting the game in debug mode by doing

cd aresmush
bin/devstart

It’ll print the log messages to the screen, which sometimes helps when the game won’t start up properly.