Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dev.icinga.com #5787] Permissions error on startup is only logged but not on stderr #1312

Closed
icinga-migration opened this issue Mar 17, 2014 · 12 comments
Labels
bug Something isn't working
Milestone

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/5787

Created by mfriedrich on 2014-03-17 16:13:19 +00:00

Assignee: gvegidy
Status: Closed (closed on 2014-06-13 11:17:11 +00:00)
Target Version: 2.0.0
Last Update: 2014-06-13 11:17:11 +00:00 (in Redmine)

Icinga Version: 0.0.8-26-ga066cbf

error.log is chowned to icinga:icingacmd within the init script, but the other logs are not (while testing as root in foreground).

Either fix permissions, or increase verbosity during startup (not piping stdout/stderr too soon to logfiles).

Caught unhandled exception.
Current time: 2014-03-17 17:09:18 +0100

***
* Application version: v0.0.8-26-ga066cbf
* Installation root: /usr
* Sysconf directory: /etc
* Local state directory: /var
* Package data directory: /usr/share/icinga2
* State path: /var/lib/icinga2/icinga2.state
* PID path: /var/run/icinga2/icinga2.pid
* Application type: icinga/IcingaApplication
***

/home/michi/coding/icinga/icinga2/lib/base/application.cpp(577): Throw in function void icinga::Application::UpdatePidFile(const icinga::String&)
Dynamic exception type: boost::exception_detail::clone_impl >
std::exception::what: Could not open PID file '/var/run/icinga2/icinga2.pid'
[icinga::StackTrace*] = 
        (0) libbase.so: void boost::throw_exception >(boost::exception_detail::error_info_injector const&) (+0x72) [0x7f16bc1688aa] (throw_exception.hpp:67 (discriminator 2))
        (1) libbase.so: void boost::exception_detail::throw_exception_(std::runtime_error const&, char const*, char const*, int) (+0xb6) [0x7f16bc165925] (throw_exception.hpp:84 (discriminator 1))
        (2) libbase.so: icinga::Application::UpdatePidFile(icinga::String const&) (+0x161) [0x7f16bc15e1e9] (application.cpp:580)
        (3) libbase.so: icinga::Application::Run() (+0xb2) [0x7f16bc15dedc] (application.cpp:525 (discriminator 1))
        (4) icinga2: main (+0x20b6) [0x471603] (??:0)
        (5) libc.so.6: __libc_start_main (+0xf5) [0x7f16ba121b45] (libc-start.c:321)
        (6) /usr/sbin/icinga2() [0x46e389]


[icinga::ContextTrace*] = 


***
* This would indicate a runtime problem or configuration error. If you believe this is a bug in Icinga 2
* please submit a bug report at https://dev.icinga.org/ and include this stack trace as well as any other
* information that might be useful in order to reproduce this problem.
***

nbmif /etc/icinga2 (master) # ls -la /var/log/icinga2
insgesamt 100M
drwxr-x---  3 icinga icingacmd 4,0K Mär 15 07:42 ./
drwxr-xr-x 28 root   root      4,0K Mär 17 08:01 ../
drwxr-xr-x  3 icinga icinga    4,0K Mär 14 17:00 compat/
-rw-r--r--  1 root   root       13K Mär 17 17:07 debug.log
-rw-r--r--  1 root   root      2,2M Mär 15 07:42 debug.log.1
-rw-r--r--  1 root   root      2,1M Mär 14 07:55 debug.log.2.gz
-rw-------  1 icinga icinga     19K Mär 17 17:08 error.log
-rw-------  1 icinga icinga    4,5K Feb 11 07:44 error.log.1
-rw-------  1 icinga icinga     25K Jan 14 17:20 error.log-20140114
-rw-------  1 icinga icinga    1,3K Feb  7 07:54 error.log.2.gz
-rw-------  1 icinga icinga    1,1K Feb  5 08:04 error.log.3.gz
-rw-------  1 icinga icinga    1,2K Jan 29 07:48 error.log.4.gz
-rw-------  1 icinga icinga    1017 Jan 22 08:04 error.log.5.gz
-rw-r--r--  1 root   root       93M Mär 11 12:05 icinga2b.log
-rw-r--r--  1 root   root      1,6K Mär 17 17:07 icinga2.log
-rw-r--r--  1 root   root      621K Mär 15 07:42 icinga2.log.1
-rw-r--r--  1 root   root      179K Feb 14 07:49 icinga2.log.10.gz
-rw-r--r--  1 root   root      434K Feb 13 07:38 icinga2.log.11.gz
-rw-r--r--  1 root   root      603K Feb 12 08:04 icinga2.log.12.gz
-rw-r--r--  1 root   root      533K Feb 11 07:44 icinga2.log.13.gz
-rw-r--r--  1 root   root       12K Mär 14 07:55 icinga2.log.2.gz
-rw-r--r--  1 root   root       26K Mär 13 07:49 icinga2.log.3.gz
-rw-r--r--  1 root   root       475 Mär 12 07:48 icinga2.log.4.gz
-rw-r--r--  1 root   root      5,7K Mär 11 07:46 icinga2.log.5.gz
-rw-r--r--  1 root   root       271 Mär  8 07:46 icinga2.log.6.gz
-rw-r--r--  1 root   root      194K Mär  5 07:51 icinga2.log.7.gz
-rw-r--r--  1 root   root      515K Mär  4 07:46 icinga2.log.8.gz
-rw-r--r--  1 root   root       66K Feb 20 09:53 icinga2.log.9.gz

