Changeset 28918


Ignore:
Timestamp:
2011-11-10T00:43:47+01:00 (6 years ago)
Author:
nico
Message:

packages/smartmontools: use new service functions

Location:
packages/utils/smartmontools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • packages/utils/smartmontools/Makefile

    r28326 r28918  
    1010PKG_NAME:=smartmontools 
    1111PKG_VERSION:=5.40 
    12 PKG_RELEASE:=1 
     12PKG_RELEASE:=2 
    1313 
    1414PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz 
  • packages/utils/smartmontools/files/smartd.init

    r10734 r28918  
    11#!/bin/sh /etc/rc.common 
    2 # Copyright (C) 2006 OpenWrt.org 
     2# Copyright (C) 2006-2011 OpenWrt.org 
    33 
    44START=95 
     5 
    56start() { 
    6   [ -f /etc/smartd.conf ] || { 
    7     echo "/etc/smartd.conf does not exist !"; 
    8     exit 0; 
    9   }; 
    10   [ -d /var/run ] || mkdir -p /var/run 
    11   [ -x /usr/sbin/smartd ] && /usr/sbin/smartd -q never -p /var/run/smartd.pid 
     7        service_start /usr/sbin/smartd -q never 
    128} 
    139 
    1410stop() { 
    15   killall smartd 
    16 } 
    17  
    18 restart() { 
    19         stop 
    20         sleep 1 
    21         start 
     11        service_stop /usr/sbin/smartd 
    2212} 
    2313 
    2414reload() { 
    25         kill -HUP `cat /var/run/smartd.pid` &>/dev/null 
     15        service_reload /usr/sbin/smartd 
    2616} 
    27  
    28  
Note: See TracChangeset for help on using the changeset viewer.