tdbtool question

Kurt Pfeifle k1pfeifle at
Tue Jul 24 15:51:16 GMT 2007

I was playing with tdbtool to show and/or delete individual keys from a
.tdb file.

What I can't find out is the precise syntax to use.


  [root at prod printing]# tdbtool SCHP011.tdb
  tdb> keys
  key 23 bytes: INFO/linear_queue_array
  key 14 bytes: STATUS/SCHP011
  key 16 bytes: NOTIFY_PID_LIST
  key 20 bytes: MSG_PENDING/SCHP011
  key 13 bytes: INFO/version
  key 16 bytes: INFO/total_jobs
  key 14 bytes: CACHE/SCHP011
  tdb> help

    create    dbname     : create a database
    open      dbname     : open an existing database
    erase                : erase the database
    dump                 : dump the database as strings
    cdump                : dump the database as connection records
    keys                 : dump the database keys as strings
    hexkeys              : dump the database keys as hex values
    info                 : print summary info about the database
    insert    key  data  : insert a record
    move      key  file  : move a record to a destination tdb
    store     key  data  : store a record (replace)
    show      key        : show a record by key
    delete    key        : delete a record by key
    list                 : print the database hash table and freelist
    free                 : print the database freelist
    ! command            : execute system command
    1 | first            : print the first record
    n | next             : print the next record
    q | quit             : terminate
    \n                   : repeat 'next' command

  tdb> info
  7 records totalling 292 bytes
  tdb> show CACHE/SCHP011
  fetch failed
  tdb> show 'CACHE/SCHP011'
  fetch failed
  tdb> show "CACHE/SCHP011"
  fetch failed
  tdb> show CACHE\/SCHP011
  fetch failed
  tdb> show CACHE
  fetch failed
  tdb> show SCHP011
  fetch failed

Does tdbtool even work currently? (this was 3.0.25b)

Kurt Pfeifle
System & Network Printing Consultant ---- Linux/Unix/Windows/Samba/CUPS
Infotec Deutschland GmbH  .....................  Hedelfinger Strasse 58
A RICOH Company  ...........................  D-70327 Stuttgart/Germany

More information about the samba-technical mailing list