# cap problems



## Beeblebrox (Feb 13, 2012)

getcap, printcap, termcap
None of these work and give a "Command not found" message

`# cap_mkdb /etc/login.conf`
does not generate a db file but
`# cap_mkdb login.conf`
does generate the db. Unfortunately, the result is ineffective because the $PATH settings in env are not updated to the new config.

So I think there is something wrong with the "cap" structure.


----------



## Beeblebrox (Feb 14, 2012)

Somehow, cap_mkdb was able to generate the db today and I got below output instead of the db being erased and an error message.
`# cap_mkdb -v /etc/login.conf`

```
cap_mkdb: 10 capability records
```
However, two statements in the $PATH setting are still ignored (/usr/local/kde4/bin for example) and printcap etc give same error.


----------



## fluca1978 (Feb 14, 2012)

Are you sure the environment is not tainted? I mean, maybe you are becoming root from another account without loading the root variables?


----------



## Beeblebrox (Feb 14, 2012)

I deleted the db and re-ran cap_mkdb from root login on tty1, just to be sure. Same result.

EDIT: You were partially right about the environment settings. I went through my /etc/csh.cshrc, /root/.cshrc, ~/.cshrc files and found that I had replicated the settings from /etc/login.conf in those files as well. Then I remembered I had done so at some point in time because the settings from login.conf were not taking effect (this exact same problem). I even had to place my PACKAGESITE=ftp:/ setting into cshrc!

When I took out the path statements in all 3 cshrc files, path reverted to only these and nothing else.

```
/usr/bin:/bin
```
Also only 10 records seems too small, considering my additions to login.conf.


----------

