SystemCallError (Unknown error - Unknown Error (0) - /home/ubuntu/.netrc)


#1

All,

I get the error below when running snowplow-emr-etl-runner on EC2 Ubuntu 14.04.4 LTS. I downloaded the file from $ wget http://dl.bintray.com/snowplow/snowplow-generic/snowplow_emr_r77_great_auk.zip and JRuby is not install on the machine.

SystemCallError (Unknown error - Unknown Error (0) - /home/ubuntu/.netrc):
    org/jruby/RubyFile.java:872:in `stat'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/netrc-0.10.3/lib/netrc.rb:43:in `check_permissions'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/netrc-0.10.3/lib/netrc.rb:52:in `read'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient/request.rb:284:in `parse_url_with_auth'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient/request.rb:175:in `execute'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient/request.rb:41:in `execute'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient.rb:69:in `post'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/elasticity-6.0.7/lib/elasticity/aws_session.rb:29:in `submit'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/elasticity-6.0.7/lib/elasticity/emr.rb:302:in `run_job_flow'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/elasticity-6.0.7/lib/elasticity/job_flow.rb:151:in `run'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/emr-etl-runner/lib/snowplow-emr-etl-runner/emr_job.rb:445:in `run'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/method_reference.rb:46:in `send_to'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts.rb:305:in `call_with'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/decorators.rb:159:in `common_method_added'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/emr-etl-runner/lib/snowplow-emr-etl-runner/runner.rb:68:in `run'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/method_reference.rb:46:in `send_to'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts.rb:305:in `call_with'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/decorators.rb:159:in `common_method_added'
    file:/home/ubuntu/bin/snowplow-emr-etl-runner!/emr-etl-runner/bin/snowplow-emr-etl-runner:39:in `(root)'
    org/jruby/RubyKernel.java:1091:in `load'
    file:/home/ubuntu/bin/snowplow-emr-etl-runner!/META-INF/main.rb:1:in `(root)'
    org/jruby/RubyKernel.java:1072:in `require'
    file:/home/ubuntu/bin/snowplow-emr-etl-runner!/META-INF/main.rb:1:in `(root)'
    /tmp/jruby5329677097345708508extract/jruby-stdlib-1.7.20.1.jar!/META-INF/jruby.home/lib/ruby/shared/rubygems/core_ext/kernel_require.rb:1:in `(root)'

Creating an empty .netrc file in the home directory and running snowplow-emr-etl-runner results in this error:

Netrc::Error (Permission bits for '/home/ubuntu/.netrc' should be 0600, but are 644):
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/netrc-0.10.3/lib/netrc.rb:45:in `check_permissions'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/netrc-0.10.3/lib/netrc.rb:52:in `read'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient/request.rb:284:in `parse_url_with_auth'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient/request.rb:175:in `execute'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient/request.rb:41:in `execute'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/rest-client-1.8.0/lib/restclient.rb:69:in `post'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/elasticity-6.0.7/lib/elasticity/aws_session.rb:29:in `submit'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/elasticity-6.0.7/lib/elasticity/emr.rb:302:in `run_job_flow'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/elasticity-6.0.7/lib/elasticity/job_flow.rb:151:in `run'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/emr-etl-runner/lib/snowplow-emr-etl-runner/emr_job.rb:445:in `run'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/method_reference.rb:46:in `send_to'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts.rb:305:in `call_with'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/decorators.rb:159:in `common_method_added'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/emr-etl-runner/lib/snowplow-emr-etl-runner/runner.rb:68:in `run'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/method_reference.rb:46:in `send_to'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts.rb:305:in `call_with'
    /home/ubuntu/bin/snowplow-emr-etl-runner!/gems/contracts-0.7/lib/contracts/decorators.rb:159:in `common_method_added'
    file:/home/ubuntu/bin/snowplow-emr-etl-runner!/emr-etl-runner/bin/snowplow-emr-etl-runner:39:in `(root)'
    org/jruby/RubyKernel.java:1091:in `load'
    file:/home/ubuntu/bin/snowplow-emr-etl-runner!/META-INF/main.rb:1:in `(root)'
    org/jruby/RubyKernel.java:1072:in `require'
    file:/home/ubuntu/bin/snowplow-emr-etl-runner!/META-INF/main.rb:1:in `(root)'
    /tmp/jruby1491907905184404293extract/jruby-stdlib-1.7.20.1.jar!/META-INF/jruby.home/lib/ruby/shared/rubygems/core_ext/kernel_require.rb:1:in `(root)'

Changing the permissions (chmod 0600 .netrc) has no effect.

I’ve tried installing jruby with no effect. I appreciate you guidance.


#2

Hi @romanumero - there was a previous thread with a similar issue in our pre-Discourse group, here: https://groups.google.com/forum/#!msg/snowplow-user/nQLgrCE8nQs/z0CIWibhEAAJ

From that thread, it looks like the problem might be an old version of JRuby clashing with the JRuby used for EmrEtlRunner. Let us know that if the linked thread is helpful in any way…


#3

Hi romanumero,

I have exactly the same issue. Just wondering if you were able to get it to work?

Thanks.