The officially official Devuan Forum!

You are not logged in.

#1 2019-03-12 10:58:50

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Problem with mounting partitions

Dear members of the forum,
I can't mount NTFS partitions.
Actually, I used to mount them, but Devuan is displaying "Not authorized to perform operation".
Thank you in advance.

Offline

#2 2019-03-12 11:04:33

xinomilo
Unknown
Registered: 2017-07-02
Posts: 315  

Re: Problem with mounting partitions

do you have cgmanager and DE's polkit deb packages installed?

Offline

#3 2019-03-12 11:21:29

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

How are you trying to mount NTFS partition?

pmount? mount? GUI filemanager?

Could you specify where the message was displayed?

Offline

#4 2019-03-12 11:40:29

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

I try to mount them by clicking on them.
I tried to mount with Disks, but I got the same message.
Which polkit deb should I install ?

Offline

#5 2019-03-12 12:40:38

xinomilo
Unknown
Registered: 2017-07-02
Posts: 315  

Re: Problem with mounting partitions

what Desktop Environment are you using? there are different packages depending on DE.

Offline

#6 2019-03-12 13:02:50

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

I have been using Xfce.

Offline

#7 2019-03-12 13:23:07

Panopticon
Member
Registered: 2018-01-27
Posts: 306  

Re: Problem with mounting partitions

Do you have ntfs-3g installed from the devuan repos?

You say ntfs partitions used to be able to mount, so did it just stop mounting when you click on them in the file manager?

Offline

#8 2019-03-12 14:23:37

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

I used to mount them. There is an error "Not authorized to perform operation".

Offline

#9 2019-03-12 15:09:33

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

Can you mount usb flash?

Offline

#10 2019-03-12 18:56:43

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

Yes, I can mount flash, but not other partitions.

Offline

#11 2019-03-13 04:44:10

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

I suppose you have to grant permissions to ordinary user to mount partitions or mount them at system startup. Everything can be done via surprisingly simple editing the /etc/fstab file. Which option you want?

Offline

#12 2019-03-13 09:52:44

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

I'd like to mount partitions with click.
How to properly edit etc/fstab ?

Offline

#13 2019-03-13 11:10:40

KatolaZ
Member
Registered: 2017-03-11
Posts: 79  

Re: Problem with mounting partitions

RIA77 wrote:

I'd like to mount partitions with click.
How to properly edit etc/fstab ?

You shouldn't need to modify your fstab at all. Which version of Devuan are ytou running? Which Desktop Environment? Have you fiddled with policykit or consolekit/elogind by any chance. This should work OOTB in Devuan ASCII.

HTH

KatolaZ

Offline

#14 2019-03-13 11:23:58

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

RIA77 wrote:

I'd like to mount partitions with click.
How to properly edit etc/fstab ?

In my opinion the correct way is /etc/fstab, but it's possible to "fix" your problem without editing text config if you want mouseclicking. You have to check following packages: policykit, gvfs, thunar-volman, udisks2 or something like that (you can find them with both synaptic and apt/aptitude). Just in case check ntfs-3g package - may be you have not installed it yet.

For (in my opinion) correct way you have to create directories for all of your ntfs partitions in the /mnt directory. This is work of installer but you can do it yourself. For example:

Suppose you've got a two ntfs partitions. Let's name directories "ntfs1" and "ntfs2" (you can name them as you want)

mkdir /mnt/ntfs1
mkdir /mnt/ntfs2

Next, you have to know where ntfs partitions are. The most simple way is to find block device address in filesystem, but the most reliable way is to use UUID. First of all, let's find partitions with the tool called blkid. Just type as root the following:

blkid

You'l get a list of partitions, their UUIDs and PARTUUIDs.

Now you can edit /etc/fstab. Suppose ntfs partitions are /dev/sda3 and /dev/sda4. In this case you have to add following strings into /etc/fstab:

/dev/sda3 /mnt/ntfs1 ntfs-3g defaults 0 0
/dev/sda4 /mnt/ntfs2 ntfs-3g defaults 0 0

Now you can mount ntfs partition from root user or they will be mounted automatically after reboot.

If you want to mount partitions using UUID or PARTUUID you have to use them instead of path to block device:

UUID=ThereMustBeUuidWhichIsALongMessOfLettersAndNumbers /mnt/ntfs1 ntfs-3g defaults 0 0
UUID=ThereMustBeUuidWhichIsALongMessOfLettersAndNumbers /mnt/ntfs2 ntfs-3g defaults 0 0
PARTUUID=ThereMustBePartUuidWhichMayBeShorterThanUuid /mnt/ntfs1 ntfs-3g defaults 0 0
PARTUUID=ThereMustBePartUuidWhichMayBeShorterThanUuid /mnt/ntfs2 ntfs-3g defaults 0 0

For more details including recommended options you can read a simple manual: https://wiki.archlinux.org/index.php/NT … onfiguring

If it doesn't work you'l need to install ntfs-3g driver from repository.

Offline

#15 2019-03-13 13:51:22

Panopticon
Member
Registered: 2018-01-27
Posts: 306  

Re: Problem with mounting partitions

I agree with Katolaz, more than likely a polkit issue. You shouldnt need to edit fstab to make an ntfs partition mount, more info on your system is needed at this point.

What is the output of below ls command?

ls /usr/share/polkit-1/actions/

Last edited by Panopticon (2019-03-13 13:59:09)

Offline

#16 2019-03-13 15:58:30

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

Okay. I have found TOTALLY INCORRECT but working solution for you. I have tested it on my Devuan box. Why it's incorrect? Because it makes your system extremely vulnerable.

The solution is:

Make policykit rule: /etc/polkit-1/localauthority/50-local.d/org.freedesktop.automount.pkla
The content of this file:

[Allow Unauthorized mounting/Unmounting]
Identity=unix-group:plugdev;cdrom
Action=org.freedesktop.udisks2.filesystem-*;org.freedesktop.udisks2.eject*
ResultAny=yes
ResultInactive=yes
ResultActive=yes

If your user account is in the "plugdev" group you will be able to mount any filesystem on your computer without root permissions. If it doesn't work write full error message or make a screenshot.

How did i find it? It's simple. I've googled it: http://forums.debian.net/viewtopic.php? … 2&start=30

Devuan is Debian done right. So almost 100% of solutions for Debian works with Devuan.

If you want CORRECT and SECURE solution you have to follow my advice about /etc/fstab editing.

Offline

#17 2019-03-13 16:25:54

Panopticon
Member
Registered: 2018-01-27
Posts: 306  

Re: Problem with mounting partitions

ToxicExMachina, why would you advise someone to follow an (in your words) incorrect method to mount a partition?

Offline

#18 2019-03-13 16:41:38

golinux
Administrator
Registered: 2016-11-25
Posts: 3,137  

Re: Problem with mounting partitions

Panopticon wrote:

ToxicExMachina, why would you advise someone to follow an (in your words) incorrect method to mount a partition?

Indeed.  RIA77 . . . listen carefully to KatolaZ not someone who just dropped in here a few days ago and is new to Devuan.

Offline

#19 2019-03-13 16:41:51

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

Panopticon wrote:

ToxicExMachina, why would you advise someone to follow an (in your words) incorrect method to mount a partition?

I give a number of solutions. The incorrect one is what topicstarter exactly asked (it's similar to printing screenshot of filemanager instead output of ls command). The correct one is the solution i recommend.

Offline

#20 2019-03-13 17:10:40

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

Panopticon wrote:

I agree with Katolaz, more than likely a polkit issue. You shouldnt need to edit fstab to make an ntfs partition mount, more info on your system is needed at this point.

What is the output of below ls command?

ls /usr/share/polkit-1/actions/

com.hp.hplip.policy
com.ubuntu.pkexec.gparted.policy
com.ubuntu.pkexec.synaptic.policy
org.freedesktop.color.policy
org.freedesktop.consolekit.policy
org.freedesktop.login1.policy
org.freedesktop.packagekit.policy
org.freedesktop.policykit.policy
org.freedesktop.RealtimeKit1.policy
org.freedesktop.udisks2.policy
org.freedesktop.upower.policy
org.freedesktop.upower.qos.policy
org.linux.lmt.gui.policy
org.opensuse.cupspkhelper.mechanism.policy
org.xfce.power.policy
org.xfce.session.policy
org.xfce.thunar.policy
org.x.xf86-video-intel.backlight-helper.policy

Should I edit fstab ?
This is the current state of fstab. Should I make any corrections ?

https://ibb.co/yghYcJs

Offline

#21 2019-03-13 17:28:27

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

golinux wrote:

someone who just dropped in here a few days ago and is new to Devuan.

How's me being new at Devuan forums relates to actual matters of discussion?

Offline

#22 2019-03-13 17:33:57

golinux
Administrator
Registered: 2016-11-25
Posts: 3,137  

Re: Problem with mounting partitions

ToxicExMachina wrote:
golinux wrote:

someone who just dropped in here a few days ago and is new to Devuan.

How's me being new at Devuan forums relates to actual matters of discussion?

If you have to ask that question, it's unlikely you'd understand the answer.

Offline

#23 2019-03-13 17:36:03

RIA77
Member
Registered: 2019-03-12
Posts: 28  

Re: Problem with mounting partitions

KatolaZ wrote:
RIA77 wrote:

I'd like to mount partitions with click.
How to properly edit etc/fstab ?

You shouldn't need to modify your fstab at all. Which version of Devuan are ytou running? Which Desktop Environment? Have you fiddled with policykit or consolekit/elogind by any chance. This should work OOTB in Devuan ASCII.

HTH

KatolaZ

I have been runing Devuan 2.0 XFCE

Offline

#24 2019-03-13 17:51:52

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

RIA77 wrote:

Should I edit fstab ?

If you want to mount partition with mouse - no. You just need to change policykit rules. If you want to get partition already mounted after booting - yes.

RIA77 wrote:

This is the current state of fstab. Should I make any corrections ?

https://ibb.co/yghYcJs

If you have created /mnt/dev/sda5 directory manually - it's correct and after reboot NTFS partition will be mounted automatically. If it worked - it's great and you can add some options for better system integration.

Offline

#25 2019-03-13 18:07:00

ToxicExMachina
Member
Registered: 2019-03-11
Posts: 210  

Re: Problem with mounting partitions

golinux wrote:
ToxicExMachina wrote:
golinux wrote:

someone who just dropped in here a few days ago and is new to Devuan.

How's me being new at Devuan forums relates to actual matters of discussion?

If you have to ask that question, it's unlikely you'd understand the answer.

You seemingly mistreat me for troll outsider. I am far from being new to systemd disaster, Devuan and GNU/Linux. Maybe you pay attention to my actual arguments instead of going ad hominem?

Offline

Board footer