Skip to contentSkip to conversation

rc.autofs.in > getnismounts > error?

DISCUSSION BRINER Cedric 1 participant 1 message Nov 24, 2003 Kernel automounter

lore
Share & tools
lore
#0 lore raw

hello,

I think that I've found a small mistake in the initialization script of autofs-4.1.0.

in the function:
function getnismounts()

{
    YPMAP=`catnismap auto.master`
    if [ -z "$YPMAP" ]; then
       YPMAP=`catnismap`
    fi
    echo $YPMAP
}

The fact is that on my machine the line:
YPMAP=catnismap auto.master
remove the "\n" of what ""catnismap auto.master"" returns. And then the read functions will not works and so on...

So in my case, I've simply changed the above function like this:
function getnismounts()

{
    YPMAP=`catnismap auto.master`
    if [ -z "$YPMAP" ]; then
       catnismap
    else
        catnismap auto.master
    fi
}

and everything works perflectly well.

Regards

Cédric BRINER
PS. thanks for your work!

Signature · 6 lines
                   +41(o)\                       at
                          76/\    -o762   briner/  \infomaniak
                              577/     \ /                    \
 .       .       .   .  .  .  . -=Cedric Briner=- .   . .ch - dot
                                       /
 46b rue Jacques-Dalphin,CH-1227 Geneva    \