Tarhon-Onu Victor <[EMAIL PROTECTED]> scria la data de 7 Noiembrie
2005:
> On Mon, 7 Nov 2005, Constantin Gavrilescu wrote:
>
> >> Asta inseamna ca parport e folosit de parport_pc si lp care la
> >> randu' lor tot module sunt. Da rmmod lp && rmmod parport_pc &&
> >> rmmod parport.
> >>
> >
> > # rmmod lp
> > lp: Device or resource busy
>
> fuser -v /dev/lp*
Asta merge atat timp cat modulul respectiv e agatat de unul sau mai
multe device-uri reprezentate in filesystem. De exemplu:
$ lsmod | grep -w ^ixj
ixj 171124 2 (autoclean)
$ grep -w ixj /etc/modules.conf
alias char-major-100 ixj
$ ls -l /dev | grep ^c.*' '100,
crw-rw-rw- 1 root root 100, 0 Oct 28 08:38 phone0
crw-rw-rw- 1 root root 100, 1 Oct 28 08:38 phone1
crw-rw-rw- 1 root root 100, 10 Oct 28 08:38 phone10
crw-rw-rw- 1 root root 100, 11 Oct 28 08:38 phone11
crw-rw-rw- 1 root root 100, 12 Oct 28 08:38 phone12
crw-rw-rw- 1 root root 100, 13 Oct 28 08:38 phone13
crw-rw-rw- 1 root root 100, 14 Oct 28 08:38 phone14
crw-rw-rw- 1 root root 100, 15 Oct 28 08:38 phone15
crw-rw-rw- 1 root root 100, 2 Oct 28 08:38 phone2
crw-rw-rw- 1 root root 100, 3 Oct 28 08:38 phone3
crw-rw-rw- 1 root root 100, 4 Oct 28 08:38 phone4
crw-rw-rw- 1 root root 100, 5 Oct 28 08:38 phone5
crw-rw-rw- 1 root root 100, 6 Oct 28 08:38 phone6
crw-rw-rw- 1 root root 100, 7 Oct 28 08:38 phone7
crw-rw-rw- 1 root root 100, 8 Oct 28 08:38 phone8
crw-rw-rw- 1 root root 100, 9 Oct 28 08:38 phone9
$ sudo fuser /dev/phone*
Password:
/dev/phone0: 4714 12156 17677 24513 26361
$ ps ax | grep -w 4714
4714 tty1 S 0:00 ohphone -u liviu -c -n -l -i 10.0.7.9 -v 0
--disable-menu --aec 5 -C RO -q 0
Pentru un modul care nu are treaba cu filesystem-ul (de exemplu unul
care creaza o interfata de network), schema asta nu mai merge:
$ lsmod | grep -w ^cipcb
cipcb 29352 1 (autoclean)
$ grep -w cipcb /etc/modules.conf
alias cipcb0 cipcb
alias cipcb1 cipcb
alias cipcb2 cipcb
alias cipcb3 cipcb
options cipcb cipe_debug=0
$ ls /dev/cipcb*
ls: /dev/cipcb*: No such file or directory
Sigur, poti sapa prin /proc/ksyms, /dev/kmem si /dev/mem, insa
detaliile acestei operatii sunt un exercitiu interesant. :-)
Salutari,
Liviu Daia
--
Dr. Liviu Daia http://www.imar.ro/~daia
_______________________________________________
RLUG mailing list
[email protected]
http://lists.lug.ro/mailman/listinfo/rlug