LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (http://www.linuxquestions.org/questions/debian-26/)
-   -   Installing 'glances' on Debian-Testing (http://www.linuxquestions.org/questions/debian-26/installing-glances-on-debian-testing-4175447932/)

rng 01-30-2013 11:03 PM

Installing 'glances' on Debian-Testing
 
I want to install 'glances' system-monitor on Debian-Testing:
http://linux.softpedia.com/get/Syste...es-78055.shtml
https://github.com/nicolargo/glances
It is not in Debian-testing repository (though it is available with many other distributions- an unusual situation). It can be installed with source tar ball and the commands: configure, make, sudo make install. But then it will not be tracked by the package management system. I tried using src2pkg software to make a Deb file (which was created). But the Deb file could not be installed by gdebi or dpkg -i commands due to errors (EOF after Description).

What is the best method to install it? Thanks for your help.

Randicus Draco Albus 01-30-2013 11:16 PM

Quote:

Glances is a CLI curses based monitoring tool
Once when I was searching through Synaptic to see what monitoring utilities were available, I remember seeing at least one that matches that description. Check out the ones that are in the repository. One might catch your fancy, and there would be no need to build from source.

descendant_command 01-31-2013 12:11 AM

It is in Sid - http://packages.debian.org/unstable/utils/glances

Check out the dependencies and the howto section at forums.debian.net for how to backport packages using already debianized sources (assuming you want it on squeeze).

rng 01-31-2013 12:26 AM

I was more interested in methods of installing such a package. What is wrong in installing with commands configure, make and sudo make install? If I need to remove it later I can do so by 'sudo make uninstall' command.

descendant_command 01-31-2013 01:12 AM

Well, that is why a package management system exists - to manage the addition and removal of software in a sane and predictable manner.

You can certainly use 'make install' but there is no guarantee you are not overwriting already installed libs or binaries or introducing version conflicts, and later apt installs or removals could also overwrite or remove your installed files.
Basically you need to babysit all that yourself.

Also, just noticed you are on testing so the sid package could well be installable without issues - http://packages.qa.debian.org/g/glances.html this implies it is not in testing due only to it arriving post-freeze.

widget 01-31-2013 07:03 PM

You can install from the Sid repo by adding it to your sources.list. You need to comment it our when not using it or you may get a surprise upgrade.

You will of coarse need to run "apt-get update" or better in my mind for this particular job "aptitude update".

To install a package from sid you would then, in apt-get, run;
Code:

apt-get -t sid install <package name>
In aptitude;
Code:

aptitude install <package name> -t sid
Aptitude really does have excellent dependency options when problems turn up.

If you keep putting alien packages on a testing install you WILL have problems. If you can't find it in the testing repo check what is available in sid or even experimental and use them instead of any 3rd party package.

If you insist on some alien package learn to build a .deb out of it and use dpkg to install it.

rng 02-01-2013 09:45 AM

I tried installing glances with checkinstall but failed.

The output of './configure':
Code:

abcde@debian:~/0-glances-system-monitor/glances-1.3.2$ ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking for a Python interpreter with version >= 2.6... python
checking for python... /usr/bin/python
checking for python version... 2.7
checking for python platform... linux2
checking for python script directory... ${prefix}/lib/python2.7/dist-packages
checking for python extension module directory... ${exec_prefix}/lib/python2.7/dist-packages
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating man/Makefile
config.status: creating config.h
config.status: config.h is unchanged
abcde@debian:~/0-glances-system-monitor/glances-1.3.2$


The output of 'make':
Code:

abcde@debian:~/0-glances-system-monitor/glances-1.3.2$ make
make  all-recursive
make[1]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
Making all in src
make[2]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/src'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/src'
Making all in man
make[2]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/man'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/man'
make[2]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
make[2]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
make[1]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
abcde@debian:~/0-glances-system-monitor/glances-1.3.2$


The output of 'sudo checkinstall':
Code:

abcde@debian:~/0-glances-system-monitor/glances-1.3.2$ sudo checkinstall

checkinstall 1.6.2, Copyright 2009 Felipe Eduardo Sanchez Diaz Duran
          This software is released under the GNU GPL.



*****************************************
**** Debian package creation selected ***
*****************************************

This package will be built according to these values:

0 -  Maintainer: [ root@debian ]
1 -  Summary: [ glances- a system-monitor cli tool ]
2 -  Name:    [ glances ]
3 -  Version: [ 1.3.2 ]
4 -  Release: [ 1 ]
5 -  License: [ GPL ]
6 -  Group:  [ checkinstall ]
7 -  Architecture: [ i386 ]
8 -  Source location: [ glances-1.3.2 ]
9 -  Alternate source location: [  ]
10 - Requires: [  ]
11 - Provides: [ glances ]
12 - Conflicts: [  ]
13 - Replaces: [  ]

Enter a number to change any of them or press ENTER to continue:

Installing with make install...

========================= Installation results ===========================
Making install in src
make[1]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/src'
make[2]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/src'
test -z "/usr/local/bin" || /bin/mkdir -p "/usr/local/bin"
 /usr/bin/install -c glances.py '/usr/local/bin'
test -z "/usr/local/lib/python2.7/dist-packages/glances" || /bin/mkdir -p "/usr/local/lib/python2.7/dist-packages/glances"
 /usr/bin/install -c -m 644 glances.py '/usr/local/lib/python2.7/dist-packages/glances'
Byte-compiling python modules...
glances.py
Byte-compiling python modules (optimized versions) ...
glances.py
make[2]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/src'
make[1]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/src'
Making install in man
make[1]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/man'
make[2]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/man'
make[2]: Nothing to be done for `install-exec-am'.
test -z "/usr/local/share/man/man1" || /bin/mkdir -p "/usr/local/share/man/man1"
 /usr/bin/install -c -m 644 glances.1 '/usr/local/share/man/man1'
make[2]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/man'
make[1]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2/man'
make[1]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
make[2]: Entering directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
make[2]: Nothing to be done for `install-exec-am'.
test -z "/usr/local/doc/glances" || /bin/mkdir -p "/usr/local/doc/glances"
/bin/mkdir: cannot create directory `/usr/local/doc': No such file or directory
make[2]: *** [install-glancesdocDATA] Error 1
make[2]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
make[1]: *** [install-am] Error 2
make[1]: Leaving directory `/home/abcde/0-glances-system-monitor/glances-1.3.2'
make: *** [install-recursive] Error 1

****  Installation failed. Aborting package creation.

Cleaning up...OK

Bye.

abcde@debian:~/0-glances-system-monitor/glances-1.3.2$

How can I solve this? Thanks for your help.

widget 02-01-2013 10:56 PM

Install the package from sid so that it is actually compatible with your system?

rng 02-02-2013 08:04 AM

For installing from sid repos, I think I need to do following steps:
1. Add following to the /etc/apt/sources.list:
Code:

deb http://ftp.debian.org/debian/ unstable main contrib non-free
deb http://security.debian.org unstable/updates main contrib non-free
deb http://ftp.debian.org/debian/ unstable-proposed-updates main contrib non-free

2. sudo aptitude update
3. sudo aptitude install glances -t sid
4. comment out sid repos in sources.list file so that it is not used any further updating/upgrading.

Please correct me if I am wrong.

descendant_command 02-02-2013 08:17 AM

Yes, except there is no "updates" or "proposed-updates" sections for sid, and you don't need to use -t (unless you have set up a /etc/apt/preferences to lower the priority of the unstable packages).

edit: and you don't need sudo if you are root ;)

rng 02-02-2013 09:16 AM

Yes, it worked. It installed following packages: glances python-jinja2 python-markupsafe python-psutil. I hope there will be no further problems. Thanks for your help.


All times are GMT -5. The time now is 07:25 AM.