runqemu-export-rootfs: use consistent whitespace
(From OE-Core rev: b05185240669e0ae811a23620913b35ca99493fb) Signed-off-by: Scott Garman <scott.a.garman@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
f60d41b4a2
commit
c435e4f9d2
|
@ -40,9 +40,9 @@ NFS_EXPORT_DIR=$(cd "$2" && pwd)
|
||||||
|
|
||||||
SYSROOT_SETUP_SCRIPT=`which oe-find-native-sysroot 2> /dev/null`
|
SYSROOT_SETUP_SCRIPT=`which oe-find-native-sysroot 2> /dev/null`
|
||||||
if [ -z "$SYSROOT_SETUP_SCRIPT" ]; then
|
if [ -z "$SYSROOT_SETUP_SCRIPT" ]; then
|
||||||
echo "Error: Unable to find the oe-find-native-sysroot script"
|
echo "Error: Unable to find the oe-find-native-sysroot script"
|
||||||
echo "Did you forget to source your build environment setup script?"
|
echo "Did you forget to source your build environment setup script?"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
. $SYSROOT_SETUP_SCRIPT
|
. $SYSROOT_SETUP_SCRIPT
|
||||||
|
|
||||||
|
@ -50,9 +50,9 @@ if [ ! -e "$OECORE_NATIVE_SYSROOT/usr/sbin/rpc.mountd" ]; then
|
||||||
echo "Error: Unable to find rpc.mountd binary in $OECORE_NATIVE_SYSROOT/usr/sbin/"
|
echo "Error: Unable to find rpc.mountd binary in $OECORE_NATIVE_SYSROOT/usr/sbin/"
|
||||||
|
|
||||||
if [ "x$OECORE_DISTRO_VERSION" = "x" ]; then
|
if [ "x$OECORE_DISTRO_VERSION" = "x" ]; then
|
||||||
echo "Have you run 'bitbake meta-ide-support'?"
|
echo "Have you run 'bitbake meta-ide-support'?"
|
||||||
else
|
else
|
||||||
echo "This shouldn't happen - something is missing from your toolchain installation"
|
echo "This shouldn't happen - something is missing from your toolchain installation"
|
||||||
fi
|
fi
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
@ -104,53 +104,53 @@ case "$1" in
|
||||||
echo " $PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.mountd $MOUNTD_OPTS"
|
echo " $PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.mountd $MOUNTD_OPTS"
|
||||||
$PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.mountd $MOUNTD_OPTS
|
$PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.mountd $MOUNTD_OPTS
|
||||||
if [ ! $? = 0 ]; then
|
if [ ! $? = 0 ]; then
|
||||||
echo "====================="
|
echo "====================="
|
||||||
echo "Error starting MOUNTD"
|
echo "Error starting MOUNTD"
|
||||||
echo "====================="
|
echo "====================="
|
||||||
ps -ef | grep -v grep | grep rpcbind 2>&1 > /dev/null
|
ps -ef | grep -v grep | grep rpcbind 2>&1 > /dev/null
|
||||||
if [ $? = 0 ] ; then
|
if [ $? = 0 ] ; then
|
||||||
echo " If you see an error above that says:"
|
echo " If you see an error above that says:"
|
||||||
echo " RPC: Authentication error; why = Client credential too weak"
|
echo " RPC: Authentication error; why = Client credential too weak"
|
||||||
echo " You need to change the startup of rpcbind"
|
echo " You need to change the startup of rpcbind"
|
||||||
echo " on your host by doing the following as root:"
|
echo " on your host by doing the following as root:"
|
||||||
echo "==============================================="
|
echo "==============================================="
|
||||||
echo " According to /etc/sysconfig/rpcbind, then "
|
echo " According to /etc/sysconfig/rpcbind, then "
|
||||||
echo " echo RPCBIND_ARGS=-i >> /etc/sysconfig/rpcbind"
|
echo " echo RPCBIND_ARGS=-i >> /etc/sysconfig/rpcbind"
|
||||||
echo " or"
|
echo " or"
|
||||||
echo " echo RPCBIND_OPTIONS=-i >> /etc/sysconfig/rpcbind"
|
echo " echo RPCBIND_OPTIONS=-i >> /etc/sysconfig/rpcbind"
|
||||||
echo " /etc/init.d/rpcbind restart"
|
echo " /etc/init.d/rpcbind restart"
|
||||||
echo "==============================================="
|
echo "==============================================="
|
||||||
echo "For Ubuntu 11.10 hosts"
|
echo "For Ubuntu 11.10 hosts"
|
||||||
echo "Add OPTIONS=\"-i -w\" to /etc/default/rpcbind"
|
echo "Add OPTIONS=\"-i -w\" to /etc/default/rpcbind"
|
||||||
echo "sudo service portmap restart"
|
echo "sudo service portmap restart"
|
||||||
fi
|
fi
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo "Starting User Mode nfsd"
|
echo "Starting User Mode nfsd"
|
||||||
echo " $PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.nfsd $NFSD_OPTS"
|
echo " $PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.nfsd $NFSD_OPTS"
|
||||||
$PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.nfsd $NFSD_OPTS
|
$PSEUDO $PSEUDO_OPTS $OECORE_NATIVE_SYSROOT/usr/sbin/rpc.nfsd $NFSD_OPTS
|
||||||
if [ ! $? = 0 ]; then
|
if [ ! $? = 0 ]; then
|
||||||
echo "Error starting nfsd"
|
echo "Error starting nfsd"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
# Check to make sure everything started ok.
|
# Check to make sure everything started ok.
|
||||||
if [ ! -f $MOUNTPID ]; then
|
if [ ! -f $MOUNTPID ]; then
|
||||||
echo "rpc.mountd did not start correctly"
|
echo "rpc.mountd did not start correctly"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
if [ ! -f $NFSPID ]; then
|
if [ ! -f $NFSPID ]; then
|
||||||
echo "rpc.nfsd did not start correctly"
|
echo "rpc.nfsd did not start correctly"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
ps -fp `cat $MOUNTPID` > /dev/null 2> /dev/null
|
ps -fp `cat $MOUNTPID` > /dev/null 2> /dev/null
|
||||||
if [ ! $? = 0 ]; then
|
if [ ! $? = 0 ]; then
|
||||||
echo "rpc.mountd did not start correctly"
|
echo "rpc.mountd did not start correctly"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
ps -fp `cat $NFSPID` > /dev/null 2> /dev/null
|
ps -fp `cat $NFSPID` > /dev/null 2> /dev/null
|
||||||
if [ ! $? = 0 ]; then
|
if [ ! $? = 0 ]; then
|
||||||
echo "rpc.nfsd did not start correctly"
|
echo "rpc.nfsd did not start correctly"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo " "
|
echo " "
|
||||||
echo "On your target please remember to add the following options for NFS"
|
echo "On your target please remember to add the following options for NFS"
|
||||||
|
@ -158,29 +158,29 @@ case "$1" in
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
if [ -f "$MOUNTPID" ]; then
|
if [ -f "$MOUNTPID" ]; then
|
||||||
echo "Stopping rpc.mountd"
|
echo "Stopping rpc.mountd"
|
||||||
kill `cat $MOUNTPID`
|
kill `cat $MOUNTPID`
|
||||||
rm -f $MOUNTPID
|
rm -f $MOUNTPID
|
||||||
else
|
else
|
||||||
echo "No PID file, not stopping rpc.mountd"
|
echo "No PID file, not stopping rpc.mountd"
|
||||||
fi
|
fi
|
||||||
if [ -f "$NFSPID" ]; then
|
if [ -f "$NFSPID" ]; then
|
||||||
echo "Stopping rpc.nfsd"
|
echo "Stopping rpc.nfsd"
|
||||||
kill `cat $NFSPID`
|
kill `cat $NFSPID`
|
||||||
rm -f $NFSPID
|
rm -f $NFSPID
|
||||||
else
|
else
|
||||||
echo "No PID file, not stopping rpc.nfsd"
|
echo "No PID file, not stopping rpc.nfsd"
|
||||||
fi
|
fi
|
||||||
if [ -f "$EXPORTS" ]; then
|
if [ -f "$EXPORTS" ]; then
|
||||||
echo "Removing exports file"
|
echo "Removing exports file"
|
||||||
rm -f $EXPORTS
|
rm -f $EXPORTS
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
restart)
|
restart)
|
||||||
$0 stop $NFS_EXPORT_DIR
|
$0 stop $NFS_EXPORT_DIR
|
||||||
$0 start $NFS_EXPORT_DIR
|
$0 start $NFS_EXPORT_DIR
|
||||||
if [ ! $? = 0 ]; then
|
if [ ! $? = 0 ]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
|
|
Loading…
Reference in New Issue