LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 01-14-2008, 12:53 PM   #1
suresheva31
LQ Newbie
 
Registered: Oct 2004
Posts: 25

Rep: Reputation: 15
mount windows partition


Hi there,

i want to mount windows patition using samba.

I believe this is the command:
mount -t smbfs //hostname/c$ /mnt/windows2003

what is the options to enter the username and password in that commnad?

when I execute the above command, it asks for the password, assuming "root" as windows user? I want to put the username and password in the command/

Any idea experts?

Thanks
Kumar
 
Old 01-14-2008, 01:50 PM   #2
Lenard
Senior Member
 
Registered: Dec 2005
Location: Indiana
Distribution: RHEL/CentOS/SL 5 i386 and x86_64 pata for IDE in use
Posts: 4,790

Rep: Reputation: 58
Try;
mount -t cifs //hostname/c$ /mnt/windows2003 -o user=username,pass=password
mount -t smbfs //hostname/c$ /mnt/windows2003 -o username=Fred,password=something
 
Old 01-14-2008, 02:00 PM   #3
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
If you have a recent kernel, it would be better using cifs because smbfs is depreciated and unsupported.

You could also create a .credentials file in your home directory that is only readable by you and then mount it with:
sudo mount -t cifs //hostname/sharename /mnt/windows2003 -o cifs,credentials=/home/<username>/.credentials

By the way, only offer as a service on the windows computer what you need to, and never share the C$ drive or any system directory. That is a security risk.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mount windows partition vcatalano Debian 6 11-11-2006 11:30 PM
Can't mount Windows XP partition hayden Fedora - Installation 15 09-16-2004 05:04 PM
How do I mount a Windows partition? jianneng Linux - Newbie 6 02-08-2003 12:06 AM
can't mount windows nt partition cyberswami Linux - General 3 01-26-2003 09:22 PM
cant mount windows partition MrPolite Linux - General 18 08-30-2002 12:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:45 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration