Skip to content

Sporadic Errno::EBADF Write  #197

@attilastrba

Description

@attilastrba

Hi guys,
we are using the Gem logging 2.2.2 with Ruby version 2.3.3p222 on a Windows 10 64bit system. We have a framework where a java application is executed from ruby by spawning the process and the STDOUT is captured in an appender.

The problem is that occesionaly we get a EBADF Write error during execution.

Rspec/elite/output/PrepareDut/FlashMate.log
19:31:01 [2018-06-01 19:31:01] DEBUG EliteProcess: Starting process: 'java -jar D:/workspace/Test-Release/Bsp-Test-Low-Gen3.0-Rspec/elite/output/flashmate.jar flash -o D:/workspace/Test-Release/Bsp-Test-Low-Gen3.0-Rspec/elite/output/artifact/ReleaseLow-Gen3.0/FL_4K0907468_N1xx___E.odx --partial'
19:31:01 [2018-06-01 19:31:01] DEBUG EliteProcess: Waiting for 'java' to end within 600 seconds
19:32:05 C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/appenders/io.rb:73:in `write': Bad file descriptor @ io_write - D:/workspace/Test-Release/Bsp-Test-Low-Gen3.0-Rspec/elite/output/PrepareDut/FlashMate.log (Errno::EBADF)
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/appenders/io.rb:73:in `canonical_write'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/appenders/buffering.rb:285:in `write'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/appender.rb:81:in `append'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/logger.rb:397:in `block in log_event'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/logger.rb:397:in `each'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/logger.rb:397:in `log_event'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/logger.rb:92:in `debug'
19:32:05 	from D:/workspace/Test-Release/Bsp-Test-Low-Gen3.0-Rspec/elite/lib/elite/tools/flashmate.rb:73:in `block in execute'
19:32:05 	from D:/workspace/Test-Release/Bsp-Test-Low-Gen3.0-Rspec/elite/lib/elite/process.rb:163:in `block (2 levels) in process_stdout'
19:32:05 	from D:/workspace/Test-Release/Bsp-Test-Low-Gen3.0-Rspec/elite/lib/elite/process.rb:162:in `each'
19:32:05 	from D:/workspace/Test-Release-/Bsp-Test-Low-Gen3.0-Rspec/elite/lib/elite/process.rb:162:in `block in process_stdout'
19:32:05 	from C:/Tools/Ruby23/lib/ruby/gems/2.3.0/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
19:32:15 Process leaked file descriptors. See https://jenkins.io/redirect/troubleshooting/process-leaked-file-descriptors for more information

Could anyone point me to the direction why this could happen? Thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions