DTraceProviderBindings error when interacting with Triton Object Storage (Manta) from shell

Travis Paul -

After installing the Triton Object Storage (Manta) module in a SmartOS infrastructure container, you may see error messages when using the manta commands such as mls, mput, and mget:

$ mls ~~
{ Error: Cannot find module './build/Release/DTraceProviderBindings'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object. (/opt/local/lib/node_modules/manta/node_modules/dtrace-provider/dtrace-provider.js:17:23)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3) code: 'MODULE_NOT_FOUND' }
{ Error: Cannot find module './build/default/DTraceProviderBindings'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object. (/opt/local/lib/node_modules/manta/node_modules/dtrace-provider/dtrace-provider.js:17:23)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3) code: 'MODULE_NOT_FOUND' }
{ Error: Cannot find module './build/Debug/DTraceProviderBindings'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object. (/opt/local/lib/node_modules/manta/node_modules/dtrace-provider/dtrace-provider.js:17:23)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3) code: 'MODULE_NOT_FOUND' }
{ Error: Cannot find module './build/Release/DTraceProviderBindings'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object. (/opt/local/lib/node_modules/manta/node_modules/restify-clients/node_modules/dtrace-provider/dtrace-provider.js:17:23)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3) code: 'MODULE_NOT_FOUND' }
{ Error: Cannot find module './build/default/DTraceProviderBindings'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object. (/opt/local/lib/node_modules/manta/node_modules/restify-clients/node_modules/dtrace-provider/dtrace-provider.js:17:23)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3) code: 'MODULE_NOT_FOUND' }
{ Error: Cannot find module './build/Debug/DTraceProviderBindings'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object. (/opt/local/lib/node_modules/manta/node_modules/restify-clients/node_modules/dtrace-provider/dtrace-provider.js:17:23)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3) code: 'MODULE_NOT_FOUND' }
jobs/
public/
reports/
stor/

The most common cause for this error is a build failure with the dtrace-provider module. You may see the following when running npm install -g manta:

Building dtrace-provider failed with exit code 1 and signal 0
re-run install with environment variable V set to see the build output

Re-installing manta with the environment variable V set, you will see more information about the errors:

$ export V=1
$ npm rm -g manta
$ npm install -g manta
gyp ERR! build error
gyp ERR! stack Error: not found: make
gyp ERR! stack     at getNotFoundError (/opt/local/lib/node_modules/npm/node_modules/which/which.js:14:12)
gyp ERR! stack     at F (/opt/local/lib/node_modules/npm/node_modules/which/which.js:69:19)
gyp ERR! stack     at E (/opt/local/lib/node_modules/npm/node_modules/which/which.js:81:29)
gyp ERR! stack     at /opt/local/lib/node_modules/npm/node_modules/which/which.js:90:16
gyp ERR! stack     at /opt/local/lib/node_modules/npm/node_modules/which/node_modules/isexe/index.js:44:5
gyp ERR! stack     at /opt/local/lib/node_modules/npm/node_modules/which/node_modules/isexe/access.js:8:5
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:111:15)
gyp ERR! System SunOS 5.11
gyp ERR! command "/opt/local/bin/node" "/opt/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /opt/local/lib/node_modules/manta/node_modules/dtrace-provider
gyp ERR! node -v v7.2.1
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

As you can see from the error above, node-gyp is unable to locate the make command.

To avoid this error, ensure that you have both gcc and gmake installed before installing the manta module:

$ pkgin search gmake
reading local summary...	
processing local summary...
pkg_summary.xz                                                                    100% 2077KB 188.9KB/s  29.5KB/s   00:11
gmake-4.1nb3         GNU version of 'make' utility

=: package is installed and up-to-date
<: package is installed but newer version is available
>: installed package has a greater version than available package

As we can see above, gmake is not installed, so you must install it with:

$ pkgin -y install gmake

Now check for gcc:

$ pkgin search gcc
gcc49-libs-4.9.4nb1 = The GNU Compiler Collection (GCC) support shared libraries
gcc49-4.9.4          The GNU Compiler Collection (GCC) - 4.9 Release Series

=: package is installed and up-to-date
<: package is installed but newer version is available
>: installed package has a greater version than available package

The runtime for gcc49 is already installed (gcc49-libs-4.9.4nb1), so we want to also install gcc49. If another version of gcc-libs is installed, install the corresponding gcc version:

$ pkgin -y install gcc49

Now you can build the dtrace-provider module and you will no longer see the errors when using the manta commands:

$ npm rm -g manta
$ npm install -g manta
$ mls ~~
jobs/
public/
reports/
stor/
Have more questions? Submit a request

0 Comments

Article is closed for comments.