Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[UDEV] permisssion de /dev/sg* (résolu)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index French
View previous topic :: View next topic  
Author Message
BuBuaBu
l33t
l33t


Joined: 09 Jul 2005
Posts: 914
Location: France

PostPosted: Sun Jan 22, 2006 11:59 am    Post subject: [UDEV] permisssion de /dev/sg* (résolu) Reply with quote

Bonjour,
Voila mon scanner scsi se trouve sur le /dev/sg0, et est par default en rw-rw----, root:root.
Par conséquant personne ne peut l'utilisé.

J'ai voulu modifié le /etc/udev/permissions.d/udev.permissions mais ce fichier n'existe plus.

J'ai trouvé celui-ci : /etc/udev/rules.d/50-udev.rules, mais pas trouvé la règle pour /dev/sg* et deplus il semblerai que la syntax ai changé depuis l'ancien fichier.


Last edited by BuBuaBu on Sun Jan 22, 2006 12:12 pm; edited 1 time in total
Back to top
View user's profile Send private message
kernelsensei
Bodhisattva
Bodhisattva


Joined: 22 Feb 2004
Posts: 5619
Location: Woustviller/Moselle/FRANCE (49.07°N;7.02°E)

PostPosted: Sun Jan 22, 2006 12:09 pm    Post subject: Reply with quote

essaye de créer un fichier dans /etc/udev/rules.d

et dedans mets :
Code:
KERNEL="sg*" , MODE="0666"


par exemple, sinon tu peux jouer sur le groupe avec GROUP=

une fois le fichier écrit, fais udevstart et regarde si ça a changé
_________________
$ ruby -e'puts " .:@BFegiklnorst".unpack("x4ax7aaX6ax5aX15ax4aax6aaX7ax2aX5aX8 \
axaX3ax8aX4ax6aX3aX6ax3ax3aX9ax4ax2aX9axaX6ax3aX2ax4ax3aX4aXaX12ax10aaX7a").join'
Back to top
View user's profile Send private message
BuBuaBu
l33t
l33t


Joined: 09 Jul 2005
Posts: 914
Location: France

PostPosted: Sun Jan 22, 2006 12:12 pm    Post subject: Reply with quote

Simple, enfin bon. Depuis quand la syntax a changé ?
Back to top
View user's profile Send private message
marvin rouge
Veteran
Veteran


Joined: 01 Aug 2004
Posts: 1422
Location: Villa Lumierrante, Zonelibre

PostPosted: Sun Jan 22, 2006 12:13 pm    Post subject: Reply with quote

Regarde peut-être du coté de /etc/hotplug/ il ya des scripts qui modifient les droits des devices.

En particulier, chez moi j'ai ça:
Code:
$  cat /etc/hotplug/usb/libusbscanner
#!/bin/sh

# This file is part of sane-backends.
# This script changes the permissions and ownership of a USB device under
# /proc/bus/usb to grant access to this device to users in the scanner group.
# Ownership is set to root:scanner, permissions are set to 0660.
# Arguments :
# -----------
# ACTION=[add|remove]
# DEVICE=/proc/bus/usb/BBB/DDD
# TYPE=usb

# latest hotplug doesn't set DEVICE on 2.6.x kernels
if [ -z "$DEVICE" ] ; then
  IF=`echo $DEVPATH | sed 's/\(bus\/usb\/devices\/\)\(.*\)-\(.*\)/\2/'`
  DEV=$(cat /sys/${DEVPATH}/devnum)
  DEVICE=`printf '/proc/bus/usb/%.03d/%.03d' $IF $DEV`
fi

if [ "$ACTION" = "add" -a "$TYPE" = "usb" ]; then
  chown root:scanner "$DEVICE"
  chmod 0660 "$DEVICE"
fi

# That's an insecure but simple alternative
# Everyone has access to the scanner
# if [ "$ACTION" = "add" -a "$TYPE" = "usb" ]; then
#  chmod 0666 "$DEVICE"
# fi
(scanner usb détéecté par XSANE)

EDIT : oops, complètement grillé ...
Back to top
View user's profile Send private message
kernelsensei
Bodhisattva
Bodhisattva


Joined: 22 Feb 2004
Posts: 5619
Location: Woustviller/Moselle/FRANCE (49.07°N;7.02°E)

PostPosted: Sun Jan 22, 2006 12:15 pm    Post subject: Reply with quote

BuBuaBu wrote:
Simple, enfin bon. Depuis quand la syntax a changé ?


depuis que permissions.d n'est plus utilisé ... c'etait dans la série des udev-0.5x (0.54 je crois)
_________________
$ ruby -e'puts " .:@BFegiklnorst".unpack("x4ax7aaX6ax5aX15ax4aax6aaX7ax2aX5aX8 \
axaX3ax8aX4ax6aX3aX6ax3ax3aX9ax4ax2aX9axaX6ax3aX2ax4ax3aX4aXaX12ax10aaX7a").join'
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index French All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum