Loading ...
Sorry, an error occurred while loading the content.

Re: [linuxham] My Serial Port is Locked!!

Expand Messages
  • Glenn VE9GJ
    ... Another thought is that it may not be permissions but another process using the serial port. You can check it in a terminal window with the fuser command
    Message 1 of 3 , Jul 9 7:14 AM
    • 0 Attachment
      Glenn VE9GJ wrote:
      > Irena and Richard Jenkins wrote:
      >> I need to find out what programs are 'owning' my serial port. When I run
      >> ls-al /dev/ttyS0 I get the following:
      >>
      >> crw-rw---- 1 root dialout 4, 64 2008-07-09 12:29 /dev/ttyS0
      >>
      >> and richard is a member of dialout. However, when richard tries to use the
      >> port ... I see a permission denied message
      >>
      >>> 2008/07/09 12:29:06;;GRIG;;2;;rig_daemon_start: Failed to open rig port
      >>> /dev/ttyS0 (permissions?)
      >>
      >>
      >> How can this be fixed??
      >>
      >> Richard
      >
      > Was richard always a member of dialout or did you just add richard to
      > the dialout group? IIRC user richard will have to log completely off
      > and then log on again for user richard to actually pick up any group
      > changes. I have got caught with that in the past myself.
      >
      > 73
      > Glenn VE9GJ

      Another thought is that it may not be permissions but another process
      using the serial port. You can check it in a terminal window with the
      fuser command (file user?):

      fuser /dev/ttyS0

      That will give you the PID of anything using the serial port
      On my ubuntu box:

      glenn@hamshack2:~$ fuser /dev/ttyS0
      /dev/ttyS0: 17610

      which gives us a PID of 17610, below we check for what PID 17610 is:

      glenn@hamshack2:~$ ps -ef|grep 17610
      glenn 17610 1 3 10:49 ? 00:00:01
      /home/glenn/bin/fldigi2.10 -s gtk+
      glenn 17615 12146 0 10:49 pts/1 00:00:00 grep 17610

      Now we can see that fldigi2.10 is using it!

      Not sure what distro of Linux you have but hopefully fuser is there by
      default.

      73
      Glenn VE9GJ
    Your message has been successfully submitted and would be delivered to recipients shortly.