On Tue, Sep 6, 2011 at 8:14 PM, Niels Baggesen 
<[email protected]>wrote:

> Den 01-09-2011 17:25, Niels Baggesen skrev:
> > First off it fixes the compile.
> >
> > This was a quick warning of a problem. I will see if I can set up a
> > MySQL server to test, unless some of you have a working setup ...
>
> Right, having set up a test environment under CentOS 5, the patch is as
> follows:
>
> diff --git a/README.sql b/README.sql
> index e2f7038..95cfc87 100644
> --- a/README.sql
> +++ b/README.sql
> @@ -12,6 +12,9 @@ The MySQL database location and password must be
> configured i
>         password=sql
>
>  User may also be configured, if using a MySQL user besides root.
> +WARNING: Some versions of MySQL (5.0 with CentOS 5) may require
> +an additional dummy parameter (x=y), otherwise the last parameter
> +in .my.cnf may be ignored.
>
>  snmptrapd.conf must be configured to for the queue size and
>  periodic flush interval:
> diff --git a/apps/snmptrapd_sql.c b/apps/snmptrapd_sql.c
> index c7433dc..59dfa6c 100644
> --- a/apps/snmptrapd_sql.c
> +++ b/apps/snmptrapd_sql.c
> @@ -437,7 +437,7 @@ netsnmp_mysql_init(void)
>           return -1;
>      }
>
> -    MY_INIT("snmptrapd");
> +    my_init();
>
>      /** load .my.cnf values */
>       load_defaults ("my", _sql.groups, &not_argc, &not_argv);
>
> Not calling my_init() results in load_defaults trying to access
> ~/.my.cnf without expanding ~. Yuk!
>
> RFV, please
>

Is it possible to develop a configure test that selects between the two
initialization styles shown above ?

Bart.
------------------------------------------------------------------------------
Using storage to extend the benefits of virtualization and iSCSI
Virtualization increases hardware utilization and delivers a new level of
agility. Learn what those decisions are and how to modernize your storage 
and backup environments for virtualization.
http://www.accelacomm.com/jaw/sfnl/114/51434361/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to