https://github.com/osquery/osquery logo
#fleet
Title
# fleet
t

Tanguy Dangelser

09/14/2021, 12:12 PM
Copy code
$ go run ./cmd/package --type=msi --fleet-url=localhost:8412 --insecure --enroll-secret=mysecrethere

heat.exe : error HEAT0001 : SetThreadErrorMode assembly:<unknown assembly> type:<unknown type> member:(null)

Exception Type: System.EntryPointNotFoundException

Stack Trace:
  at (wrapper managed-to-native) Interop+Kernel32.SetThreadErrorMode(uint,uint&)
  at System.IO.DisableMediaInsertionPrompt.Create () [0x00008] in <3d7a9349295c42b6abb3487b4473a6b8>:0
  at System.IO.FileSystem.FillAttributeInfo (System.String path, Interop+Kernel32+WIN32_FILE_ATTRIBUTE_DATA& data, System.Boolean returnErrorOnNotFound) [0x0000a] in <3d7a9349295c42b6abb3487b4473a6b8>:0
  at System.IO.FileSystem.FileExists (System.String fullPath) [0x00008] in <3d7a9349295c42b6abb3487b4473a6b8>:0
  at System.IO.File.Exists (System.String path) [0x0003d] in <3d7a9349295c42b6abb3487b4473a6b8>:0
  at System.Configuration.ConfigurationManager.OpenExeConfigurationInternal (System.Configuration.ConfigurationUserLevel userLevel, System.Reflection.Assembly calling_assembly, System.String exePath) [0x00050] in <9dbd70885bbe478dbcc5b41c7b0e0973>:0
  at System.Configuration.ConfigurationManager.OpenExeConfiguration (System.String exePath) [0x0000f] in <9dbd70885bbe478dbcc5b41c7b0e0973>:0
  at Microsoft.Tools.WindowsInstallerXml.AppCommon.ReadConfiguration (System.Collections.Specialized.StringCollection extensions) [0x00022] in <13acedad176f4740bcdf107d029f167c>:0
  at Microsoft.Tools.WindowsInstallerXml.Tools.Heat.Run (System.String[] args) [0x0005d] in <05dc1d4b31e6439dabb75d17e14330a3>:0
2021-09-14T14:06:23+02:00 FTL package failed error="package root files: heat failed: exit status 1"
exit status 1
b

Benjamin Edwards

09/14/2021, 3:42 PM
Looks like some issue in the container running installer process. Not sure if it’s an M1 issue though. I don’t have an M1 so it’s difficult for me to verify.
z

zwass

09/14/2021, 4:08 PM
Agreed it may be an M1 issue. One of our engineers has an M1 so we will try to look into it.
Verified that this issue also happens on our M1. Building MSIs from other platforms uses a pretty tricky little Docker hack and I'm not sure we're going to be able to immediately address this.
💯 1
a

Ashish

10/06/2021, 6:53 PM
I also tried creating the MSI and getting the same issue.
ubuntu@ip:/usr/local/bin$ fleetctl package --type=msi --fleet-url=ht                                                                                                                                   <tps://XXXX:8412> --insecure --enroll-secret=gsT5x4c1u4m800000lP+RmHH149ca                                                                                                                                   oaW
{"level":"debug","path":"/tmp/orbit-package032829848","time":"2021-10-06T18:50:2                                                                                                                                   2Z","message":"created temp dir"}
{"level":"debug","error":"stat /tmp/orbit-package032829848/root/bin/osqueryd/win                                                                                                                                   dows/stable/osqueryd.exe: no such file or directory","time":"2021-10-06T18:50:22                                                                                                                                   Z","message":"stat file"}
{"level":"debug","path":"/tmp/orbit-package032829848/root/bin/osqueryd/windows/s                                                                                                                                   table/osqueryd.exe","time":"2021-10-06T18:50:23Z","message":"got osqueryd"}
{"level":"debug","error":"stat /tmp/orbit-package032829848/root/bin/orbit/window                                                                                                                                   s/stable/orbit.exe: no such file or directory","time":"2021-10-06T18:50:23Z","me                                                                                                                                   ssage":"stat file"}
{"level":"debug","path":"/tmp/orbit-package032829848/root/bin/orbit/windows/stab                                                                                                                                   le/orbit.exe","time":"2021-10-06T18:50:23Z","message":"got orbit"}
docker: Got permission denied while trying to connect to the Docker daemon socke                                                                                                                                   t at unix:///var/run/docker.sock: Post <http://%2Fvar%2Frun%2Fdocker.sock/v1.24/c>                                                                                                                                   ontainers/create?platform=linux%2F386: dial unix /var/run/docker.sock: connect:                                                                                                                                    permission denied.
See 'docker run --help'.
package root files: heat failed: exit status 126
z

