Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Nov 2008
    Des Moines, IA

    Accessing /dev/sda1 after unlocking drive

    Greetings everyone,

    I am working on an embedded Linux (2.6.1 system that boots from a flash (JFFS2) disk, however the system has a SATA controller and a HDD used only for the storage of data. It is required that the security password be enabled on the drive.

    All of the security work, enable/disable password, unlock drive, etc, all functions as it should.

    The problem is when the system boots (from power on), and the drive is locked, the /dev/sda1 (and /dev/sda2) partitions are not known to the system. I can still access /dev/sda to unlock the drive, and read SMART data, however trying to mount the partitions yields the following error:

    / $ mount -a
    mount: Mounting /dev/sda1 on /mnt/dsk1 failed: No such device or address
    mount: Mounting /dev/sda2 on /mnt/dsk2 failed: No such device or address

    After unlocking the drive, fdisk will show the partitions on the drive.

    So, the question is, how does one get access to these partitions once the drive is unlocked?

    Many thanks,


  2. #2
    Linux Engineer Freston's Avatar
    Join Date
    Mar 2007
    The Netherlands

    I may have had a similar situation. What worked for me was issuing an `fdisk -l` (that is a small L, not a 1 or a capital i) before mounting. It's ugly, but it forces a reread of the partitioning table, so the newly accessible partitions get 'discovered'. You can make it non-verbose by doing it like this: `fdisk -l > /dev/null`

    I dunno if it'll work for you, but it seems worth a shot
    Can't tell an OS by it's GUI

  3. #3
    Just Joined!
    Join Date
    Nov 2008
    Des Moines, IA
    Many thanks for your reply!!

    Unfortunately, it does not work. The fdisk displays the partitions, as seen below:

    / $ fdisk -l

    Disk /dev/sda: 250.0 GB, 250059350016 bytes
    255 heads, 63 sectors/track, 30401 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot Start End Blocks Id System
    /dev/sda1 1 244 1959898+ 83 Linux
    /dev/sda2 245 30401 242236102+ 83 Linux

    I thought this would have worked as well. Hence my posting here.

    If this should work,this might point to a problem in the block device, or the scsi driver. I wonder if some error is set in the device table, and not being cleared out appropriately.

    Many thanks for your reply.



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts