On Fri, Jan 11, 2013 at 09:34:25AM -0800, peasthope@shaw.ca wrote: > While vlc is producing sound from M1357873276.WAV this > is observed. > > peter@dalton:~$ lsof /home/peter/*.WAV > COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME > vlc 10888 peter 9u REG 8,6 20470 3612711 /home/peter/M1357873276.WAV > > man lsof explains, > "The mode character is followed by one of these lock charac- > ters, describing the type of lock applied to the file: > ... > u for a read and write lock of any length;" > > A write lock would prevent another process from writing to > the file while vlc is working. > > Can anyone tell me the meaning of file descriptor 9? Simply, it is the ninth file handle that vlc has open. When a process starts, it is provided with three channels of I/O: stdin (0), stdout (1) and stderr (2). At any point it may open more channels (usually to/from files) and these would start at 3. It may be that the process opens a file (say a configuration file on fd 3), then closes it and opens a different one; in this case the file descriptor can be re-used. I am not sure of this, but I suspect the allocated file-descriptor number is the highest number already opened plus one. If you look at vlc's other opened files, you will probably see that they are a combination of the stdio channels, control pipes (maybe) and libraries.
Attachment:
signature.asc
Description: Digital signature