Centos 掛載windows分區 出現mount: unknown filesystem type 'ntfs' 掛載大於2T硬碟

來源:互聯網
上載者:User

今天幫客戶掛載一個USB 移動硬碟4T,NTFS格式,遇到了一些問題,總結記錄如下,

系統

#fdisk -l

有看到一個4T硬碟

WARNING: GPT (GUID Partition Table) detected on '/dev/sdc'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sdc: 4000.8 GB, 4000787029504 bytes
256 heads, 63 sectors/track, 484501 cylinders
Units = cylinders of 16128 * 512 = 8257536 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x0fecfae6

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1               1      266306  2147483647+  ee  GPT
Partition 1 does not start on physical sector boundary.

 

 

掛載移動硬碟: 
      # mount –t ntfs /dev/sdc1 /mnt/windows
      mount: unknown filesystem type ‘ntfs’ 
      提示無法識別NTFS格式的分區。 

解決辦法: 
      通過使用 ntfs-3g 來解決。 
      開啟ntfs-3g的下載點http://www.tuxera.com/community/ntfs-3g-download/ ,將最新穩定(當前最新版本為ntfs-3g_ntfsprogs-2016.2.22)下載到CentOS,執行以下命令安裝: 
      1) 編譯安裝 ntfs-3g:

# tar zxvf  ntfs-3g_ntfsprogs-2016.2.22.tgz

# cd ntfs-3g_ntfsprogs-2016.2.22

#./configure

#make

#make install

在網上找了,方法一樣安上 還是不能掛載,最後在官方站 找到方法了,如下:

[root@localhost ~]# mount -t ntfs-3g /dev/sdc1 /mnt/windows 

NTFS signature is missing.
Failed to mount '/dev/sdc1': 無效的參數
The device '/dev/sdc1' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a
partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?

又報錯了,

 

-------------------------------------------------------------------------

試著查看4T硬碟分區#lsblk

NAME                        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sdc                           8:32   0   3.7T  0 disk
|-sdc1                        8:33   0   128M  0 part
`-sdc2                        8:34   0   3.7T  0 part /mnt/windows  分區是在sdc2上
sda                           8:0    0 111.3G  0 disk
|-sda1                        8:1    0   500M  0 part /boot
`-sda2                        8:2    0 110.8G  0 part
  |-VolGroup-lv_root (dm-0) 253:0    0    50G  0 lvm  /
  |-VolGroup-lv_swap (dm-1) 253:1    0   7.8G  0 lvm  [SWAP]
  `-VolGroup-lv_home (dm-2) 253:2    0    53G  0 lvm  /home
sdb                           8:16   0  10.9T  0 disk
`-sdb1                        8:17   0  10.9T  0 part /fairpur
sr0                          11:0    1  1024M  0 rom 

 

 

[root@localhost ~]# mount -t ntfs-3g /dev/sdc2 /mnt/windows 

成功,可以看到資料了

這樣就可以掛載了,如果想開機啟動 ,就掛載上的話,編輯/etx/fstat 檔案

如下,如果只是想拷貝一下資料就不用加自啟動了:

/dev/sdc2     /mnt/windows    ntfs-3g        defaults 0 0

 最後可以用mount /mnt/windows  檢測下 fstab 檔案修改是否有錯

 

 

拷貝資料 

#cp -r -f /mnt/windows/*  /www/  拷貝(並覆蓋不提示)

如這裡有提示還是要輸入Y 一個一個覆蓋 輸入

# vi ~/.bashrc
在alias cp='cp -i'前加上"#"注釋掉這行,:wq!儲存推出,然後重新登陸就可以了。

查看某檔案夾檔案大小

#du -h --max-depth=1 /mnt/windows/images

356M    /mnt/windows/images/201608
116M    /mnt/windows/images/201609
1.5M    /mnt/windows/images/avatar
8.3G    /mnt/windows/images/buy
581G    /mnt/windows/images/content
193G    /mnt/windows/images/thumb
783G    /mnt/windows/images/  這個檔案夾總計783G

可以用來對比拷貝過去的資料 有沒有完成對比

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.