-
Notifications
You must be signed in to change notification settings - Fork 1.2k
[WIP] Centralized logging capability. Follow up on the #4108 #5296
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
base: main
Are you sure you want to change the base?
Conversation
@rhtyd @DaanHoogland @weizhouapache I have added a new global setting to enable/disable the remote logging in system VMs and router VMs. Based on the One option is to leave it as is and let the system administrator be in charge of changes in management servers and nodes. Another option is that cloudstack changes the following files in the management server/agent restart. I prefer to automate the procedure as much as possible, but I don't know how to achieve that. I appreciate any help. Changes in nodes:
module(load="imtcp")
input(type="imtcp" port="514")
module(load="imudp")
input(type="imudp" port="514")
# cat /etc/rsyslog.d/00-fwd.conf
if ($fromhost-ip startswith '169.') then {
*.* @<Management Server IP>:514
stop
} Changes in management servers:
module(load="imtcp")
input(type="imtcp" port="514")
module(load="imudp")
input(type="imudp" port="514")
# 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
& ~ |
@soreana You are asking a rather wide question but let me try;
Most operators will want to make it a different machine than the management server. The IP of the remote logging server should be configurable per target as one can have a rather various cloud topography. An alternative would be to install a pass-through logging server that redirects to a central server, but that is only for the advanced version. I'm pretty sure I didn't answer (all of) your questions but I hope I contributed some. |
2656b15
to
a5c39d5
Compare
@DaanHoogland Thanks for the detailed comment. I have added the following global settings to manage remote logging for console proxy VM, storage VM, and router VM.
I want to change the |
is that a one time change or an on-line configuration? the onetime change should be in the install pacckage for the agent. the online configuration should be a libvirt command (if it is only for KVM) |
@DaanHoogland As a cloudstack admin, I prefer to have the same configuration for hosts as the ones I defined for system VMs. Something Like:
I want to change I think It is better to go with the libvirt command option. I found lot of samples in |
I'm having second thoughts about my use of the phrase "libvirt command" as it is nothing to do with libvirt. It would be a command to be executed by the agent though. maybe the execution at the backend doesn't have to be so different as on the SVMs?? |
@DaanHoogland Honestly, when I tried to change the code to add a libvirt command, I noticed how many changes it requires for such a small task. I searched for other options. I thought it is better to add some fields in agent.properties and modify the mentioned files in agent init process. My idea is to create a new class in Let me know what do you think. |
sounds like a plan @soreana |
… secondary storage.
a5c39d5
to
8c9a8b9
Compare
Hi @${author}, your pull request has merge conflicts. Can you fix the conflicts and sync your branch with the base branch? |
Description
I have created a PR to enable remote logging in system VM and routerVM in the past (PR: #4108, issue: #4093, ML discussion). This is an upgrade to that pr which enable/disable remote logging in systemvm and routervm using
systemvm.remote.logging.enabled
global setting.Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Screenshots (if appropriate):
Refer to PR: #4108 and issue: #4093
How Has This Been Tested?