panel icon indicating copy to clipboard operation
panel copied to clipboard

Add save container output to file

Open deff-dev opened this issue 2 years ago • 5 comments

Is there an existing feature request for this?

  • [X] I have searched the existing issues before opening this feature request.

Describe the feature you would like to see.

I want to add save container output to file, it's feature that will help people when server restated/crashed. They always can check old logs and understand why the server crashed, etc...

Describe the solution you'd like.

After every run/stop, panel saving file with container console output, example file name: output_2022-11-11-04:01:35.log (output_date_time.log)

Additional context to this request.

No response

deff-dev avatar Nov 11 '22 07:11 deff-dev

Most things save a log already. What are you running that doesn't save logs on error/crash

notAreYouScared avatar Nov 12 '22 01:11 notAreYouScared

My idea is to save console logs (output container). For example now at CS:GO I don't understand why crashed server, because don't have last game console logs. And if I want to check yesterday logs (for example game chat at specific time), I can't do it because they don't exist (don't saved). CS:GO have parameter "-condebug" at start line, and implement the feature I need through it, but not every game have it. Now my entrypoint.sh looks like that: image

It's feature exists at LGSM and I know I can add ">> file.log" to file, but think it's not quite right

deff-dev avatar Nov 12 '22 07:11 deff-dev

Most things save a log already. What are you running that doesn't save logs on error/crash

PaperMC. I've had numerous crashes where nothing is logged at all -- no crash-report directory and latest.log abruptly ends. While lots of programs do log, there are also lots of situations where a program will just immediately terminate without getting the chance to write the error to a logfile.

I think that saving container output would be a great feature. For space concerns, just saving the last few hundred lines would be sufficient too.

ItzDerock avatar Oct 22 '23 17:10 ItzDerock

I support this.

FYI, you can use another logger like journald instead which preserves the logs, but you have to ssh to the server to see them.

bergice avatar May 13 '24 04:05 bergice

i have the same problem please add this feature

Radiirgummii avatar Jul 30 '24 16:07 Radiirgummii