1

This was the photo of my gparted from hdd:

PIC 1

I wanted to increase the hdd space by unmounting and deleting the extended partition sdb1,then creating a new partition...
Now in gparted,I have this:

PIC 2

So i wanted to open the hdd from nautilus,but i couldn't open that...
I faced with an error which says:

This location could not be displayed

You do not have the permissions necessary to view the contents of "lost+found".

Now,What should i do? I can do nothing from nautilus(copy paste a file or folder or open a new folder in hdd),but i can do anything from terminal with root permission.

Check this: PIC 3

PIC 4

Sss
  • 1,022
  • The contents of your new partition are displayed already, only one single folder exists in your partition, this is the folder lost+found. This folder is created automatically by the system, is owned by root and all other users do not have any permissions (and we mostly don't need to access this folder). This folder is not your partition, it is a folder in your partition. – mook765 Oct 18 '17 at 20:21
  • If you press Ctrl+H to show hidden files in Nautilus you may see a second folder called .Trash-1000 or similar. This folder is also created by default. – mook765 Oct 18 '17 at 20:25
  • @mook765 so what should i do? how can i create 1TB free space and use that partition?? – Sss Oct 18 '17 at 20:48
  • You should be able to use the partition just right now. Try to open a second Nautilus window and drag a file or folder from your home-folder to free space near the lost+found-folder-icon in the other Nautilus-window. Does that work? – mook765 Oct 18 '17 at 20:57
  • unfortunately...cant copy and paste any files in free space... the free space is hdd...it's not /home or /var /tmp or anything like that... it's a internal free hdd... my OS is on ssd @mook765 – Sss Oct 18 '17 at 21:14
  • Your screen shot shows a 931 GB partition mounted to your file-system, the Nautilus window shows the content of this partition. Just right now your fresh and correctly created partition contains only the two folders I mentioned in my comments above. Everything just looks correct. – mook765 Oct 18 '17 at 21:26
  • 1
    But it's formatted ext4. By default it's owned by root. sudo chown user.group /path/to/mount/point should fix this. – vidarlo Oct 20 '17 at 11:10
  • @vidarlo chown: invalid user: ‘user.group’ – Sss Oct 20 '17 at 11:21
  • 1
    @sina - replace user and group with your username and groupname, e.g. chown sina.sina ... – vidarlo Oct 20 '17 at 11:30
  • sudo chown msi.msi /media/msi/c0d44499-6cbe-44da-92da-f1a48159e079/sina thank u it work fine – Sss Oct 20 '17 at 11:34

2 Answers2

2

Create one or more directories in your partition using

sudo mkdir directory-name

and change the ownershíp to your regular user ID using

sudo chown "$USER":"$USER" directory-name

Then you should be able to use the directories (in my example "directory-name") as your regular user. In these directories you will be able to create and delete subdirectories and files without restrictions.


Note for other users: Please notice that this is a linux ext4 file system. If you have a Microsoft file system, FAT32, exFAT or NTFS, the permissions and ownership for linux is set when mounting the file system. The permissions and ownership will be inherited by all subdirectories and files. If the automatic mounting does not provide write access you can try according to the following link,

How to change default permissions on automounted usb flash, formatted in NTFS?

sudodus
  • 46,324
  • 5
  • 88
  • 152
  • Or simply chown the root of that partition to user. – vidarlo Oct 20 '17 at 11:11
  • @vidarlo, Yes, you are right, but I think it is a good idea to let the root of a partition be owned by the root user, and have partitions owned by other user IDs. Both ways work :-) – sudodus Oct 20 '17 at 11:14
  • 1
    sudo mkdir sina ............ sudo chown "$USER" "$USER" sina .....chown: cannot access 'msi': No such file or directory – Sss Oct 20 '17 at 11:24
  • @sudodus please check the edited question – Sss Oct 20 '17 at 11:29
  • Sorry for the typing error: there should be a colon between the user entry and group entry, so sudo chown "$USER":"$USER" directory-name – sudodus Oct 20 '17 at 12:06
1

Run the following commands

$ sudo fdisk -l

You will find list of partitions, so you can identify the partition in which you are not able to copy paste or make new folder.

Run second command

$ sudo ntfsfix /dev/sdb3 

Replace /dev/sdb3 by your drive

Now run third command

$ sudo mount -o remount,rw /media/dravinash/General/

Replace /media/dravinash/General/ by your drive name

Now restart the system.

I am not an expert but I found these commands on web and it worked for me.....

avin
  • 11