[ZBX-2203] Zabbix Agent add unnecessary EOL symbols on reading windows eventlog (spaces on start and end of each line wrongly converted to \r\n). Created: 2010 Mar 21  Updated: 2017 May 30  Resolved: 2010 Aug 06

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Agent (G)
Affects Version/s: 1.8.1
Fix Version/s: 1.8.3, 1.9.0 (alpha)

Type: Incident report Priority: Major
Reporter: Oleksii Zagorskyi Assignee: Unassigned
Resolution: Fixed Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows XP SP3, 20003 R2 SP2 RUS, ENG


Attachments: PNG File Thanks._now_all_fine_with_EOL.png     PNG File history_multiline_bug.png     Text File history_multiline_bug.txt    

 Description   

??? ????????? ???????? ??????? Windows ???? ????????, ??? ????????? ??????? ???????? ?????? ???????? ?????. ? ?????????? ??? ??????????? ? ??????? ???? ??????? ????? ???????? ?? ?????? ? ??? ???? ?????? ????? ??? ????????, ??? ???????????? ??????????? ?? ????????? ????????? ???????.
???????? ??? ??????? ??? ????????? ??????? ???????? ????????????, ?????? ??? ??? ?????????? ????? ?????? ?????? ??????????? ?????? ??????? ??????.

?????????? ??????? ?????? ??????? ? ?????? ? ?????, ??? ?????? ?????? ???????, ??????? ????????? ? ????? ??? ?????? ?????? ?????? ????????????????? ? ?????? ????? ??????.
??? ?????? ????? ???? ? ?????? ???? ???????? ?????????? 4. ????? ??? ??????????? ??????? \r\n ? ???????? ???????.

?????? ??? ????.
??????????? ???????? ??????? ??? ????????? ? ??? ?? ????????? ????? ?? ??????? (?????? ??????? ?????????). ? ??????? ???? ??????? ?????? ? ????? ?????, ?? ????????? ??? ??? ???????? ? ???????? ? ?????? ?????.

??? ???????: ??????????????
???????? ???????: NETLOGON
????????? ???????: ???????????
??? ???????: 5781
????: 17.03.2010
?????: 17:44:38
????????????: ?/?
?????????: XXXX
????????:
?????? ??? ???????????? ??????????? ??? ???????? ????? ??? ?????????? ??????? DNS, ????????? ? ??????? DNS "XXXX.XXXX.XXXX.XXXX.". ??? ?????? ???????????? ??????? ???????????? ??? ?????? ??????? ??????? ??? ??????????? ?????? (???? ?????? ????? Active Directory) ??? ??? ??????? LDAP (???? ????????? ????? ???????? ???????? ??????????).

????????? ??????? ??????:

  • ? ????????? TCP/IP ??????? ??????????? ??????? ?????????? ?????????? ???????? IP-?????? ??????????????? ? ??????????????? DNS-????????
  • ????????? ???????????????? ? ?????????????? DNS-??????? ?? ????????
  • DNS-???????, ?????????? ????????? ??? ?????????????? ???????, ?? ????????
  • ?????????????? ??? ?????????????? DNS-?????? ???????? ? ?????????????? ???????? ???????? ??????
  • ???????????? ???? DNS ???????? ???????????? ????????????? ? ???????? ????, ??????????? ??? ??????? DNS, ?? ????????? ???????????

???????? ????????????
????????? ?????? ????????? ? ??????????? ??????????? ??? ???????? ??????? DNS, ???????? ????????? "nltest.exe /dsregdns" ? ????????? ?????? ??? ???????????? ?????? ????? ? ?????. ????????? Nltest.exe ??????? ?? ???????-??? "???????? ???????? Microsoft Windows Server".



 Comments   
Comment by Oleksii Zagorskyi [ 2010 Mar 21 ]

К сожалению при вставке текста события в описание удалились лишние пробелы в конце строк, поэтому смотрите вложенный текстовый файл (кодировка Win-1251)

Comment by Oleksii Zagorskyi [ 2010 Aug 06 ]

Tested /branches/dev/zbx-2807-subject-newlines revision 13802.
Now all fine.
Thanks again. See picture

Comment by Aleksandrs Saveljevs [ 2010 Aug 06 ]

Fixed in pre-1.8.3 in r13823.

Comment by Oleksii Zagorskyi [ 2010 Aug 06 ]

Please, recompile new windows agents for trunk and branche.

Comment by Aleksandrs Saveljevs [ 2010 Aug 06 ]

Available in pre-1.8.3 in r13828 and in trunk in r13829. Enjoy and thanks for testing!

Comment by Oleksii Zagorskyi [ 2010 Aug 06 ]

Aleksandrs,
binary from trunk repo:
>zabbix_agentd.exe -V
Zabbix Agent Win32 (service) v1.8.3rc3 (revision

{ZABBIX_REVISION}

) (2 August 2010)
Compilation time: Aug 6 2010 01:55:37

Now binaries (r13828-13829) windows agent from trunk and branches repo are exactly the same!
I need truly !!! trunk binary. Please.

Comment by Aleksandrs Saveljevs [ 2010 Aug 06 ]

Oops, sorry! The trunk binaries are available in r13833.

Comment by Aleksandrs Saveljevs [ 2010 Aug 06 ]

Oleksiy, I do not think we have it documented anywhere how to build Windows binaries.

We will document it someday. Meanwhile, whenever you need Windows binaries, you can do the following:

  • Install Microsoft Windows SDK with examples.
  • The agent needs afxres.h and winres.h to build and the SDK does not have these headers by default. To solve this, go to the examples directory, grab these header files and put them into the SDK's main include directory.
  • From the SDK command prompt, go to the directory build\win32\project from svn checkout. Type "nmake /f Makefile_agent" and that should build the agent binary. Similarly, you can do with zabbix_get and zabbix_sender.

Let me know if you have any questions.

Comment by Lionel [ 2011 Apr 06 ]

Hello,
Because of a special network configuration, i have to disable the security check in listener.c file which checks if the server is listed in the configuration file.

So, I have to recompile the windows binaries. (OK for linux)

  • I installed Windows SDK and copied afxres.h and winres.h files into the includes directory.
  • I tried to compile with the command "nmake /f Makefile_agent" but it failed: "
    mc.exe -U -s -h ".
    " -r ".
    " messages.mc
    mc : error : 0x7b trying to open file <.\>.
    NMAKE : fatal error U1077: '"C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\mc
    .exe"' : code retour '0x1'
    Stop."
  • So, I tried with the command: "nmake /I /f Makefile_agent":
    mt.exe /outputresource:"..\..\..\bin\win32\zabbix_agentd.exe;#1" /manife
    st zabbix_agentd.exe.manifest /nologo

zabbix_agentd.exe.manifest : general error c1010070: Failed to load and parse th
e manifest.

Can you help me?

Thanks in advance

Generated at Sun Jun 29 06:05:58 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.