Page 2 of 2 FirstFirst 12
Results 11 to 12 of 12

Thread: 18.04 -- USB to SATA External Hard Drive not recognized

  1. #11
    Join Date
    Jun 2014

    Re: 18.04 -- USB to SATA External Hard Drive not recognized

    If you are developing bad sectors on your windows system you should first run chkdsk which must be done from windows. If you can't do it from windows, you may need to download some windows tool to do it or use the Repair function on the windows installation DVD (if you have one). There is Linux software called ntfsfix which might repair a very minor problem with an ntfs filesystem but it is very limited on the proprietary ntfs filesystem as one would expect.

    As suggested above, if you have windows 10, was this external drive attached to windows 10 and was that system hibernated or was fast boot on? Linux systems won't mounted a drive which shows as hibernated.

  2. #12
    Join Date
    Mar 2010

    Re: 18.04 -- USB to SATA External Hard Drive not recognized

    With great power comes great responsibility. Linux has great power. It, the OS, has an expectation that the OS users are responsible.

    Linux skills aren't something you can expect to gain overnight. Windows skills seldom transfer. When beginning with Linux, a strong foundation of understanding is very helpful. As a Windows user, people are used to the OS holding their hands and trying to stop them from attempting dumb things. Linux is different. The OS doesn't know if you are ignorant or a genius, so it assumes you know what you are doing and will actually do what is requested. If what you mean isn't the same as what you request, well, bad things can and do happen all the time.

    Linux (and all Unix-based OSes) are multi-user. Each command runs with a specific effective userid and specific effective groupid. These control the access to directories and files on the system. Everything on Unix is either
    a) a file
    b) a process
    everything. A process is a running program. Anything that isn't a running program, is a file. Period. Files have an owner, group, and permissions. This controls all access.

    BTW, drives don't get mounted. File systems get mounted.
    Drives hold partitions. Partitions can hold a few other things, one of which might be a file system, but that isn't actually required.

    sda = drive, the entire drive.
    sdb = drive, a different drive.
    sda1 = the first partition on the drive, sda
    sda2 = the 2nd partition on the drive, sda

    File systems - there are many, many, different types of file systems. Each has strengths and weaknesses. In Windows, there are basically 3 file systems - NTFS, FAT32 and exFAT.
    In Linux, there are 20+ popular file systems. ext2, ext3, ext4, zfs, xfs, jfs, ReiserFS, brtfs, f2fs, .... and in certain situations, NTFS, FAT32 and exFAT can be accessed by Linux systems, assuming the file system was properly "closed" by Windows before being disconnected.
    Windows and Linux file systems have some major differences, mainly around user, group and file permissions.
    In Windows, permissions were never really central to the OS security model. Whenever you copy a file, you get the data and that is pretty much all you need.

    In Linux, file and directory permissions are ABSOLUTELY CRITICAL to the OS security model. When you copy a file, you need the data, but you also need the owner, group, permissions and ACLs which are connected to the file. Getting just the data won't leave you with a working file, unless it is just data.

    This is meant to explain why copying files between different file systems doesn't always get everything you need. Going FROM Windows to Linux will probably be fine, since Windows thinks of all files as data. Going from a Linux file system to Windows, will lose the extra parts of those files which can be extremely important to make use of the file later.

    Copying data usually happens either by imaging - bit-for-bit - copying or by using file copies.

    dd, clonezilla, ddrescue, partimage, and a few others are bit-for-bit copies. They have to be used at the partition or disk level to be most effective. Notice, I didn't say File System. By cloning a partition, we get the file system and all the files/directories included.

    rsync, tar, rdiff-backup, and most other backup tools are file-level copies. They work at the individual file/directory level and allow copying 1 file or an entire file system full of files. This provides more flexibility in which specific areas of the directories are copied. But care is required to get not just the data, but also the ownership, group and file permissions.

    So, with all that background, assuming you have access to the file systems for the SOURCE and TARGET directories on the 2 different disks, then I would use rsync to mirror all the files.

    $ rsync -avz {SOURCE} {TARGET}
    This only works after the source and target file systems are mounted. rsync will try to get the permissions and data. The owner will be the current userid running the rsync command.

    A quick review .... everything is a file if it isn't a process. That means you can run file commands on anything on the system if you have permissions which allow that access for the file.
    A file is a file (hosts)
    A directory is a file (/etc/)
    A partition is a file (sda1)
    An entire HDD is a file (sda)
    The mouse device is a file
    The screen device is a file
    A network card is a file
    A specific network port is a file
    The keyboard is a file.
    A virtual machine is a file, unless it is running, then it is both a file and a process.

    File permissions, ownership and group membership are central to all Unix security.

    So, if you want to understand any Unix system, like Linux, Android, OSX, iOS, then a good understanding of file access, file permissions, file management, would be a good thing to master, yes?

    I didn't mean to scare anyone with this information, but just trying to point out that Unix is really very simple. From 1 simple idea, everything is a file, the entire OS has been built, but since everything is a file, some very basic capabilities are possible.

    Oh ... and lsblk -f is a very helpful command to see the HDD, partitions, file systems and mount point for connected storage.

Page 2 of 2 FirstFirst 12

Tags for this Thread


Posting Permissions

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