1#!/bin/sh 2# 3# $NetBSD: swap1,v 1.8 2002/03/24 15:52:41 lukem Exp $
| 1#!/bin/sh 2# 3# $NetBSD: swap1,v 1.8 2002/03/24 15:52:41 lukem Exp $
|
4# $FreeBSD: head/etc/rc.d/swap1 124616 2004-01-17 10:16:38Z mtm $
| 4# $FreeBSD: head/etc/rc.d/swap1 124622 2004-01-17 10:59:43Z mtm $
|
5# 6 7# PROVIDE: localswap 8# REQUIRE: disks 9# KEYWORD: FreeBSD shutdown 10 11. /etc/rc.subr 12 13name="swap1"
| 5# 6 7# PROVIDE: localswap 8# REQUIRE: disks 9# KEYWORD: FreeBSD shutdown 10 11. /etc/rc.subr 12 13name="swap1"
|
| 14start_cmd='swapon -a' 15stop_cmd=':'
|
14
| 16
|
15case ${OSTYPE} in 16FreeBSD) 17 start_cmd='swapon -a' 18 stop_cmd=':' 19 ;; 20NetBSD) 21 # Add all block-type swap devices; these might be necessary 22 # during disk checks. 23 # 24 start_cmd="swap1_start" 25 stop_cmd="swap1_stop" 26 ;; 27esac 28
| |
29# Add all block-type swap devices; these might be necessary 30# during disk checks. 31# 32swap1_start() 33{ 34 if ! checkyesno no_swap; then 35 swapctl -A -t blk 36 fi
--- 14 unchanged lines hidden --- | 17# Add all block-type swap devices; these might be necessary 18# during disk checks. 19# 20swap1_start() 21{ 22 if ! checkyesno no_swap; then 23 swapctl -A -t blk 24 fi
--- 14 unchanged lines hidden --- |