为什么shutil.copy抛出" OSError:[Errno 38]功能未实现:' / media / some / path'"?

时间:2015-08-16 17:11:30

标签: python linux shutil

我有一个相对简单的代码片段会引发错误:

import shutil
abspath_to_source_file = '/media/moose/VFF1147/MAP_DATA/BACK/B0000040.DFT'
target_dir = '/media/moose/9C33-6BBD/PRIVATE/PANA_GRP/PAVC/LUMIX/MAP_DATA/BACK'
shutil.copy2(abspath_to_source_file, target_dir)

给出了

Traceback (most recent call last):
  File "/usr/local/bin/lumixmaptool", line 4, in <module>
    __import__('pkg_resources').run_script('lumixmaptool==1.0.15', 'lumixmaptool')
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 735, in run_script
    self.require(requires)[0].run_script(script_name, ns)
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 1652, in run_script
    exec(code, namespace, namespace)
  File "/usr/local/lib/python2.7/dist-packages/lumixmaptool-1.0.15-py2.7.egg/EGG-INFO/scripts/lumixmaptool", line 56, in <module>
    main(args)
  File "/usr/local/lib/python2.7/dist-packages/lumixmaptool-1.0.15-py2.7.egg/EGG-INFO/scripts/lumixmaptool", line 49, in main
    copy.main(args.mapdata, args.path_to_sdcard, args.regions)
  File "/usr/local/lib/python2.7/dist-packages/lumixmaptool-1.0.15-py2.7.egg/lumixmaptool/copy.py", line 177, in main
    copy_maps(mapdata, path_to_sdcard, regions)
  File "/usr/local/lib/python2.7/dist-packages/lumixmaptool-1.0.15-py2.7.egg/lumixmaptool/copy.py", line 148, in copy_maps
    shutil.copy2(abspath_to_source_file, target_dir)
  File "/usr/lib/python2.7/shutil.py", line 131, in copy2
    copystat(src, dst)
  File "/usr/lib/python2.7/shutil.py", line 100, in copystat
    os.chmod(dst, mode)
OSError: [Errno 38] Function not implemented: '/media/moose/9C33-6BBD/PRIVATE/PANA_GRP/PAVC/LUMIX/MAP_DATA/BACK/B0000040.DFT'

原因最终是文件系统吗? (如果我没记错的话,我把它格式化为exFAT,但是当我尝试df -Tmount时,我只会得到#39; fuse {sudo file -Ls /dev/sdb1 DOS/MBR boot sector })

第一个问题:问题是什么?

第二个问题:我该如何解决?

0 个答案:

没有答案