# pkg upgrade error



## WCSN (Jun 11, 2013)

Hi,

I just installed 9.1-RELEASE amd64. I have a problem with pkg upgrade. Posts fewer, but were as follows:


```
# pkg upgrade
...
Checking integrity...
Conflict found on path /usr/local/share/locale/sr@ijekavian/LC_MESSAGES/libktorrent.mo between libktorrent-1.3.1_2(net-p2p/libktorrent) and sr-kde-l10n-4.10.3(misc/kde4-l10n-sr)

Conflict found on path /usr/local/share/locale/sr@ijekavianlatin/LC_MESSAGES/libktorrent.mo between libktorrent-1.3.1_2(net-p2p/libktorrent) and sr-kde-l10n-4.10.3(misc/kde4-l10n-sr)

Conflict found on path /usr/local/share/locale/sr@latin/LC_MESSAGES/libktorrent.mo between libktorrent-1.3.1_2(net-p2p/libktorrent) and sr-kde-l10n-4.10.3(misc/kde4-l10n-sr)

# pkg info | grep sr-
# pkg info | grep libktorrent

pkg No packages matching libktorrent and sr-*
```

These packages are not installed. There are no newer or older versions. Do not delete anything. Installation from ports also gives a similar error. Thus packages can be installed only in the absence of make.conf:

```
(comment) # WITH_PKG = yes
```

"pkg" but will not find them in its database and will be reinstalled and re-detect the conflict. Maybe you should try to install it from ports and make pkg register them???

Steadily getting this problem in four workers and home computers.

What to do? How to fixed it?


----------



## SirDice (Jun 11, 2013)

It's 
	
	



```
WITH_PKGNG=YES
```
 (Note the spelling and the spaces)

You now probably have a mix of packages that are registered the old and new way. Better clean the whole lot and start over.


----------



## WCSN (Jun 11, 2013)

Yes, of course, WITH_PKGNG. The above is a typo. I just WITH_PKGNG.

```
# cat /etc/make.conf.gcc
# Uncomment this if you want to do port builds with no interaction
#BATCH=yes
# wget                                                                                                                              
FETCH_CMD=/usr/local/bin/wget -c                                                                                                    
DISABLE_SIZE=yes
KDE4_PREFIX=/usr/local

WITH_PKGNG=yes

# added by use.perl 2012-11-16 18:38:57
PERL_VERSION=5.14.2

VER=48

.if !defined(CC) || ${CC} == "cc"
CC=gcc${VER}
.endif

.if !defined(CXX) || ${CXX} == "c++"
CXX=g++${VER}
.endif
```

These packages are not installed. I removed them when trying to resolve the conflict. Now they are not (they are older) and pkg apparently finds a conflict when trying to install. Moreover, sr-* is a Serbian locale I do not need it (us_US/ru_RU). pkg but stubbornly wants to put it. . This is depends to KDE.


----------



## WCSN (Jun 11, 2013)

Also http://forums.pcbsd.org/showthread.php?p=106813#post106813 say about...


----------



## SirDice (Jun 11, 2013)

They're probably registered with the old package-tools. Have a look with [cmd=]pkg_version -v[/cmd]. That's pkg_version(1), not pkg-version(8).

You can do two things, pull your hair out trying to solve all the conflicts or start fresh. For your own sanity I advise you to start over.


----------



## WCSN (Jun 11, 2013)

I understand you. But I use the pkg(ng) from December 2012. Has already made several updates via pkg. And everything was fine. All installation of ports is also made â€‹â€‹with the option WITH_PKGNG.

I would do all over again, but the old base pkg_* (old pkg) fear is no longer relevant - I did not delete it ... conversion will be incorrect. You advise pkg remove the existing database and create it again?

But I'm not sure if this will help. In the current database does not mention that the libtorrent and sr-kde-l10n-4.10.3 installed.

`pkg info` does not find them in the database, just as they are not looking for `pkg_info`. I'm sure pkg finds conflicts checking in preparation for the upgrade (`pkg upgrade -fy`)


----------



## SirDice (Jun 11, 2013)

WCSN said:
			
		

> But I'm not sure if this will help. In the current database does not mention that the libtorrent and sr-kde-l10n-4.10.3 installed.


Ah, wait. Have you tried looking for kde-i10n-sr?


----------



## WCSN (Jun 11, 2013)

kde4-i10n-sr is not installed. Generally speaking I tried to install it, then to tear down - well, that he took with him all of the base and with remote... but it does not help too


----------



## WCSN (Jun 12, 2013)

I had to install all updates "manually". `pkg update` lists updates on the basis of this list was the script:

```
#!/bin/bash

 pkg install-Ufy orc-0.4.16_1
 pkg install-Ufy gstreamer-0.10.36
 pkg install-Ufy gstreamer-plugins-0.10.36_3, 3
 pkg install-Ufy policykit-0.9_6

and etc ...
```

I excluded conflicting packages and install the appropriate ports of disabling the use pkg-base when make install.

I was too lazy (sorry) to understand why there is a conflict (although understanding why this is so in general it is), but not too lazy to fix almost 1000 lines of script  generated `pkg update -y> inst`.

Updates are installed - achieved the desired result.


----------



## kpa (Jun 12, 2013)

Not much to go on but I think the problem was that the some of the ports in question got split/merged and/or some of the files were moved to another port. The proper update procedure could have been found in /usr/ports/UPDATING


----------



## WCSN (Jun 12, 2013)

Mmm.. Why watch it? What does this have to pkg(ng)?


----------



## kpa (Jun 12, 2013)

Because that's the only place where the official procedures for potentially troublesome updates are published. It's recommended to keep an eye on that file. There's even the pkg_updating(1) tool to look up UPDATING entries for installed packages. For example, this shows the entries for the last month:

`pkg updating -d $(/bin/date -j -v -1m +%Y%m%d)`


----------



## WCSN (Jun 12, 2013)

Yes, I agree. This will help you understand what updates are needed and what's changed. But `pkg upgrade` makes updating the system and forms the entire list. Makes a comparison of conflict and in the cases if found the problem - stops working if it can not resolve the conflict. What guided pkg? To me it does not matter in this case. I need some updates which offers pkg.

I've written a script update.

Why is it done faster pkg its authors understand. I wish them good luck and success - make a good deal. Thank them.

`pkg updating -d `date -j -v -1m +%Y%m%d``?


----------

