Page 1 of 1

Can't copy and past files

Posted: Mon Feb 11, 2019 6:01 pm
by Linuxunil
Hi everyone!
I can't copy and paste files, can't create new files or folders on my new 1Tb HDD which I use for storing important personal data. Doing it as root with elevated privileges doesn't help either. It is formatted as an ext4 filesystem and it's mounted. What am I doing wrong?

Help and advice is much appreciated. Thanks!

Re: Can't copy and past files

Posted: Mon Feb 11, 2019 8:02 pm
by pbear
You don't give much information. Is the new HDD internal or external? Formatted with what tool? Tried to access with elevated privileges how? Also, please open Terminal and run these two commands: inxi -Fxz and lsblk. Both are ordinary user commands and don't require sudo. Report back the results, enclosing the output in code tags (the </> button above the text entry box).

Re: Can't copy and past files

Posted: Mon Feb 11, 2019 10:50 pm
by all41
You cannot write (or paste) to a partition you do not own.
This seems to be the case and the info requested by pbear will tell.

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 8:49 am
by Linuxunil
pbear wrote:
Mon Feb 11, 2019 8:02 pm
You don't give much information. Is the new HDD internal or external? Formatted with what tool? Tried to access with elevated privileges how? Also, please open Terminal and run these two commands: inxi -Fxz and lsblk. Both are ordinary user commands and don't require sudo. Report back the results, enclosing the output in code tags (the </> button above the text entry box).
Thanks for the fast replies guys!
I formatted the internal HDD with the Gnome Disk tool. In the file manager (Files) I right clicked and selected "open as root" (As I understand it is similar to the "Open as administrator" command in Windows, right?), then a new window popped up with the header "Elevated Privileges". Then I tried to copy and paste a file to the HDD in question without success.

There is no mount point for the 1Tb HDD it seems according to the "lsblk" command but Gnome Disk utility says otherwise:
Screenshot from 2019-02-12 13-32-11.png
Screenshot from 2019-02-11 22-50-38.png

Code: Select all

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 931,5G  0 disk 
└─sda1   8:1    0 931,5G  0 part 
sdb      8:16   0 186,3G  0 disk 
├─sdb1   8:17   0  93,2G  0 part /mnt/b3f91c1f-0b89-45c2-a913-7ec6def29f86
├─sdb2   8:18   0    20G  0 part [SWAP]
└─sdb3   8:19   0  73,1G  0 part /
sr0     11:0    1  1024M  0 rom 

Code: Select all

System:    Host: en-To-be-filled-by-O-E-M Kernel: 4.15.0-45-generic x86_64
           bits: 64 gcc: 7.3.0
           Desktop: Cinnamon 3.8.9 (Gtk 3.22.30-1ubuntu1)
           Distro: Linux Mint 19 Tara
Machine:   Device: desktop System: Gigabyte product: N/A serial: N/A
           Mobo: Gigabyte model: 970A-DS3P v: x.x serial: N/A
           BIOS: American Megatrends v: FB date: 10/31/2014
CPU:       8 core AMD FX-8370 Eight-Core (-MCP-) 
           arch: Bulldozer rev.0 cache: 16384 KB
           
           flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm) bmips: 64296
           clock speeds: max: 4000 MHz 1: 1544 MHz 2: 1424 MHz 3: 1406 MHz
           4: 1403 MHz 5: 1406 MHz 6: 1406 MHz 7: 1405 MHz 8: 1405 MHz
Graphics:  Card: NVIDIA GF106GL [Quadro 2000] bus-ID: 01:00.0
           Display Server: x11 (X.Org 1.19.6 )
           drivers: nvidia (unloaded: modesetting,fbdev,vesa,nouveau)
           Resolution: 1280x1024@60.02hz
           OpenGL: renderer: Quadro 2000/PCIe/SSE2
           version: 4.6.0 NVIDIA 390.77 Direct Render: Yes
Audio:     Card-1 NVIDIA GF106 High Def. Audio Controller
           driver: snd_hda_intel bus-ID: 01:00.1
           Card-2 Advanced Micro Devices [AMD/ATI] SBx00 Azalia (Intel HDA)
           driver: snd_hda_intel bus-ID: 00:14.2
           Sound: Advanced Linux Sound Architecture v: k4.15.0-45-generic
Network:   Card: Realtek RTL8111/8168/8411 PCIE Gigabit Ethernet Controller
           driver: r8169 v: 2.3LK-NAPI port: d000 bus-ID: 03:00.0
           IF: enp3s0 state: up speed: 100 Mbps duplex: full mac: <filter>
Drives:    HDD Total Size: 1200.3GB (6.5% used)
           ID-1: /dev/sda model: WDC_WD10EZEX size: 1000.2GB
           ID-2: /dev/sdb model: SAMSUNG_SP2004C size: 200.0GB
Partition: ID-1: / size: 72G used: 18G (27%) fs: ext4 dev: /dev/sdb3
           ID-2: swap-1 size: 21.47GB used: 0.00GB (0%)
           fs: swap dev: /dev/sdb2
RAID:      No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors:   System Temperatures: cpu: 22.8C mobo: N/A gpu: 0.0:50C
           Fan Speeds (in rpm): cpu: N/A
Info:      Processes: 233 Uptime: 23 min Memory: 2002.5/8007.8MB
           Init: systemd runlevel: 5 Gcc sys: 7.3.0
           Client: Shell (bash 4.4.191) inxi: 2.3.56 
/code]

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 9:05 am
by philotux
What do

Code: Select all

 cat /etc/fstab
and

Code: Select all

sudo blkid -o list
say?

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 11:14 am
by hcentaur13
when the partition you new home is eeally you new hone:open a terminal
sudo chown -R $USER:$USER path-to-the mountpoint the new partition is on.

That is because gparted creats partition for root and so anything on the new partition gets the ownership of root.

Only the owner of a directory/file has the alloance to create/change it. So a new partition created from root gets its ownership.

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 1:41 pm
by pbear
Hey Linuxunil. FWIW, I avoid Disks for stuff like this because it's easy but inscrutable. You have little control and often don't know exactly what it's going to do. As has been explained, what you need to do is change ownership of sda1 from root to yourself as user. How you do that lies at the intersection of philotux's question and hcentaur's suggested form of command. Keep going. You'll get there.

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 5:14 pm
by Linuxunil
I turned my PC on and opened the Gnome Disk app. It said "Disk OK, one bad sector". I heard a high pitched slightly louder noise from the case than usual.
I opened the case so that I can hear it better and check what's wrong. The noise stopped a couple of seconds later. I reopened the Disk app and saw that the "Disk is OK". Bad sectors appear when the HDD is dying as far as I know but it's a week old one. What could be the reason for this?

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 6:53 pm
by pbear
AFAIK, Disks doesn't have diagnostic capabilities of its own. Rather, for something like this, it's relying on the self-reported SMART tests from the drive. Could be a false alarm or a defective drive. Don't know what tools are available to test further, but assume there are some.

Re: Can't copy and past files

Posted: Tue Feb 12, 2019 7:52 pm
by all41
Linuxunil wrote:
Mon Feb 11, 2019 6:01 pm
Hi everyone!
I can't copy and paste files, can't create new files or folders on my new 1Tb HDD which I use for storing important personal data. Doing it as root with elevated privileges doesn't help either. It is formatted as an ext4 filesystem and it's mounted. What am I doing wrong?

Help and advice is much appreciated. Thanks!
1.
Take ownership:

Code: Select all

sudo chown $USER:$USER /mnt/b3f91c1f-0b89-45c2-a913-7ec6def29f86
2.
State permissions:

Code: Select all

sudo chmod -R 777 /mnt/b3f91c1f-0b89-45c2-a913-7ec6def29f86
This will allow full acccess to everyone--you can change these permissions later.

Note the rather obscure identification number for your device (b3f91c1f-0b89-45c2-a913-7ec6def29f86)
I would use gparted to give this drive a humanly recognizable label (example: 'Music')--instead of mumbo-jumbo-uninformative-bunch of alphanumerics-designation
If you need coaching don't be shy

Re: Can't copy and past files

Posted: Thu Feb 14, 2019 4:52 am
by Linuxunil
all41 wrote:
Tue Feb 12, 2019 7:52 pm
Linuxunil wrote:
Mon Feb 11, 2019 6:01 pm
Hi everyone!
I can't copy and paste files, can't create new files or folders on my new 1Tb HDD which I use for storing important personal data. Doing it as root with elevated privileges doesn't help either. It is formatted as an ext4 filesystem and it's mounted. What am I doing wrong?

Help and advice is much appreciated. Thanks!
1.
Take ownership:

Code: Select all

sudo chown $USER:$USER /mnt/b3f91c1f-0b89-45c2-a913-7ec6def29f86
2.
State permissions:

Code: Select all

sudo chmod -R 777 /mnt/b3f91c1f-0b89-45c2-a913-7ec6def29f86
This will allow full acccess to everyone--you can change these permissions later.

Note the rather obscure identification number for your device (b3f91c1f-0b89-45c2-a913-7ec6def29f86)
I would use gparted to give this drive a humanly recognizable label (example: 'Music')--instead of mumbo-jumbo-uninformative-bunch of alphanumerics-designation
If you need coaching don't be shy
The change owner command (chown) worked. I can create and copy files, folders on the drive. Thank you.

Now I have another problem. :) Last night I became frustrated and reformatted the drive (after backing up my data) I am having problems with, using GParted as a single partition drive and gave it a label ("Adattár"=data storage), yet in the file manager it shows up by it's UUID name and not by the label I gave it ("Adattár") plus new items have appeared as well. See the attached images for reference.
Screenshot from 2019-02-14 09-42-42.png
Screenshot from 2019-02-14 07-45-12.png
Screenshot from 2019-02-14 07-45-12.png (13.58 KiB) Viewed 633 times
I just want the drives to appear by their given labels in the file manager like before, without the 4 new items in the list that I have no idea what they are.

Re: Can't copy and past files

Posted: Thu Feb 14, 2019 11:45 am
by Linuxunil
The problem that I posted in my last reply is gone. I just needed to reboot, now the drives show up by their labels in the file manager as I intended.

Thank you all for your help. I do appreciate it.

Re: Can't copy and past files

Posted: Thu Feb 14, 2019 3:26 pm
by all41
Linuxunil wrote:
Thu Feb 14, 2019 11:45 am
The problem that I posted in my last reply is gone. I just needed to reboot, now the drives show up by their labels in the file manager as I intended.

Thank you all for your help. I do appreciate it.
Hi Linuxunil,
Glad to be of help.
Welcome aboard--enjoy

Re: Can't copy and past files

Posted: Thu Feb 14, 2019 3:38 pm
by Linuxunil
Linuxunil wrote:
Thu Feb 14, 2019 11:45 am
The problem that I posted in my last reply is gone. I just needed to reboot, now the drives show up by their labels in the file manager as I intended.

Thank you all for your help. I do appreciate it.

Hi everyone, my previous problem returned. Now the labels associated with the drives and partitions are gone in the file manager and are replaced by a series of characters which look like their UUID plus I see those other items with a different icon in the drivers list. See attached image. What are those?
Screenshot from 2019-02-14 20-28-39.png
Screenshot from 2019-02-14 20-28-39.png (13.47 KiB) Viewed 598 times
I can't unmount the drive that I store my data on but I can create and copy new files and folders on it. Why?

Re: Can't copy and past files

Posted: Thu Feb 14, 2019 9:35 pm
by all41
With the new format your uuid has changed--and so the mountpoints.
If you used gparted to format or partition a drive root will own these--because gparted
asks for root permission at the onset.
So you will need to take ownership again. Then the labels should be correct after reboot

Re: Can't copy and past files

Posted: Tue Feb 19, 2019 7:17 pm
by Linuxunil
I successfully fubared Linux. I backed up my data and will attempt to reinstall it in the future...maybe.
I'm having issues with partitioning. Any suggestions on what partitioning scheme I should use for a 200Gb HDD, 8Gb of RAM and a UEFI mobo?

I tried setting it up like this during installation:
-gpt partition table.
-1. partition: /boot, Ext2 (no journaling, faster boot time), primary, 1Gb
-2. /root, Ext4, primary, 30 Gb
-3. swap, 8Gb (8Gb of RAM)
-4. /home, Ext4, primary, What's left of the storage space is allocated to this partition.
I Get an error message saying that the 2nd root partition can't be created.

Linux Mint is not intuitive at all for me and it seems to be unstable and buggy compared to the spyware Windows007.
My HDD makes very strange noises when partitioning or when I boot Linux from a USB stick. I haven't heard it make these sounds before I started messing with Linux.

Re: Can't copy and past files

Posted: Wed Feb 20, 2019 12:23 am
by lsemmens
Hang in there Linuxunit, you are nearly there. As has already been stated Gparted is way better than Disks for drive management. If you are attempting to re-install Linux, Just accept the defaults as you go. (IF, of course, you are installing LINUX as your ONLY OS then you need to change the selection when you try to install again, or you will end up with 2 Linux systems).

My systems are all set up using the defaults. The ONLY time I tend to muck around with additional partitions on my boot drive is if I am using a large (i.e. > 200Gb) device. Normally I just set up a small drive as my boot device and use other drives for my static data.

Re: Can't copy and past files

Posted: Wed Feb 20, 2019 12:40 am
by kevin987
Your hard drive may be starting to fail since it's making those noises. This isn't caused by Linux. If this is happening it's the drive partitioning itself, which is placing stress of the drive.

You won't need a swap partition if Mint 19 is the only operating system on that hard drive. The swap file process has replaced that need.