zwass

10/06/2021, 7:00 PM
^ This looks like a different issue. Does it work if you try
sudo fleetctl package
? On default Linux installs I believe you need root privileges to access the Docker unix socket.
👍 1
a

Ashish

10/06/2021, 7:18 PM
Thank you, yes this was because root priv issue. Apologies completely my oversight, didn't noticed the
permission denied
message in the log.
j

Jaideep Natu

10/11/2021, 9:48 PM
For reference, I'm getting the same error on CentOS VM on x86
Copy code
# fleetctl package --type msi --fleet-url=https://<url>:8412 --insecure --enroll-secret=<secret> --debug
{"level":"debug","path":"/tmp/orbit-package149266210","time":"2021-10-11T14:44:22-07:00","message":"created temp dir"}
{"level":"debug","error":"stat /tmp/orbit-package149266210/root/bin/osqueryd/windows/stable/osqueryd.exe: no such file or directory","time":"2021-10-11T14:44:23-07:00","message":"stat file"}
{"level":"debug","path":"/tmp/orbit-package149266210/root/bin/osqueryd/windows/stable/osqueryd.exe","time":"2021-10-11T14:44:23-07:00","message":"got osqueryd"}                 
{"level":"debug","error":"stat /tmp/orbit-package149266210/root/bin/orbit/windows/stable/orbit.exe: no such file or directory","time":"2021-10-11T14:44:23-07:00","message":"stat file"}
{"level":"debug","path":"/tmp/orbit-package149266210/root/bin/orbit/windows/stable/orbit.exe","time":"2021-10-11T14:44:24-07:00","message":"got orbit"}
heat.exe : error HEAT0001 : SetThreadErrorMode assembly:<unknown assembly> type:<unknown type> member:(null)

Exception Type: System.EntryPointNotFoundException

Stack Trace:
  at (wrapper managed-to-native) Interop+Kernel32.SetThreadErrorMode(uint,uint&)
  at System.IO.DisableMediaInsertionPrompt.Create () [0x00008] in <3d7a9349295c42b6abb3487b4473a6b8>:0 
  at System.IO.FileSystem.FillAttributeInfo (System.String path, Interop+Kernel32+WIN32_FILE_ATTRIBUTE_DATA& data, System.Boolean returnErrorOnNotFound) [0x0000a] in <3d7a9349295c42b6abb3487b4473a6b8>:0 
  at System.IO.FileSystem.FileExists (System.String fullPath) [0x00008] in <3d7a9349295c42b6abb3487b4473a6b8>:0 
  at System.IO.File.Exists (System.String path) [0x0003d] in <3d7a9349295c42b6abb3487b4473a6b8>:0 
  at System.Configuration.ConfigurationManager.OpenExeConfigurationInternal (System.Configuration.ConfigurationUserLevel userLevel, System.Reflection.Assembly calling_assembly, System.String exePath) [0x00050] in <9dbd70885bbe478dbcc5b41c7b0e0973>:0 
  at System.Configuration.ConfigurationManager.OpenExeConfiguration (System.String exePath) [0x0000f] in <9dbd70885bbe478dbcc5b41c7b0e0973>:0 
  at Microsoft.Tools.WindowsInstallerXml.AppCommon.ReadConfiguration (System.Collections.Specialized.StringCollection extensions) [0x00022] in <13acedad176f4740bcdf107d029f167c>:0 
  at Microsoft.Tools.WindowsInstallerXml.Tools.Heat.Run (System.String[] args) [0x0005d] in <05dc1d4b31e6439dabb75d17e14330a3>:0 
package root files: heat failed: exit status 1
7 Views