Changesets

2014-03-17 17:06:23 +00:00 by (unknown) cf3f0ea

Chown log/pid on startup.

Refs #5787

Relations:

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-03-17 16:14:42 +00:00

Same for the pid file.

Caught unhandled exception.
Current time: 2014-03-17 17:14:07 +0100

***
* Application version: v0.0.8-26-ga066cbf
* Installation root: /usr
* Sysconf directory: /etc
* Local state directory: /var
* Package data directory: /usr/share/icinga2
* State path: /var/lib/icinga2/icinga2.state
* PID path: /var/run/icinga2/icinga2.pid
* Application type: icinga/IcingaApplication
***

/home/michi/coding/icinga/icinga2/lib/base/application.cpp(577): Throw in function void icinga::Application::UpdatePidFile(const icinga::String&)
Dynamic exception type: boost::exception_detail::clone_impl >
std::exception::what: Could not open PID file '/var/run/icinga2/icinga2.pid'
[icinga::StackTrace*] = 
        (0) libbase.so: void boost::throw_exception >(boost::exception_detail::error_info_injector const&) (+0x72) [0x7f5e81ec28aa] (throw_exception.hpp:67 (discriminator 2))
        (1) libbase.so: void boost::exception_detail::throw_exception_(std::runtime_error const&, char const*, char const*, int) (+0xb6) [0x7f5e81ebf925] (throw_exception.hpp:84 (discriminator 1))
        (2) libbase.so: icinga::Application::UpdatePidFile(icinga::String const&) (+0x161) [0x7f5e81eb81e9] (application.cpp:580)
        (3) libbase.so: icinga::Application::Run() (+0xb2) [0x7f5e81eb7edc] (application.cpp:525 (discriminator 1))
        (4) icinga2: main (+0x20b6) [0x471603] (??:0)
        (5) libc.so.6: __libc_start_main (+0xf5) [0x7f5e7fe7bb45] (libc-start.c:321)
        (6) /usr/sbin/icinga2() [0x46e389]


[icinga::ContextTrace*] = 


***
* This would indicate a runtime problem or configuration error. If you believe this is a bug in Icinga 2
* please submit a bug report at https://dev.icinga.org/ and include this stack trace as well as any other
* information that might be useful in order to reproduce this problem.
***

@icinga-migration
Copy link
Author

Updated by gvegidy on 2014-03-17 17:21:04 +00:00

I'd say this is also related to #5666.
Unfortunately I don't have the permissions to add that into the correct field in the bugtracker.

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-03-17 17:28:53 +00:00

That's left for reporters/developers in redmine permissions. Maybe you should just apply for the team then.

@icinga-migration
Copy link
Author

Updated by gvegidy on 2014-03-17 17:36:33 +00:00

don't know if I qualify for that, that is your decision.

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-03-17 17:41:33 +00:00

Not really. Everyone who thinks he/she may qualify may send their proposal including a short introduction, why and what. Using the contact form, or directly at info@i.o - that's a team decision, not mine or any individual's.

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-03-31 12:14:23 +00:00

  • Target Version changed from 0.0.9 to 0.0.10

@icinga-migration
Copy link
Author

Updated by gbeutner on 2014-04-11 11:19:45 +00:00

  • Assigned to changed from mfriedrich to gvegidy

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-04-29 12:14:09 +00:00

  • Target Version changed from 0.0.10 to 0.0.11

@icinga-migration
Copy link
Author

Updated by gbeutner on 2014-05-16 09:45:33 +00:00

  • Target Version changed from 0.0.11 to 2.0 Beta 1

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-05-26 15:46:32 +00:00

  • Target Version changed from 2.0 Beta 1 to 2.0 Beta 2

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-06-06 08:52:30 +00:00

  • Target Version changed from 2.0 Beta 2 to 2.0.0

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2014-06-13 11:17:11 +00:00

  • Status changed from Assigned to Closed
  • Done % changed from 0 to 100

Cannot reproduce this, and the permission logging has been enhanced in #6070, so this should be resolved anyway.

@icinga-migration icinga-migration added bug Something isn't working libicinga labels Jan 17, 2017
@icinga-migration icinga-migration added this to the 2.0.0 milestone Jan 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant