Koozali.org: home of the SME Server

UPSD problem (again)

Offline ElFroggio

  • *
  • 262
  • +0/-0
UPSD problem (again)
« on: January 30, 2015, 03:35:45 AM »
Hi,

I've been trying to customize and control my UPS settings 2..6.5-2. I have followed:

http://wiki.contribs.org/Uninterruptable_Power_Supply and tried to set the "battery.charge.low" and I got:

Code: [Select]
Unexpected response from upsd: ERR ACCESS-DENIED
I have found that this was due to ACLs. I have followed the ACL for the http://wiki.contribs.org/Uninterruptable_Power_Supply:LatestGeekery. It still didn't work until I added the following:

Code: [Select]
upsd : admin op localhost : ALLOW to
Code: [Select]
/etc/hosts.allow and restarting nut.

How do I add that line to the

Code: [Select]
{
$DB->hosts_allow_spec('nut','nut');
}

so I can expand the template and don't have to add manually on reboots?

Thanks

/Syv

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: UPSD problem (again)
« Reply #1 on: January 30, 2015, 10:53:08 AM »
ElFroggio

create a custom template
See the Howto link above for the Template Tutorial
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline stephdl

  • *
  • 1,523
  • +0/-0
    • Linux et Geekeries
Re: UPSD problem (again)
« Reply #2 on: January 30, 2015, 02:40:12 PM »
Hi el froggio

I would know about security implication on the command you gave. I agree that we are working on the nut aspect and we have some bugs pending it seems :p

You should go to bugzilla

Can you add pointers that you read and explain what you did, we need to test on our side and understanding the situation. In fact nut should work out of the box....so if you need to search to get it in works, i call that a bug

This weekend i am at the fossdem, but monday we can start to work
« Last Edit: January 30, 2015, 02:41:59 PM by stephdl »
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline ElFroggio

  • *
  • 262
  • +0/-0
Re: UPSD problem (again)
« Reply #3 on: January 30, 2015, 03:49:44 PM »
create a custom template
See the Howto link above for the Template Tutorial

Exactly what I'm trying to do. Any generalities don't help. At least give me some link http://wiki.contribs.org/Category:Template obviously this is not what you meant.

/Syv
« Last Edit: January 30, 2015, 03:58:02 PM by ElFroggio »

Offline ElFroggio

  • *
  • 262
  • +0/-0
Re: UPSD problem (again)
« Reply #4 on: January 30, 2015, 03:54:10 PM »
I would know about security implication on the command you gave. I agree that we are working on the nut aspect and we have some bugs pending it seems :p
Yes and no. Very little security implications (unless I'm missing something). This is an internal server, behind a firewall...

You should go to bugzilla

Can you add pointers that you read and explain what you did, we need to test on our side and understanding the situation. In fact nut should work out of the box....so if you need to search to get it in works, i call that a bug

I googled and found some people with exactly the same error message.

This weekend i am at the fossdem, but monday we can start to work

Have a great time...

/Syv

Offline ElFroggio

  • *
  • 262
  • +0/-0
Re: UPSD problem (again)
« Reply #5 on: January 30, 2015, 05:35:14 PM »

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: UPSD problem (again)
« Reply #6 on: January 30, 2015, 07:55:46 PM »
ElFroggio

Be thankful for any directions given, rather than being critical.
This is a free forum & I do not get paid to assist people here.
it took me 5 seconds to follow the advice I gave you
ie
Click on Howto link at top of this Forum
On the Howto page, scroll down to the very bottom (past the alphabetical links to howto names), then click on Next 200 to display more names
On the next screen (listed alphabetically under letter T), then select Template Tutorial.

Please look a little harder next time rather than expecting or demanding to be given a direct link to the page.

I was busy at the time & gave you a quick answer that was sufficient to get you started if you tried a little harder.

Hopefully now you know how to look up all the available Howtos.
Just providing you a direct link does not teach you how to find all the Howtos.



Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: UPSD problem (again)
« Reply #7 on: January 31, 2015, 12:58:13 AM »
Syv

I have not tried this so you may need to experiment.
You already have the method described in the UPS Geekery article you referred to,  which I assume you have followed.

Follow the same instructions but create another fragment
upsd2
Put your extra line in there & expand as per the Geekery version Howto.
The code in both fragments (upsd & upsd2) will be "permanently" added to the /etc/hosts.allow config file.

Read the Template Tutorial Howto for more general concepts.
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.