Device /dev/ttyS0 is locked or Serial port locked while using minicom

In general minicom will use serial ports in Debian Linux. So the programs using minicom will create a “temporary lock” file in some of the temporary directory in Linux like /tmp or /var/tmp/ or /var/lock/, so that there is no access violation in case if another user is trying to use the same program. Many times these program have to be quit or exited in an un-graceful fashion as a result of which the “temporary lock” file is never deleted.

While using minicom, you may have seen messages like the following in Ubuntu :

minicom-lock-1

Now you can remove the lock by deleting the lock file located at /var/lock in Ubuntu as follows:

minicom-lock-2

Now open the minicom with the desired USB port as follows:

minicom-lock-3

Here you go, the minicom works :

minicom-lock-4

Comments

  1. By Anthony Ovalles

    Reply

Leave a Reply