Get the most out of your Centmin Mod LEMP stack
Become a Member

Glances a top command alternative

Discussion in 'Centmin Mod Insights' started by eva2000, Jan 1, 2017.

Tags:
  1. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    cheers, strange haven't run across this message yet

     
  2. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    FYI, going to have temporarily disable the centmin.sh auto update pip/glances/psutil function as CentOS 6.x systems are spitting out errors on centmin.sh runs !
    Code (Text):
    DEPRECATION: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. A future version of pip will drop support for Python 2.6
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
      SNIMissingWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
      InsecurePlatformWarning
    DEPRECATION: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. A future version of pip will drop support for Python 2.6
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
      SNIMissingWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
      InsecurePlatformWarning
    DEPRECATION: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. A future version of pip will drop support for Python 2.6
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
      SNIMissingWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
      InsecurePlatformWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
      SNIMissingWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
      InsecurePlatformWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#snimissingwarning.
      SNIMissingWarning
    /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.io/en/latest/security.html#insecureplatformwarning.
      InsecurePlatformWarning
    Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-y3Bzlv/glances/
    
     
  3. pamamolf

    pamamolf Premium Member Premium Member

    4,071
    427
    83
    May 31, 2014
    Ratings:
    +833
    Local Time:
    8:33 PM
    Nginx-1.25.x
    MariaDB 10.3.x
    Any fix for that?

    I have the same issue when i try to use the aws s3 cli tool :(

    CentOS release 6.10 (Final)

    I use the script for 3,6 at addons directory but i am getting the same error again...
     
    Last edited: Jan 20, 2019
  4. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    If you're using CentOS 6 and run into issues installing latest Glances version which now requires Python 2.7, you can install Python 2.7 as SCL Yum package via Centmin Mod addons/python27_install.sh
    Code (Text):
    cd /usr/local/src/centminmod/addons
    ./python27_install.sh install
    mkdir -p /home/pip-tmp
    chmod 1777 /home/pip-tmp
    export TMPDIR=/home/pip-tmp
    pip2.7 install --upgrade pip
    pip2.7 install --upgrade psutil
    pip2.7 install --upgrade glances
    

    Code (Text):
    pip --version                   
    pip 18.1 from /usr/lib/python2.7/site-packages/pip (python 2.7)
    

    Code (Text):
    glances --version
    Glances v3.1.0 with psutil v5.4.8
    
     
  5. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
  6. pamamolf

    pamamolf Premium Member Premium Member

    4,071
    427
    83
    May 31, 2014
    Ratings:
    +833
    Local Time:
    8:33 PM
    Nginx-1.25.x
    MariaDB 10.3.x
    All updated with no issues but i am still getting this error when i run the aws s3 cli tool as it seems to use the old 2.6 python :(

     
  7. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    use pip2.7 to install awscli not pip
     
  8. ndha

    ndha Member

    82
    10
    8
    Sep 28, 2014
    Ratings:
    +29
    Local Time:
    1:33 AM
    Latest
    10
    @eva2000
    I just rebuilt Nginx with GCC 8
    and then TOP2 error,
    i got PSutil library not found. Glances cannot start.
    Already doing like you said in Quote but throw some error too :
    1. pip install --upgrade pip = Requirement already up-to-date: pip in /usr/lib/python2.7/site-packages (19.0.1)
    2. pip uninstall psutil = Cannot uninstall 'psutil'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
    3. pip uninstall psutil = Cannot uninstall 'psutil'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
    4. pip install psutil = Requirement already satisfied: psutil in /usr/lib64/python2.7/site-packages (2.2.1)
    5. pip install --upgrade psutil --force-reinstall -v | egrep 'ccache|gcc|installed' = uninstalled_pathset = UninstallPathSet.from_dist(dist)

    glances -V = PSutil library not found. Glances cannot start.

     
  9. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    If you use centmin mod 123.09beta01 with latest updates via cmupdate command you can just run centmin.sh once and it will take care of pip updates for glances and then exit centmin.sh and glances should work
     
  10. ndha

    ndha Member

    82
    10
    8
    Sep 28, 2014
    Ratings:
    +29
    Local Time:
    1:33 AM
    Latest
    10
    Yes it's :)
    Already doing that..
    But it must be uninstall & reinstall glance after doing cmupdate..
    Cause in my case if only doing like you suggest it got error "glances command not found"
    Thanks for fixing it Eva
     
  11. upgrade81

    upgrade81 Member

    295
    17
    18
    Sep 5, 2016
    CH
    Ratings:
    +30
    Local Time:
    7:33 PM
    1.17
    10.3
    Hi, I have problems on a VM.
    Just installed with the beta.
    Code:
    pip --version
    pip 19.0.3 from /usr/lib/python2.7/site-packages/pip (python 2.7)
    
    glances --version
    PSutil library not found. Glances cannot start.
    
    pip2.7 install --upgrade psutil
    DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
    Collecting psutil
      Using cached https://files.pythonhosted.org/packages/2f/b8/11ec5006d2ec2998cb68349b8d1317c24c284cf918ecd6729739388e4c56/psutil-5.6.1.tar.gz
    Installing collected packages: psutil
      Found existing installation: psutil 2.2.1
    Cannot uninstall 'psutil'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
    
    
     
  12. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    centos 7 or 6 ?

    does messages go away on subsequent centmin.sh menu runs ?
     
  13. upgrade81

    upgrade81 Member

    295
    17
    18
    Sep 5, 2016
    CH
    Ratings:
    +30
    Local Time:
    7:33 PM
    1.17
    10.3
    centos 7.6
    Unfortunately, no, it remains so even after numerous starts
     
  14. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    do manual remove of yum version of psutils
    Code (Text):
    yum -y remove python2-psutil

    then run centmin.sh one and exit
     
  15. upgrade81

    upgrade81 Member

    295
    17
    18
    Sep 5, 2016
    CH
    Ratings:
    +30
    Local Time:
    7:33 PM
    1.17
    10.3
    ok, result in:

    Code:
    -bash: /usr/bin/glances: No such file or directory
     
  16. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    did you re-run centmin.sh ? make sure centmin mod is updated via command = cmupdate before re-run centmin.sh
     
  17. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    if that doesn't work manually run ignoring deprecation notices
    Code (Text):
    pip install psutil
    pip install glances
    
     
  18. upgrade81

    upgrade81 Member

    295
    17
    18
    Sep 5, 2016
    CH
    Ratings:
    +30
    Local Time:
    7:33 PM
    1.17
    10.3
    Code:
    pip install psutil
    DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
    Requirement already satisfied: psutil in /usr/lib64/python2.7/site-packages (5.6.1)
    And
    Code:
    pip install glances
    DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
    Requirement already satisfied: glances in /usr/lib/python2.7/site-packages (3.1.0)
    Requirement already satisfied: psutil>=5.3.0 in /usr/lib64/python2.7/site-packages (from glances) (5.6.1)
    final

    Code:
    top2
    -bash: glances: command not found
     
  19. eva2000

    eva2000 Administrator Staff Member

    53,865
    12,160
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,712
    Local Time:
    4:33 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    top2 command is command alias so need to exist ssh session and relogin for it to work on updated glances maybe

    what about
    Code (Text):
    pip uninstall glances
    pip install glances
    
     
  20. upgrade81

    upgrade81 Member

    295
    17
    18
    Sep 5, 2016
    CH
    Ratings:
    +30
    Local Time:
    7:33 PM
    1.17
    10.3
    result in:

    Code:
    Proceed (y/n)? y
      Successfully uninstalled Glances-3.1.0
    Code:
    pip install glances
    DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
    Collecting glances
      Using cached https://files.pythonhosted.org/packages/32/34/72f9202ad5b7ada314507a50b9ab1fb604d2f468b138679e0a4fedeb91fa/Glances-3.1.0.tar.gz
    Requirement already satisfied: psutil>=5.3.0 in /usr/lib64/python2.7/site-packages (from glances) (5.6.1)
    Installing collected packages: glances
      Running setup.py install for glances ... done
    Successfully installed glances-3.1.0
    Logout and relogin:
    Code:
    top2
    psutil library not found. Glances cannot start.
    :-(
     
  21. upgrade81

    upgrade81 Member

    295
    17
    18
    Sep 5, 2016
    CH
    Ratings:
    +30
    Local Time:
    7:33 PM
    1.17
    10.3
    I can only tell you that it occurs on two vps after answering YES before starting the recompilation of nginx or php.

    Code:
    Do you want to run YUM install checks ?  [y/n]
    
    This will increase your upgrade duration time wise.
    Check the change log centminmod.com/changelog.html
    to see if any Nginx or PHP related new additions
    which require checking YUM prequisites are met.
    If no new additions made, you can skip the
    YUM install check to speed up upgrade time.
    
     [y/n]: