[Samba] Problems copying some files from windows to linux

Mark Dorset mdorset at trinity.unimelb.edu.au
Tue Feb 3 06:47:42 GMT 2004


Hi,

This might not be entirely samba server related, but the problem I am 
experiencing is affecting a planned implementation of a new Samba 
Server, and from the smbmount man page, it appears that this is the 
recommended list to reqest help - so hopefully someone might be able to 
assist :-).


I am running a Debian Linux machine (kernel 2.6.0) with Samba 3.0.1 
which will soon be replacing an existing Windows PDC here. We are 
looking at transferring files from the existing Windows server to the 
linux box, but have a problem with some of the files. For example, file 
names with apostrophes (i.e., "company's.exe"), and question marks 
(i.e., "Help?.doc") do not seem to be manageable, while everything 
other file in a given subdirectory will be fine. We're pretty much just 
mounting the share on the windows box as a smbfs off a local mount 
point, and we only need this temporarily as the windows server will be 
decommissioned once the files are across.


The fstab entry;
=-=-=
//windowsserver/D$ /mnt/windowsserver/D smbfs 
defaults,rw,username=validuser,password=validpass
=-=-=


The file can be seen by doing a wildcard ls;
=-=-=
# ls -l /mnt/windowsserver/D/fred/Eudora/Attach/c*
-rwxr--r--    1 root     root        24576 Nov 14  2001 
/mnt/windowsserver/D/fred/Eudora/Attach/company's.exe
-rwxr--r--    1 root     root       162816 Aug 30  2001 
/mnt/windowsserver/D/fred/Eudora/Attach/corporate_plan.doc
=-=-=


Trying to access the file without the apostrophe works fine, but the 
one with the apostrophe doesn't;
=-=-=
# ls -l /mnt/windowsserver/D/fred/Eudora/Attach/corporate_plan.doc
-rwxr--r--    1 root     root       162816 Aug 30  2001 
/mnt/windowsserver/D/fred/Eudora/Attach/corporate_plan.doc

# ls -l /mnt/windowsserver/D/fred/Eudora/Attach/company\'s.exe
ls: /mnt/windowsserver/D/fred/Eudora/Attach/company's.exe: No such file 
or directory

# ls -l "/mnt/windowsserver/D/fred/Eudora/Attach/company\'s.exe"
ls: /mnt/windowsserver/D/fred/Eudora/Attach/company\'s.exe: No such 
file or directory
=-=-=


To try and resolve the problem, I've done all the following without 
achieving success;

- tried all kind of varieties of backslashes, quotes, etc to try and 
get the system to see the file
- searched the samba archives as well as plenty of google searches for 
possible solutions
- messed around with the codepage and iocharset options for smbmount

Strangely, if I create a new file within the mounted windows file 
system tree with an apostrophe, it is recognised and accepted;

=-=-=
# touch /mnt/windowsserver/D/fred/Eudora/Attach/test\'ing.exe
# ls -l /mnt/windowsserver/D/fred/Eudora/Attach/test\'ing.exe
-rwxr--r--    1 root     root        0 Feb  3 16:35 
/mnt/windowsserver/D/fred/Eudora/Attach/test'ing.exe
=-=-=

If anyone has any suggestions as to how I can further pursue a 
resolution to this behaviour, I would be most appreciative!

thanks in advance,
Mark



--
Mark Dorset                               IT Department, Trinity College
p:03 9348 7465  m:0412 28 3311          Royal Parade, Parkville VIC 3052
mdorset at trinity.unimelb.edu.au         http://www.trinity.unimelb.edu.au



More information about the samba mailing list