# info messages after install a package



## polhallen (Apr 28, 2013)

Hi folks!

I need to check where are the messages that show at the end of installing a package, ie: `pkg_add -v -r postfix`, at the end there are some messages. Where can I find those messages?

Thanks!

Pol


----------



## bkouhi (Apr 28, 2013)

`pkg_info -D -x foobar`

You can also check the pkg-message file in the port directory.

For example:


```
[CMD]# pkg_info -D -x apache[/CMD]
Information for apache22-2.2.24:

Install notice:
To run apache www server from startup, add apache22_enable="YES"
in your /etc/rc.conf. Extra options can be found in startup script.
...
```

Same as:

```
[CMD]# cat /usr/ports/www/apache22/pkg-message[/CMD]
To run apache www server from startup, add apache22_enable="YES"
in your /etc/rc.conf. Extra options can be found in startup script.
...
```

There are some ports that prints some non-standard messages. For those ports, you must check that port's Makefile.


```
[CMD]cat /usr/port/www/phpbb3/Makefile[/CMD]
...
pre-everything::
.if !defined(BATCH)
        @ ${TEST} -r ${PKGOPTS} && \
          (${ECHO_MSG} '-------------------------------------------------------------------------'; \
           ${ECHO_MSG} 'Perform a "make options" to see a list of available installation options.'; \
           ${ECHO_MSG} '-------------------------------------------------------------------------')
.endif
...
```

More about pkg-message.


----------



## polhallen (Apr 28, 2013)

Clear. Many thanks boy.

Cheers!

Pol


----------



## polhallen (Apr 29, 2013)

Another question about pkg_info: how to discover what is the package that include a command? E.g.: adduser. I need to check adduser to understand what are its configuration files.

Thanks!


----------



## fonz (Apr 29, 2013)

Actually, adduser(8) is not from any package, it's part of the base system. Its (main) configuration file is /etc/adduser.conf, as described in the man page I just linked to.


----------



## bkouhi (Apr 29, 2013)

If you are asking which package installed a special file, try this:

`pkg_info -W /path/to/file`

For example:


```
[CMD]% pkg_info -W /usr/local/etc/portmaster.rc.sample[/CMD]
/usr/local/etc/portmaster.rc.sample was installed by package portmaster-3.16
[CMD]% pkg_info -W /usr/local/bin/xcalc[/CMD]
/usr/local/bin/xcalc was installed by package xcalc-1.0.5
```

But it doesn't work in the case of adduser(8)(). Because adduser(8)() is part of base system. However, adduser(8)()'s main configuration file is /etc/adduser.conf


----------



## polhallen (Apr 29, 2013)

Thanks!


----------

