Skip to content
Advertisement

Interacting with a .db file from Linux shell

I recently installed minidlna, a lightweight UPnP server, on my Raspberry Pi. Since this lacks the web interface of other programs such as Mediatomb, I thought it could be an interesting project for me to write one.

I believe minidlna stores library information in a single file named “files.db”.


EDIT: I was advised to check the output of file files.db – this was as follows:

files.db: SQLite 3.x database, user version 8


However, I can’t find a program that lets me interact with .db files from the shell. I’ve seen the following programs recommended:

  • isql
  • dbaccess
  • sql
  • SQLite3
  • db.util

In the first four cases, sudo apt-get install cannot find the programs.

sudo apt-get install db.util appears to install, but partway through installation, yields the following messages:

JavaScript

Thereafter, which db-util, which db.util, and which dbutil do not yield any results.

Is db.util the correct program to be installing to interact with .db files? If so, how can I fix the reported error with gcj-dbtool? If not, could someone recommend a better program?

Advertisement

Answer

You will have to install a package named ‘sqlite’ or ‘sqlite3’.

Then you will be able to interact with your .db file using

JavaScript

In your post you mention ‘SQLite3’, the package name should have no caps letters.

Did you run an apt-cache search sqlite ?

User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement