You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2020/05/20 10:25:04 UTC

[GitHub] [cloudstack] soreana opened a new issue #4093: Centralised logging via rsyslog

soreana opened a new issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093


   ##### ISSUE TYPE
    * Feature Idea
   
   ##### COMPONENT NAME
   ~~~
   Systemvm
   ~~~
   
   ##### CLOUDSTACK VERSION
   ~~~
   It can be merge to 4.14
   ~~~
   
   ##### CONFIGURATION
   <!--
   Information about the configuration if relevant, e.g. basic network, advanced networking, etc.  N/A otherwise
   -->
   
   
   ##### OS / ENVIRONMENT
   Used Ubuntu 18:04 as a host for management server and KVM Hypervisor.
   
   ##### SUMMARY
   
   As a Cloudstack team, we want to propose centralised logging feature. It enabled us to access systemvm's log file through management server. We think it would be interesting for other as well. To better explaining our setup I depicted the configuration in below picture.
   
   ![Cloudstack Centralized logging-2](https://user-images.githubusercontent.com/9499410/82427752-cdabb200-9a89-11ea-8e8e-c4eb0744076f.png)
   
   In this case rather than downloading log file manually from systemvms, they will be available automatically through management server.
   
   ### STEPS TO REPRODUCE
   
   Below are configuration files for hypervisor, management server and sytemvms.
   
   #### Hypervisors
   
   Below 4 lines have to uncommented in rsyslog configuration file on each hypervisor in `/etc/rsyslog.conf`
   
   ```Python
   module(load="imtcp")
   input(type="imtcp" port="514")
   
   module(load="imudp")
   input(type="imudp" port="514")
   ```
   
   Adding below file on each hypervisor to export logs from hypervisor to management server.
   
   ```Java
   # cat /etc/rsyslog.d/00-fwd.conf
   if ($fromhost-ip startswith '10.' or $fromhost-ip startswith '172.' or $fromhost-ip startswith '169.') then {
       *.* @<Management Server IP>:514
       stop
   }
   ```
   
   #### Management Server
   
   Just like hypervisors, below 4 lines have to uncommented in rsyslog configuration file on management server in `/etc/rsyslog.conf`
   
   ```Python
   module(load="imtcp")
   input(type="imtcp" port="514")
   
   module(load="imudp")
   input(type="imudp" port="514")
   ```
   
   Add below file on management server
   
   ```Java
   # cat /etc/rsyslog.d/00-remote.conf
   $template remote-incoming-logs,"/var/log/rsyslog/%HOSTNAME%/syslog"
   $template remote-incoming-logs-combined,"/var/log/rsyslog/remote"
   if ($fromhost-ip startswith '10.' or $fromhost-ip startswith '172.') then ?remote-incoming-logs
   if ($fromhost-ip startswith '10.' or $fromhost-ip startswith '172.') then ?remote-incoming-logs-combined
   & ~ 
   ```
   
   #### Systemvm
   
   `00-fwd.conf` file should add on each systemvm as well to export logs from systemvms to hypervisors.
   
   ```Java
   # cat /etc/rsyslog.d/00-fwd.conf
   *.*  @169.254.0.1:514
   ```
   
   `49-cloud.conf` file should add on each systemvm. This file describes the logs that eventually sent to a management server
   
   ```Java
    # cat /etc/rsyslog.d/49-cloud.conf
   $InputFileName /var/log/cloud.log
   $InputFileTag cloud
   $InputFileStateFile stat-file1-cloud
   $InputFileSeverity info 
   $InputFileFacility local7 
   $InputFilePollInterval 1 
   $InputFilePersistStateInterval 1 
   $InputRunFileMonitor
   ```
    
   Need to uncomment below lines if they are commented in /etc/rsyslog.conf
   
   ```python
   $ModLoad imudp
   $UDPServerRun 3914
   ```
   
   ##### EXPECTED RESULTS
   
   ~~~
   Management server store systemvm's logs in /var/log/rsyslog/<Systemvm's host name>/syslog
   ~~~
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-769756854


   tnx for your efforts @soreana , i'm marking it as unplanned for now, feel free to come back at any time of your convenience.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
rhtyd commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-923717675


   Removing 4.16 milestone as PR has no milestone; let's move this back if the milestone tagging changes.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] soreana commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
soreana commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-923736187


   @rhtyd good  :+1: 
   Sorry for late, we got a lot of issues recently, I can't find a room to work on this pr. Maybe next week 🤞 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-769713695


   @soreana are you still planning for this?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-816560515


   @soreana should/can we mark this for 4.16?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] soreana commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
soreana commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-816562328


   @DaanHoogland When do you planned for 4.16 release?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] soreana commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
soreana commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-816576844


   I asked our PO. We made a story to work on that. :)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] soreana commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
soreana commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-769733352


   @DaanHoogland Honestly, it took a lot of time to apply the changes you required to merging this pr. I discussed it with my colleagues, and we concluded that it isn't our priority now. We focused on other stuff. It is still in our backlog, and we planned to work on it next quarter.
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] soreana commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
soreana commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-769758089


   No, they are legitimate requirements :D


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-769757151


   > @DaanHoogland Honestly, it took a lot of time to apply the changes you required to merging this pr. I discussed it with my colleagues, and we concluded that it isn't our priority now. We focused on other stuff. It is still in our backlog, and we planned to work on it next quarter.
   
   btw, i hope they didn't sound unreasonable!?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-816569188


   this summer somewhere.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rohityadavcloud commented on issue #4093: Centralised logging via rsyslog

Posted by GitBox <gi...@apache.org>.
rohityadavcloud commented on issue #4093:
URL: https://github.com/apache/cloudstack/issues/4093#issuecomment-1003004610


   I think it may be possible via some log4j config?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org