Linux Tips and Tricks

A collection of tips, tricks and everything linux

Access a microsoft windows share from the bash terminal in Ubuntu Linux Desktop

with one comment

Setup

Ever want to access a windows share from your terminal? Well using ‘ mount ‘ and cifs/samba this is a snap.

Make sure you have smbfs/cifs support, on ubuntu linux distributions you can simply type
apt-get install smbfs
Now we need to make a directory on our hard disk where we can mount our windows share.
mkdir /mnt/location

Mounting Windows Share

Now we\’re ready to mount the filesystem on our newly created directory (/mnt/location).

Mount with cifs
mount -t cifs //server-ip-or-name/share /mnt/location -o username=user,password=pass,domain=DOMAIN
Mount with smbfs
mount -t smbfs //server-ip-or-name/share /mnt/location -o username=user,password=pass,domain=DOMAIN

Clean Up

When finished with our windows mount, we should exit the directory, or close any windows that are accessing it, and then unmount the Microsoft Windows NTFS share by using the following series of commands.

cd /; umount /mnt/location

Written by mnk0

September 22nd, 2008 at 4:02 pm

One Response to 'Access a microsoft windows share from the bash terminal in Ubuntu Linux Desktop'

Subscribe to comments with RSS or TrackBack to 'Access a microsoft windows share from the bash terminal in Ubuntu Linux Desktop'.

  1. Very well written article you got here. As 1 blogger to another, I recognize how challenging and how much time it requires to conjure up something tangible and good. You have my respect.

    attract a woman

    1 Jul 10 at 11:11

Leave a Reply