Skip to content

Allow nohup background running #147

@maaaaz

Description

@maaaaz

Hello there,

Currently, on Linux, if you try to run ODD in an unattended way, for instance with nohup, it does not work at all, the following message is returned:

Console input is redirect, maybe it is run inside another host. This could mean that no input will be send/processed.
2025-01-10 20:01:43.705 [WRN] Console input is redirect, maybe it is run inside another host. This could mean that no input will be send/processed.
2025-01-10 20:01:43.751 [ERR] Error processing action
System.UnauthorizedAccessException: Access to the path is denied.
 ---> System.IO.IOException: Bad file descriptor
   --- End of inner exception stack trace ---
   at Interop.ThrowExceptionForIoErrno(ErrorInfo, String, Boolean)
   at Interop.CheckIo(Int64, String , Boolean )
   at Interop.CheckIo(Int32, String , Boolean )
   at System.ConsolePal.Read(SafeFileHandle, Span`1)
   at System.ConsolePal.UnixConsoleStream.Read(Span`1)
   at System.IO.ConsoleStream.Read(Byte[], Int32, Int32)
   at System.IO.StreamReader.ReadBuffer()
   at System.IO.StreamReader.Read()
   at System.IO.SyncTextReader.Read()
   at System.Console.Read()
   at OpenDirectoryDownloader.Command.ProcessConsoleInput(OpenDirectoryIndexer openDirectoryIndexer)
Unhandled exception. System.UnauthorizedAccessException: Access to the path is denied.
 ---> System.IO.IOException: Bad file descriptor
   --- End of inner exception stack trace ---
   at Interop.ThrowExceptionForIoErrno(ErrorInfo, String, Boolean)
   at Interop.CheckIo(Int64, String , Boolean )
   at Interop.CheckIo(Int32, String , Boolean )
   at System.ConsolePal.Read(SafeFileHandle, Span`1)
   at System.ConsolePal.UnixConsoleStream.Read(Span`1)
   at System.IO.ConsoleStream.Read(Byte[], Int32, Int32)
   at System.IO.StreamReader.ReadBuffer()
   at System.IO.StreamReader.Read()
   at System.IO.SyncTextReader.Read()
   at System.Console.Read()
   at OpenDirectoryDownloader.Command.ProcessConsoleInput(OpenDirectoryIndexer openDirectoryIndexer)
   at OpenDirectoryDownloader.Program.Main(String[] args)
   at OpenDirectoryDownloader.Program.<Main>(String[] args)

Could you allow such capacity ?

Cheers!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions