2013-11-28 29 views
12

我是新來融合。當我嘗試運行一個FUSE客戶端程序,我得到這個錯誤:如果您使用保險絲安裝到非空安裝點,會發生什麼情況?

fuse: mountpoint is not empty 
fuse: if you are sure this is safe, use the 'nonempty' mount option 

我明白,一個掛載點這裏,您將邏輯附加FUSE文件系統的目錄。如果我安裝到這個位置會發生什麼?有什麼危險?只是該目錄會被覆蓋?基本上:如果你掛載到非空目錄會發生什麼?

回答

13

您需要確保保險絲上安裝的設備上的文件而不是與非空掛載點中已存在的文件具有相同的路徑和文件名。否則這會導致混淆。如果您確定,請將-o nonempty傳遞給mount命令。

您可以嘗試什麼是使用下面的命令..發生(Linux的岩石!)..不破壞任何東西..

// create 10 MB file 
dd if=/dev/zero of=partition bs=1024 count=10240 

// create loopdevice from that file 
sudo losetup /dev/loop0 ./partition 

// create filesystem on it 
sudo e2mkfs.ext3 /dev/loop0 

// mount the partition to temporary folder and create a file 
mkdir test 
sudo mount -o loop /dev/loop0 test 
sudo echo "bar" test/foo 

# unmount the device 
sudo umount /dev/loop0 

# create the file again 
echo "bar2" > test/foo 

# now mount the device (having file with same name on it) 
# and see what happens 
sudo mount -o loop /dev/loop0 test 
+0

-nonempty你的意思呢? FUSE(FuseHandler(a),b,foreground = True)我是否將-o nonempty添加到該調用中? – bernie2436

+0

您是否使用命令行工具或編程語言來控制保險絲? – hek2mgl

+0

我打電話給一個導入pyfuse的python文件 – bernie2436

1

顯然什麼也沒有發生,它以非破壞性的方式失敗,並給你一個警告。

我最近也遇到過這種情況。你能解決這個的一種方式是通過在非空掛載點移動的所有文件到別的地方,例如:

mv /nonEmptyMountPoint/* ~/Desktop/mountPointDump/ 

這樣,你的掛載點現在是空的,你的mount命令將工作。

2

就在mount命令的命令行

s3fs -o nonempty <bucket-name> </mount/point/> 
相關問題