How to mount remote windows partition (windows share) under Linux

导读:

  All files accessible in a Linux (and UNIX) system are arranged in one big tree, the file hierarchy, rooted at /. These files can be spread out over several devices. The mount command serves to attach the file system found on some device to the big file tree.

  Use the mount command to mount remote windows partition or windows share under Linux as follows:

   Procedure to mount remote windows partition (NAS share)

  1) Make sure you have following information:

  ==> Windows username and password to access share name

  ==> Sharename (such as //server/share) or IP address

  ==> root level access on Linux

  2) Login to Linux as a root user (or use su command)

  3) Create the required mount point:

  # mkdir -p /mnt/ntserver

  4) Use the mount command as follows:

  # mount -t cifs //ntserver/download -o username=vivek,password=myPassword /mnt/ntserver

  Use following command if you are using Old version such as RHEL <=4 or Debian <= 3:

  # mount -t smbfs -o username=vivek,password=D1W4x9sw //ntserver/download /mnt/ntserver

  5) Access Windows 2003/2000/NT share using cd and ls command:

  # cd /mnt/ntserver; ls -l

  Where,

   -t smbfs: File system type to be mount (outdated, use cifs)

   -t cifs: File system type to be mount

   -o: are options passed to mount command, in this example I had passed two options. First argument is password (vivek) and second argument is password to connect remote windows box

   //ntserver/download: Windows 2000/NT share name

   /mnt/ntserverLinux mount point (to access share after mounting)

  See also:

  Configure a system to automount a Samba share with /etc/fstab file

  Updated for accuracy on Aug-8-2007, 8:19PM.

  Want to stay up to date with the latest Linux tips, news and announcements? Subscribe to our free e-mail newsletteror full RSS feedto get all updates. You can Email this pageto a friend.

   You may also be interested in...

  Linux mount remote filesystems automatically at boot time

  Resize Windows Partition with Open Source Software

  Best Linux / UNIX Posts of 2007: Part ~ I

  How to add Windows TrueType fonts easily in Linux desktop system

  Tip of the day: Automount your Linux samba host into a Windows environment

   Discussion on This Article:

  D'AngeloSays: February 2nd, 2007 at 12:40 am

  I Have two Operating System, Windows XP the other is Fedora how can I make them talk to each other, how can I make them file share?

  nixcraftSays: February 2nd, 2007 at 3:23 am

  D’Angelo,

  Is it a dual boot system or networked system?

  NandkishorSays: May 8th, 2007 at 7:31 am

  Hi,

  I have used dual boot system, using Windows 2001 &Red Hat Linux.

  1) How make them to speak or share etch other files.

  2) How I login Linux &windows without restarting the computer. There is any utility for this.

  Regards,

  Nandkishor

  nadavSays: May 8th, 2007 at 1:57 pm

  using -t cifs : File system type to be mount

  seams to work better is some cases

  example:

  mount -t cifs //server/share /mnt –verbose -o user=username

  michaelSays: August 2nd, 2007 at 12:32 pm

  I tried this command on my Ubuntu system but got the following error:

  mount: wrong fs type, bad option, bad superblock on //server_name/Ubuntu_Backups,

  missing codepage or other error

  In some cases useful info is found in syslog - try

  dmesg | tail or so

  I also tried nfs but still no good. I have a windows server 2003 machine I am sharing to the ubuntu box.

  martinSays: August 3rd, 2007 at 11:50 am

  Hi,

  i have exactly the same issue michael…

  Does anyone know, what the problem is?

  thanks a lot,

  martin

  vivekSays: August 3rd, 2007 at 2:51 pm

  michael / martin,

  Use cifs option instead of smbfs (outdated and not supported).

  HTH

  francoSays: November 28th, 2007 at 7:56 pm

  Martin, Michael, you must have smbfs installed to run cifs, so

  $sudo aptitude install smbfs

   Leave a Reply

  We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!

  Name (required)

  Mail (will not be published) (required)

  Website

   XHTML:You can use these tags: ="" ="" ="" ="" ="" ="" ="">
  

  Anti-spam word: (Required)*

  To prove you're a person (not a spam script), type the security word shown in the picture.



本文转自

http://www.cyberciti.biz/tips/how-to-mount-remote-windows-partition-windows-share-under-linux.html
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值