December 2020 eLog
2020-12-29
Author: Colin
- Now have got Network UPS Tools (NUT) working for UPS in the ctalab
- This will shutdown the server automatically in the event of a power outage, and notify me, Bill, and Massimo
- Brief summary of what was done:
- Mostly followed directions from here: https://kinavu.org/install-and-configure-nut-on-ubuntu/
- sudo apt install nut
- Add to files in /etc/nut/
- ups.conf
- [nevis-ctalab-ups]
driver = snmp-ups
port = nevis-ctalab-ups.nevis.columbia.edu
community = public
mibs=apcc
- upsd.users
- [monups]
password = acdc
upsmon master
- upsmon.conf
- nut.conf (this addition was done later in the process, may have been the cause of failures [previously MODE=none])
- Created file /home/bin/notify.sh and made it executable
- did sudo cp /lib/udev/rules.d/62-nut-usbups.rules /etc/udev/rules.d/ and followed it with a reboot
- /var/run/nut already existed, so did:
- sudo chown root:nut /var/run/nut
- sudo chmod 770 /var/run/nut
- Not sure if either of these were necessary
- [TESTING COMMANDS] The upsdrvctl stuff that was being used in the tutorial was having issues, so I just tried out what Bill shared which was:
- sudo systemctl enable nut-server
sudo systemctl enable nut-monitor
sudo systemctl start nut-server
sudo systemctl start nut-monitor
- and then: sudo upsc nevis-ctalab-ups to see if it was working
- The first time I ran the testing commands, there wasn't a whole lot of output, except with the start nut-monitor I got out:
- Job for nut-monitor.service failed because the service did not take the steps required by its unit configuration.
See "systemctl status nut-monitor.service" and "journalctl -xe" for details.
- So I ran systemctl status nut-monitor.service and it told me:
-
o nut-monitor.service - Network UPS Tools - power device monitor and shutdown controller
Loaded: loaded (/lib/systemd/system/nut-monitor.service; enabled; vendor preset: enabled)
Active: failed (Result: protocol) since Tue 2020-12-29 16:12:07 EST; 10s ago
Process: 2734 ExecStart=/sbin/upsmon (code=exited, status=0/SUCCESS)
Dec 29 16:12:07 ctalab-Precision-3630-Tower systemd[1]: Starting Network UPS Tools - power device monitor and shutdown controller...
Dec 29 16:12:07 ctalab-Precision-3630-Tower upsmon[2734]: upsmon disabled, please adjust the configuration to your needs
Dec 29 16:12:07 ctalab-Precision-3630-Tower upsmon[2734]: Then set MODE to a suitable value in /etc/nut/nut.conf to enable it
Dec 29 16:12:07 ctalab-Precision-3630-Tower systemd[1]: nut-monitor.service: Can't open PID file /var/run/nut/upsmon.pid (yet?) after start: No such file or directory
Dec 29 16:12:07 ctalab-Precision-3630-Tower systemd[1]: nut-monitor.service: Failed with result 'protocol'.
Dec 29 16:12:07 ctalab-Precision-3630-Tower systemd[1]: Failed to start Network UPS Tools - power device monitor and shutdown controller.
- Following this, I:
- Installed the server with sudo apt install nut-snmp
- Changed in the nut.conf file: MODE=none -> MODE=standalone
- Rebooted again
- This seemed to work, full output:
2020-12-18
Author: Colin
- NMC for UPS now working
- Will adjust the details of the networking section of the NevisLabsSetup page to reflect additional changes
2020-12-10
Author: Colin
- Setting up all the networking and devices
- ctalab machine
- # host odo
odo.nevis.columbia.edu is an alias for ctalab.nevis.columbia.edu.
ctalab.nevis.columbia.edu has address 10.44.2.10
- Started ssh server following direction on this page:
- https://linuxize.com/post/how-to-enable-ssh-on-ubuntu-18-04/
- Smart UPS
- # host nevis-ctalab-ups
nevis-ctalab-ups.nevis.columbia.edu has address 10.44.1.204
- account: admin
password: ctaups
- NOT WORKING CURRENTLY
- Switched capacitors on test board to power Hamamatsu SiPM (Nancy)
- Did this to accommodate higher bias voltage needed
- C1, C3, C4: replace with 100nF, 100V (1206 package)
- C5, C6, C7: replace with 2.2uF, 100V (1206 package)
2020-12-09
Author: Colin
- Tried to find the network card for the UPS
- Not located upstairs in the supply room as was initially thought
- Found one that looked like it could be it in Bill's office, but not sure how it could've gotten there with Bill absent
- Programmed the Aim TTi EL302P -USB PSU
- added as a class of the dcps
python package, new class called 'AimTTiEL302P"
- can find the code at /home/ctalab/anaconda3/envs/cta/lib/python3.8/site-packages/dcps/AimTTiEL302P.py
- So far implemented commands to do:
- Write voltage
- setVoltage(self, voltage)
- Write current
- setCurrent(self, current)
- Read the set voltage
- Read the set current
- Measure voltage
- Measure current
- Turning output on/off
- outputOff(self)
- outputOn(self)
- Checking if output is on
- Start-up code is:
- and then use the `aim` object to do all the commands
- Still need to implement commands for
- switching between local/remote (this isn't an option for the model we have)
2020-12-02
- Author: Massimo.
- Picked up corrected frame from Barnard (see attachment) and finished mounting optical enclosure with last side panel
- Images
--
Colin Adams - 2020-12-09
Comments
This topic: Veritas
> PSCT >
NevisLabsSetup >
NevisLabsELog > NevisLabsELogDecember2020
Topic revision: r10 - 2021-06-14 - ColinAdams