#!/bin/bash PATH=$PATH:/bin:/usr/bin if test -z "#"; then case $1 in lock) my_dir=`ls -l /dev/disk/by-path/*usb* 2>/dev/null|sed 's%^.*/\([^/]*\)$%\1%'|fgrep -wf - /proc/mounts|cut -d' ' -f2|head -1` test -z "$my_dir" && exit 1 echo "$my_dir" exit 0;; unlock) test -d $path || `logger "cprocps: The flash disk was unmounted while in use" && exit 0` exit 0;; esac elif test -z ""; then case $1 in lock) volrmmount -i rmdisk0 || exit 1 while test ! -d /rmdisk/rmdisk0 do true done echo "/rmdisk/rmdisk0" exit 0 ;; unlock) test -d $path || exit 1 volrmmount -e rmdisk0 exit $? ;; esac elif test -z "#"; then case $1 in lock) my_dir=`mount|fgrep -w msdosfs|cut -d ' ' -f3|head -1` test -z "$my_dir" && exit 1 echo "$my_dir" exit 0;; unlock) test -d $path || `logger "cprocps: The flash disk was unmounted while in use" && exit 0` exit 0;; esac #elif test -z "#"; then #mount|fgrep -w 'to chto nado" | sed -e 's#/dev/.* /#/#' | sed -e 's#\(.*\)j.*#\1#'| head -1 fi exit 1
У меня CSP версии 3.6. В списке считывателей есть FLASH, но флешка не работает. Что делать?
Публикация: 20 Декабрь 2010 - 18:13, редакция: 20.12.2010 18:40
Замените скрипт /opt/cprocsp/sbin/архитектура/mount_flash.sh на: