how to install longview in CentOS 8 ?

baseurl=https://yum-longview.linode.com/centos/8/noarch/
is not exist !
how to install longview int CentOS8

6 Replies

They don't appear to have a repo for centos 8 yet. The centos 7 version they have has a package dependency on perl-Crypt-SSLeay which doesn't exist in centos8 - but I'm not sure it is really using that package and the dependency probably needs to be removed for the centos8 version (or updated to use perl-Net-SSLeay?) Crypt::SSLeay would be for LWP prior to version 6 (centos 7 already was at version 6 of LWP) - after LWP6 scripts should be using LWP::Protocol::https so chances are they didn't really need it for the centos7 version either.

So, here's the way I got longview working on a centos8 system - it's a few manual steps, and one forced rpm install on the centos7 version to get past the bad dependency on perl-Crypt-SSLeay (it also complained about the perl version, which is odd since 5.26.3 is what is on the system.)


You would be better off waiting for the official repo to show up
If you follow these steps, you will have to undo them when they do get the real repos up


I'm using wget to get the centos7 packages from the linode repo - if you need wget, you can install it with
yum install wget

Get the packages (I'm forcing ipv4 here, ipv6 was giving me trouble talking to the repos):

wget -4 https://yum-longview.linode.com/centos/7/noarch/linode-longview-1.1-5.noarch.rpm
wget -4 https://yum-longview.linode.com/centos/7/noarch/perl-Log-LogLite-0.82-1.noarch.rpm
wget -4 https://yum-longview.linode.com/centos/7/noarch/perl-IO-LockedFile-0.23-1.noarch.rpm

Install those perl-* rpms you just picked up:

yum install perl-IO-LockedFile-0.23-1.noarch.rpm perl-Log-LogLite-0.82-1.noarch.rpm

Install the other pre-reqs that come out of base/epel:

yum install perl-Net-SSLeay perl-libwww-perl perl-LWP-Protocol-https perl-DBD-mysql perl-DBI perl-JSON perl-IO-Socket-INET6

In the linode web UI, add your longview client if you haven't already. You need to get the api key for this longview client - in the old manager there's a the little info 'i' next to the client. Click that.
Longview Client Settings

The Longview API Key on the settings tab is what you want (a couple lines above the red box in this image)
Longview API Key Location

Put that key in to the /etc/linode/longview.key file (replace with your key after the echo):
echo '586604E5-C618-A522-YADDAYADDA' | sudo tee /etc/linode/longview.key

At this point, if you tried to install longview rpm with 'rpm -ivh linode-longview-1.1-5.noarch.rpm' you'd get something like this:

warning: linode-longview-1.1-5.noarch.rpm: Header V3 RSA/SHA1 Signature, key ID 325a043e: NOKEY
error: Failed dependencies:
perl >= 0:5.006000 is needed by linode-longview-1.1-5.noarch
perl(Crypt::SSLeay) is needed by linode-longview-1.1-5.noarch

That first failure is odd since the perl version is more recent than that. The second one is the one that's broken. This is the bit you don't usually want to do (I'm assuming you are going to do this just to see longview work - see the bold warning above) - force the install, ignoring the depencencies:
rpm --nodeps -ivh linode-longview-1.1-5.noarch.rpm

It'll likely start the longview service as part of that install. Check it with
systemctl status longview
If you need to restart it
systemctl restart longview

The longview log is at /var/log/linode/longview.log . You can look at it to be sure longview isn't complaining about the api key. If you see something like:

10/08 22:04:38 INFO Longview[19077] - 400 Bad Request API key: D06FB7A3-XXX is made up, rejecting payload!
10/08 22:04:38 INFO Longview[19077] - API key: D06FB7A3-XXX is made up, rejecting payload!

Double check your api key and make sure it is the only thing in the /etc/linode/longview.key file.

A normal startup looks something like this:

10/08 22:05:19 INFO Longview[19130] - Starting Longview Agent version 1.1.5
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Disk.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Network.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/SysInfo.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Memory.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/CPU.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Processes.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Ports.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Applications/MySQL.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Applications/Nginx.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Applications/Apache.pm
10/08 22:05:19 INFO Longview[19131] - Loading module /opt/linode/longview/Linode/Longview/DataGetter/Packages/YUM.pm
10/08 22:05:19 INFO Longview[19131] - Start up complete

After a couple minutes, in the linode manager, you should see longview say that it is gathering data and it will eventually show data.

Again - don't really follow this as a guide since you'll want the official repo and package when they come up with it. This is just if you really want to see longview working ahead of time on centos8 and you are ok with undoing many of the steps above (mostly removing those packages you wget).

ehh you probably shouldn't use Longview, if you can avoid it. I would guess based on stuff like this redirect:

https://linode.com/longview

that Longview isn't "Long" for this world.

You may want to try this - unofficial - Longview client:

https://github.com/kmansoft/longview-go/releases

Written in GO, it has no install dependencies, just a single executable file (and some config files).

There is no repository for Centos, but there are RPM packages.

Disclaimer: I'm the author.

Longview has been packaged for CentOS 8 - so the normal install process should work now.

When I try to install Longview Agent on Centos 8 by the following command:

curl -s https://lv.linode.com/C33396C1-51D6-472F-BAD7AABA9D9F6DC7 | sudo bash

I get the following error:

bash: line 43: yum: command not found

On Centos 8 yum has been replaced by dnf.

Thanks for help.

Fabio

CentOS 8 should include a symlink for yum commands to use dnf. I tried this with a fresh CentOS 8 deploy, just now, and it seemed to work.

Are you using one of Linode's CentOS 8 images or is this for an external server? It's a possibility that not all CentOS 8 installs include that symlink I mentioned.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct