Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > alt.os.linux.ubuntu > #197460 > unrolled thread

Mount external ext4 partition

Started byMike Easter <MikeE@ster.invalid>
First post2017-10-13 15:12 -0700
Last post2017-10-15 16:58 -0400
Articles 20 on this page of 25 — 7 participants

Back to article view | Back to alt.os.linux.ubuntu


Contents

  Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-13 15:12 -0700
    Re: Mount external ext4 partition Bit Twister <BitTwister@mouse-potato.com> - 2017-10-14 00:41 +0000
    Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 00:03 -0700
    Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 11:54 -0700
      Re: Mount external ext4 partition "Jonathan N. Little" <lws4art@gmail.com> - 2017-10-14 15:03 -0400
        Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 12:54 -0700
          Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 13:17 -0700
            Re: Mount external ext4 partition Paul <nospam@needed.invalid> - 2017-10-14 16:37 -0400
              Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 14:08 -0700
              Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 14:28 -0700
                Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 15:09 -0700
                Re: Mount external ext4 partition "Jonathan N. Little" <lws4art@gmail.com> - 2017-10-14 23:21 -0400
                  Re: Mount external ext4 partition Marek Novotny <marek.novotny@marspolar.com> - 2017-10-14 22:22 -0500
                    Re: Mount external ext4 partition "Jonathan N. Little" <lws4art@gmail.com> - 2017-10-14 23:29 -0400
            Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 13:41 -0700
              Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 14:01 -0700
                Re: Mount external ext4 partition Mike Easter <MikeE@ster.invalid> - 2017-10-14 14:17 -0700
                  Re: Mount external ext4 partition Paul <nospam@needed.invalid> - 2017-10-14 18:03 -0400
            Re: Mount external ext4 partition Mike Easter <MIkeE@ster.invalid> - 2017-10-15 18:55 +0000
              Re: Mount external ext4 partition Mike Easter <MIkeE@ster.invalid> - 2017-10-15 19:11 +0000
                Re: Mount external ext4 partition Paul <nospam@needed.invalid> - 2017-10-15 16:40 -0400
                Re: Mount external ext4 partition "Jonathan N. Little" <lws4art@gmail.com> - 2017-10-15 18:31 -0400
          Re: Mount external ext4 partition "Jonathan N. Little" <lws4art@gmail.com> - 2017-10-14 23:17 -0400
    Re: Mount external ext4 partition Big Bad Bob <BigBadBob-at-mrp3-dot-com@testing.local> - 2017-10-15 12:38 -0700
      Re: Mount external ext4 partition Paul <nospam@needed.invalid> - 2017-10-15 16:58 -0400

Page 1 of 2  [1] 2  Next page →


#197460 — Mount external ext4 partition

FromMike Easter <MikeE@ster.invalid>
Date2017-10-13 15:12 -0700
SubjectMount external ext4 partition
Message-ID<f4cs22Fg5lU1@mid.individual.net>
----------------- before it worked -----------------

I have an IDE drive with an ext4 linux partition I removed from a dead 
computer.

I have a kit which allows me to power up the hdd and adapt the ide/pata 
data connection to USB.

Neither windows nor linux nor the computer's BIOS sees that usb hdd. 
The BIOS opportunity is when I use its boot options feature, which bios 
can see other USB devices including flash drives and an external usb hdd 
and an external usb optical as well as the internal SATA.

I didn't try using any other Windows utilities besides its file manager.

In linux, I can see the hdd with GPartEd and see its partitions.  I can 
also see the hdd with Gnome Disks, but disks does not provide me with 
the option to mount the partition I want, which is ext4.  In disks and 
gparted, the hdd is

sdc1 fat32 windows part
sdc2 extended (includes following)
   sdc5 ext4 (my target)
   sdc7 fat32
   sdc6 linux swap

In disks, I can graphically mount and unmount sdc1, but not any other parts.

Such as fdisk -l also shows my various parts.  I don't know much about 
this mounting business from the command line.  I created a directory 
named geode and tried to use it as a mount point:

ubuntu@ubuntu:~$ sudo mkdir geode
ubuntu@ubuntu:~$ sudo mount /dev/sdc2
mount: /dev/sdc2: can't find in /etc/fstab.
ubuntu@ubuntu:~$ sudo mount -t ext4 /dev/sdc2 geode
mount: /home/ubuntu/geode: /dev/sdc2 is not a valid block device.

----------------- end section it didn't work -----------------

Solved.

Aha!  One big advantage of creating a message to ask a question is that 
it causes one to go back over every step.  Doh!  I realized that I was 
using sdc2 as the device I wanted, but it should have been sdc5.  When I 
said:

sudo mount -t ext4 /dev/sdc5 geode

... it worked and when I open the directory geode, I can see the 
contents of the part. It also shows up in the file manager as geode.

This isn't a 'permanent' mounting situation; it is just temporary so 
that I can use a live Ub 17.10 beta2 to copy some directories and files 
from the old linux part to a hdd installed in the computer booting the 
live Ub 17.10.

For contrast with simplicity; I have another usb hdd which was powered 
down when I was having trouble with the above.  When I power it up, it 
also doesn't show in the file manager.  *BUT*  When I use gnome disks, 
it shows and it has the option to mount the drive graphically, which the 
above part didn't do.  After that drive is mounted, it shows in the file 
manager as expected.

-- 
Mike Easter

[toc] | [next] | [standalone]


#197463

FromBit Twister <BitTwister@mouse-potato.com>
Date2017-10-14 00:41 +0000
Message-ID<slrnou2n8u.6cn.BitTwister@wb.home.test>
In reply to#197460
On Fri, 13 Oct 2017 15:12:17 -0700, Mike Easter wrote:
> ----------------- before it worked -----------------
>
> I have an IDE drive with an ext4 linux partition I removed from a dead 
> computer.
>
> I have a kit which allows me to power up the hdd and adapt the ide/pata 
> data connection to USB.

>
> Aha!  One big advantage of creating a message to ask a question is that 
> it causes one to go back over every step.

Just a FYI.

I have a  SIIG SUPERSPEED USB 3.0 to SATA 3.5" Enclosure.

Bought/installed a terabyte drive. Jacked it into a usb
port back of the system.

Now when I power up the enclosure, systemd automagically mounts all
the partitions on the drive.

Originally I created the desired partitions, formatted, and set each
media and partition label to match the ones on my systems. Then
rsync'ed and verified all looked good.

