I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out). Secondly, in order to copy stuff on the
device, I must preface the command with sudo and type in
my password. OK, I can do that, but why?
Thirdly, and most irritatingly, after the first (largish)
copy, subsequent copy operations gave the notice that the
job was stopped. Why is this? I must find out how to resume
a stopped job, which I think I can.
But why is all this happening? What should I type in to
format a USB stick?
As mentioned before, I work under Kubuntu 23.04.
...I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
On Wed, 23 Aug 2023 06:49:15 -0400, db <dieterhansbritz@gmail.com> wrote:
I got a lot of advice on how to format a USB stick and ended up
typing in
find this out). Secondly, in order to copy stuff on the
device, I must preface the command with sudo and type in
my password. OK, I can do that, but why?
It was mounted by root. Unmount it, unplug the device and plug it
back in. I'm assuming Kubuntu uses udev and it's kde has the
removable devices system tray applet enabled. If desired, use systemsettings5/Hardware/Removable storage to enable auto mounting
of the file system owned by the currently logged in user.
On 2023-08-23 11:28, David W. Hodgins wrote:
On Wed, 23 Aug 2023 06:49:15 -0400, db <dieterhansbritz@gmail.com> wrote:
I got a lot of advice on how to format a USB stick and ended up
typing in
...
find this out). Secondly, in order to copy stuff on the
device, I must preface the command with sudo and type in
my password. OK, I can do that, but why?
It was mounted by root. Unmount it, unplug the device and plug it
back in. I'm assuming Kubuntu uses udev and it's kde has the
removable devices system tray applet enabled. If desired, use
systemsettings5/Hardware/Removable storage to enable auto mounting
of the file system owned by the currently logged in user.
Will not work when using ext4 or any other Linux filesystem.
There are several methods. One that has not been mentioned yet is
creating a directory inside owned by the normal user. Notice that this
user will be a different user if the stick is connected to another
computer. It is the uuid number that matters.
Am 23.08.2023 um 12:49:15 Uhr schrieb db:
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
On Wed, 23 Aug 2023 21:50:01 -0400, Carlos E. R.
<robin_listas@es.invalid> wrote:
On 2023-08-23 11:28, David W. Hodgins wrote:
On Wed, 23 Aug 2023 06:49:15 -0400, db <dieterhansbritz@gmail.com>
wrote:
I got a lot of advice on how to format a USB stick and ended up
typing in
...
find this out). Secondly, in order to copy stuff on the
device, I must preface the command with sudo and type in
my password. OK, I can do that, but why?
It was mounted by root. Unmount it, unplug the device and plug it
back in. I'm assuming Kubuntu uses udev and it's kde has the
removable devices system tray applet enabled. If desired, use
systemsettings5/Hardware/Removable storage to enable auto mounting >>> of the file system owned by the currently logged in user.
Will not work when using ext4 or any other Linux filesystem.
There are several methods. One that has not been mentioned yet is
creating a directory inside owned by the normal user. Notice that this
user will be a different user if the stick is connected to another
computer. It is the uuid number that matters.
My mistake. Thanks for the correction.
It gets mounted with "drwxr-xr-x 3 root root" so the user has read
access, but
not write access.
So either the uid has to be specified during the mkfs.ext4 or mount it
using the device notifier and then chown the directory used as the
mount point using sudo. The chown only has to be run the first time it's mounted, not after subsequent mounts.
Regards, Dave Hodgins
Am 23.08.2023 um 12:49:15 Uhr schrieb db:
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
On 23.08.2023 13.39, Marco Moock wrote:
Am 23.08.2023 um 12:49:15 Uhr schrieb db:How do I do that? I know about chmod but not how to use it on a
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
device.
On 23.08.2023 13.39, Marco Moock wrote:
Am 23.08.2023 um 12:49:15 Uhr schrieb db:How do I do that? I know about chmod but not how to use it on a
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
device.
This was posted earlier by Kenny McCormack on Aug. 23rd.
On 28/08/2023 10:34, db wrote:
On 23.08.2023 13.39, Marco Moock wrote:
Am 23.08.2023 um 12:49:15 Uhr schrieb db:How do I do that? I know about chmod but not how to use it on a
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
device.
IIRC, but its a long time since I had this problem, you need to ensure
first of all that the mount point is accessible permissions-wise without
any device mounted on it.
Then once mounted all you 'see' are directories - even the root
directory of the device is just a directory, so changing that directory permissions is possible.
So again to the best of my memorry if you are say going to mount on /mnt
#chmod 777 /mnt
followed by
#mount /dev/whatever /mnt
and then
#chmod 777 /mnt
AGAIN
has effectively opened up the root directory of the device to all and sundry.
The Natural Philosopher <tnp@invalid.invalid> wrote:
On 28/08/2023 10:34, db wrote:
On 23.08.2023 13.39, Marco Moock wrote:
Am 23.08.2023 um 12:49:15 Uhr schrieb db:How do I do that? I know about chmod but not how to use it on a
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface theChange the permissions on the device, so you can write there. If the
command with sudo and type in my password. OK, I can do that, but why? >>>>
owner is root and only the owner is allowed to write, this is what
happens.
device.
IIRC, but its a long time since I had this problem, you need to ensure
first of all that the mount point is accessible permissions-wise without
any device mounted on it.
Then once mounted all you 'see' are directories - even the root
directory of the device is just a directory, so changing that directory
permissions is possible.
So again to the best of my memorry if you are say going to mount on /mnt
#chmod 777 /mnt
followed by
#mount /dev/whatever /mnt
and then
#chmod 777 /mnt
AGAIN
has effectively opened up the root directory of the device to all and
sundry.
You just need to change the permissions/owner on the root directory on
the device, to do this mount the device, assuming it's /mnt, then as
root: chown user.group /mnt
chmod a+rwx /mnt
I don't change the permissions of the mountpoint so that if I
accidently try to write to it without anything mounted there I get a permission denied message.
Jerry
You just need to change the permissions/owner on the root directory on
the device, to do this mount the device, assuming it's /mnt, then as
root: chown user.group /mnt
chmod a+rwx /mnt
I don't change the permissions of the mountpoint so that if I
accidently try to write to it without anything mounted there I get a permission denied message.
On 28/08/2023 10:34, db wrote:
On 23.08.2023 13.39, Marco Moock wrote:
Am 23.08.2023 um 12:49:15 Uhr schrieb db:How do I do that? I know about chmod but not how to use it on a
I got a lot of advice on how to format a USB stick and ended up
typing in
sudo mkfs.ext4 /dev/sdb1
This worked, except for a few things. Firstly I guess there
must be an option for the final name of the device (I can
find this out).
https://unix.stackexchange.com/questions/289477/what-is-the-difference-between-a-name-and-a-label-in-gparted
e2label can change the label.
Secondly, in order to copy stuff on the device, I must preface the
command with sudo and type in my password. OK, I can do that, but why?
Change the permissions on the device, so you can write there. If the
owner is root and only the owner is allowed to write, this is what
happens.
device.
IIRC, but its a long time since I had this problem, you need to ensure
first of all that the mount point is accessible permissions-wise without
any device mounted on it.
Then once mounted all you 'see' are directories - even the root
directory of the device is just a directory, so changing that directory permissions is possible.
So again to the best of my memorry if you are say going to mount on /mnt
#chmod 777 /mnt
followed by
#mount /dev/whatever /mnt
and then
#chmod 777 /mnt
AGAIN
has effectively opened up the root directory of the device to all and sundry.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 307 |
Nodes: | 16 (2 / 14) |
Uptime: | 53:10:29 |
Calls: | 6,913 |
Calls today: | 3 |
Files: | 12,379 |
Messages: | 5,430,308 |