При сохранении изменённого файла по сети: Неожиданная ошибка: Not a directory
Опубликовано Николай в 23.04.2009 в 08:55
вот моя проблема
wer@wer-work:~$ echo 111 > /media/lan/share/1111/
bash: /media/lan/share/1111/: Not a directory
wer@wer-work:~$ ls -l /media/lan/share/1111/
-rwxrwxrwx 1 wer wer 319 2008-12-16 14:19 /media/lan/share/1111/
строчка монтирования
#lan
//192.168.0.101/Volume_1-1 /media/lan cifs auto,dev,user=sgmeng/user,pass=xxxxxxx,uid=1000,gid=1000,iocharset=utf8 0 0
могу удалять, переименовывать, компировать, а ИЗМЕНЯТЬ НЕТ idiot2
на вендовых машинах всё нормально
это конфиг nas, который раздаёт файло (знаю, что бред share и всё равно userов использовать, но увы так хочет nas)
здесь forum(dot)ubuntu(dot)ru(slash)?topic=55241.0 там ничего интересного... имхо
решил
проблема была в NAS Dlink-323 так его и так!
Цитиую на будущее
How to workaround the DFS samba bug on the DNS323 NAS ?
Firstly, here is a quick bug description: It's impossible to modify any existing files. The “Not a directory” or “No such file or directory” or “touch: setting times of…” errors occurs when trying to modify a file.
If your linux cifs or smbfs client support the nodfs flag (integrated in kernels > 2.6.27). You just have to add this option to the mount command. Example:
Код:
mount -t cifs -o credentials=/home/kerphi/.smb-zekra-credentials,iocharset=utf8,file_mode=0777,d ir_mode=0777,nodfs //zekra/Volume_1 /home/kerphi/zekra
If you cannot upgrade your kernel (like me because i'm following the debian releases), you have to follow this workaround:
* сonnect to the DNS323 using the web GUI and goto tools→system. * Save the configuration to your workstation (in “CONFIGURATION SETTINGS” section). * After saving edit the file and just under this line:
Код:
;[ global ]
add the following line:
Код:
msdfs root = no
* Then upload this file through the web interface, your NAS will reboot and you will be able to modify existing file again !