tgstation / tgstation-server

A production scale tool for DreamMaker server management
https://tgstation.github.io/tgstation-server/
GNU Affero General Public License v3.0
63 stars 81 forks source link

DMAPI Verification failing on linux #1249

Closed LetterN closed 3 years ago

LetterN commented 3 years ago

Describe the bug WaitforInput errors with running dreamdaemon, causes DMAPI to not be verified in linux. image

To Reproduce Steps to reproduce the behavior:

  1. Install TGS on linux using docker
  2. Create a new instance & download whatever coderbase you want
  3. Deploy code (with or without DMAPI verification, still causes the error but DMAPI failing will stop it)
  4. See error

Expected behavior No errors

Logs Please include full server logs to help diagnose your problem

Server State: (please complete the following information):

Cyberboss commented 3 years ago

That error is expected on linux and should just be a debug log. Is there more log context you can give?

LetterN commented 3 years ago
2021-04-24T05:28:54.5867502+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Components.StaticFiles.Configuration: Script output:"
""+ original_dir=/tgs4_instances/ae/Configuration/EventScripts
+ cd /tgs4_instances/ae/Game/42cc0390-9ef9-4cef-ad32-44e8b6be77d1
+ . dependencies.sh
++ export BYOND_MAJOR=513
++ BYOND_MAJOR=513
++ export BYOND_MINOR=1536
++ BYOND_MINOR=1536
++ export RUST_G_VERSION=0.4.7
++ RUST_G_VERSION=0.4.7
++ export NODE_VERSION=12
++ NODE_VERSION=12
++ export NODE_VERSION_PRECISE=12.20.0
++ NODE_VERSION_PRECISE=12.20.0
++ export SPACEMAN_DMM_VERSION=suite-1.6
++ SPACEMAN_DMM_VERSION=suite-1.6
++ export EXTOOLS_VERSION=v0.0.7
++ EXTOOLS_VERSION=v0.0.7
++ export PYTHON_VERSION=3.6.8
++ PYTHON_VERSION=3.6.8
+ cd /tgs4_instances/ae/Configuration/EventScripts
+ set +e
++ command -v git
+ has_git=/usr/bin/git
++ command -v /root/.cargo/bin/cargo
+ has_cargo=/root/.cargo/bin/cargo
++ command -v sudo
+ has_sudo=
++ command -v grep
+ has_grep=/bin/grep
+ set -e
+ '[' -x /root/.cargo/bin/cargo ']'
+ '[' -x /usr/bin/git ']'
+ '[' -x /bin/grep ']'
+ '[' -f /usr/lib/i386-linux-gnu/libssl.so ']'
+ dpkg --add-architecture i386
+ apt-get update
Hit:1 http://deb.debian.org/debian buster InRelease
Get:2 http://deb.debian.org/debian buster-updates InRelease [51.9 kB]
Get:3 http://security.debian.org/debian-security buster/updates InRelease [65.4 kB]
Get:4 http://deb.debian.org/debian buster-updates/main amd64 Packages.diff/Index [6640 B]
Get:5 http://deb.debian.org/debian buster-updates/main i386 Packages.diff/Index [6640 B]
Get:6 http://deb.debian.org/debian buster-updates/main amd64 Packages 2021-04-23-1401.02.pdiff [1127 B]
Get:6 http://deb.debian.org/debian buster-updates/main amd64 Packages 2021-04-23-1401.02.pdiff [1127 B]
Get:7 http://security.debian.org/debian-security buster/updates/main amd64 Packages [272 kB]
Get:8 http://deb.debian.org/debian buster-updates/main i386 Packages 2021-04-23-1401.02.pdiff [1125 B]
Get:8 http://deb.debian.org/debian buster-updates/main i386 Packages 2021-04-23-1401.02.pdiff [1125 B]
Get:9 http://security.debian.org/debian-security buster/updates/main i386 Packages [271 kB]
Fetched 675 kB in 7s (99.3 kB/s)
Reading package lists...
+ apt-get install -y lib32z1 pkg-config libssl-dev:i386 libssl-dev
Reading package lists...
Building dependency tree...
Reading state information...
pkg-config is already the newest version (0.29-6).
lib32z1 is already the newest version (1:1.2.11.dfsg-1).
libssl-dev is already the newest version (1.1.1d-0+deb10u6).
libssl-dev:i386 is already the newest version (1.1.1d-0+deb10u6).
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
+ '[' '!' -d rust-g ']'
Fetching rust-g...
+ echo 'Fetching rust-g...'
+ cd rust-g
+ git fetch
+ /root/.cargo/bin/rustup target add i686-unknown-linux-gnu
info: component 'rust-std' for target 'i686-unknown-linux-gnu' is up to date
+ echo 'Deploying rust-g...'
Deploying rust-g...
+ git checkout 0.4.7
HEAD is now at b9d8668 Bump version to v0.4.7
+ env PKG_CONFIG_ALLOW_CROSS=1 /root/.cargo/bin/cargo build --release --target=i686-unknown-linux-gnu
    Finished release [optimized] target(s) in 0.09s
+ mv target/i686-unknown-linux-gnu/release/librust_g.so /tgs4_instances/ae/Game/42cc0390-9ef9-4cef-ad32-44e8b6be77d1/librust_g.so
+ cd ..
+ echo 'Compiling tgui...'
+ cd /tgs4_instances/ae/Game/42cc0390-9ef9-4cef-ad32-44e8b6be77d1
Compiling tgui...
+ chmod +x tools/bootstrap/node
+ env TG_BOOTSTRAP_CACHE=/tgs4_instances/ae/Configuration/EventScripts TG_BOOTSTRAP_NODE_LINUX=1 TG_BUILD_TGS_MODE=1 tools/bootstrap/node tools/build/build.js
 => Starting 'tgui'
➤ YN0000: ┌ Resolution step
➤ YN0000: └ Completed
➤ YN0000: ┌ Fetch step
➤ YN0013: │ No packages were cached - 827 packages had to be fetched
➤ YN0000: └ Completed in 0s 458ms
➤ YN0000: ┌ Link step
➤ YN0000: └ Completed in 0s 821ms
➤ YN0000: Done in 1s 553ms
assets by path *.js 1.02 MiB
  asset tgui.bundle.js 640 KiB [emitted] [minimized] (name: tgui)
  asset tgui-common.bundle.js 349 KiB [emitted] [minimized] (name: tgui-common) (id hint: vendors)
  asset tgui-panel.bundle.js 57.3 KiB [emitted] [minimized] (name: tgui-panel)
assets by path *.css 271 KiB
  asset tgui.bundle.css 175 KiB [emitted] (name: tgui)
  asset tgui-panel.bundle.css 96.1 KiB [emitted] (name: tgui-panel)
Entrypoint tgui 1.14 MiB = tgui-common.bundle.js 349 KiB tgui.bundle.css 175 KiB tgui.bundle.js 640 KiB
Entrypoint tgui-panel 502 KiB = tgui-common.bundle.js 349 KiB tgui-panel.bundle.css 96.1 KiB tgui-panel.bundle.js 57.3 KiB
2021-04-24 05:28:52: webpack 5.23.0 compiled successfully in 16220 ms
 => Finished 'tgui' in 21.256s
 => Done in 21.304s" ()
2021-04-24T05:28:54.6028467+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Components.Deployment.DreamMaker: Selected "tgstation".dme for compilation! ()
2021-04-24T05:28:54.6037130+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.System.ProcessExecutor: "L"aunching process in "/tgs4_instances/ae/Game/42cc0390-9ef9-4cef-ad32-44e8b6be77d1": "/tgs4_instances/ae/Byond/513.1536/byond/bin/DreamMaker.sh" "-clean tgstation.dme" ()
2021-04-24T05:28:54.6049603+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.System.Process: Error on WaitForInputIdle()! ()
System.InvalidOperationException: WaitForInputIdle failed.  This could be because the process does not have a graphical interface.
   at System.Diagnostics.Process.WaitForInputIdleCore(Int32 milliseconds)
   at System.Diagnostics.Process.WaitForInputIdle()
   at Tgstation.Server.Host.System.Process.<>c__DisplayClass16_0.<.ctor>b__0() in /repo/src/Tgstation.Server.Host/System/Process.cs:line 93
2021-04-24T05:29:04.3354123+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:29:14.6428558+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:29:24.9231077+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:29:35.2885755+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:29:45.5035657+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Components.Deployment.DreamMaker: DreamMaker exit code: 0 ()
2021-04-24T05:29:45.5036795+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Components.Deployment.DreamMaker: DreamMaker output: "
""DM compiler version 513.1536
loading tgstation.dme
loading interface/skin.dmf
loading map_files/generic/CentCom.dmm
saving tgstation.dmb (DEBUG mode)
tgstation.dmb - 0 errors, 0 warnings (4/24/21 5:29 am)
Total time: 0:51" ()
2021-04-24T05:29:45.5039757+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Components.Session.SessionControllerFactory: Launching session with CompileJob null... ()
2021-04-24T05:29:45.5060761+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.System.ProcessExecutor: "L"aunching process in "/tgs4_instances/ae/Game/42cc0390-9ef9-4cef-ad32-44e8b6be77d1": "/tgs4_instances/ae/Byond/513.1536/byond/bin/DreamDaemon.sh" "tgstation.dmb -port 1340 -ports 1-65535 -close -trusted -invisible -params \"server_service_version=5.3.0&tgs_port=5000&tgs_key=9Jln1Ibxo99wjdem%2fooKLbfSLBcMB6Cz3%2bs8Y%2fnx\"" ()
2021-04-24T05:29:45.5067810+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.System.Process: Error on WaitForInputIdle()! ()
System.InvalidOperationException: WaitForInputIdle failed.  This could be because the process does not have a graphical interface.
   at System.Diagnostics.Process.WaitForInputIdleCore(Int32 milliseconds)
   at System.Diagnostics.Process.WaitForInputIdle()
   at Tgstation.Server.Host.System.Process.<>c__DisplayClass16_0.<.ctor>b__0() in /repo/src/Tgstation.Server.Host/System/Process.cs:line 93
2021-04-24T05:29:45.5069762+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Components.Session.SessionController: Created session controller. CommsKey: "9Jln1Ibxo99wjdem/ooKLbfSLBcMB6Cz3+s8Y/nx", Port: 1340 ()
2021-04-24T05:29:45.5732374+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:29:55.9590866+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:30:06.5520066+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:30:16.8899911+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:30:27.1745918+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:30:37.5327048+00:00 (Instance:2|Job:|Request:GET /Job/33|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Controllers.JobController: Starting API request: Version: "9.0.0". "User-Agent": "Tgstation.Server.ControlPanel/2.1.1.0" ()
2021-04-24T05:30:45.7239833+00:00 (Instance:2|Job:33|Request:PUT /DreamMaker|User:1|Monitor:|Bridge:|Chat:): [DBG] Tgstation.Server.Host.Jobs.JobManager: Job 33 exited with error! ()
Tgstation.Server.Host.Jobs.JobException: DreamDaemon did not validate the DMAPI!
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.VerifyApi(UInt32 timeout, DreamDaemonSecurity securityLevel, CompileJob job, IByondExecutableLock byondLock, UInt16 portToUse, Boolean requireValidate, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 248
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.VerifyApi(UInt32 timeout, DreamDaemonSecurity securityLevel, CompileJob job, IByondExecutableLock byondLock, UInt16 portToUse, Boolean requireValidate, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 250
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.RunCompileJob(CompileJob job, DreamMakerSettings dreamMakerSettings, IByondExecutableLock byondLock, IRepository repository, IRemoteDeploymentManager remoteDeploymentManager, UInt32 apiValidateTimeout, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 479
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.RunCompileJob(CompileJob job, DreamMakerSettings dreamMakerSettings, IByondExecutableLock byondLock, IRepository repository, IRemoteDeploymentManager remoteDeploymentManager, UInt32 apiValidateTimeout, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 501
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.RunCompileJob(CompileJob job, DreamMakerSettings dreamMakerSettings, IByondExecutableLock byondLock, IRepository repository, IRemoteDeploymentManager remoteDeploymentManager, UInt32 apiValidateTimeout, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 516
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.Compile(RevisionInformation revisionInformation, DreamMakerSettings dreamMakerSettings, UInt32 apiValidateTimeout, IRepository repository, IRemoteDeploymentManager remoteDeploymentManager, Action`1 progressReporter, Nullable`1 estimatedDuration, Boolean localCommitExistsOnRemote, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 839
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.Compile(RevisionInformation revisionInformation, DreamMakerSettings dreamMakerSettings, UInt32 apiValidateTimeout, IRepository repository, IRemoteDeploymentManager remoteDeploymentManager, Action`1 progressReporter, Nullable`1 estimatedDuration, Boolean localCommitExistsOnRemote, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 850
   at Tgstation.Server.Host.Components.Deployment.DreamMaker.DeploymentProcess(Job job, IDatabaseContextFactory databaseContextFactory, Action`1 progressReporter, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Components/Deployment/DreamMaker.cs:line 653
   at Tgstation.Server.Host.Jobs.JobManager.RunJob(Job job, JobEntrypoint operation, CancellationToken cancellationToken) in /repo/src/Tgstation.Server.Host/Jobs/JobManager.cs:line 123
Cyberboss commented 3 years ago

Have you tried increasing the startup timeout in DreamDaemon settings?

LetterN commented 3 years ago

Wait nevermind, i'm stupid and didn't think about cit extools not working on linux