Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Glances won't start on Windows Server 2012R2 #1157

Closed
ohadbenita opened this issue Sep 29, 2017 · 4 comments
Closed

Glances won't start on Windows Server 2012R2 #1157

ohadbenita opened this issue Sep 29, 2017 · 4 comments

Comments

@ohadbenita
Copy link

ohadbenita commented Sep 29, 2017

I run Glances using glances -c server_ip

Traceback (most recent call last):
File "C:\Python27\Scripts\glances-script.py", line 11, in
load_entry_point('Glances==2.11.1', 'console_scripts', 'glances')()
File "c:\python27\lib\site-packages\glances_init_.py", line 134, in main
start(config=config, args=args)
File "c:\python27\lib\site-packages\glances_init_.py", line 103, in start
mode.serve_forever()
File "c:\python27\lib\site-packages\glances\client.py", line 238, in serve_forever
if not self.login():
File "c:\python27\lib\site-packages\glances\client.py", line 180, in login
self.screen = GlancesCursesClient(config=self.config, args=self.args)
File "c:\python27\lib\site-packages\glances\outputs\glances_curses.py", line 104, in init
self.screen = curses.initscr()
NameError: global name 'curses' is not defined

Glances v2.11.1 with psutil v5.3.1

Any help is appreciated

@nicolargo
Copy link
Owner

The Curses interface is not available in Windows OS (shame on Microsoft).

Two workarounds:

  1. use a Glances client in a GNU/Linux terminal
  2. Use the Web server instead of the RCP Server and monitor your Windows OS from a remote Web browser.

@ohadbenita
Copy link
Author

ohadbenita commented Sep 30, 2017

Thanks for that,

Can you elaborate (in a newbie) level how can this be done ?

  1. Are you referring to using Glances client on a Linux VM running on this Windows machine ?
  2. Would I still be able to connect from home assistant based Glances server to the client's glances instance ?

My main usage for Glances is integration with HomeAssistant
I attempted configuring a VirtualBox but it was too much of a pain so I stopped

Thanks for the info

@nicolargo
Copy link
Owner

If you are a newbie, the second solution is the simple.

So start the Glances server on the machine you want to monitor:

glances -w

On the client machine, start your Web browser and enter the following URL: http://<@IPSERVER>:61208/

@gseluja
Copy link

gseluja commented Nov 13, 2018

Hi, I´ve got an issue but don´t know if it is about W2012 or something else. I need actions to be executed as the server starts up without a web client connect to it.
What is more, Glances is grabbing stats every 15 minutes running on the server, but in my Windows 10 desktop, is grabbing every few seconds, although is the same config file. Where is this time parameter to set up?
How can I do that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants