Permission

How to change gnome3 and mate permission to open in ROOT. Need to change k3b in setting, programs, permission. Have followed all instructions for using k3b as user, but to no avail. One error message relates to DBus Backend and that I am not a wheel group member. However, in /etc, group it shows wheel:*:0:root,randy and operator:*:5:root,randy. (randy being the user).
 
How to change gnome3 and mate permission to open in ROOT. Need to change k3b in setting, programs, permission. Have followed all instructions for using k3b as user, but to no avail. One error message relates to DBus Backend and that I am not a wheel group member. However, in /etc, group it shows wheel:*:0:root,randy and operator:*:5:root,randy. (randy being the user).
What is the output of groups randy and id randy?
 
groups randy: is wheel operator
id randy: uid=1001(randy) gid=0(wheel) groups=0(wheel),5(operator)
 

Attachments

  • Screenshot at 2020-08-27 09-19-59.png
    Screenshot at 2020-08-27 09-19-59.png
    204.2 KB · Views: 134
I do not have a CD/DVD drive anymore, but IIRC I had to edit some settings in devfs.conf(5) in my previous system. I.e.
Code:
link    cd0     cdrom
own cd0 root:cdrom
perm cd0 0660
pw groupadd cdrom. Add your user to the group cdrom, or use another group like e.g. operator, staff or wheel. pw groupmod -m randy cdrom. The primary group of your user should not be wheel. Instead, usually each user has it's own group named like the the username. E.g.
Code:
paul@t450s:~ % id
uid=1001(paul) gid=1001(paul) groups=1001(paul),0(wheel),5(operator),20(staff),44(video),68(dialer),69(network),145(webcamd)
 
After researching appropriate fourms, FreeBSD, Linux, etc. . . . , for two days and reading chapter 3.4 regularly, I am at an end as to why before I left for the summer everything was working just fine. Upon returning four days ago and updating Freebsd 12.1 and then simply going through the regular process of opening the descktop in root so I could burn an ISO image, Mate, Gnome, Kde GUIs will not open when logged in as ROOT. Please will someone talk with me as to what is the issue. Brasero used to work fine in ROOT, but has no value when in my user mode. In addition, the only time I ever used any of the GUIs was for updating my usb backup HHDs or burning audio or data cd/dvds. OH! k3b is needing some attention, dbus error, cdrecord error etc... especially when one is trying to correct those issues while in the configure, setting, program window and forced to be in user mode because Mate, Gnome or KDE will not open in ROOT.
Thank you for your time and support in the matter.
 
In KDE, you can: right click on the start menu -> edit menu entries -> select the program of interest (search @top) -> click the extended tab -> run as different user: write: root
Very likely this can be done in a similar way in other DEs like Mate or XfCE. I'm not shure, but maybe k3b refuses to run as root, and then this is useless (but it's usefull e.g. for octopkg). Please edit your /etc/devfs.conf like I wrote in my previous post. This should enable k3b (or any other CD/DVD authoring tool like e.g. brasero for Mate or XfCE) to access the burner in write mode when it was started by a regular user. After you've done that & it does not succeed to burn a CD/DVD, then please post the output of
  • ls -l /dev/cd*
  • id randy
  • cat /etc/devfs.conf
 
I installed k3b just like 2 weeks ago and used it (as a user, not root) to burn some mp3s for use in my car. Basically I just followed the instructions in the pkg-message and k3b itself and it worked out of the box:
Code:
1. The FreeBSD k3b port supports SCSI drives only. If you have IDE CD or DVD
   drives, use them through the cam system. See Chapter 17.5.1 of the handbook
   (http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/creating-cds.html)
2. k3b has to be started from a root console, which is not recommended.
   Alternatively, do ALL of the following:
   a. Every user must have read and write access to /dev/cdX:
      - add to your /etc/devfs.rules under '[system=10]':
          add path 'cd*' mode 666
      - or if you prefer allow access for a group XXX only add instead:
          add path 'cd*' mode 660 group XXX
      - to enable it, add to your /etc/rc.conf
          # sysrc devfs_system_ruleset="system"
   b. Every user who should be able to use k3b must have read and write access
      to all pass through devices connected with CD and DVD drives and to the
      /dev/xpt0 device. Run 'camcontrol devlist' to identify those devices (seek
      string 'passX' at the end of each line). Note, that this is a security
      leak as well but that there is no alternative!
      - add to your /etc/devfs.rules under '[system=10]':
          add path 'pass*' mode 666
          add path 'xpt0' mode 666
      - or if you prefer allow access for a group XXX only add instead:
          add path 'pass*' mode 660 group XXX
          add path 'xpt0' mode 660 group XXX
      - to enable it, add to your /etc/rc.conf
          # sysrc devfs_system_ruleset="system"
      - to apply these changes without reboot, run as root:
          # service devfs restart