Now here was the downside. Next time I powered it up, systemd mounted
the labeled partitions on/over the top of current mounted partitions
including /.    :-(

Had to go back and add _bk to the USB drive partitions to keep that
from happening again.

[toc] | [prev] | [next] | [standalone]


#197465

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 00:03 -0700
Message-ID<f4dr6uF6pt7U1@mid.individual.net>
In reply to#197460
Mike Easter wrote:
> I have an IDE drive with an ext4 linux partition I removed from a dead 
> computer.
> 
> I have a kit which allows me to power up the hdd and adapt the ide/pata 
> data connection to USB.
> 
> Neither windows nor linux nor the computer's BIOS sees that usb hdd. The 
> BIOS opportunity is when I use its boot options feature, which bios can 
> see other USB devices including flash drives and an external usb hdd and 
> an external usb optical as well as the internal SATA.

I'm trying to figure out this 'missing ingredient' issue, which was 
overcome/mitigated by using linux to create a mountable drive out of 
what appeared to be (almost) 'nothing' (at first glance).

The ingredient is NOT missing in:

  - I have an external SATA-USB enclosure which I used to enclose a 
'free-standing'/'loose' SATA hdd.  The enclosure has a power supply and 
power switch.
  - I have an external USB optical drive; it gets its power by having 2 
USB connections
  - Naturally I have 'gobs' of USB thumb drives

All of those USB devices as well as the internal SATA hdd show up in the 
BIOS, actually UEFI, of the computer which I attached the USB which was 
'handling' the USB/IDE data adapter.

Besides showing up in the computer/UEFI boot menu, all of those devices 
also show up 'spontaneously' in the file managers for Windows and Linux. 
  What is it in the hardware/firmware of the USBs and SATA internal that 
allows/causes the BIOS/UEFI to see the storage device which is *missing* 
from the IDE hdd + USB/IDE adapter which is NOT missing from the other 
external SATA hdd + USB/SATA adapter 'built-in' to the USB enclosure 
which was purchased for the SATA drive?

How is the 'kit' (which consists of various adapter cables and power 
supply) different from the previously empty enclosure for a SATA hdd? 
The kit would allow one to power and data connect one of the following 
drives: SATA, 2.5" IDE, 3.5" IDE.  The kit's power is an AC to molex 
type output which can be converted to sata power pinx by a 
cable/adapter.  The kit's 'data adapter' is a device which has 
inputs/connection for 2 different shapes of IDE pins, 2.5 & 3.5, and 
SATA pins/connection and output as USB.

Initially, I thought something was wrong with the IDE drive or the kit.


-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197466

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 11:54 -0700
Message-ID<f4f4reFgaakU1@mid.individual.net>
In reply to#197460
Mike Easter wrote:
> I have an IDE drive with an ext4 linux partition I removed from a dead 
> computer.

While copying some files from this removed IDE hdd, I encountered some 
.pdf/s which alerted: Permission denied; which upon investigation said I 
could not change the permissions because I wasn't the owner and the 
owner was user #1000 group 1000,  How does one fix that?   The exact 
same problem applied to 6 different .pdf files which had been downloaded 
from 5 different sources, none were created by me, I think.  I can 
neither open nor copy those .pdf/s, so I can't look at them to see if I 
copied, downloaded, or printed to .pdf.

If they /had/ been created by me, it would have been by 'print to .pdf'.


-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197467

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-10-14 15:03 -0400
Message-ID<ortn1e$bin$1@dont-email.me>
In reply to#197466
Mike Easter wrote:
> Mike Easter wrote:
>> I have an IDE drive with an ext4 linux partition I removed from a dead
>> computer.
>
> While copying some files from this removed IDE hdd, I encountered some
> .pdf/s which alerted: Permission denied; which upon investigation said I
> could not change the permissions because I wasn't the owner and the
> owner was user #1000 group 1000,  How does one fix that?   The exact
> same problem applied to 6 different .pdf files which had been downloaded
> from 5 different sources, none were created by me, I think.  I can
> neither open nor copy those .pdf/s, so I can't look at them to see if I
> copied, downloaded, or printed to .pdf.
>
> If they /had/ been created by me, it would have been by 'print to .pdf'.
>
>

sudo chown $USER:$USER *.pdf

Assuming you have sudo rights...

-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


#197468

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 12:54 -0700
Message-ID<f4f8avFh44eU1@mid.individual.net>
In reply to#197467
Jonathan N. Little wrote:
> sudo chown $USER:$USER *.pdf
> 
> Assuming you have sudo rights...

The environment I'm doing this is a live Ub; I believe that su/sudo 
commands don't require a pass.  As far as I know, there isn't one; it 
isn't blank/empty.

But I'm not clear on the $USER syntax above.  Does that colon signify 
'from:to' or what?

The live ub default user is ubuntu and the character at the command 
prompt is $.  I can execute sudo commands from that prompt without any pass.

Am I supposed to be changing user 1000 to ubuntu?  Such as

sudo chown 1000:ubuntu *.pdf

I tried that on one .pdf and it left the user as:  user #1000 and 
changed the group to ubuntu and I still can't open the file.

Second attempt:

sudo chown ubuntu example.pdf

That works on example.pdf to cause the user to say 'Me'  and doesn't 
change the group and I can open the .pdf.  So the part before the colon 
must change the user and the part after change the group and if there 
isn't any colon only the user is changed.

Looking at a couple of those .pdf/s, I would guess they were created by 
print to pdf.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197469

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 13:17 -0700
Message-ID<f4f9mnFhdtbU1@mid.individual.net>
In reply to#197468
Mike Easter wrote:
> sudo chown ubuntu example.pdf
> 
> That works on example.pdf to cause the user to say 'Me'  and doesn't 
> change the group and I can open the .pdf.

But, in the long run, it isn't going to be ubuntu who wants to open/use 
the .pdf; ubuntu is just a temporary user/handler.

Why does there need to be permission restrictions?  Hundreds of other 
files were copied from the IDE hdd to another storage location and 
didn't require solving permission problems; just those 6.  Maybe all of 
them were created by print to .pdf.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197470

FromPaul <nospam@needed.invalid>
Date2017-10-14 16:37 -0400
Message-ID<ortsi9$lqg$1@dont-email.me>
In reply to#197469
Mike Easter wrote:
> Mike Easter wrote:
>> sudo chown ubuntu example.pdf
>>
>> That works on example.pdf to cause the user to say 'Me'  and doesn't 
>> change the group and I can open the .pdf.
> 
> But, in the long run, it isn't going to be ubuntu who wants to open/use 
> the .pdf; ubuntu is just a temporary user/handler.
> 
> Why does there need to be permission restrictions?  Hundreds of other 
> files were copied from the IDE hdd to another storage location and 
> didn't require solving permission problems; just those 6.  Maybe all of 
> them were created by print to .pdf.
> 

The CUPS PDF service, seems to be configurable.

https://embraceubuntu.com/2006/03/23/print-to-pdf-using-cups-pdf/

   "Edit /etc/cups/cupsd.conf and change the line that says:
    RunAsUser Yes
    to
    RunAsUser No

    Restart cupsys:
    sudo /etc/init.d/cupsys restart
   "

Before touching that setting, I'd want to understand
how that changes the ownership of the output files...

    Paul

[toc] | [prev] | [next] | [standalone]


#197473

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 14:08 -0700
Message-ID<f4fcmrFi374U1@mid.individual.net>
In reply to#197470
Paul wrote:
>    "Edit /etc/cups/cupsd.conf and change the line that says:
>     RunAsUser Yes
>     to
>     RunAsUser No

I'm looking at Mint 18.2 Cinn live and Ub 17.10 Gno live and neither 
cupsd.conf has a pre-existing RunAsUser line, nor any other line I've 
found so far which purpose looks like it would do that.

That 2006 info must be ng now.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197475

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 14:28 -0700
Message-ID<f4fdr4FibjdU1@mid.individual.net>
In reply to#197470
Paul wrote:
> I'd want to understand how that changes the ownership of the output
> files...
The default mode of live mint 18.2 CUPS is appropriate.  Print to pdf 
makes permissions owner mint - live session user read/write; group mint 
read/write; others read only.

I have no idea why/how those several .pdf/s on the old hdd got 'that 
way' with the funky owner user #1000 group 1000 Others access none.   "I 
didn't do it."  I've never heard of such a user or group.  I'm sure that 
I was operating as my typical user on a Mint 17 XFCE for all of those.



-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197477

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 15:09 -0700
Message-ID<f4fg7vFisd6U1@mid.individual.net>
In reply to#197475
Mike Easter wrote:
> The default mode of live mint 18.2 CUPS is appropriate.  Print to pdf 
> makes permissions owner mint - live session user read/write; group mint 
> read/write; others read only.

That print to pdf is the same whether the application doing the printing 
is a text editor or a browser Firefox print function.  The difference is 
that the default directory is Documents and the filename Unsaved 
document for the text editor and the user directory and the filename 
mozilla.pdf for the browser.  Previously I believe the default was a PDF 
directory


Aha!  I found something in the old IDE hdd cups dir, a cups-pdf.conf 
file which is not present in current cups dir.  That file has umask 
information section.

The anon umask default is 0000 and the user umask default is 0077.

Since the previous directory was ./PDF, all of those .pdf/s have None 
permissions for others, so there are a lot more than 6.  I also want 
access to all of those .pdf/s, so I should go with chmod *.pdf rather 
than individually.

http://www.cups-pdf.de/cups-pdf-CURRENT/extra/cups-pdf.conf

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197479

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-10-14 23:21 -0400
Message-ID<oruk7g$n3g$1@dont-email.me>
In reply to#197475
Mike Easter wrote:
> I have no idea why/how those several .pdf/s on the old hdd got 'that
> way' with the funky owner user #1000 group 1000 Others access none.

Well the UID 1000 is not funky, in Ubuntu and other Debian distros 1000 
is the first login user on a system. IIRC Redhat and their ilk was 500? 
Been a long time since I use RH and Mandrake.

-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


#197480

FromMarek Novotny <marek.novotny@marspolar.com>
Date2017-10-14 22:22 -0500
Message-ID<6OednZrmnrrhSX_EnZ2dnUU7-c2dnZ2d@giganews.com>
In reply to#197479
On 2017-10-15, Jonathan N. Little <lws4art@gmail.com> wrote:
> Mike Easter wrote:
>> I have no idea why/how those several .pdf/s on the old hdd got 'that
>> way' with the funky owner user #1000 group 1000 Others access none.
>
> Well the UID 1000 is not funky, in Ubuntu and other Debian distros 1000 
> is the first login user on a system. IIRC Redhat and their ilk was 500? 
> Been a long time since I use RH and Mandrake.

For 6.x and lower, yes 500. For 7.x it is 1000.

-- 
Marek Novotny
https://github.com/marek-novotny

[toc] | [prev] | [next] | [standalone]


#197481

From"Jonathan N. Little" <lws4art@gmail.com>
Date2017-10-14 23:29 -0400
Message-ID<orukm1$op6$1@dont-email.me>
In reply to#197480
Marek Novotny wrote:
> On 2017-10-15, Jonathan N. Little <lws4art@gmail.com> wrote:
>> Mike Easter wrote:
>>> I have no idea why/how those several .pdf/s on the old hdd got 'that
>>> way' with the funky owner user #1000 group 1000 Others access none.
>>
>> Well the UID 1000 is not funky, in Ubuntu and other Debian distros 1000
>> is the first login user on a system. IIRC Redhat and their ilk was 500?
>> Been a long time since I use RH and Mandrake.
>
> For 6.x and lower, yes 500. For 7.x it is 1000.
>

I said it's been a long time ;-)

-- 
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

[toc] | [prev] | [next] | [standalone]


#197471

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 13:41 -0700
Message-ID<f4fb3kFho79U1@mid.individual.net>
In reply to#197469
Mike Easter wrote:
> Hundreds of other files were copied from the IDE hdd to another storage 
> location and didn't require solving permission problems; just those 6.  
> Maybe all of them were created by print to .pdf.

I looked at another .pdf in a same directory which didn't alert.  The 
difference in permissions was in the Others access.

Owner: User #1000
Access: Read and write

Group: 1000
Access: Read only

Others:
Access: Read only


Whereas the problem .pdf/s were the same as above in Owner/Group but 
instead the Others access said None.

The nature of these printed .pdf/s is that I don't really care what the 
user/group is, but I want Others to have access to read.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197472

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 14:01 -0700
Message-ID<f4fca4Fi0eiU1@mid.individual.net>
In reply to#197471
Mike Easter wrote:
> The nature of these printed .pdf/s is that I don't really care what the 
> user/group is, but I want Others to have read privileges

It turns out that man chown is clearer to me than chown -help in terms 
of the instructions about user and group.

It also turns out that I believe I want to work on chmod instead of 
chown, since chown doesn't fix the Others problem which is what needs to 
be fixed.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197474

FromMike Easter <MikeE@ster.invalid>
Date2017-10-14 14:17 -0700
Message-ID<f4fd7uFi6qbU1@mid.individual.net>
In reply to#197472
Mike Easter wrote:
> I believe I want to work on chmod instead of chown, since chown doesn't 
> fix the Others problem which is what needs to be fixed.

How about I just change the Others to read on all the .pdf/s

chmod o=r *.pdf

I plan to navigate to the directory to apply that and I want to affect 
all the .pdf/s inside that dir and all of the dir/s within that dir.

I could do them one at a time since there are only 6 that have 
restricted others.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197476

FromPaul <nospam@needed.invalid>
Date2017-10-14 18:03 -0400
Message-ID<oru1ip$oqq$1@dont-email.me>
In reply to#197474
Mike Easter wrote:
> Mike Easter wrote:
>> I believe I want to work on chmod instead of chown, since chown 
>> doesn't fix the Others problem which is what needs to be fixed.
> 
> How about I just change the Others to read on all the .pdf/s
> 
> chmod o=r *.pdf
> 
> I plan to navigate to the directory to apply that and I want to affect 
> all the .pdf/s inside that dir and all of the dir/s within that dir.
> 
> I could do them one at a time since there are only 6 that have 
> restricted others.
> 

Try it and see.

As long as you have full sudo (not feature limited)
or root, you can usually dig yourself out of a hole.

Now is a perfect time to learn how to use chown,
chmod, chattr.

*******

Account numbers don't have to be the same on a bunch
of multi-booting OSes. You will see this when you
list a directory and you see "1000:ubuntu" rather
than "somename:ubuntu". It means in the /etc/password
file (or whete ever account information is stored), there
is nothing indicating the symbolic name for a particular
numeric value. The system runs on numeric values, and
symbolic (name) representations are to make the system
"user friendly".

You see this a lot more, when "tarring" a structure from
dis-similar systems and then trying to restore it elsewhere.
The numbers may not have any names defined, so you can
figure out what the account "used to be". It helps if you
have access to the old system, to get the account list
so you have a mapping for later.

Even things like the "Nobody" account might not have
consistent definitions (between say, FreeBSD, Solaris, Linux).
Nobody might be the highest value numerically, but the
numerical range might be 32767 on one ecosystem and
65535 on another, and then the "highest value" heuristic
doesn't work out. A tarfile might have something stamped
with Nobody, and then that isn't the value of Nobody
on a different platform.

*******

At work, when I parachuted into a Unix group, one of the
first things I was taught by the other employees, was
permissions and ownership. For many other functions,
I was left to my C-shell and Bourne-shell books
(as by mutual agreement, I wasn't to ask questions
on obscure stuff unless I was really stuck). There
was no Google back then :-) If it wasn't for my books,
I would really have been stuck. But the permissions
and ownership lecture was "free", because of the need
to share files immediately. And because the basics are
so simple, that part should stick with you over the
years.

There are always parts of the ecosystem which are obscure
and little used. And that's for the best :-)

There are rules for the $TEMP directory. Root cannot
delete user files in $TEMP. There is a bit set on the
TEMP (/tmp) directory indicating that behavior is required
there.

There is setuid for executables (like maybe Xterm).

There is the CHATTR "immutable" to protect Linux files.
So you cannot delete them, without undoing the immutable first.

There are permissions for "sockets", which you might
see in temp. Maybe Xorg needs a socket, and there's
one of them in there. So some of these things are
a bit on the obscure side, and more things that a
programmer would know.

But at the very least, you should understand the
simple stuff, like how the /tmp behavior works
so that multi-users can all share the same /tmp
without trampling on one another.

I think there's also a kind of bit that covers "terminate and
stay resident". That was intended, long ago, to cache
an executable that has just run, making it easier
to load the next time (a means to improve script
performance perhaps). This isn't really necessary any
more, because the OS has a ton of features that
do the same sorts of things (system read cache perhaps).
I think one of the first system read caches I ran into,
was SunOS 4.1.3 or so, but many OSes copied this feature
afterwards. I remember being blown away, when my
new Mac G4 at the time, exhibited system read cache
behavior (running a checksum on a file twice, the
second run was "super-fast" because the file was
still in RAM). On Windows, it was Win2K, but the
behavior has "back-slided" quite a bit over the years.
Win2K took it seriously. Many Windows operations now,
refuse to use the cached copy, for no good reason.

    Paul

[toc] | [prev] | [next] | [standalone]


#197482

FromMike Easter <MIkeE@ster.invalid>
Date2017-10-15 18:55 +0000
Message-ID<f4hp8qF4d2dU1@mid.individual.net>
In reply to#197469
Mike Easter wrote:
> Mike Easter wrote:
>> sudo chown ubuntu example.pdf
>>
>> That works on example.pdf to cause the user to say 'Me'  and doesn't
>> change the group and I can open the .pdf.
>
> But, in the long run, it isn't going to be ubuntu who wants to open/use
> the .pdf; ubuntu is just a temporary user/handler.
>
I'm wrestling with this again in a different dimension and trying to 
figure out how to do what I want to do.

Another problem is the firefox profile directory.  The directory itself 
has the permissions described previously for those problem .pdf/s, the 
owner is user #1000, group 1000, and the access of Others is none.

I'm working in a live Ub 17.10 and I'm trying to copy some directories 
and files from the old IDE hdd connected by external kit USB to another 
hdd and USB.

Not only the ffx directory itself, but also many other directories and 
files inside it are in the same problem permissions status.

In the long run, it isn't going to be the ubuntu user who is currently 
handling this directory who wants to use it; but presently that ubuntu 
user 'simply' wants to be able to copy those directories and files.

I thought I could just navigate to the profile's firefox directory and 
use sudo chmod to allow Others read access to everything with:

sudo chmod o=r <dir_name>

That fixed the directory to give others read access, but not everything 
inside, so next I:

sudo chmod -R o=r <dir_name>

But that didn't do it either.  The directories inside Others access was 
only changed to List only instead of Read.  In order to copy to the 
other storage I need to do something else.




-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


#197483

FromMike Easter <MIkeE@ster.invalid>
Date2017-10-15 19:11 +0000
Message-ID<f4hq72F4ku5U1@mid.individual.net>
In reply to#197482
Fixed it.

Mike Easter wrote:
> sudo chmod -R o=r <dir_name>
>
> But that didn't do it either.  The directories inside Others access was
> only changed to List only instead of Read.  In order to copy to the
> other storage I need to do something else.

First, I found out that syntax was wrong, the - R belonged after o=r, 
but changing that didn't get the job done either.

Then, I found a graphical solution.

When I drill into the profile folder's Permissions, I am offered a 
graphical "Change Permissions for Enclosed Files"

That function can change the permissions of all 3 user/group/others in a 
variety of ways.  I was able to change others to access files instead of 
just list.

-- 
Mike Easter

[toc] | [prev] | [next] | [standalone]


Page 1 of 2  [1] 2  Next page →

Back to top | Article view | alt.os.linux.ubuntu


csiph-web