AMP Seems to Restart Server if it Hasn't Finished "In Time"

  • 47 Views
  • Last Post 2 weeks ago
VintageDon posted this 2 weeks ago

So I'll be happy to provide logs and everything, but I thought I'd take a stab at a post first, as I may just be hitting up against a setting I can change that I don't know about.

Am using the network edition, and I run a small network of modded Minecraft servers, some of them running very "heavy" modpacks that take a while to start up. Everything is working fine on all of them, except one running the "AllTheMods" (henceforth ATM) modpack. In fact, the ATM server was working great until we accumulated enough data that the server started taking quite a while to boot up.

What is happening is that it seems that if the server doesn't start within a certain amount of time, AMP simply gives up, kills the process (or whatever it does) and tries again. It's not a server issue, as I installed Mark2 (an open source Python panel) on the same server, and can boot and run the server without issue (and is what I'm currently using).

Since ATM isn't on the list of servers, I'm simply running it as a forge server using the current version they are using.

Is there a time limit or anything that you can think of that would be causing this? If so, is there something I can change to make it more lenient?

NOTE: I want to point out, as I did before, that AMP was working fine on this server until the server started taking longer to boot up.

Thanks, Don

9 Comments
Order By: Standard | Newest | Votes
Mike posted this 2 weeks ago

Can you pastebin AMPs log from this?

VintageDon posted this 2 weeks ago

Hello:

So you can find one of the logs in question at the following PasteBin: https://pastebin.com/nvY37AyQ Note that the times are, in all cases, right in the middle of the boot process with no pause whatsoever on the time stamp. The server does NOT log anything in the crash-reports folder, so it's not an actual crash.

You can see what I'm talking about at the following lines that I've pointed out in this extra PasteBin: https://pastebin.com/gRQAXmqg

In all three cases, the server is in the middle of starting, and without any error listed or any provocation, it simply begins a process of boot looping.

I've run this both at the command line and with the Mark2 control panel, and the server boots without issue at all. As soon as I use AMP to start it, the server returns to this behavior.

Mike posted this 2 weeks ago

AMP isn't what's doing the stopping. Something is going wrong with the server somewhere and its stopping itself (and AMP dutifully retries when it fails), so it's probably a matter of startup arguments.

When AMP starts the MC server, it logs what arguments it uses to AMPs own log file - try running Java manually using those same arguments from the same directory in AMPs own datastore and see what happens.

[17:31:27] [MinecraftModule:Core Debug] : Java located at: /usr/bin/java
[17:31:27] [MinecraftModule:Core Debug] : Java start arguments: -Xmx14336M -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+CMSIncrementalMode -XX:+CMSIncrementalPacing -XX:+CMSParallelRemarkEnabled -XX:MaxGCPauseMillis=50 -XX:+DisableExplicitGC -XX:+AggressiveOpts -XX:+UseFastAccessorMethods -XX:+UseBiasedLocking -XX:TargetSurvivorRatio=90 -jar forge-1.10.2-12.18.3.2297-universal.jar nogui
[17:31:27] [ModuleShared:Core Debug] : Starting process /usr/bin/java
[17:31:27] [ModuleShared:Core Debug] : Working Directory: ./Minecraft/

Also check that /usr/bin/java is actually pointed to the intended version of Java in case you have multiple versions installed. Otherwise you can change MinecraftModule.kvp to use a different path.

VintageDon posted this 2 weeks ago

Mike:

As I said, I already run the server, both from the command line and using Mark2 with those exact same arguments, and it runs fine and without issue. And yes, from the same directory. As long as I don't run the server with AMP, it works fine.

And yes, /usr/bin/java is where Java is and is the correct version. It's also the same version that I use when I run the server from the command line and the same version that Mark2 uses when it runs the server. It's the only version of Java on the server.

[root@atm bin]# java -version
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)

As Always, Don

Mike posted this 2 weeks ago - Last edited 2 weeks ago

Just for my benefit, could you do this:

java -Xmx14336M -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+CMSIncrementalMode -XX:+CMSIncrementalPacing -XX:+CMSParallelRemarkEnabled -XX:MaxGCPauseMillis=50 -XX:+DisableExplicitGC -XX:+AggressiveOpts -XX:+UseFastAccessorMethods -XX:+UseBiasedLocking -XX:TargetSurvivorRatio=90 -jar forge-1.10.2-12.18.3.2297-universal.jar nogui > mcsrv.out

From the Minecraft directory that AMP created, and upload mcsrv.out to pastebin assuming it does a complete start?

AMP doesn't do anything special, it just starts the process - there's no difference running something inside of AMP than outside, so if it's misbehaving then there's some external environmental factor that's causing the behaviour and it's just a matter of finding out what that is.

VintageDon posted this 2 weeks ago

Mike:

The log is here. It started up, as it always does. https://s3.amazonaws.com/cdn.craincraft.com/logs/mcsrv.zip

Sorry about the zip; PasteBin kept bombing out under high load this morning.

AMP doesn't do anything special, it just starts the process - there's no difference running something inside of AMP than outside, so if it's misbehaving then there's some external environmental factor that's causing the behaviour and it's just a matter of finding out what that is.

I'm not accusing AMP of doing anything, I'm just stating what's happening on my end to try to help us figure out what's going on. All I know is that it will start from the command line or with Mark2, but it simply boot loops with AMP. I'd MUCH rather be using AMP than mark2 because it's safer, and easier to train my staff how to use it. If it's something on my end, I'm just as happy to be at fault. I just want it to work.

As Always, Don

Mike posted this 2 weeks ago

What's the output of whereis java ?

VintageDon posted this 2 weeks ago

Mike:

[amp@atm servers]$ which java
/usr/bin/java
[amp@atm servers]$ whereis java
java: /usr/bin/java /opt/jdk1.8.0_131/bin/java
[amp@atm servers]$ java -version
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)

As Always, Don

Mike posted this 2 weeks ago

Hmm okay, I'm going to stick some extra logging in there and see what's going on. I don't think it's AMP but it's gonna be tricky to find out what's causing it.