Author: | poushag |
---|---|
Date: | 2007-07-01 |
Revision: | 01 |
Description: | This is a how-to about implementing NUT on OS X |
I have more than one computer powered by my old serial cable UPS. I wanted to try to have a safe shutdown of all systems with the Mac as master (polling the UPS) and others as slaves (polling the Mac). See 'Advanced configuration' graphic on http://www.networkupstools.org/docs/user-manual.chunked/ar01s06.html#DataRoom for diagram.
It wasn't too difficult but the nuggets needed to figure it out were scattered around the net a bit and obfuscated somewhat by other info. So now that I have filtered out all the useless data and implemented NUT successfully, I wanted to share the methods in case others would like to do the same.
Wide Compatibility: The USB DB9 adapter is with Industrial FTDI chipset, compatible for Windows 10 / 8.1 / 8/7 / Vista / XP / 2000 and Mac OS X 10.6, Linux, etc. Easy to Setup: driverless for Win10/8.1/8,; for other OS, plug & play after one time driver installation. Stable Data Transfer: USB to RS232 serial cable supports data rate up to 1M / bps. Mac mini Core i7 Intel NUC 9 Pro Kit (NUC9VXQNX) Price: $1,899: $2800: Dimensions: 197mm x 197mm x 36mm: 238 x 216 x 96mm: Processor: Intel Core i7 3.2GHz 6 cores, Turbo Boost to 4.6GHz.
Before dealing with NUT, I had to get the UPS connected to the Mac. The first thing needed was a DB-9 (male) serial port. For me this meant buying a USB to serial adapter cable and a USB PCI card as well since I didn't have any spare USB ports. (My Mac is a PowerMac G4 MDD.)
I obtained a USB 2.0 PCI card Encore ENLUSB2-5PCI-BR (4 ports ext, 1 port int). All I had to do was power down and install the card.
I also found a CP-Tech CP-US-03 adapter that sources said was compatible with Linux as it is based on the Prolific PL2303 chip. I found that it required a driver for OSX that was NOT on the manufacturers website or the CD that came with the part. I found it here: <http://www.llondel.org/md_pl2303_v109b6.zip> (Thanks to David Hough for posting this driver. His 'Interfacing a Contact-Closure UPS to Mac OS X and Linux' write-up was a good source but was not exclusively focussed on OSX as my text here is.) The driver installation required a reboot and then the device showed up at /dev/tty.usbserial and was visible in the System Profiler app on the USB bus.
NUT binaries were not available for Mac OS X as of June 2007. But thanks to Ranger Rick and his friends at Fink I was able to build NUT myself. This is not as hard as it might sound. I followed the one-page quick start <http://www.finkproject.org/download/index.php?phpLang=en> for the most part. It should have mentioned in step 6 that Fink Commander is at <http://sourceforge.net/project/showfiles.php?group_id=48896> and (for using fink packages from source on 10.4) XCode 2.4.1 is at <http://connect.apple.com> & under 'Downloads' click 'Developer Tools' (requires free user registration). After this I ran the Fink self-update from source and then installed the 'nut' package from source. (For a serial cable UPS, the 'nut-usb' package is not needed. And the 'nut-cgi' package is only needed for webpage monitoring of the UPS.)
NUT requires a fair amount of linux style configuration and a bit of Mac type tweaking too. First I backed up all the sample files and removed the '.sample' extension. Then I edited the configuration files as follows.
ups.conf contains settings specific to the UPS:
The NUT hardware compatibility list at <http://www.networkupstools.org/stable-hcl.html> has a table of supported hardware and each corresponding driver (and upstype if applicable) for entry in the ups.conf file. As for the rest, it was just the same port info from above plus manufacturer and model number. The user has complete freedom to name the UPS via the string between the brackets. This name will be used to poll the UPS in combination with the hostname or IP address of the server.
upsd.users for OS X master (with password deleted of course):
upsmon.conf I left alone except one line (again without actual password):
upssched.conf I deleted after determining that no timers are needed for my application of NUT.
Initial verification can be done by starting all the processes manually. Make sure you have nothing else important in progress because if you get things wrong it may decide that the machine needs to be shut down immediately. Connect the all cable terminations.
Start the NUT processes as root in a terminal.(I prefer iTerm <http://iterm.sourceforge.net/download.shtml>):
Of course you should substitute the name of your own UPS as you set it in the ups.conf file.
The 'ps aux' command should return something like this:
And the 'upsc' command output similar to this:
For OS X it is necessary to navigate to /System/Library/StartupItems. I started by copying another directory tree (I used 'NFS') as a template for 'UPS' directory. Then I changed to the 'UPS' directory and renamed the 'NFS' file to 'UPS' using the mv command. And last I edited the files in the 'UPS' directory.
These are the terminal commands:
Edit 'UPS' to match this content:
Edit the StartupParameters.plist file to read:
NUT is built to run under the user 'nobody' on OS X. This user already existed so all I did was change the owner and permissions on the configuration files to make them secure:
After the config files are secured, if further configuration tweaking is needed I find Pseudo a good tool for editing (as root) these files with BBEdit Lite on OS X.<http://personalpages.tds.net/~brian_hill/pseudo.html>
Reboot and run the upsc command as before. If output appears normal then the final test is to trip the circuit breaker feeding power to the UPS. The system should flip over to battery power and return a warning in the terminal window that it is on battery. You should be able to configure clients on other machines, such as I did using WinNUT <http://csociety.ecn.purdue.edu/~delpha/winnut/>.
You can now play Word Nut: Word Puzzle Games & Crosswords for PC on a desktop/laptop running Windows XP, Windows 7, Windows 8, Windows 8.1, Windows 10 and MacOS/OS X. This can easily be done with the help of BlueStacks or Andy OS Android emulator.
TRY WORD NUT & DOWNLOAD the best word games FREE!
Word Nut has exciting word games Free, Word Nerds! Word Nut starts as an easy word game and gets harder as you level up!
ENJOY WORD CROSSING GAMEPLAY!
– Connect letters in any direction to form the hidden word matches!
– Find as many words as possible to level up and earn bonus rewards!
– Fill in every word in the crossword! Earn bonus coins when you discover hidden words!
– Can't figure out the word jumble? Use coins to get a special hint and win the level!
FEATURES:
– Daily bonus coins for free hints!
– Daily Challenge gives you more free word games, more free bonus coins and more FUN EVERY DAY!
– Over 1000+ Levels to play word games free!
– Free 500 coins at the first word game login.
– Easy to play and difficulty increases as you go!
– Play OFFLINE or ONLINE to train your brain – anytime, anywhere.
– Whether you want word games for adults or word games for kids, Word Nut is the best free word game!
– For word games free single player mode, download Word Nut's Free Word Game Now!
Get Word Nut for the best word games free for word game fans, word search addicts, crossword and more!
Play word games now in Word Nut – it's so addictive and nutty fun!
Having an issue with these free word games for android? For immediate support, contact us at support@chippymediallc.com Thanks!
Word Nut: Word Puzzle Games & Crosswords For PC can be easily installed and used on a desktop computer or laptop running Windows XP, Windows 7, Windows 8, Windows 8.1, Windows 10 and a Macbook, iMac running Mac OS X. This will be done using an Android emulator. To install Word Nut: Word Puzzle Games & Crosswords For PC, we will use BlueStacks app player. The method listed below is set to help you get Word Nut: Word Puzzle Games & Crosswords For PC. Go ahead and get it done now.
Download: Bluestacks Android Emulator
Download: Word Nut: Word Puzzle Games & Crosswords (Play Store)
More From Us: Body Doctor Temperature scan For PC / Windows 7/8/10 / Mac – Free Download
Also Read: Weather Watch on Home Screen For PC / Windows 7/8/10 / Mac – Free Download
That would be all from our side. In case you have got any queries or you have any issue following the guide, do let me know by leaving your thoughts in the comments section below.