# [PEAR] Access violation when emerging horde-pear

## arlequin

Hi all,

i'm getting this message when I try to emerge dev-php/horde-pear :

```
serveur32 ~ # emerge -uv horde-pear

Calculating dependencies ...done!

>>> emerge (1 of 22) dev-php/PEAR-Mail_Mime-1.2.1-r1 to /

>>> md5 files   ;-) ChangeLog

>>> md5 files   ;-) PEAR-Mail_Mime-1.2.1-r1.ebuild

>>> md5 files   ;-) metadata.xml

>>> md5 files   ;-) files/digest-PEAR-Mail_Mime-1.2.1-r1

>>> md5 src_uri ;-) Mail_Mime-1.2.1.tgz

>>> Unpacking source...

>>> Unpacking Mail_Mime-1.2.1.tgz to /var/tmp/portage/PEAR-Mail_Mime-1.2.1-r1/work

tar: Un bloc zéro solitaire repéré à 151

>>> Source unpacked.

>>> Test phase [not enabled]: dev-php/PEAR-Mail_Mime-1.2.1-r1

>>> Install PEAR-Mail_Mime-1.2.1-r1 into /var/tmp/portage/PEAR-Mail_Mime-1.2.1-r1/image/ category dev-php

install ok: Mail_Mime 1.2.1

ACCESS DENIED  rename:    /var/lib/net-snmp/snmpapp.conf

No log handling enabled - turning on stderr logging

Cannot rename //var/lib/net-snmp/snmpapp.conf to //var/lib/net-snmp/snmpapp.0.conf

ACCESS DENIED  unlink:    /var/lib/net-snmp/snmpapp.conf

Cannot unlink //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

man:

prepallstrip:

strip: strip --strip-unneeded

>>> Completed installing PEAR-Mail_Mime-1.2.1-r1 into /var/tmp/portage/PEAR-Mail_Mime-1.2.1-r1/image/

--------------------------- ACCESS VIOLATION SUMMARY ---------------------------

LOG FILE = "/tmp/sandbox-dev-php_-_PEAR-Mail_Mime-1.2.1-r1-31991.log"

rename:    /var/lib/net-snmp/snmpapp.conf

unlink:    /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

--------------------------------------------------------------------------------
```

Any good ideas will be welcome  :Smile: 

More about my system :

```
serveur32 ~ # emerge info

Portage 2.0.51.19 (default-linux/x86/2005.0/2.4, gcc-3.3.5, glibc-2.3.4.20041102-r1, 2.6.10-grsec i686)

=================================================================

System uname: 2.6.10-grsec i686 Pentium III (Coppermine)

Gentoo Base System version 1.4.16

Python:              dev-lang/python-2.2.3-r5,dev-lang/python-2.3.4-r1 [2.3.4 (#1, Mar 12 2005, 13:21:40)]

distcc 2.16 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [enabled]

dev-lang/python:     2.2.3-r5, 2.3.4-r1

sys-devel/autoconf:  2.13, 2.59-r6

sys-devel/automake:  1.6.3, 1.9.4, 1.4_p6, 1.5, 1.7.9-r1, 1.8.5-r3

sys-devel/binutils:  2.15.92.0.2-r1

sys-devel/libtool:   1.5.10-r4

virtual/os-headers:  2.6.8.1-r2

ACCEPT_KEYWORDS="x86"

AUTOCLEAN="yes"

CFLAGS="-march=pentium3 -O3 -pipe -fomit-frame-pointer"

CHOST="i686-pc-linux-gnu"

CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/bind /var/qmail/alias /var/qmail/control /var/vpopmail/domains /var/vpopmail/etc"

CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"

CXXFLAGS="-march=pentium3 -O3 -pipe -fomit-frame-pointer"

DISTDIR="/usr/portage/distfiles"

FEATURES="autoaddcvs autoconfig ccache distcc distlocks sandbox sfperms strict"

GENTOO_MIRRORS="http://mir.zyrianes.net/gentoo/"

LANG="fr_FR"

LC_ALL="fr_FR"

MAKEOPTS="-j3"

PKGDIR="/usr/portage/packages"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"

USE="x86 alsa apache2 apm arts avi berkdb bitmap-fonts cdr crypt curl emboss encode esd foomaticdb gd gdbm gif hardened imagemagick imap imlib innodb java jpeg ldap libg++ libwww mad mikmod mmx motif mp3 mpeg mysql ncurses nls odbc oggvorbis opengl oss pam pdflib perl png python qmail quicktime readline sdl slang snmp spamassassin spell sqlite sse ssl svga tcltk tcpd truetype truetype-fonts type1-fonts xml xml2 xv zlib"

Unset:  ASFLAGS, CBUILD, CTARGET, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
```

