Is it posisble to have rook ceph with zabbix - zabbix

I want to have my rook ceph cluster monitored by zabbix.
However, enabling module and configuring zabbix host is not enough.
Basically it expects that mon/mgr containers have zabbix_sender, which upstream rejected (https://github.com/ceph/ceph-container/issues/1651).
Before I will start building my own ceph images, does anybody have better idea?
Maybe somehow mount zabbix_sender from host? How this could be done that rook operator creates such containers?
Thanks

after several experiments, easiest solution is to extend ceph images in this way:
FROM quay.io/ceph/ceph:v16.2.6
RUN yum install -y https://repo.zabbix.com/zabbix/5.4/rhel/8/x86_64/zabbix-release-5.4-1.el8.noarch.rpm && yum install -y zabbix-sender && yum clean all

Related

Installing MySQL and MySQLWorkbench In Offline Red Hat 7 Machine

I am trying to install mysql workbench on a system without network. I downloaded the mysql-workbench-community, mysql-community-{server, client, common, libs} which were noted in the "Installing RPM Packages" section of MySQL Install Manual. It states that these are the standard rpm packages needed for a basic functional install of mysql community. So with that I downloaded all the rpm packages and attempted to manually install each using:
sudo rpm -ivh mysql-community-package-name.rpm
Unfortunately I keep getting dependency errors. I found this link to obtain all the dependencies for a package. So on my second attempt I ran the following:
Repoquery -R --resolve --recursive mysql-community-server | xargs -r yumdownloader
Which gave me about 100 rpm packages. I transferred them onto my machine and unfortunately more dependencies like mysql-connectors-community and mysql-=tools-community came up which were never documented or mentioned as dependencies with the script.
What am i doing wrong? Is there a way to download all the rpms and bundle them together as a custom RPM in the future? I see ubuntu has a apt-offline command mentioned here. Is there a similar method I can apply for redhat?
Update1:
I have an idea to create a container rhel7 instance, mounting /root/tmpkg and running this example. But is there another way I should consider?

Running Google Cloud SQL Proxy on Raspberry

I'm getting an error while trying to connect raspberry running ubuntu mate to my Google Cloud SQL instance.
These are the step I did to install:
git clone https://github.com/GoogleCloudPlatform/cloudsql-proxy
cd cloudsql-proxy/
sudo sh download_proxy.sh
My instance is configured this way (I deleted some characters in the image and in the code):
I didn't set the network because I'll be using proxy
Then I download into the same folder my JSON key.
wget https://drive.google.com/file/d/my_key.json
And the start the proxy
sudo ./cloud_sql_proxy -instances=be - 21:us-central1:be =tcp:3306 \
-credential_file=./my_key.json &
But I'm getting the error:
pi#pi:~/cloudsql-proxy$ ./cloud_sql_proxy: 1: ./cloud_sql_proxy:
Syntax error: ")" unexpected
I've tried removing the .json and I was getting the same error before without credential, I think that the problem is in the setup.
My dir ls is:
Any help is appreciated :)
download_proxy.sh downloads the proxy compiled for the amd64 architecture of CPU (aka x86_64). Your raspberry Pi has a ARM CPU, so this binary cannot run on your machine.
Google does not provide pre-build ARM versions of the proxy. I don't even know if it is able to build on ARM CPU. If it is possible, this is how you must do it:
Install go, e.g. with apt-get install golang
Setup a GOPATH, as per https://github.com/golang/go/wiki/GOPATH
Run go get github.com/GoogleCloudPlatform/cloudsql-proxy/cmd/cloud_sql_proxy
Run the proxy with $GOPATH/cloud_sql_proxy -instances=...
Ok.
I'm sharing what I did to make it work, as David I don't know what version was I downloading.
I tried to avoid installing Go but it was the only way to get it installed.
sudo apt-get install golang-go
export GOPATH=$HOME/go
go get github.com/GoogleCloudPlatform/cloudsql-proxy/cmd/cloud_sql_proxy
cd $GOPATH/bin
wget your_key.json
sudo ./cloud_sql_proxy -instances=the_full_name_of_the_instance=tcp:3306 -credential_file=./your_key.json &
But I was getting a error because I already have mysql running localy in the same port
So now I'm using a unix soquet
sudo ./cloud_sql_proxy -instances=the_full_name_of_the_instance -credential_file=./your_key.json &
And then it's ready for connections :)
Thanks guys
I found issues with this when compiling SQL-proxy. I did, however, find the instructions here worked great on my raspberry pi 3. Have to make sure to remove all prior installations then reinstall it
wget https://storage.googleapis.com/golang/go1.9.linux-armv6l.tar.gz
sudo tar -C /usr/local -xzf go1.9.linux-armv6l.tar.gz
export PATH=$PATH:/usr/local/go/bin # put into ~/.profile`

