駭客小築's Archiver

star 發表於 2006-2-1 03:37 AM

[轉載] [分享] UPS的設定/心得

--
好小孩 <psilotum....@ptt.csie.ntu.edu.tw>


I. 前言


   去年買了個 UPS ,不過一直懶得去測試到底停電之後能不能安全 Shutdown
   還有到底能不能由COM1控制 UPS,因為dmesg並沒有相關的訊息,後來突然熊熊發現
   所附的光碟裡頭有支援FreeBSD的 ups daemon,因此
   小弟就把一些經驗分享給大家,如果有什麼漏誤還請諸位大大指正。


II.規格


   廠牌:臺達電不斷電供應系統(Delta UPS)
   型號:S-series; S-650
   類型:離線式(Off-Line) UPS
   用途:個人工作站使用。
   網頁:[url]http://www.deltaww.com/products/ups/s.htm[/url] (English)
         [url]http://www.deltaww.com/ups/products/hardware/s650_series.htm[/url] (中文)


   通訊介面: RS232 via com1 or com2 (/dev/cuaa0; /dev/cuaa1)
   所附的軟體:電力管理大師2000(UPSentury Smart 2000)
           ([url]http://www.deltaww.com/ups/products/software/manager.htm)[/url]


III. 網路資源/文件


   For FreeBSD說明:
   [url]http://www.deltaww.com/ups/products/software/spec_freebsd.htm[/url]
   同時這個網頁上也有簡繁體、英文的pdf檔使用說明。


IV. 測試平台及軟體版本


測試平台: 4.8-STABLE
安裝版本: FreeBSD 3.4 3.01.10版


V. 安裝


   簡易安裝:若要更詳細的安裝過程說明,請參閱官方網站上的說明。


   1. 解壓縮 freebsd3_4.tar


      #tar -xvf freebsd3_4.tar


   2. 利用所附的 install shell安裝


      #./install


   3. 之後會 step by step去設定安裝的資料夾
      Master / Slave 等問題,就依照個人需求
      設定。


      --> 詳細安裝過程:


      i.  安裝開始,選擇安裝的目錄:


          The default destination directory is" /usr/local/smart ".
          Enter your new destination directory below,
          or just press 'Enter' key for default.
          New destination directory:


          (直接按 Enter 接受預設。)


      ii. 是否確定要安裝 UPSentry Smart 2000這個程式?


          Do you want to install the UPSentry Smart 2000 now ?[y|n]


         (按 y 繼續安裝程序。)


      iii.選擇安裝的介面:


         Please enter the COM port which connects to your UPS."
         For example: COM1 is /dev/cuaa0, COM2 is /dev/cuaa1."
         COM Port:
         (我是接在COM1 port, 所以我鍵入 /dev/cuaa0)


      iv. 輸入主機的ip(rs232連線的主機)


         Please enter the IP address of the master
         which this computer will connect to.
         IP address is :


         (輸入您的ip: ex:140.112.250.151)


      v.  選擇通訊的模式:


          Please select the communication mode.
          1. Master:
          If this computer connects to an UPS directly(RS232 or USB)
          and will administrate the UPS.
          2. Serial Slave:
          If this computer connects to an UPS directly(RS232 or USB)
          but will only monitor the UPS.
          3. Networking Slave:
          If this computer powered by an UPS but doesn't communicate
          with the UPS directly.
          Please enter '1' for Master, '2' for Serial Slave or '3' for
          Networking Slave:
          (我選擇1,直接連線,Master模式。)


      vi. 是否啟動UPS daemon


          Do you want to start upsd now ?[y|n]


         (我選擇 y)


      vii.啟動 upsd


          Starting upsd ...


         *下次 reboot之後,就會自動啟動 upsd


    4. 其他的問題在網頁上的pdf檔都寫得蠻詳盡的,我也正在閱讀中。


V. 設定問題


   相關設定:還在閱讀中 ^^;


VI.附錄:


   A. 以下羅列出ports底下有的 upsd 軟體


   Port:   apcupsd-3.8.6
   Path:   /usr/ports/sysutils/apcupsd


   Port:   bkpupsd-1.0a
   Path:   /usr/ports/sysutils/bkpupsd


   Port:   mgeupsd-0.3
   Path:   /usr/ports/sysutils/mgeupsd


   Port:   upsd-2.0.1.6_1
   Path:   /usr/ports/sysutils/upsd


   B. screenshot


   [url]http://tchaikovsky.m7.ntu.edu.tw/~psilotum/img/upsd_main.jpg[/url]
                                                  upsd_scroll.jpg
                                                  upsd_diagram.jpg
                                                  upsd_config.jpg
如果有錯誤,還希望各位指正,多謝。 :)


--
※ 發信站: 批踢踢實業坊(ptt.csie.ntu.edu.tw)
◆ From: 140.112.250.151

頁: [1]

Powered by Discuz! Archiver 6.1.0  © 2001-2007 Comsenz Inc.