----------

## wellwhoopdedooo

I am having the same problem, when I try "emerge -uvD world" it wants to install a new package, dev-php/PEAR-Auth_SASL. Here is the error I am receiving:

```
>>> emerge (1 of 9) dev-php/PEAR-Auth_SASL-1.0.1 to /

>>> md5 files   ;-) PEAR-Auth_SASL-1.0.1.ebuild

>>> md5 files   ;-) ChangeLog

>>> md5 files   ;-) metadata.xml

>>> md5 files   ;-) files/digest-PEAR-Auth_SASL-1.0.1

>>> md5 src_uri ;-) Auth_SASL-1.0.1.tgz

>>> Unpacking source...

>>> Unpacking Auth_SASL-1.0.1.tgz to /var/tmp/portage/PEAR-Auth_SASL-1.0.1/work

tar: A lone zero block at 74

>>> Source unpacked.

>>> Test phase [not enabled]: dev-php/PEAR-Auth_SASL-1.0.1

>>> Install PEAR-Auth_SASL-1.0.1 into /var/tmp/portage/PEAR-Auth_SASL-1.0.1/image/ category dev-php

install ok: Auth_SASL 1.0.1

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

No log handling enabled - turning on stderr logging

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

man:

prepallstrip:

strip: i686-pc-linux-gnu-strip --strip-unneeded

>>> Completed installing PEAR-Auth_SASL-1.0.1 into /var/tmp/portage/PEAR-Auth_SASL-1.0.1/image/

--------------------------- ACCESS VIOLATION SUMMARY ---------------------------

LOG FILE = "/tmp/sandbox-dev-php_-_PEAR-Auth_SASL-1.0.1-26696.log"

open_wr:   /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf
```

And here is my info:

```
Portage 2.0.51.19 (default-linux/x86/2005.0, gcc-3.3.5-20050130, glibc-2.3.4.20041102-r1, 2.6.11-gentoo-r5-01 i686)

=================================================================

System uname: 2.6.11-gentoo-r5-01 i686 Pentium III (Katmai)

Gentoo Base System version 1.4.16

Python:              dev-lang/python-2.3.4-r1 [2.3.4 (#1, Feb 23 2005, 03:53:57)]

distcc 2.16 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]

ccache version 2.3 [enabled]

dev-lang/python:     2.3.4-r1

sys-devel/autoconf:  2.59-r6, 2.13

sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.4

sys-devel/binutils:  2.15.92.0.2-r7

sys-devel/libtool:   1.5.14

virtual/os-headers:  2.6.8.1-r2

ACCEPT_KEYWORDS="x86"

AUTOCLEAN="yes"

CFLAGS="-O2 -pipe -march=pentium3 -fomit-frame-pointer"

CHOST="i686-pc-linux-gnu"

CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/alias /var/qmail/control"

CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"

CXXFLAGS="-O2 -pipe -march=pentium3 -fomit-frame-pointer"

DISTDIR="/usr/portage/distfiles"

FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms strict"

GENTOO_MIRRORS="http://gentoo.mirrors.pair.com/ http://gentoo.ccccom.com/ http://gentoo.netnitco.net/ http://gentoo.llarian.net/"

MAKEOPTS=""

PKGDIR="/usr/portage/packages"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

SYNC="rsync://rsync.gentoo.org/gentoo-portage"

USE="acl aim apache2 bash-completion berkdb bitmap-fonts bzlib calendar caps cdb crypt cups curl curlwrappers dba dbx dio doc emboss encode ethereal exif fam fastcgi flac flash flatfile foomaticdb fortran ftp gd gdbm gif gmp gnutls icq imagemagick imap imlib inifile innodb ipv6 irc jabber java jikes jpeg kerberos krb4 ldap libg++ libwww lj mad maildir mcal mcve memlimit mhash mime ming mmap mmx mng mp3 mpi msession msn mysql mysqli nas ncurses nfsv4 nis nls nntp nocardbus nptl odbc offensive ogg oggvorbis openal oscar pam pcntl pcre pdflib perl php pic pie png posix postgres ppds python readline recode rss ruby samba sasl session shared sharedmem simplexml slang slp smtp sndfile snmp sockets sox speex spell spl sse ssl svg sysvipc szip tcpd tiff tokenizer truetype truetype-fonts type1-fonts unicode winbind wmf x86 xml xml2 xmlrpc xpm xsl xv yahoo zlib"

Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
```

