I have a minecraft server running as a system service and wish to check up on it. I know I can do systemctl status minecraft.service
but that doesn't let me see the java process's output and/or input new commands. Is there any way to access the process spawned by the service?
Asked
Active
Viewed 154 times
1

ChildishGiant
- 111
- 1
-
Is there a log file? Also, perhaps you can type sudo dmesg | grep 'minecraft' which might give you the info you need. Just a guess :) The 'top' command might also give more info or if you have htop installed you can probably get more info on a per user basis. – Admiral Noisy Bottom May 21 '20 at 03:18
-
Nothing from dmesg. There's a latest.log but I can't interact with the running process through that. I can see the processes in htop but again have the issue of not being able to interact with it through that. – ChildishGiant May 21 '20 at 10:30
-
In what way do you want to interact with the process? How you communicate with a running process depends on the process I guess. – Admiral Noisy Bottom May 22 '20 at 04:42
-
When manually started it creates its own console kinda thing where you can type commands and see what's going on. I could run it and then screen in and out of it but that'd defeat the point of an ongoing service. – ChildishGiant May 23 '20 at 16:03
-
Is there an option when the service starts to output to a log? I know nothing about minecraft but I'd imagine there might be a configuration function, or .conf file, with an option to output data to a log somewhere. Perhaps this helps https://www.reddit.com/r/admincraft/comments/ekrhou/vanilla_minecraft_server_on_linux_command_line/ – Admiral Noisy Bottom May 24 '20 at 04:04