Continue after reboot Linux custom script - Azure ARM template

I am trying to build ARM JSON template and facing a problem with custom script extension and request for your help.
This is the sample script that I am executing as a part of virtual machine extensions (Linux).
#!/usr/bin/bash
export AZURE_STORAGE_ACCOUNT="$1"
export AZURE_STORAGE_ACCESS_KEY="$2"
AZURE_STORAGE_CONTAINER="$3"
yum update -y
reboot
yum install -y epel-release
yum install -y gcc gcc-c++ kernel-devel ksh m4 sshpass nodejs npm
With this script the VM was able to install updates and reboot. However the command "yum install -y epel-release" and following commands were not executed. And also while deployment this operation hangs and timeouts.
Can you help suggest how to solve this situation using JSON ARM template or custom script extension or using any Linux workaround ?
probably powershell dsc can help you achieve that (configure certain properties to force configuration to continue after reboot), or split your configuration into 2 scripts and deploy them independently of each other, so the first script reboots the machine, and after that second script should start working as soon as the VM becomes available and waagent talk to Azure.

How to install expect and tcl on linux RHEL server 6.5

I am new to linux and i have few expect scripts to execute. I read few blogs on how to install expect and tcl. The command i am trying is
sudo yum install expect
sudo yum install tcl
I am getting
No package expect available
No package tcl available
It seems RHEL should have tcl and expect prebuilt but this is not the case in my version of linux.
How should i proceed from here ?
Help will be highly appreciated..Thanks :)
Install the development tools:
yum groupinstall "Development tools"
then
./configure
make
make install
should be good to go.
Have you tried this? In this way you will be able to compile from source.
1) Download the expect package from the below link
http://sourceforge.net/projects/expect/
2) Install the required dependecy packages "Tcl/Tk" language toolkit
# yum install tcl
3) Install the "expect" package using the below commands
# tar -zxvf expectx.xx.tar.gz
# ./configure
# make
# make install
I tried the following links and it worked for me. http://www.linuxfromscratch.org/blfs/view/svn/general/tcl.html http://www.linuxfromscratch.org/blfs/view/svn/general/expect.html
Try ActiveTcl from ActiveState:
http://downloads.activestate.com/ActiveTcl/releases/8.6.4.1/ActiveTcl8.6.4.1.299124-linux-x86_64-threaded.tar.gz
You can add EPEL Repo
On 32-Bit -
# rpm -Uvh http://epel.mirror.net.in/epel/6/i386/epel-release-6-8.noarch.rpm
On 64-Bit -
# rpm -Uvh http://epel.mirror.net.in/epel/6/x86_64/epel-release-6-8.noarch.rpm
and then you can use yum to install.
Also you can compile from source or get from ActiveState like in previous answers.

Alternative ways to deploy code to Openshift

I am trying to setup Travis CI to deploy my repository to Openshift on a successful build. Is there a way to deploy a repository besides using Git?
Git is the official mechanism for how your code is update, however depending on the type of application that you are deploying you may not need to deploy your entire code base.
For example Java application (war, ear, etc) can be deployed to JBoss or Tomcat servers, by simply taking the built application and checking it into the OpenShift git repositories, webapps or deploy directories.
An alternative to this (and it will be unsupported), is to scp your application to the gear using the SSH key. However any time the application is moved or updated (with git) this content stands a good chance of getting deleted(cleaned), by the gear.
We're working on direct binary deploys ("push") and "pull" style deploys (Openshift downloads a binary for you. The design/process is described here:
https://github.com/openshift/openshift-pep/blob/master/openshift-pep-006-deploy.md
You can do a SCP to the app-root/dependencies/jbossews/webapps directory direcly. I was able to do that successfully and have the app working. Here is the link
Here is the code which I had in the after_success blck
after_success:
- sudo apt-get -y install sshpass
- openssl aes-256-cbc -K $encrypted_8544f7cb7a3c_key -iv $encrypted_8544f7cb7a3c_iv
-in id_rsa.enc -out ~/id_rsa_dpl -d
- chmod 600 ~/id_rsa_dpl
- sshpass scp -i ~/id_rsa_dpl webapps/ROOT.war $DEPLOY_HOST:$DEPLOY_PATH
Hope this helps