LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-15-2011, 01:55 AM   #1
JATA01
Member
 
Registered: Nov 2007
Posts: 207

Rep: Reputation: 15
Exclamation mount: block device giving read only


Hi,

I want to keet some data on windows dir. I have tried the below command and giving the below error.

[root@xyz0044 ~]# mount -t cifs //10.48.64.52/jata -o username=domain\v.kumar3,password=xxxx /mnt/backup
mount: block device //10.48.64.52/jata is write-protected, mounting read-only
mount: cannot mount block device //10.48.64.52/jata read-only


Thanks-
Shankar
 
Old 03-15-2011, 02:29 AM   #2
sem007
Member
 
Registered: Nov 2006
Distribution: RHEL, CentOS, Debian Lenny, Ubuntu
Posts: 638

Rep: Reputation: 113Reputation: 113
Hi,

Check sharing and security permission on windows. There might only read permission on folder.
 
Old 03-17-2011, 05:25 AM   #3
JATA01
Member
 
Registered: Nov 2007
Posts: 207

Original Poster
Rep: Reputation: 15
Yes, I have created a folder name jata in D: directory and gien full access, but problem still same.
Do we need to install cifs_utils rpm on linux box? it's a production box. we can't find cifs_utils on my proxy server.
Is there any other way or do we need samba??

Thanks-
Shankar
 
Old 03-17-2011, 08:12 AM   #4
agentbuzz
Member
 
Registered: Oct 2010
Location: Texas
Distribution: Debian, Ubuntu, CentOS, RHEL
Posts: 131

Rep: Reputation: 25
samba client

Shankar,
You don't need all of Samba unless you will be mounting shares FROM Windows to your Linux box, but you do need the samba client and winbind and the Kerberos 5 libs and userland programs for getting Kerberos tickets. Here are the package names on a CentOS box:

Code:
[root@localhost ~]# cat /etc/redhat-release
CentOS release 5.5 (Final)

samba-client.x86_64
samba3x-winbind.x86_64
krb5-libs.x86_64
krb5-workstation.x86_64
krb5-auth-dialog.x86_64
pam_krb5.x86_64
You will still have to define your Kerberos realms, KDCs, etc., in /etc/krb5.conf.
Code:
man krb5.conf
 
Old 03-18-2011, 07:39 AM   #5
Reuti
Senior Member
 
Registered: Dec 2004
Location: Marburg, Germany
Distribution: openSUSE 15.2
Posts: 1,339

Rep: Reputation: 260Reputation: 260Reputation: 260
@agentbuzz: how does the mount of a Windows share refer to Kerberos?
 
Old 03-18-2011, 10:04 AM   #6
agentbuzz
Member
 
Registered: Oct 2010
Location: Texas
Distribution: Debian, Ubuntu, CentOS, RHEL
Posts: 131

Rep: Reputation: 25
Reuti,
In my case, the Windows users have to access resources on the Linux server and there is a password expiration policy. I don't want to maintain a separate Samba password for the home shares. So, I need Service Principal Names for the Linux server; Kerberos uses the SPNs. Those can only exist if the Linux server is a domain "Member Server" in AD. As well, I have to use winbind and can only do that if the Linux server is a domain member. To join the domain and then enumerate shares or mount them, I must have configured Samba in ADS mode to use Kerberos. As far as mounting the Windows share from Linux, it can be done using either NTLMv2 or Kerberos, but it's easier if the Linux box can obtain a TGT from the Windows DC/KDC and can simply ask for an additional ticket for the shared resource. The "machine account" in AD is granted write privilege to the share and doesn't have to have service account credentials cached somewhere.
 
Old 03-19-2011, 02:34 PM   #7
JATA01
Member
 
Registered: Nov 2007
Posts: 207

Original Poster
Rep: Reputation: 15
In our scenario..

one report file is created on linux servers and I want this file(content of this file) should be sync with windows file.
I have tried cift but some where I read that 2.6.18 kernel has some bug and can't mount cifs.
Using samba only samba share file should available on windows but content will be on linux only and user which has no access of linux server.
what steps we need to setup using kerberos??

Thanks-
Shankar
 
Old 03-21-2011, 02:50 AM   #8
JATA01
Member
 
Registered: Nov 2007
Posts: 207

Original Poster
Rep: Reputation: 15
Please find the below error and suggest, how to mount windows(win2003 standard edition) dir on linux(2.6.18-92.1.1.el5).

[root@indls00xx ~]# sudo mount -t cifs //indws00yy/jata(windows file) /share -o username=<domain>\<username>,password=<xxxx>,domain=<domain name>
mount error 13 = Permission denied
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)
[root@indls00xx ~]# sudo mount.cifs //indws00yy/jata /share -o username=<doamin>\<username>,password=xxxx,domain=<domain name>
mount error 13 = Permission denied
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)
You have mail in /var/spool/mail/root
[root@indls0037 ~]#


Thanks-
Shankar
 
Old 04-06-2011, 03:21 AM   #9
JATA01
Member
 
Registered: Nov 2007
Posts: 207

Original Poster
Rep: Reputation: 15
Hi,

I was making mistake, 2nd option works perfect after installing samba packages.

1. #mount -t cifs //10.48.64.52/jata -o username=domain\v.kumar3,password=xxxx /mnt/backup

2. #mount -t cifs //10.48.64.52/jata -o username=domain/v.kumar3,password=xxxx /mnt/backup

Thanks-
Shankar
 
  


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 -cifs giving read only error kiwidesign Linux - Newbie 10 06-16-2021 06:53 PM
mount: block device is write-protected, mounting read-only xpucto Linux - Server 10 02-01-2017 03:16 AM
mount: cannot mount block device ... read-only Krajisnik Linux - Newbie 4 07-15-2009 03:33 AM
block device read size ta0kira Programming 0 10-17-2008 04:02 AM
Why Linux returns the device size for 1 block more when it could be read?? fa3a Programming 1 01-29-2004 07:23 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:47 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