~ubuntu-branches/ubuntu/precise/open-iscsi/precise-backports

« back to all changes in this revision

Viewing changes to utils/iscsi_discovery

  • Committer: Bazaar Package Importer
  • Author(s): Colin Watson
  • Date: 2009-08-04 12:30:44 UTC
  • Revision ID: james.westby@ubuntu.com-20090804123044-qx8o9krbl7t2xl3i
Tags: 2.0.870.1-0ubuntu6
utils/iscsi_discovery: Fix several bashisms (test ==, &> redirection,
trap with numeric signals).

Show diffs side-by-side

added added

removed removed

Lines of Context:
53
53
 
54
54
initialize()
55
55
{
56
 
        trap "exit" 2
 
56
        trap "exit" INT
57
57
        debug=false
58
58
        force="0"
59
59
        log_out="1"
171
171
set_transport()
172
172
{
173
173
        transport=$1
174
 
        if [ "$transport" == "iser" ];then
 
174
        if [ "$transport" = "iser" ];then
175
175
                iscsiadm -m node --targetname ${target} --portal ${portal} \
176
176
                                --op update -n node.conn[0].iscsi.HeaderDigest -v None
177
177
                iscsiadm -m node --targetname ${target} --portal ${portal} \
197
197
check_iscsid()
198
198
{
199
199
        #check if iscsid is running
200
 
        pidof iscsid &>/dev/null
 
200
        pidof iscsid >/dev/null 2>&1
201
201
        ret=$?
202
202
        if [ $ret -ne 0 ]; then
203
203
                echo "iscsid is not running"