figured it out…
have to edit the .config/monitors.xml file instead
figured it out…
have to edit the .config/monitors.xml file instead
I’m wondering if anyone can help me out or point me in the direction of some easy to understand info on systemd and services?
I have a Fedora 29 Server installation I am using to run a game server and I am trying to configure it so that systemd starts the game server when the server starts up. I’ve been following the server setup section from this tutorial but can’t seem to get the service to start.
I have create the service unit file (I think that’s what its called) as follows:
[Unit] Description=Screeps Server (World) Wants=network-online.target After=network-online.target [Service] Type=simple WorkingDirectory=/home/screeps/world ExecStart=/home/screeps/world/node_modules/screeps/bin/screeps.js start ExecStop=/home/screeps/world/node_modules/screeps/bin/screeps.js stop User=screeps Group=screeps [Install] WantedBy=multi-user.target
which is saved in /etc/systemd/system/screeps-world.service
I’ve tested the server and I can start and stop it manually without problems but when I try to start it via systemctl I am getting permission errors.
[[email protected] ~]$ sudo systemctl start screeps-world [[email protected] ~]$ sudo systemctl status screeps-world ● screeps-world.service - Screeps Server (World) Loaded: loaded (/etc/systemd/system/screeps-world.service; enabled; vendor preset: disabled) Active: failed (Result: exit-code) since Tue 2018-11-27 21:44:24 GMT; 12s ago Process: 1097 ExecStart=/home/screeps/world/node_modules/screeps/bin/screeps.js start (code=exited, status=203/EXEC) Main PID: 1097 (code=exited, status=203/EXEC) Nov 27 21:44:24 screep-sever-000 systemd: Started Screeps Server (World). Nov 27 21:44:24 screep-sever-000 systemd: screeps-world.service: Failed to execute command: Permission denied Nov 27 21:44:24 screep-sever-000 systemd: screeps-world.service: Failed at step EXEC spawning /home/screeps/world/node_modules/screep> Nov 27 21:44:24 screep-sever-000 systemd: screeps-world.service: Main process exited, code=exited, status=203/EXEC Nov 27 21:44:24 screep-sever-000 systemd: screeps-world.service: Failed with result 'exit-code'.
I am assuming that this is because systemd cannot acces the start up scripts because they are in the /home directory of the “screeps” user account but if that is the case I am confused as to the purpose the “User=screeps” directive in the “screeps-world.service” file, isn’t this telling the OS to run the service as that user?
I have confirmed that the ExecStart command is correct as I can run it under the screeps user account but not via the service. Is there something else I need to do to ensure that /home/screeps/world/ is accessible from the service?
I can probably re-install my the server into the /usr/bin/ folder to get around this but I am curious as to what’s happening since the tutorial is also running the service under a dedicated user account.
Any help would be very much appreciated.
You need to
chmod +x the file you’re trying to run.
Or you could
/usr/bin/node /path/to/file.js start to bypass needing
+x. (this is probably “best practice”)
Thank you @sgtawesomesauce !! I added /usr/bin/node to the ExecStart/ExecStop command lines and it works perfectly now.
Last login: Tue Nov 27 22:10:56 2018 from 192.168.1.10 [[email protected] ~]$ sudo systemctl status screeps-world.service [sudo] password for shecks: ● screeps-world.service - Screeps Server (World) Loaded: loaded (/etc/systemd/system/screeps-world.service; enabled; vendor preset: disabled) Active: active (running) since Tue 2018-11-27 22:20:25 GMT; 49s ago Main PID: 956 (node) Tasks: 78 (limit: 4915) Memory: 380.2M CGroup: /system.slice/screeps-world.service ├─ 956 /usr/bin/node /home/screeps/world/node_modules/screeps/bin/screeps.js start ├─ 983 /usr/bin/node /home/screeps/world/node_modules/@screeps/storage/bin/start.js ├─ 994 /usr/bin/node /home/screeps/world/node_modules/@screeps/backend/bin/start.js ├─1001 /usr/bin/node /home/screeps/world/node_modules/@screeps/engine/dist/main.js ├─1002 /usr/bin/node /home/screeps/world/node_modules/@screeps/engine/dist/runner.js ├─1003 /usr/bin/node /home/screeps/world/node_modules/@screeps/engine/dist/processor.js └─1004 /usr/bin/node /home/screeps/world/node_modules/@screeps/engine/dist/processor.js Nov 27 22:20:25 screep-sever-000 systemd: Started Screeps Server (World). Nov 27 22:20:27 screep-sever-000 node: Server version 3.1.7 Nov 27 22:20:27 screep-sever-000 node: Starting all processes. Ports: 21025 (game), 21026 (cli) Nov 27 22:20:27 screep-sever-000 node: [storage] process 983 started Nov 27 22:20:28 screep-sever-000 node: [backend] process 994 started Nov 27 22:20:28 screep-sever-000 node: [engine_main] process 1001 started Nov 27 22:20:28 screep-sever-000 node: [engine_runner] process 1002 started Nov 27 22:20:28 screep-sever-000 node: [engine_processor1] process 1003 started Nov 27 22:20:28 screep-sever-000 node: [engine_processor2] process 1004 started
I was an idiot, it all makes sense now, I was trying to execute the java script file directly.
I setup another server recently and just running “screeps start” worked because somehow the installation added the following symlink to /usr/bin/
lrwxrwxrwx. 1 root root 42 Nov 22 18:20 screeps -> ../lib/node_modules/screeps/bin/screeps.js
I’ve no idea why the new installation didn’t do the same but it’s working now and I learned a few new things.
It takes practice, it’s all part of learning. Don’t beat yourself up about it.
You’ll do something one day and realize how much you’ve learned and adapted. For example, when you try to install something, rather than look it up via search engine you’ll do something like
apt search openjdk to find the package you’re looking for.
Things like that.
You’re doing better than most in this world, just keep that in perspective and it’s all up hill (downhill? It’s hard walking up hills )
I seem to have accidentally Installed xubuntu for i386 Architecture (not sure. uname shows i686 and dpkg complains it’s i386).
Since i never did that before, what are the limitations compared to amd64 (4th gen core i5, 16G RAM). And is it possible to change the Architecture without reinstallation?
You’ll only be able to utilize 4GB of RAM. I don’t think you can change that without reinstalling.
This should give you an indication that although it is possible to update your install from 32bit to 64bit - the fact that you’re asking the question means that you probably shouldn’t as this will probably go south extremely fast.
Backing up your home directory and doing a reinstall/config is probably the easiest/best way.
Well, that and some software can run significantly slower. X86 isn’t just a 32 bit clone of and64. Amd64 has lots of instructions that x86 doesn’t have.
Thanks for the replies. I just went ahead and reinstalled. Hadn’t set up to much already, so it wasn’t that big of a deal. No clue how that happend though. Never managed to do that before.
So I just updated packages on my Fedora 29 install and things aren’t going too well. Seems that the GPU (intel) drivers are not working properly. I’m getting lots of display lag. 15fps while using KDE with the OpenGL 3.0 compositor. Switching my Rendering Backend in KDE settings to “XRender” fixes the issue, but I’m fairly certain that’s CPU rendering.
Anyways, I’ve tried to roll back the updates via DNF and it’s throwing an error on a required package from VirtualBox. (CLI output below) I don’t use Virtualbox, so I’m curious if there’s a way to just force it to ignore a specific operation while rolling back multiple transactions? I can’t find that specific package version. Alternatively, if someone knows how to generate that RPM, I’d be happy to build it as well.
sudo dnf history rollback 61 Last metadata expiration check: 2:06:39 ago on Thu 29 Nov 2018 10:57:17 AM PST. Rollback to transaction 61, from Thu 29 Nov 2018 12:36:40 PM PST Undoing the following transactions: 62, 63 Upgraded kmod-VirtualBox-4.18.18-300.fc29.x86_64-5.2.20-1.fc29.x86_64 @@System Upgrade kmod-VirtualBox-4.18.18-300.fc29.x86_64-5.2.22-1.fc29.x86_64 @@commandline Install kmod-VirtualBox-4.19.4-300.fc29.x86_64-5.2.22-1.fc29.x86_64 @@commandline No package kmod-VirtualBox-4.18.18-300.fc29.x86_64-5.2.20-1.fc29.x86_64 available. Error: no package matched
Sorry, I don’t have a solution for you. But thanks for taking the hit…
Still no virtualbox repo for Fedora 29? Or docker-ce repo? https://github.com/docker/for-linux/issues/430
uname -r 4.19.4-300.fc29.x86_64 ~ docker version Client: Version: 1.13.1 API version: 1.26 Package version: docker-1.13.1-62.git9cb56fd.fc29.x86_64 Go version: go1.11beta2 Git commit: accfe55-unsupported Built: Wed Jul 25 18:54:07 2018 OS/Arch: linux/amd64 Server: Version: 1.13.1 API version: 1.26 (minimum version 1.12) Package version: docker-1.13.1-62.git9cb56fd.fc29.x86_64 Go version: go1.11beta2 Git commit: accfe55-unsupported Built: Wed Jul 25 18:54:07 2018 OS/Arch: linux/amd64 Experimental: false
They have docker.
Oh wait, this may be the Fedora repos though.
dnf info docker Installed Packages Name : docker Epoch : 2 Version : 1.13.1 Release : 62.git9cb56fd.fc29 Arch : x86_64 Size : 78 M Source : docker-1.13.1-62.git9cb56fd.fc29.src.rpm Repo : @System From repo : fedora Summary : Automates deployment of containerized applications URL : https://github.com/projectatomic/docker License : ASL 2.0 Description : Docker is an open-source engine that automates the deployment of any : application as a lightweight, portable, self-sufficient container that will : run virtually anywhere. : : Docker containers can encapsulate any payload, and will run consistently on : and between virtually any server. The same container that a developer builds : and tests on a laptop will run at scale, in production*, on VMs, bare-metal : servers, OpenStack clusters, public instances, or combinations of the above.
Yes, it’s probably available in Fedora’s repos, but docker-ce don’t have their own F29 repo yet… and folks have been waiting months now.
Same deal with virtualbox. It’s probably available in Fedora’s repos, but virtualbox don’t have a directory/repo file for F29 yet. http://download.virtualbox.org/virtualbox/rpm/fedora/
I’ve previously asked about whether it’s best to use packages for common software from Fedora’s own repos or from the software organizations themselves (docker, virtualbox, etc). It’s not always clear what the differences are, and usually folks report that both work fine… But in the interest of standardization I’m inclined to go with what is most common, not just for one distro.
Is there a difference between the Fedora and docker-ce repos? I’m not super up-to-date on how Docker handles their repos.
I don’t know and I’ve asked that myself. I decided to go with docker-ce repos.
Okay. That’s fair.
Just checked that repo URL in the github issue (https://download.docker.com/linux/fedora/) If you look, it’s got a
29 directory, although it’s only Nightlies. So it looks like they’re at least making progress on it.
Reading through the issue, this is why I hate docker devs so much that it makes me want to hug Comcast execs. They’re lazy assholes who clearly don’t even accept help when it’s offered. I’d be happy to setup builds for F29, but it seems that they’re waiting for god knows what.
And then, more importantly, you see the organization locking the conversation, so I can’t even offer help if I wanted to.
Yes yes and yes.
The nightlies were a relatively recent addition, and not everyone is interested in non-stable builds.
Locking the conversation also annoying… the complaints have been coming in since F29 was in beta. People are really fed up of waiting.
Apparently it’s been a recurring issue, since the F28 release? F26? …
Fresh install of Fedora 29, Gnome and KDE, have the same issue. Works fine until you update the system and do a first reboot.
Serious mouse hang, when going to “Activities” or running any desktop application.
NVidia GPU + Intel CPU
I also had a similar issue with gnome on a server (normies need to use it). CPU was pegged when using Wayland. It was fine in 28.