Page 1 of 3 123 LastLast
Results 1 to 10 of 26

Thread: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

  1. #1
    Join Date
    Aug 2012
    Location
    UK
    Beans
    145
    Distro
    Lubuntu

    no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    Yes I've tried the switch on the side haha, even after formatting it over and over again, changing the file system, taking ownership of it - I can't get rid of the lost and found file (when I put write protect on with the switch on the side of the card ubuntu wont even mount the first partition [with the lost & found folder]).

    I had previously used startup disk creator to put lubuntu live on it but at boot it just told me to 'insert bootable media then press any key' so I decided to start again.

    Just read that linux reserves a % of the drive for use by root as a lost and found file? - (lost & found is over 600mb)
    it's partitioned:
    1st: 7gb ext4 for ubuntu live (some folks said not to use ext4 as a boot partition but then others said with it being an sd card it would actually be better? - had used fat32 previously)
    2nd: 7gb fat32 for storage
    3rd: swap partition

    I'm not used to all this hastle, I usually use a usb stick and things go smoothly (for the most part), reason I want a live sd card is because it's faster than disk + I can still use the dvd drive and I don't want a usb stick hanging out the side of the laptop
    when on thin ice; dance

  2. #2
    Join Date
    Feb 2007
    Location
    West Hills CA
    Beans
    10,050
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    First, the "lost&found" is a directory not a file. Inside "lost&found" will be a bunch of randomly numbered files that represent recovered files and bits and pieces of files that were recovered during a file system check. It's possible that your SD card is having problems and thus won't mount or boot properly. The fact that you have 600 MB of files in "lost&found" means you have a lot of files and file fragments during your previous file system check and recovery.

    Running any operating system from SD card or USB stick, you run the risk of disk corruption because of the nature of how flash memory is used and how the "wear-leveling" algorithms interfere with the disk access required by the OS. So although your reasons for using an SD card are sound, the reality is that SD cards are not suited for long-term operating system use. How long was your system stable before the problems?
    -------------------------------------
    Oooh Shiny: PopularPages

    Unumquodque potest reparantur. Patientia sit virtus.

  3. #3
    Join Date
    Aug 2012
    Location
    UK
    Beans
    145
    Distro
    Lubuntu

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    the card was brand new, never been used, tried to install lubuntu live on the primary partition, it wouldn't boot so I formatted it and started again, that's when I had the 600mb+ lost & found problem.

    I've got a few bootable live usb sticks (the oldest will only boot 1 out of 5 times so I presume it's failing [even then it will only boot from a specific usb port] but it is a good 5 years old and actually an mp3 player)

    Edit: This is the usual time I would begrudgingly head downstairs and fire up the naughty box but windows 7 wont even recognise it, by design too - according to the m$ webite.

    Edit 2: sudo rmdir /media/lubuntu/lost+found got rid of it, there was a hidden .999-trash file there too that I deleted & it says there's nothing there at all but it still shows that 600mb+ as being used in properties
    Last edited by greatsirkain; July 3rd, 2013 at 05:42 PM.
    when on thin ice; dance

  4. #4
    Join Date
    Mar 2010
    Location
    India
    Beans
    8,175
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    Quote Originally Posted by greatsirkain View Post
    the card was brand new, never been used, tried to install lubuntu live on the primary partition, it wouldn't boot so I formatted it and started again, that's when I had the 600mb+ lost & found problem.
    The "lost & found" directory is not a problem, it is an inherent part of the Linux file-systems (ext2/3/4). It gets created in every partition formatted as ext2/3/4. By default it is owned by root and normal users don't have even read permission to it, so you can't actually determine the space occupied by it. You can change the permission with "chown" command to see what's in and how much space it has occupied. Unless there was a problem and some files were recovered, it'll be empty occupying no additional space.

    The 600 MB you noticed must have been the reserved space. It is by default 5% of the partition size, if the partition is ext2/3/4. You can change this %age, for example on partition /dev/sdb1, with -
    Code:
    sudo tune2fs -m 0 /dev/sdb1
    0 is the percentage. For partition that contains the operation system or is bootable one, it is recommended to reserve at least 100 MB or more space to avoid crashes. Even for data partitions, it is recommended to reserve at least 2% or 200 MB to avoid excessive fragmentation.

    That being explained, how are you trying to make it live??

    As far as I know, it is mandatory to have the partition formatted as FAT or FAT32 if you want to install a "Live" system on it. This is because "syslinux" - the boot loader that boots a live os - is only compatible with FAT/32, it has been designed as such for a good reason.

    Also, I think all the tools that create a Live USB specifically look for partitions that are formatted as FAT/32. They won't/can't use a partition if it is formatted as an ext file-system.

    By your current partitioning scheme, it seems you are attempting a full installation, which is okay, but will significantly reduce the life of the card.
    Varun
    Help others by marking threads as [SOLVED], if they are. (See how)
    Wireless Script | Use Code Tags
    Am I not replying your post? This is why.

  5. #5
    Join Date
    Feb 2007
    Location
    West Hills CA
    Beans
    10,050
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    5% of a 7GB OS partition would be around 350MB of reserved space. It's possible that there was a write error when initially installing to the SD card. That is consistent with non-boot behavior. Reformatting the partition will not fix such an error because it is either a bad memory location or the SD drive controller (electronics) is having a problem with large, sustained writes.

    I'm running 12.10 and there are no files in lost+found. I'm not sure where the reserved disk space is kept, but I can't see it in my lost+found.
    -------------------------------------
    Oooh Shiny: PopularPages

    Unumquodque potest reparantur. Patientia sit virtus.

  6. #6
    Join Date
    Mar 2010
    Location
    India
    Beans
    8,175
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    Quote Originally Posted by tgalati4 View Post
    5% of a 7GB OS partition would be around 350MB of reserved space. It's possible that there was a write error when initially installing to the SD card. That is consistent with non-boot behavior. Reformatting the partition will not fix such an error because it is either a bad memory location or the SD drive controller (electronics) is having a problem with large, sustained writes.
    That's ^ right.

    @greatsirkain,
    Why are you trying a live system on an ext partition? The swap partition does make some sense, but the rest of the complexity is not worth it. I'd suggest to remove all the partitions (even better - simply re-write a fresh msdos partition table) using gparted and create a single fat32 partition on tha card, as is expected on it. If you have access to a windows machine, you may try formatting the card on it (with fat32 of course) as sometimes it has been reported to make the difference when formatting on Linux doesn't work. If formatting on gparted, make sure to put the "boot" flag on the partition.

    If the live system boots by doing this, you may consider shrinking the partition and creating an additional swap partition (although not recommended for a flash media).

    As for the mysterious 600+ MB usage, the default file browser may get confused sometimes. Just unplug > re-plug the card, and check the property again. Or show us the output of -
    Code:
    df -h
    Varun
    Help others by marking threads as [SOLVED], if they are. (See how)
    Wireless Script | Use Code Tags
    Am I not replying your post? This is why.

  7. #7
    Join Date
    Aug 2012
    Location
    UK
    Beans
    145
    Distro
    Lubuntu

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    I tried the fat32 live version first, when that failed I just wanted to try & make it bootable and have the full OS installed to the ext2 partition, neither would boot on the windows desktop downstairs or this laptop.


    This laptops hard drive wont boot after I formatted it to get rid of windows 7 and put Ubuntu on it so I formatted it again and just use it as storage (booting from USB).


    I looked at the bios of both machines and they looked normal & didn't mention UEFI anywhere but then I noticed bitlocker on the desktop bios so maybe there's some pre UEFI windows TPM voodoo going on (I seem to have lost touch with current computing through using old hardware) which might explain the desktop but the only thing I was unsure of on the laptop bios was 'execute-disable bit' which looks harmless enough, basic anti-virus-y-thingy?



    Without me wanting to confuse things further talking about the desktop anymore (SD card's only for use with the laptop anyway) or looking at alternative bootloaders – I'll redo the partition table then make the single fat32 as varunendra suggested

    ...Can't redo it with windows because windows refuses to recognise the card and the timer just runs continuoulsy as soon as I plug it in until I remove it - on purpose, another example of microsoft locking out hardware it can't control & taking over things it can (another possibility is that the card reader on the desktop is just too old to recognise this card).
    when on thin ice; dance

  8. #8
    Join Date
    Mar 2010
    Location
    India
    Beans
    8,175
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    Quote Originally Posted by greatsirkain View Post
    ...Can't redo it with windows because windows refuses to recognise the card and the timer just runs continuoulsy as soon as I plug it in until I remove it - on purpose, another example of microsoft locking out hardware it can't control & taking over things it can (another possibility is that the card reader on the desktop is just too old to recognise this card).
    ..yet another possibility could be that there is really something seriously wrong with the card itself, like tgalati4 pointed out earlier

    The partitioning scheme you currently have is okay for a full installation. The single fat partition advice was for Live system, a full installation will need an ext partition anyway.
    Varun
    Help others by marking threads as [SOLVED], if they are. (See how)
    Wireless Script | Use Code Tags
    Am I not replying your post? This is why.

  9. #9
    Join Date
    Jul 2010
    Location
    ozarks, Arkansas, USA
    Beans
    10,926
    Distro
    Xubuntu 14.04 Trusty Tahr

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    greatsirkain;
    Recon that card has a lock on it from not being "safely removed" causing problem ? Just a thought, sure others can advise better.
    THE current(cy) in Documentation:
    https://help.ubuntu.com/community/PopularPages

    Happy ubuntu'n !

  10. #10
    Join Date
    Aug 2012
    Location
    UK
    Beans
    145
    Distro
    Lubuntu

    Re: no r/w privilege, SD card, lost & found file, live ubuntu, ext4

    well if I haven't messed up the file system... *shrugs*
    the card works fine when reading/writing there's no problems there now, Ubuntu seems to have installed to it fine, I can mount and un-mount it from within Ubuntu ok, it just doesn't get recognised at boot...I'll check it with other distros and maybe try it in winxp with hbcd.
    I checked the file system of each partition with fsck, each one came back clean and there were no errors reported in gparted...*shrugs again*...I thought if there were actual damage one of them would hint at it?

    *goes for power nap*
    when on thin ice; dance

Page 1 of 3 123 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

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