Ciao Sgaragnam,
Grazie per il tuo aiuto.
Ho provato, ma ancora non riesco.
Andando sull'impostazione della condivisione del MAC il sistema mi ha dato:
"Gli utenti Windows possono accedere alle cartelle condivise su questo computer e gli amministratori possono accedere a tutti i volumi a smb://192.168.0.126."
A questo punto sono andato nel sammygo/etc/init.d/04_04_samba.init
E ho impostato cosi, ma ancora nulla:
##### CHANGE MEEEEE !!!!! ######
USER="manfer72"
PASSWD="manfer72"
PERM="rw" # can be ro or rw
##### CHANGE MEEEEE END ######
[ -z $USER ] && exit 1
[ -z $PASSWD ] && exit 1
DEST_DIR=/dtv/usb/smb
SERVER=""
# SERVER="10.0.0.1" # if you want a fixed server
SHARES=""
FR_NAME="Samba Server"
# M_OPTS="rw,user=${USER},password=${PASSWD}"
M_OPTS="$PERM,user=${USER},password=${PASSWD}"
SERVERS="Don't set me!!"
do_mount()
{
$(echo -e "[sdh]\nVendor : CifsMount\nProduct : $FR_NAME\n\
Serial : Q80VQLFH\nDevpath : 8\nLun : 0\nMountDir : $DEST_DIR\nFileSystem : vfat\n" >> /dtv/usb/log)
for i in $S_MOUNTS ; do
M_POINT="$DEST_DIR/$1/$(echo -n $i | sed -e "s/\\\$/_/g")"
mkdir -p "$M_POINT"
if [ `cat /proc/mounts | grep -c "$M_POINT"` -lt "1" ] ; then
mount -o "${M_OPTS}" -t cifs "//$1/$i" "$M_POINT"
else
echo "$M_POINT is mounted!"
fi
done
}
get_shares()
{
echo -n "Search Shares on: "
for i in $SERVERS ; do
S_MOUNTS=$(smbclient -s "$SYSROOT/etc/smb.conf" -U ${USER}%${PASSWD} \
-g -L $i | grep "Disk|" | grep -v "\\$" | grep -v " Service" | cut -d "|" -f2)
[ -n "$S_MOUNTS" ] && do_mount $i
done
}
get_servers()
{
if [ -z "$SERVER" ] ; then
SERVERS=$(cat /proc/net/arp | grep -v "smb://192.168.0.126" | cut -d " " -f1)
else
SERVERS=$SERVER
fi
}
case $1 in
start)
get_servers
get_shares
;;
stop)
# may can fail if device access the mount from content library
for i in $(cat /proc/mounts | grep cifs | cut -d " " -f2) ; do
umount $i
done
;;
status)
;;
*)
echo "Usage: $0 {start|stop}" 1>&2
exit 0
;;
esac
User e PSW sono quelle del mio utente MAC.
Altri suggerimenti.
Grazie 1000
Ferruccio