You are not logged in.

#1 2013-11-07 00:55:25

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

[Solved] Cant use second partition /dev/sda2

sudo mount /dev/sda2 /mnt

this works and i see lost+found of the /dev/sda2
but i cant write or add folders to /dev/sda2
"Error creating directory: Permission denied"
and it disapears from the file manager side panel

this happend when i was using thunar in xfce
and again when using pcmanfm in openbox

Last edited by Shockwave0 (2013-11-12 08:27:26)

Offline

#2 2013-11-07 00:57:50

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

What's the output of 'lsblk -f' and 'mount'?

Offline

#3 2013-11-07 00:58:15

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,168

Re: [Solved] Cant use second partition /dev/sda2

Are you trying to write as a normal user or as root?

What filesystem is on sda2?


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#4 2013-11-07 01:03:54

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

as user with sudo

[shockwave@ArchLinux ~]$ lsblk -f
NAME   FSTYPE  LABEL       UUID                                 MOUNTPOINT
sda                                                             
├─sda1 ext4                aff5b1d2-0452-467f-81e7-dc3b2298101e /
├─sda2 ext4    backup      b8c96528-bdce-4a7b-9d0b-b215e9332242 /mnt
└─sda3 swap                1519cef9-0d8d-4ea4-b9d5-cc94b09cd59a 
sr0    iso9660 ARCH_201311 2013-11-01-08-10-26-00               /run/media/shock
[shockwave@ArchLinux ~]$ 
[shockwave@ArchLinux ~]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=2023684k,nr_inodes=505921,mode=755)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
/dev/sda1 on / type ext4 (rw,relatime,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpuacct,cpu)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=25,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/sr0 on /run/media/shockwave/ARCH_201311 type iso9660 (ro,nosuid,nodev,relatime,uid=1000,gid=100,iocharset=utf8,mode=0400,dmode=0500,uhelper=udisks2)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)
/dev/sda2 on /mnt type ext4 (rw,relatime,data=ordered)

Last edited by Shockwave0 (2013-11-07 01:14:05)

Offline

#5 2013-11-07 01:11:44

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

What's the output 'mount | grep sda2'? I would like to see what mount options are you using for this partition.

Offline

#6 2013-11-07 01:14:59

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

[shockwave@ArchLinux ~]$ mount | grep sda2
/dev/sda2 on /mnt type ext4 (rw,relatime,data=ordered)
[shockwave@ArchLinux ~]$ 

Offline

#7 2013-11-07 01:17:16

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

What's the output of

sudo touch /mnt/foo

Offline

#8 2013-11-07 01:21:39

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

that created a text file foo in /dev/sda2

Last edited by Shockwave0 (2013-11-07 01:22:29)

Offline

#9 2013-11-07 01:23:55

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

Were you trying to add directories to /dev/sda2? That's not how it works.
Try

sudo mkdir /mnt/bar

Offline

#10 2013-11-07 01:25:20

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

in /etc/sudoers is this right ?

root ALL=(ALL) ALL
shockwave ALL=(ALL) ALL

Last edited by Shockwave0 (2013-11-07 01:26:35)

Offline

#11 2013-11-07 01:26:46

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

Shockwave0 wrote:

in /etc/sudoers is this right ?

root ALL=(ALL) ALL
shockwave ALL=(ALL) ALL

It's OK.

When exactly did you get "Error creating directory: Permission denied" error? What and how were you trying to do?

Last edited by karol (2013-11-07 01:27:28)

Offline

#12 2013-11-07 01:29:43

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

karol wrote:

Were you trying to add directories to /dev/sda2? That's not how it works.
Try

sudo mkdir /mnt/bar

ok that works

i think its becuse im not runing the file manager with sudo maybe ?

Offline

#13 2013-11-07 01:34:00

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

[shockwave@ArchLinux ~]$ sudo pcmanfm

(pcmanfm:1119): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

(pcmanfm:1119): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

(pcmanfm:1119): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

(pcmanfm:1119): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

i was able to create another folder with the gui but the /dev/sda2 partition still doesnt show on the side panel

Last edited by Shockwave0 (2013-11-07 01:34:47)

Offline

#14 2013-11-07 01:37:17

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

karol wrote:
Shockwave0 wrote:

in /etc/sudoers is this right ?

root ALL=(ALL) ALL
shockwave ALL=(ALL) ALL

It's OK.

When exactly did you get "Error creating directory: Permission denied" error? What and how were you trying to do?

i get that error when just using pcmanfm without sudo

Last edited by Shockwave0 (2013-11-07 01:39:55)

Offline

#15 2013-11-07 01:40:07

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

http://i40.tinypic.com/14m3rdj.png

Last edited by Shockwave0 (2013-11-07 01:52:17)

Offline

#16 2013-11-07 01:42:20

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

You get this error when trying to create a file or directory in /mnt or in /dev/sda2?

Offline

#17 2013-11-07 01:46:40

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

karol wrote:

You get this error when trying to create a file or directory in /mnt or in /dev/sda2?

both in /mnt without sudo but when i enter this

 
sudo pcmanfm

i get no error

Last edited by Shockwave0 (2013-11-07 01:47:39)

Offline

#18 2013-11-07 01:47:26

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,414

Re: [Solved] Cant use second partition /dev/sda2

Shockwave0, that picture is too large for these forums.  You need to put it up on a picture hosting site and link back to it.

Offline

#19 2013-11-07 01:53:08

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

WonderWoofy wrote:

Shockwave0, that picture is too large for these forums.  You need to put it up on a picture hosting site and link back to it.

It's pretty light at just 36K but you're right, the size is way off.


You should be able to create files and directories w/o sudo.
Shockwave0, please create a directory in /mnt, unmount sda2 from /mnt and mount it to that subdirectory of /mnt.

Offline

#20 2013-11-07 01:54:42

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: [Solved] Cant use second partition /dev/sda2

And chown the created directory to your user...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#21 2013-11-07 02:05:02

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

karol wrote:

You should be able to create files and directories w/o sudo.
Shockwave0, please create a directory in /mnt, unmount sda2 from /mnt and mount it to that subdirectory of /mnt.

sudo umount /dev/sda2 /mnt

and now the /dev/sda2 partition shows up on the left panel

without sudo
Error creating directory: Permission denied when trying to add files or folders

Offline

#22 2013-11-07 02:06:25

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

jasonwryan wrote:

And chown the created directory to your user...

i dont know how

Offline

#23 2013-11-07 02:09:08

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [Solved] Cant use second partition /dev/sda2

# chown <your user name>:users <mountpoint>

e.g. I would run

# chown karol:users /mnt/bar

You need to read some manuals :-)

Offline

#24 2013-11-07 02:12:19

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: [Solved] Cant use second partition /dev/sda2

Shockwave0 wrote:
jasonwryan wrote:

And chown the created directory to your user...

i dont know how

Then learn to search. If you are going to stick with Arch, you will need to cultivate that desire/skill; help vampirism is not welcome here.

# edit: karol, please put away the spoon...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#25 2013-11-07 02:13:41

Shockwave0
Member
Registered: 2013-10-22
Posts: 28

Re: [Solved] Cant use second partition /dev/sda2

ok ill read up and go from there thanks for the help

Offline

Board footer

Powered by FluxBB