Register
It is currently Wed Nov 22, 2017 5:31 am

Removable media restrictions


All times are UTC


Post new topic Reply to topic  [ 1 post ] 
Author Message
 PostPosted: Fri Aug 04, 2017 1:46 pm   
. . . .
User avatar

Joined: Mon Apr 21, 2003 3:56 pm
Posts: 8265
Recently dropped one Debian derived distribution to install another, more highly regarded Debian based distribution. The latter distribution sits atop the current Distrowatch list, so I felt safe with the idea of going into a straight install using Mate, on my Athlon X2 64 bit eMachine.

In all my computer usage, I use several removable media, mostly USB flash drives. I store payment records on one drive (mount, store the payment record, unmount), music files on another drive (mostly only reading files to the MP3 player of my choice), and I'll archive both of those onto a USB hard disk.

A couple days ago, I inserted the records device, it automagically appeared on my desktop and was already mounted, a big no-no in my computing life. You see, when I use as many distros in a month as some people do oil changes over the life of their auto.... you get to see errors on your media.

My devices permissions had been converted to root.root, but I inserted the device as user and now I cannot write! SU/SUDO/direct root login to chown the mount point, and/or all the files on the removable media? No good.

My current distribution isn't the cause, since I've seen and posted about this issue before. The base issue is partly as follows. For whatever reason, SOME drives I use get permissions locked when I insert them into SOME Debian based distributions. I know the permissions on both the records and the music devices were set up for mmmna.mmmna. In my current distribution, the devices are both root.root, and the biggest issue is that logging in as root, I am totally unable to chown the root.root files into mmmna.mmmna. Wut? Rhetorically speaking, If root can't fix it, who can?

My successful response required me to do the following (very time consuming):
  • copy all the files from the removable media as user (my current distro can barely move files at 4.5 megabits per second (the hardware does go much faster), my drives total hundreds of gigs, more than 15 of thousand files on one)
  • diff -dr all the files on the local hard disk versus what was on the flash media and correct any issues (just as slow)
  • when any issues are resolved, delete all the files on the removable media
  • repartition the removable flash media for those media where I personally doctored the partitions
  • create non FAT file systems, because there have been a few write issues lately (unusually slow)
  • copy all the hard disk files back onto the removable media (slow in this direction as well)
  • diff -dr all the files on the flash media versus what was on the local hard disk drive (did I say slow yet?)
  • When the copies placed on the removable flash media are matched with the local hard disk files AND the permissions are mmmna.mmmna AND I can write a file to the parent folder of the removable flash media
  • delete the local hard disk files

I've been choosing ext3 for the later partitions, because I've seen a few errors on the former FAT file systems and am not using any Micro$oft OS.

So there you have it, I fixed my troubles. This took about 30 hours.

Synopsis:
-unsure if my repartitioned media was the root cause
-rather sure that Debian based distros have some of the blame for their refusal to allow root to chown root.root files
-choose file systems that Linux has deepest knowledge about
-copy the files as user
-recursive options to diff and chown

Now to try an RPM based distro or two since I've been focusing on Debian based distros and I'm seeing this problem only on the Debian based distros.

_________________
eMachines T5246 AMD 64 X2 w/Antix 16.2 for AMD64
EeePC 900A w/ Antix 16.2 32 bit
Dell Inspiron 1545 w/ Fedora something recent for 32 bit


Top
 Profile  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: Majestic-12 [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  


Powered by phpBB © 2012 phpBB Group
© 2003 - 2012 USA LINUX USERS GROUP