3. Create a directory on a partition, which has enough disk space to hold a CDs
   or DVDs content (usually below /usr). Enter this directory in Settings->
   Configure K3b...->Misc.
4. You must configure devel/kf5-solid appropriately:
   a. Either use the (default) HAL backend, and enable HAL in /etc/rc.conf via
      # sysrc hald_enable="YES"
   b. *or* use the (experimental) BSDISKS backend.
5. Last but not the least, you need to set cdrecord parameters in K3b's
   "Settings --> Configure k3b... --> Programs --> User Parameters" to
   match your device as seen by `cdrecord -scanbus' (e.g. dev=3,0,0)
In my /etc/devfs.rules file I got:
Code:
[localrules=10]

# Allow members of group operator access to SCSI disk devices.
add path 'da*p*' mode 0660 group operator
add path 'da*s*' mode 0660 group operator

# Allow members of group operator access to USB devices.
add path 'usb/*' mode 0660 group operator

# Allow members of group operator access to CD/DVD drive.
add path 'cd0' mode 0660 group operator
add path 'pass1' mode 0660 group operator
add path 'xpt0' mode 0660 group operator
It's the last three lines that should be important for k3b, and as explained above, you need to find out the passX device that corresponds to your CD/DVD drive using camcontrol devlist. Also you need to activate those rules in your /etc/rc.conf by adding:
Code:
devfs_system_ruleset="localrules"
The user needs to be a member of the operator group (not sure if wheel is needed too, but I got that one also), and don't forget to restart devfs or reboot the machine, for the changes to become effective.
 
I installed k3b just like 2 weeks ago and used it (as a user, not root) to burn some mp3s for use in my car. Basically I just followed the instructions in the pkg-message and k3b itself and it worked out of the box:
Code:
1. The FreeBSD k3b port supports SCSI drives only. If you have IDE CD or DVD
   drives, use them through the cam system. See Chapter 17.5.1 of the handbook
   (http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/creating-cds.html)
2. k3b has to be started from a root console, which is not recommended.
   Alternatively, do ALL of the following:
   a. Every user must have read and write access to /dev/cdX:
      - add to your /etc/devfs.rules under '[system=10]':
          add path 'cd*' mode 666
      - or if you prefer allow access for a group XXX only add instead:
          add path 'cd*' mode 660 group XXX
      - to enable it, add to your /etc/rc.conf
          # sysrc devfs_system_ruleset="system"
   b. Every user who should be able to use k3b must have read and write access
      to all pass through devices connected with CD and DVD drives and to the
      /dev/xpt0 device. Run 'camcontrol devlist' to identify those devices (seek
      string 'passX' at the end of each line). Note, that this is a security
      leak as well but that there is no alternative!
      - add to your /etc/devfs.rules under '[system=10]':
          add path 'pass*' mode 666
          add path 'xpt0' mode 666
      - or if you prefer allow access for a group XXX only add instead:
          add path 'pass*' mode 660 group XXX
          add path 'xpt0' mode 660 group XXX
      - to enable it, add to your /etc/rc.conf
          # sysrc devfs_system_ruleset="system"
      - to apply these changes without reboot, run as root:
          # service devfs restart
3. Create a directory on a partition, which has enough disk space to hold a CDs
   or DVDs content (usually below /usr). Enter this directory in Settings->
   Configure K3b...->Misc.
4. You must configure devel/kf5-solid appropriately:
   a. Either use the (default) HAL backend, and enable HAL in /etc/rc.conf via
      # sysrc hald_enable="YES"
   b. *or* use the (experimental) BSDISKS backend.
5. Last but not the least, you need to set cdrecord parameters in K3b's
   "Settings --> Configure k3b... --> Programs --> User Parameters" to
   match your device as seen by `cdrecord -scanbus' (e.g. dev=3,0,0)
In my /etc/devfs.rules file I got:
Code:
[localrules=10]

# Allow members of group operator access to SCSI disk devices.
add path 'da*p*' mode 0660 group operator
add path 'da*s*' mode 0660 group operator

# Allow members of group operator access to USB devices.
add path 'usb/*' mode 0660 group operator

# Allow members of group operator access to CD/DVD drive.
add path 'cd0' mode 0660 group operator
add path 'pass1' mode 0660 group operator
add path 'xpt0' mode 0660 group operator
It's the last three lines that should be important for k3b, and as explained above, you need to find out the passX device that corresponds to your CD/DVD drive using camcontrol devlist. Also you need to activate those rules in your /etc/rc.conf by adding:
Code:
devfs_system_ruleset="localrules"
The user needs to be a member of the operator group (not sure if wheel is needed too, but I got that one also), and don't forget to restart devfs or reboot the machine, for the changes to become effective.
Thanks - I have carried out everyone of the above as those we listed at the end of the make install clean process. I've been using Freebsd since 4.7.
 
Back
Top