采集云服务器ECS日志

<p class="shortdesc">本文主要介绍如何采集并查看云服务器ECS的日志,并介绍如何设置告警规则,触发告警后,系统通过邮件通知用户异常信息。</p> <section class="section prereq" id="ECS_Log__prereq_n22_5rb_vmb"><div class="tasklabel"><h2 class="doc-tairway">前提条件</h2></div> <ul class="ul" id="ECS_Log__ul_gdq_5rb_vmb"> <li class="li">用户需要开通日志服务,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/Pricing.Buy" target="_blank">购买流程</a>。</li> <li class="li">您已购买一台ECS云服务器。</li> </ul> </section> <section class="section limitation" id="ECS_Log__xkx_qrb_vmb"><div class="tasklabel"><h2 class="doc-tairway">使用限制</h2></div> <p class="p">创建索引的地域,请与待采集日志的ECS服务器所在地域保持一致。</p> </section> <section><div class="tasklabel"><h2 class="doc-tairway">操作步骤</h2></div><ol class="ol steps"><li class="li step stepexpand" id="ECS_Log__step_jpn_kqy_wmb"> <span class="ph cmd"> 登录<a class="xref" href="/console/logcloud/indexed/list" target="_blank">日志服务管理控制台</a>。</span> </li><li class="li step stepexpand"> <span class="ph cmd">单击左侧导航栏<span class="ph uicontrol">索引管理</span>,进入<span class="keyword wintitle">索引列表</span>页面。</span> </li><li class="li step stepexpand"> <span class="ph cmd">选择目标地域,单击页面右上角<span class="ph uicontrol">创建索引</span>,进入<span class="keyword wintitle">创建索引</span>页面,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/User_Guide.Collect.Indexed.Create_Index" target="_blank">创建索引</a>页面的详细信息,创建索引。</span> <div class="itemgroup info"> <img class="image" id="ECS_Log__image_kmx_3sb_vmb" src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20210106133705-1da1cb289df2.png" width="830"> </div> </li><li class="li step stepexpand"> <span class="ph cmd">单击左侧导航栏<span class="ph uicontrol">项目管理</span>,进入<span class="keyword wintitle">项目列表</span>页面。</span> </li><li class="li step stepexpand"> <span class="ph cmd">选择目标地域后,点击页面右上角<span class="ph uicontrol">创建项目</span>,进入<span class="keyword wintitle">创建项目</span>页面,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/User_Guide.Collect.Project.Create_Project" target="_blank">创建项目</a>页面的详细信息,创建项目。</span> <div class="itemgroup info"> <img class="image" id="ECS_Log__image_qjj_b4y_wmb" src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20210106133705-168efc079014.png" width="830"> </div> </li><li class="li step stepexpand"> <span class="ph cmd">单击左侧导航栏的<span class="ph uicontrol">项目管理</span>,进入<span class="keyword wintitle">项目列表</span>页面。</span> </li><li class="li step stepexpand"> <span class="ph cmd">选在目标地域,单击目标项目的名称。</span> </li><li class="li step stepexpand"> <span class="ph cmd">单击<span class="ph uicontrol">AGENT主机组</span>页签。</span> </li><li class="li step stepexpand"> <span class="ph cmd">单击页签右上角的<span class="ph uicontrol">创建主机组</span>,进入<span class="keyword wintitle">创建主机组</span>页面,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/User_Guide.Collect.Agent_Group.Create_Agent_Group" target="_blank">创建主机组</a>页面的详细信息,创建主机组。</span> <div class="itemgroup info"> <img class="image" id="ECS_Log__image_emh_h4y_wmb" src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20210106133705-140a174794d0.png" width="830"> </div> </li><li class="li step stepexpand"> <span class="ph cmd">单击<span class="ph uicontrol">AGENT配置</span>页签。</span> </li><li class="li step stepexpand"> <span class="ph cmd">单击页面右上角<span class="ph uicontrol">创建配置</span>,进入<span class="keyword wintitle">创建配置</span>页面,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/User_Guide.Collect.Collect_Strategy.Create_Strategy" target="_blank">创建通用采集策略</a>页面的详细信息,创建通用采集策略。</span> </li><li class="li step stepexpand"> <span class="ph cmd">查询日志。</span> <div class="itemgroup info"> <ol class="ol" type="a" id="ECS_Log__ol_unp_44y_wmb"> <li class="li">单击左侧导航栏<span class="ph uicontrol">日志搜索</span>,进入<span class="keyword wintitle">日志搜索</span>页面。</li> <li class="li">设置自定义出查询条件,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/User_Guide.Search.Search_Log" target="_blank">查询日志</a>页面的详细信息,查询日志。<img class="image" id="ECS_Log__image_pzb_r4y_wmb" src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20210106133705-175f6897903f.png" width="830"></li> </ol> </div> </li><li class="li step stepexpand"> <span class="ph cmd">设置告警。</span> <div class="itemgroup info"> <ol class="ol" type="a" id="ECS_Log__ol_itn_s4y_wmb"> <li class="li">单击左侧导航栏<span class="ph uicontrol">告警管理</span>,进入<span class="keyword wintitle">告警列表</span>页面。</li> <li class="li"> 选择目标地域,单击页面右上角<span class="ph uicontrol">创建告警</span>,进入<span class="keyword wintitle">创建告警</span>页面,可参考<a class="xref" href="/ssr/help/middleware/LogCloud/User_Guide.Alarm.Create_Alarm" target="_blank">创建告警</a>页面的详细信息,创建告警。<img class="image" id="ECS_Log__image_o5q_54y_wmb" src="https://obs-cn-shanghai.yun.pingan.com/pcp-portal/20210106133703-197ba2839cf8.png" width="830"></li> </ol> </div> </li></ol></section>
以上内容是否解决了您的问题?
请补全提交信息!
咨询·建议

电话咨询 - 7x24 小时

400-151-8800

邮件咨询

cloud@pingan.com

在线客服

7x24 小时,急速解答

工单支持

解决云产品相关技术问题