----------

## arlequin

I (temporary) solved it by doing :

```
emerge -vp "=horde-pear-1.3-r1"
```

but, that don't satisfy me...  :Sad: 

----------

## sound

same problem here with PEAR-DB-1.6.8

```

>>> Install PEAR-DB-1.6.8 into /var/tmp/portage/PEAR-DB-1.6.8/image/ category dev-php

install ok: DB 1.6.8

ACCESS DENIED  rename:    /var/lib/net-snmp/snmpapp.conf

No log handling enabled - turning on stderr logging

Cannot rename //var/lib/net-snmp/snmpapp.conf to //var/lib/net-snmp/snmpapp.0.conf

ACCESS DENIED  unlink:    /var/lib/net-snmp/snmpapp.conf

Cannot unlink //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

ACCESS DENIED  open_wr:   /var/lib/net-snmp/snmpapp.conf

read_config_store open failure on //var/lib/net-snmp/snmpapp.conf

man:

prepallstrip:

strip: i686-pc-linux-gnu-strip --strip-unneeded

>>> Completed installing PEAR-DB-1.6.8 into /var/tmp/portage/PEAR-DB-1.6.8/image/

--------------------------- ACCESS VIOLATION SUMMARY ---------------------------

LOG FILE = "/tmp/sandbox-dev-php_-_PEAR-DB-1.6.8-21902.log"

rename:    /var/lib/net-snmp/snmpapp.conf

unlink:    /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

open_wr:   /var/lib/net-snmp/snmpapp.conf

--------------------------------------------------------------------------------

```

----------

## wellwhoopdedooo

I found a solution of sorts to this...

Edit /usr/portage/eclass/php-pear.eclass. Right below the line "addpredict /usr/share/snmp/mibs/.index", add "addpredict /var/lib/net-snmp/snmpapp.conf".

I was able to emerge fine after that, although I'm not sure if the install should be able to write to snmpapp.conf... maybe someone can copy their snmpapp.conf to a backup, and instead of addpredict /var/lib/net-snmp/snmpapp.conf", make it "addwrite /var/lib/net-snmp/snmpapp.conf" and let us know what the differences are.

Also, next time you "emerge sync", your change will be undone. Hopefully this is fixed before we need to update again.

----------

## Hurri-Cane

 *Quote:*   

> wellwhoopdedooo
> 
> I found a solution of sorts to this... 
> 
> Edit /usr/portage/eclass/php-pear.eclass. Right below the line "addpredict /usr/share/snmp/mibs/.index", add "addpredict /var/lib/net-snmp/snmpapp.conf". 
> ...

 

(i got the same error emerging PEAR-DB-1.6. :Cool: 

now before i started i found that the file /var/lib/net-snmp/snmpapp.conf did not exist

so i tried it with the "addwrite /var/lib/net-snmp/snmpapp.conf" solution and found it created the file with the contents

 *Quote:*   

> #
> 
> # net-snmp (or ucd-snmp) persistent data file.
> 
> #
> ...

 

 not sure if this is any help but i was able to emerge succsessfully

----------

