Results 1 to 5 of 5
I just installed apcupsd-3.14.2 via RPM on a RHEL3 machine. I edited
/etc/apcupsd/spcupsd.conf and started the service. It says that it
starts OK, but in /var/log/messages I get:
Dec 20 ...
- 12-21-2007 #1
Problem with apcupsd
I just installed apcupsd-3.14.2 via RPM on a RHEL3 machine. I edited
/etc/apcupsd/spcupsd.conf and started the service. It says that it
starts OK, but in /var/log/messages I get:
Dec 20 18:42:02 sddev01 apcupsd[21170]: apcupsd FATAL ERROR in pcnet.c
at line 655 Cannot bind socket (9
Dec 20 18:42:02 sddev01 apcupsd: apcupsd startup succeeded
I saw a couple of mentions of machines reporting this but still working,
so I tried:
[root@sddev01 root]# apcaccess status
FATAL ERROR in apcaccess.c at line 41
tcp_open: cannot connect to server localhost on port 3551.
ERR=Connection refused
So... the only references I'm finding to these messages do not help. I
am not using selinux.
No firewall:
[root@sddev01 root]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
I also tried:
[root@sddev01 root]# apctest
2007-12-20 18:50:03 apctest 3.14.2 (15 September 2007) redhat
Checking configuration ...
Attached to driver: pcnet
sharenet.type = DISABLE
cable.type = APC_NET
You are using a SMART cable type, so I'm entering SMART test mode
Unknown mode.type: 15
Setting up the port ...
apctest FATAL ERROR in pcnet.c at line 655
Cannot bind socket (9
^X
[root@sddev01 root]#
My config file contents:
UPSCABLE ether
UPSTYPE pcnet
DEVICE 192.168.2.7:admin:********
LOCKFILE /var/lock
SCRIPTDIR /etc/apcupsd
PWRFAILDIR /etc/apcupsd
NOLOGINDIR /etc
ONBATTERYDELAY 6
BATTERYLEVEL 5
MINUTES 3
TIMEOUT 0
ANNOY 300
ANNOYDELAY 60
NOLOGON disable
KILLDELAY 0
NETSERVER on
NISIP 0.0.0.0
NISPORT 3551
EVENTSFILE /var/log/apcupsd.events
EVENTSFILEMAX 10
UPSCLASS standalone
UPSMODE disable
STATTIME 0
STATFILE /var/log/apcupsd.status
LOGSTATS off
DATATIME 0
- 12-23-2007 #2Just Joined!
- Join Date
- Dec 2007
- Posts
- 5
I have a similar case. Although I can start the apcupsd service. The message I get in /var/logs/messages is:
Dec 23 04:12:27 baldur apcupsd[24099]: apcupsd 3.14.2 (15 September 2007) suse startup succeeded
Dec 23 04:12:27 baldur apcupsd[24099]: NIS server startup succeeded
And when I simulate a power failure I get a message from the UPS telling me that the computer is now running on batteries.
But when I try to run "/etc/init.d/apcupsd status" or "apcaccess status" I get the same error as you did:
FATAL ERROR in apcaccess.c at line 41
tcp_open: cannot connect to server localhost on port 3551.
ERR=Connection refused
I also have no firewall.
It seems that my UPS is working, but I would like to see the Status work.
I'm sorry not to be able to help you with your problem. But I'm interested to hear if anyone has a solution to this?
- 12-23-2007 #3
My "cannot connect to server localhost on port 3551" error was caused by something else already occupying port 3551. Turned out it was a rogue process from APCs POS PCNS software. dreamspy - stop your apcupsd service, then use netstat to look for port 3551. If you tried to use PCNS and gave up in frustration, it may be the culprit.
- 12-23-2007 #4Just Joined!
- Join Date
- Dec 2007
- Posts
- 5
That was actually not the case in my computer. It was probably an error in the APCUPSD software.
I was able to fix my error by going to the configuration file for apcupsd, I had the NISIP set to my local ip:
NISIP 192.168.1.104
Which should be quite ok, but I changed it to the default value:
NISIP 0.0.0.0
And after that "apcaccess status" worked like a charm.
- 12-31-2007 #5Just Joined!
- Join Date
- Dec 2007
- Posts
- 1


Reply With Quote

