Por que minha unidade de DVD é “/ dev / dvd1” em vez de “/ dev / dvd”?

3

Eu raramente uso DVDs, então notei que o VLC não conseguiu encontrar a unidade (como /dev/dvd ). Olhando para a pasta / dev, /dev/dvd1 e /dev/dvdrw1 e /dev/cdrom1 existem. Eu nunca tive um segundo drive de DVD lá, então minha pergunta é:

Como isso aconteceu?

O que é responsável por atribuir esses nomes de arquivos?

    
por marto 21.12.2011 / 19:02

1 resposta

2

Não sei dizer como, mas as regras do udev estão atribuindo esses nomes de arquivos. No passado, com o Kubuntu: link .

Um leia-me: /etc/udev/rules.d/README

The files in this directory are read by udev(7) and used when events are performed by the kernel. The udev daemon watches this directory with inotify so that changes to these files are automatically picked up, for this reason they must be files and not symlinks to another location as in the case in Debian.

Packages do not generally install rules here, this directory is for local rules. If you want to override behaviour of package-supplied rules, which can be found in /lib/udev/rules.d, you can do one of two things:

1) Write your own rules in this directory that assign the name, symlinks, permissions, etc. that you want. Pick a number higher than the rules you want to override, and yours will be used.

2) Copy the file from /lib/udev/rules.d and edit it here; you should generally only do this if you want to prevent a program from being run.

If the ordering of files in this directory are not important to you, it's recommended that you simply name your files "descriptive-name.rules" such that they are processed AFTER all numbered rules in both this directory and /lib/udev/rules.d and thus override anything set there.

O /etc/udev/rules.d/70-persistent-cd.rules tem as regras do CD e do DVD. Você poderia modificá-lo:

This file was automatically generated by the /lib/udev/write_cd_rules program, run by the cd-aliases-generator.rules rules file.

You can modify it, as long as you keep each rule on a single line, and set the $GENERATED variable.

    
por user26687 21.12.2011 / 20:22