[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Re: Read-only USB scan



Hi,

 hdparm -r1 /dev/sda
works and I get this output when I read back the information with plain '-r'

  $ sudo hdparm -r /dev/sda

/dev/sda:
 readonly     =  1 (on)


Does this make it really read-only ?

My harddisk is having a PV and then a VG ... LV which if i mount, still is able to write to it ? [ VG activation is successful ]

(dont know if 'write' means really write a large file but I checked using touch command and I am still able to create the file)

My kernel is 2.6.21.1

Is there anything I am missing here ?


Ron Johnson wrote:
<div class="moz-text-flowed" style="font-family: -moz-fixed">On 12/20/08 12:32, Bhasker C V wrote:
Hi all,


I have a server where there is a USB SCSI disk with lots of important data. The only problem is accidentally people try to understand some other similar ide-scsi disk (sdb may be) as the
 first one (sda) and delete data.

I was going to find out if there is any method so that I can make a disk (a particular device) read-only. i.e in case I insert this disk with very important data, I must be able to make this disk (may be scanned as sdX) as readonly so that people are only able to see the partition, mount it and use it ratherthan try to accidentally delete data which
will result in disk reporting it as read-only

[ PS: I am not referring a workaround of mouting a partition read-only which can still help, but i want the whole disk
  to be made read-only ]

# hdparm -r

You might have to crack open the USB enclosure and physically install the drive in a PC in order for this to work.


--
Bhasker C V
Registered Linux user: #306349 (counter.li.org)
The box said "Requires Windows 95, NT, or better", so I installed Linux.


Reply to: