RHEL 7 collectd dbi freetds issues - dbi

I can't seem to get the dbi plugin working for collectd on RHEL 7. I am trying to connect to Microsoft SQL Server using the FreeTDS driver, but collectd/dbi can't find it.
I've installed the latest collectd:
Name : collectd
Arch : x86_64
Version : 5.5.2
Release : 1.el7
Size : 1.8 M
Repo : installed
From repo : epel
Summary : Statistics collection daemon for filling RRD files
License : GPLv2
I've installed collectd-dbi:
Name : collectd-dbi
Arch : x86_64
Version : 5.5.2
Release : 1.el7
Size : 32 k
Repo : installed
From repo : /collectd-dbi-5.5.2-1.el7.x86_64
Summary : DBI plugin for collectd
License : GPLv2
I've installed FreeTDS:
Name : freetds
Arch : x86_64
Version : 0.95.81
Release : 1.el7
Size : 2.7 M
Repo : installed
From repo : epel
Summary : Implementation of the TDS (Tabular DataStream) protocol
License : LGPLv2+ and GPLv2+
collectd shows an error when trying to load FreeTDS:
dbi plugin: cdbi_connect_database: dbi_driver_open_r (FreeTDS) failed.
What am I missing? Any help would be greatly appreciated.

I'm fighting the same problem myself, and while I haven't yet got it working I'm pretty sure you need DBD::Sybase in addition to collectd, collectd-dbi and freetds. I grabbed it from http://search.cpan.org/CPAN/authors/id/M/ME/MEWP/DBD-Sybase-1.15.tar.gz.
With luck you'll get past where I'm at, which is that Perl says the driver is available, but the collectd plugin can't reference it.
Seeming success on the perl side:
cat ./test.pl
#!/usr/bin/perl
use DBI;
#Prints a list of the available DBD drivers.
#available_drivers = DBI->available_drivers;
print ("The available DBD drivers are: #available_drivers.\n");
$ ./test.pl
The available DBD drivers are: DBM ExampleP File Gofer Oracle Proxy Sponge Sybase mysql.
But I get this error in the collectd log:
[2016-09-27 14:18:09] dbi plugin: cdbi_connect_database: dbi_driver_open_r (Sybase) failed.
[2016-09-27 14:18:09] dbi plugin: Maybe the driver isn't installed? Known drivers are:
[2016-09-27 14:18:09] dbi plugin: * mysql
That mysql driver became available after I installed the libdbi-dbd-mysql rpm, but no love yet getting it to recognize the Sybase driver.

Related

Unable to install pypi package(google-cloud-bigquery) on GCP Composer

I am trying to install google-cloud-bigquery==1.5.0 PyPI packages on GCP composer for a new environment recently has been created. I get this error:
Successfully installed google-cloud-bigquery-1.5.0 google-cloud-core-0.28.1 pypd-1.1.0 strict-rfc3339-0.7
+ [[ -z fail ]]
+ python3 -m pipdeptree --warn fail
Warning!!! Possibly conflicting dependencies found:
* google-cloud-translate==2.0.1
- google-cloud-core [required: >=1.1.0,<2.0dev, installed: 0.28.1]
* google-cloud-storage==1.29.0
I tried another version (2.2.0) and it had conflicts with some other google pre-installed packages.
The new environment image version is composer-1.12.2-airflow-1.10.6.
There is another environment created few months ago and all pypi packages are installed successfully and airflow dags are running smoothly, the image version for it is composer-1.10.0-airflow-1.10.6 .
Question 1: I think the current issue is linked to the image version and probably I have to recreate the new environment with older image version, am I correct?
Question 2: To create new environment I have only three options for image version which are composer-1.12.2-airflow-1.10.6, composer-1.12.2-airflow-1.10.9, composer-1.12.2-airflow-1.10.10. How I can create environment with image version composer-1.10.0 ? We have several other projects and environment with the same location/zone but with composer-1.10.0
Please, have a look to the official documentation for the Apache Airflow and Python versions that Cloud Composer supports. You can refer to the section for the Python packages which comes with composer-1.12.2-airflow-1.10.6. A specific Cloud Composer Airflow version already comes with a set of included packages. When you upgrade/downgrade a specific installed PyPi package or try to use any other packages, you can run into conflicts.
As for now, there is no way to check conflicts ahead of time within Cloud Composer environment. I would like to suggest you to adjust your packages to be able to use in the one of the Composer environments: composer-1.12.4-airflow-1.10.10,
composer-1.12.4-airflow-1.10.9 or composer-1.12.4-airflow-1.10.6.

octave: add gdal support for mapping package

I am trying to run some old matlab code with octave. Unfortunately this code contains a geotiffread function and I think I should change this function with rasterread (package mapping).
However, when I try to install the mapping package I get this warning:
octave:7> pkg install mapping-1.4.0.tar.gz
configure: WARNING: GDAL library not found. Reading of raster files will be disabled.
For information about changes from previous versions of the mapping package, run 'news mapping'.
I tried to run octave (5.2.0 version) within:
a Debian Buster distribution (snap and flatpak package)
a docker container (MacOS 10.15 host, installed from the mtmiller/octave image).
online with the octave-online service, running this code:
pkg load mapping;
[bands, info] = rasterread ('mexutm250.tiff');
With this output:
octave:3> source("my_script.m")
error: gdalread: reading of raster file with GDAL was disabled during installation
error: called from
rasterread at line 56 column 26
my_script at line 2 column 15
No attempt was successful.
EDIT 2: I know that my octave installations are without GDAL support. I would like to use octave with full mapping package, and GDAL support, without recompile it. There is a way to do it (e.g. update a library path within the docker installation to add the libgdal library)?
If there is no way to add GDAL support without recompile octave, there is a guide to do it with minimal effort?
EDIT 3: I already installed the gdal dependencies:
$ sudo aptitude search gdal |grep ^i
[sudo] password for virtuser:
i gdal-bin - Geospatial Data Abstraction Library - programmi di utilità
i A gdal-data - libreria Geospatial Data Abstraction Library - file di dati
i libgdal-dev - libreria Geospatial Data Abstraction Library - file di sviluppo
i libgdal20 - libreria Geospatial Data Abstraction Library
Thank you.
I got octave with GDAL integration when I installed the octave package from the debian repository. I needed octave 5.2, so I switched to Ubuntu 20.04.
as suggested in one of the comments, checking
>> news mapping
(also at https://octave.sourceforge.io/mapping/NEWS.html)
looking at mapping 1.2.1 where rasterread was introduced, it states:
** New features
Reading GIS raster data: A first go is provided using
functions rasterread.m and rasterinfo.m. Both invoke binary
function gdalread() of which an initial version was provided
by Shashank Khare. rasterread.m and rasterinfo.m can read
and return info on any raster data type that the underlying
GDAL library can read. As such, separate functions for e.g.,
GeoTIFF and ArcGrid etc. are not required.
To make use of these functions the GDAL library must be
present on your system => GDAL is a suggested dependency.
You should be able to install the GDAL library in Debian using your preferred installation method.
Unsure whether or not you'll need to uninstall/reinstall the mapping package afterward, but if an unload/reload doesn't get rid of the message, try that and see if mapping is able to see the library.

Ganglia csv export gives timestamp as 1970-01-01 but not current time

Ganglia csv export gives time stamp as 1970-01-01. But when I view ganglia webfrontend, it shows proper time. I check Ganglia-webfrontend code, it shows that it is getting this value from RRDtool. Any solution to this.
Ganglia Web Frontend version 3.6.1
Ganglia Web Backend (gmetad) version 3.6.0.
RRDtool version 1.5.4
[Edit1]
Sample of csv exported file from my cluster :
Timestamp,1-min,Nodes,CPUs ,Procs
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
1970-01-01T05:30:00+05:30,16:08:20 03:29:01,NaN,NaN,NaN,NaN
Sample of csv exported file from https://ganglia.wikimedia.org/latest/ :
Timestamp,In ,Out
2016-08-20T12:00:15+00:00,12849582.909,311121.67333
2016-08-20T12:00:30+00:00,12872902.147,360193.53067
2016-08-20T12:00:45+00:00,12774903.844,365818.67533
2016-08-20T12:01:00+00:00,12748911.431,383361.00133
2016-08-20T12:01:15+00:00,12759820.237,390467.666
2016-08-20T12:01:30+00:00,12914302.844,389208.29267
2016-08-20T12:01:45+00:00,12938113.925,372756.31267
Ganglia wiki gives latest timestamp but the one installed on my cluster gives 1970-01-01. So this means Ganglia has the feature to display latest timestamp but one install on my cluster doesn't support this feature. But this is the latest ganglia version I could get using apt-get. There is Ganglia-3.7.2 available but it is not install able using apt-get and facing some issue while installing using rpm. Any help
[Edit2]
When I check the Ganglia version on Ganglia-wiki, this is the version I found. Only difference is with the rrdtool version.
Ganglia Web Frontend version 3.6.1
Ganglia Web Backend (gmetad) version 3.6.0.
RRDtool version 1.4.7
Problem solved after installation of rrdtool-1.4.7-1
Step to install rrdtool-1.4.7:
1)Downlaod .deb file from https://launchpad.net/ubuntu/precise/amd64/rrdtool/1.4.7-1
2)Goto to download directroy
3)sudo dpkg -i rrdtool_1.4.7-1_amd64.deb

How to install LXC c libraray?

I know Linux Container (LXC) has an API. We can use it via liblxc, which should be a c library. But I cannot find any? So, how people use this API currently?
If you installed lxc successfully, shared libraries & header files are copied to your environment. ex) /usr/local/include/lxc , /usr/local/lib/liblxc.so
then you can build your code within linking option '-llxc'
You need to install lxc-devel. Here's the information about this package.
# yum info lxc-devel
Loaded plugins: langpacks
Available Packages
Name : lxc-devel
Arch : x86_64
Version : 1.0.7
Release : 2.0.12.el7
Size : 20 k
Repo : ol7_latest/x86_64
Summary : Development library for lxc
URL : http://linuxcontainers.org
License : LGPLv2+
Description : The lxc-devel package contains header files and library needed for
: development of the Linux containers.

P4 diff doesn't work on Redhat linux 5.7

o-xterm-91:maxwell1/arch/simt/func/proto-compiler> p4 diff run_passes.pl
==== //arch/simt/func/proto-compiler/run_passes.pl#247 - /home/scratch.ankurj_maxwell-info/maxwell1/arch/simt/func/proto-compiler/run_passes.pl ====
mgdiff: error while loading shared libraries: libXm.so.2: cannot open shared object file: No such file or directory
All other perforce commands are working except for the diff.
Suggest alternative's or fixes.
I am using Centos, Redhat linux 5.7 enterprise version
It sounds like you have configured a custom diff program using the P4DIFF configuration setting: http://www.perforce.com/perforce/doc.current/manuals/cmdref/env.P4DIFF.html
Try clearing the P4DIFF and DIFF configuration settings, and you can use the built-in Perforce command-line diff, which is a simple textual diff program.
Else, try reviewing the "mgdiff" installation materials at the mgdiff site ant see if you can re-install or repair the Motif libraries on your machine. http://packages.debian.org/sid/text/mgdiff

Resources