libapt-pkg and apt-get are not Turkish locale safe

Bug #80248 reported by Alperen Yusuf Aybar on 2007-01-17
28
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apt (Ubuntu)
Medium
Michael Vogt
Intrepid
Undecided
Unassigned
Jaunty
Medium
Unassigned
update-manager (Ubuntu)
Undecided
Unassigned
Intrepid
Undecided
Unassigned
Jaunty
Undecided
Unassigned

Bug Description

libapt-pkg and apt-get use the "tolower"/"toupper" and
"strcasecmp"/"stringcasecmp" functions which are
locale-dependent. In the Turkish locale, toupper('i') != 'I'
and tolower('I') != 'i'. Package headers are hashed using
"tolower" in the user's locale in

   "apt-pkg/deb/deblistparser.cc:debListParser::VersionHash()"

even though the package headers are ASCII-only data. And
when the locale happens to be Turkish (tr_TR.UTF-8), the
"tolower()" function's behaviour is different on "I" compared
to its behaviour on "I" in the "C" locale. When this function
("VersionHash", that is) operates on headers like

   Depends: ... ,e2fsprogs (>= 1.32+1.33-WIP-2003.04.14-1), ...

in the Turkish locales, the hashes it produces are "improper"
because of the complications of the Turkish "i"s. Hence,
packages whose headers contain capital "i"s trigger
this problem and seem to have updates when in reality
they don't.

Please read

https://bugs.launchpad.net/ubuntu/+source/apt/+bug/80248/comments/32

for more information.

=== Old description follows ===

Update manager shows 3 available updates;

"e2fsprogs, initscripts and volumeid"

When I click update button it downloads&installs them but they keep staying in the update list.
One more strange thing they're upgrading from same version to same version:

e2fsprogs -> from 1.39-1 to 1.39-1
initscripts -> from 2.86.ds1-14.1ubuntu16 to 2.86.ds1-14.1ubuntu16
volumeid -> from 093-0ubuntu18 to 093-0ubuntu18

I tried both sudo aptitude upgrade & sudo apt-get upgrade ;but no change.

On ubuntuforums.org a Turkish Ubuntu user, like me, having the same problem:
http://ubuntuforums.org/showthread.php?t=283647

Alperen Yusuf Aybar (alperen) wrote :
Fabián Rodríguez (magicfab) wrote :

Thank you for your report. What version of Ubuntu are you using ?
Would it be possible for you to provide the same screen shot but in english ?

Changed in update-manager:
status: Unconfirmed → Needs Info
Alperen Yusuf Aybar (alperen) wrote :

I am using Ubuntu 6.10.

Michael Vogt (mvo) wrote :

Thanks for your bugreport.

Can you please attach your sources.list?

Alperen Yusuf Aybar (alperen) wrote :
fustundag (fatih-ustundag) wrote :

I have exactly same problem. I am using Ubuntu 6.10

Kayra Akman (ckakman) wrote :

I have the same problem as well. I have 6.10 installed on three boxes. But I observed the same problem on 2 of my boxes (Ubuntu and Xubuntu) which use the "generic" kernel. The third box (Ubuntu) has the "386" kernel (I have removed the default generic kernel and installed this one) but doesn't have this problem. I don't know whether this kernel issue is a coincidence, but this is what happened.

Alperen Yusuf Aybar (alperen) wrote :

I can still reproduce this bug in a fresh install of feisty.

The bug only occurs when using Turkish Locale

Cem Ahmet Mercan (ahmet-mercan) wrote :

I have exactly same problem. I am using Ubuntu feisty (amd64, 64 bit) with turkish locale.
uname -a:
Linux h2o 2.6.20-16-generic #2 SMP Thu Jun 7 19:00:28 UTC 2007 x86_64 GNU/Linux

Launchpad Janitor (janitor) wrote :

[Expired for update-manager (Ubuntu) because there has been no activity for 60 days.]

Changed in update-manager:
status: Invalid → Confirmed
ehcpdeveloper (ehcpdeveloper) wrote :

i think this is annoying, is there going to be a fix release?

Alperen Yusuf Aybar (alperen) wrote :

This bug still exist in a fresh install of Ubuntu 7.10 Gutsy Gibbon.
As I stated previously, the bug only occurs when using Turkish Locale.

Arda (ardasaltoglu+launchpad) wrote :

I can confirm the bug using following locales on otherwise up-to-date Kubuntu 7.10:

LANG=en_US.UTF-8
LC_CTYPE=tr_TR.UTF-8
LC_NUMERIC=tr_TR.UTF-8
LC_TIME=en_DK.UTF-8
LC_COLLATE=tr_TR.UTF-8
LC_MONETARY=tr_TR.UTF-8
LC_MESSAGES=en_US.UTF-8
LC_PAPER=tr_TR.UTF-8
LC_NAME=tr_TR.UTF-8
LC_ADDRESS=tr_TR.UTF-8
LC_TELEPHONE=tr_TR.UTF-8
LC_MEASUREMENT=tr_TR.UTF-8
LC_IDENTIFICATION=tr_TR.UTF-8
LC_ALL=

Arda (ardasaltoglu+launchpad) wrote :

Sorry, I forgot to add: I actually use aptitude, not update-manager, but the problem seems to be with checking the version by the packaging system anyway, and is apparently independent from the tool used to install/update.

egitimist (egitimist) wrote :

I used to have that same problem, to. I'm working hardy. Language: Turkish.

[code]egitimist@serdar-laptop:~$ sudo apt-get upgrade
[sudo] password for egitimist:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
  e2fsprogs initscripts
2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/402kB of archives.
After this operation, 0B of additional disk space will be used.
Do you want to continue [Y/n]? y
(Reading database ... 171696 files and directories currently installed.)
Preparing to replace e2fsprogs 1.40.8-2ubuntu2 (using .../e2fsprogs_1.40.8-2ubuntu2_i386.deb) ...
Unpacking replacement e2fsprogs ...
Setting up e2fsprogs (1.40.8-2ubuntu2) ...
(Reading database ... 171696 files and directories currently installed.)
Preparing to replace initscripts 2.86.ds1-14.1ubuntu45 (using .../initscripts_2.86.ds1-14.1ubuntu45_i386.deb) ...
Unpacking replacement initscripts ...
Setting up initscripts (2.86.ds1-14.1ubuntu45) ...

egitimist@serdar-laptop:~$ [/code]

And than upgrade;

[code]egitimist@serdar-laptop:~$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
  e2fsprogs initscripts
2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/402kB of archives.
After this operation, 0B of additional disk space will be used.
Do you want to continue [Y/n]?
  [/code]

latif (latifseker) wrote :

I can produce this on Hardy Heron

istblacken (behlulkahyaoglu) wrote :

this is still a problem in hardy 8.04. will there be any fix for this?

Michael Vogt (mvo) wrote :

If this is still a problem on hardy for some of you, could you please attach the output of:
$ apt-cache show e2fsprogs
$ dpkg -p e2fsprogs
and let me know what server you use (in your /etc/apt/sources.list)

Alperen Yusuf Aybar (alperen) wrote :

Hi Micheal, I can reproduce this bug on 8.04 when only using Turkish locale.

I am attaching my outputs.

Download full text (11.7 KiB)

Hi, below is output of commands you requested, i use ubuntu 8.04,
turkish locale.

bvidinli@bvidinli-laptop:~$
bvidinli@bvidinli-laptop:~$ apt-cache show e2fsprogs
Package: e2fsprogs
Essential: yes
Priority: required
Section: base
Installed-Size: 1740
Maintainer: Ubuntu Core Developers <email address hidden>
Original-Maintainer: Theodore Y. Ts'o <email address hidden>
Architecture: i386
Version: 1.40.8-2ubuntu2
Replaces: hurd (<= 20040301-1), libblkid1 (<<
1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
(>= 1.34-1)
Suggests: e2fsck-static, gpart, parted
Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (<<
1.55-8.1), sysvinit (<< 2.85-4)
Filename: pool/main/e/e2fsprogs/e2fsprogs_1.40.8-2ubuntu2_i386.deb
Size: 338136
MD5sum: e7409d7353e73fcfb10decb74a1b81fb
SHA1: 1769239369d0e7cb692eff56e3cce87b20976874
SHA256: 92e454970790a0567ddc9f723ddf6e38e6f6e0cb60a7051bbc896dca5f658e0c
Description: ext2 file system utilities and libraries
 EXT2 stands for "Extended Filesystem", version 2. It's the main
 filesystem type used for hard disks on Debian and other Linux systems.
 .
 This package contains programs for creating, checking, and maintaining EXT2
 filesystems, and the generic `fsck' wrapper.
Bugs: mailto:<email address hidden>
Origin: Ubuntu
Task: minimal

Package: e2fsprogs
Essential: yes
Status: install ok installed
Priority: required
Section: admin
Installed-Size: 1740
Maintainer: Ubuntu Core Developers <email address hidden>
Architecture: i386
Version: 1.40.8-2ubuntu2
Replaces: hurd (<= 20040301-1), libblkid1 (<<
1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
(>= 1.34-1)
Suggests: e2fsck-static, gpart, parted
Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (<<
1.55-8.1), sysvinit (<< 2.85-4)
Conffiles:
 /etc/mke2fs.conf 4ebb30bdb5951f1fc86c1470e4d81532
 /etc/e2fsck.conf 71563145349a6c512471c495ad8d5143
Description: ext2 file system utilities and libraries
 EXT2 stands for "Extended Filesystem", version 2. It's the main
 filesystem type used for hard disks on Debian and other Linux systems.
 .
 This package contains programs for creating, checking, and maintaining EXT2
 filesystems, and the generic `fsck' wrapper.
Original-Maintainer: Theodore Y. Ts'o <email address hidden>

bvidinli@bvidinli-laptop:~$ dpkg -p e2fsprogs
Package: e2fsprogs
Essential: yes
Priority: required
Section: admin
Installed-Size: 1740
Maintainer: Ubuntu Core Developers <email address hidden>
Architecture: i386
Version: 1.40.8-2ubuntu2
Replaces: hurd (<= 20040301-1), libblkid1 (<<
1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
(>= 1.34-1)
Suggests: e2fsck-static, gpart, parted
Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (...

ehcpdeveloper (ehcpdeveloper) wrote :
Download full text (12.8 KiB)

i still have same issue...

2008/5/7 bvidinli <email address hidden>:
> Hi, below is output of commands you requested, i use ubuntu 8.04,
> turkish locale.
>
> bvidinli@bvidinli-laptop:~$
> bvidinli@bvidinli-laptop:~$ apt-cache show e2fsprogs
> Package: e2fsprogs
> Essential: yes
> Priority: required
> Section: base
> Installed-Size: 1740
> Maintainer: Ubuntu Core Developers <email address hidden>
> Original-Maintainer: Theodore Y. Ts'o <email address hidden>
> Architecture: i386
> Version: 1.40.8-2ubuntu2
> Replaces: hurd (<= 20040301-1), libblkid1 (<<
> 1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
> Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
> libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
> (>= 1.34-1)
> Suggests: e2fsck-static, gpart, parted
> Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (<<
> 1.55-8.1), sysvinit (<< 2.85-4)
> Filename: pool/main/e/e2fsprogs/e2fsprogs_1.40.8-2ubuntu2_i386.deb
> Size: 338136
> MD5sum: e7409d7353e73fcfb10decb74a1b81fb
> SHA1: 1769239369d0e7cb692eff56e3cce87b20976874
> SHA256: 92e454970790a0567ddc9f723ddf6e38e6f6e0cb60a7051bbc896dca5f658e0c
> Description: ext2 file system utilities and libraries
> EXT2 stands for "Extended Filesystem", version 2. It's the main
> filesystem type used for hard disks on Debian and other Linux systems.
> .
> This package contains programs for creating, checking, and maintaining EXT2
> filesystems, and the generic `fsck' wrapper.
> Bugs: mailto:<email address hidden>
> Origin: Ubuntu
> Task: minimal
>
> Package: e2fsprogs
> Essential: yes
> Status: install ok installed
> Priority: required
> Section: admin
> Installed-Size: 1740
> Maintainer: Ubuntu Core Developers <email address hidden>
> Architecture: i386
> Version: 1.40.8-2ubuntu2
> Replaces: hurd (<= 20040301-1), libblkid1 (<<
> 1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
> Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
> libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
> (>= 1.34-1)
> Suggests: e2fsck-static, gpart, parted
> Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (<<
> 1.55-8.1), sysvinit (<< 2.85-4)
> Conffiles:
> /etc/mke2fs.conf 4ebb30bdb5951f1fc86c1470e4d81532
> /etc/e2fsck.conf 71563145349a6c512471c495ad8d5143
> Description: ext2 file system utilities and libraries
> EXT2 stands for "Extended Filesystem", version 2. It's the main
> filesystem type used for hard disks on Debian and other Linux systems.
> .
> This package contains programs for creating, checking, and maintaining EXT2
> filesystems, and the generic `fsck' wrapper.
> Original-Maintainer: Theodore Y. Ts'o <email address hidden>
>
> bvidinli@bvidinli-laptop:~$ dpkg -p e2fsprogs
> Package: e2fsprogs
> Essential: yes
> Priority: required
> Section: admin
> Installed-Size: 1740
> Maintainer: Ubuntu Core Developers <email address hidden>
> Architecture: i386
> Version: 1.40.8-2ubuntu2
> Replaces: hurd (<= 20040301-1), libblkid1 (<<
> 1.38+1.39-WIP-2005.12.10-2), li...

Hi,

My output for Micheal's requests ($ apt-cache show e2fsprogs, $ dpkg -p e2fsprogs and /etc/apt/sources.list) are attached.

Some background info:
I use xubuntu 8.04 at the moment; Turkish locale.
I am experiencing the same issue almost from the end of 2006 with Ubuntu 6.10 (see my forum entry: http://ubuntuforums.org/showthread.php?t=283647 and bug report: Bug #68331 which is a duplicate of this bug), then with xubuntu 7.04 and then xubuntu 7.10 and finally with xubuntu 8.04 at the time being.
From xubuntu 7.04 to xubuntu 7.10 and from xubuntu 7.10 to xubuntu 8.04 I performed distro upgrade via Web; I'm not sure if a clean install can solve the issue or not.
Once, I was having the issue was for three packages: e2fsprogs, initscripts and volumeid. At the moment volumeid package warning disappeared and the problem is valid for e2fsprogs and initscripts.
The nature of the problem seems to differ slightly now in xubuntu 8.04: Once, just update manager was of1fering those packages but not synaptic.Now, synaptic as well offers the two packages in aweird way, such as: When I refresh synaptic database and ask to find updates, it doesn't show any package at the bottom but "apply" button is active as if there are something to apply. No matter if I click apply; it keeps on offering the same "apply" thing again and again, seems to download and install e2fsprogs and initscripts packages, to update them from the same version to the same version. I can supply you with screenshots and/or with further info if you have some specific questions.
Regards...

Özgür BASKIN (ozgur-baskin) wrote :

I can produce this on Hardy Heron

yes,
i still have this issue...
i always have two packages to update !! e2fsprogs..

2008/7/5 Özgür BASKIN <email address hidden>:
> I can produce this on Hardy Heron
>
> --
> e2fsprogs initscripts volumeid Update Issue
> https://bugs.launchpad.net/bugs/80248
> You received this bug notification because you are a direct subscriber
> of the bug.
>

--
İ.Bahattin Vidinli
Elk-Elektronik Müh.
-------------------
iletisim bilgileri (Tercih sirasina gore):
skype: bvidinli (sesli gorusme icin, www.skype.com)
msn: <email address hidden>
yahoo: bvidinli

+90.532.7990607
+90.505.5667711

I can produce this on Hardy Heron

this bug continues in 8.10 alpha 3, intrepid

05 Temmuz 2008 Cumartesi 23:16 tarihinde bvidinli <email address hidden> yazdı:
> yes,
> i still have this issue...
> i always have two packages to update !! e2fsprogs..
>
> 2008/7/5 Özgür BASKIN <email address hidden>:
>> I can produce this on Hardy Heron
>>
>> --
>> e2fsprogs initscripts volumeid Update Issue
>> https://bugs.launchpad.net/bugs/80248
>> You received this bug notification because you are a direct subscriber
>> of the bug.
>>
>
>
>
> --
> İ.Bahattin Vidinli
> Elk-Elektronik Müh.
> -------------------
> iletisim bilgileri (Tercih sirasina gore):
> skype: bvidinli (sesli gorusme icin, www.skype.com)
> msn: <email address hidden>
> yahoo: bvidinli
>
> +90.532.7990607
> +90.505.5667711
>

--
İ.Bahattin Vidinli
Elk-Elektronik Müh.
-------------------
iletisim bilgileri:
msn/email: <email address hidden>
yahoo,skype,google: bvidinli

Vodafone: +90.543.2388711
Turkcell: +90.532.7990607

Thanks for the additional information.

I tried to reproduce this problem on a system with turkish locales, but without success so far. Could you please attach the terminal output of: "apt-cache policy e2fsprogs" ?

We had similar issues in the paste when (for some reason) one (or more) of the following fields were different between /var/lib/dpkg/status and the data in /var/lib/apt/lists/*Packages for the same version number:
const char *Sections[] ={"Installed-Size",
                            "Depends",
                            "Pre-Depends",
                            "Conflicts",
                            "Breaks",
                            "Replaces",
0};

Could you please check if one of those fields differes for the same version number (1.40.8-2ubuntu2 in hardy) between /var/lib/dpkg/status and the output of apt-cache show e2fsprogs?

Thanks,
 Michael

Changed in update-manager:
assignee: nobody → mvo
importance: Undecided → Medium
status: Confirmed → Triaged
status: Triaged → Incomplete
Download full text (5.0 KiB)

below is the info you wanted.
as i see, when i compared /var/lib/dpkg/status with *Packages file,
everyting seems same, as i managed to check...

i may do other tests as you wish..
as i said before, i also installed intrepid on another machine, same
issue continues..

and, my i ask: may i remove this package, e2fsprogs ? does it breaks system ?

thanks

console output and related parts:

bvidinli@bvidinli-laptop:~$ uname -a
Linux bvidinli-laptop 2.6.24-20-generic #1 SMP Thu Jul 17 16:29:46 UTC
2008 i686 GNU/Linux
bvidinli@bvidinli-laptop:~$

bvidinli@bvidinli-laptop:~$ apt-cache policy e2fsprogs
e2fsprogs:
  Kurulu (me:Means installed): 1.40.8-2ubuntu2
  Aday (means candidate) : 1.40.8-2ubuntu2
  Sürüm tablosu (means version table):
     1.40.8-2ubuntu2 0
        500 http://tr.archive.ubuntu.com hardy/main Packages
 *** 1.40.8-2ubuntu2 0
        100 /var/lib/dpkg/status
bvidinli@bvidinli-laptop:~$

here is related part of /var/lib/dpkg/status:

Package: e2fsprogs
Essential: yes
Status: install ok installed
Priority: required
Section: admin
Installed-Size: 1740
Maintainer: Ubuntu Core Developers <email address hidden>
Architecture: i386
Version: 1.40.8-2ubuntu2
Replaces: hurd (<= 20040301-1), libblkid1 (<<
1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
(>= 1.34-1)
Suggests: e2fsck-static, gpart, parted
Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (<<
1.55-8.1), sysvinit (<< 2.85-4)
Conffiles:
 /etc/mke2fs.conf 4ebb30bdb5951f1fc86c1470e4d81532
 /etc/e2fsck.conf 71563145349a6c512471c495ad8d5143
Description: ext2 file system utilities and libraries
 EXT2 stands for "Extended Filesystem", version 2. It's the main
 filesystem type used for hard disks on Debian and other Linux systems.
 .
 This package contains programs for creating, checking, and maintaining EXT2
 filesystems, and the generic `fsck' wrapper.
Original-Maintainer: Theodore Y. Ts'o <email address hidden>

here is related part from
/var/lib/apt/lists/tr.archive.ubuntu.com_ubuntu_dists_hardy_main_binary-i386_Packages
:

Package: e2fsprogs
Essential: yes
Priority: required
Section: base
Installed-Size: 1740
Maintainer: Ubuntu Core Developers <email address hidden>
Original-Maintainer: Theodore Y. Ts'o <email address hidden>
Architecture: i386
Version: 1.40.8-2ubuntu2
Replaces: hurd (<= 20040301-1), libblkid1 (<<
1.38+1.39-WIP-2005.12.10-2), libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)
Pre-Depends: e2fslibs (= 1.40.8-2ubuntu2), libblkid1 (>= 1.34-1),
libc6 (>= 2.7-1), libcomerr2 (>= 1.34-1), libss2 (>= 1.34-1), libuuid1
(>= 1.34-1)
Suggests: e2fsck-static, gpart, parted
Conflicts: dump (<< 0.4b4-4), initscripts (<< 2.85-4), quota (<<
1.55-8.1), sysvinit (<< 2.85-4)
Filename: pool/main/e/e2fsprogs/e2fsprogs_1.40.8-2ubuntu2_i386.deb
Size: 338136
MD5sum: e7409d7353e73fcfb10decb74a1b81fb
SHA1: 1769239369d0e7cb692eff56e3cce87b20976874
SHA256: 92e454970790a0567ddc9f723ddf6e38e6f6e0cb60a7051bbc896dca5f658e0c
Description: ext2 file system utilities and libraries
 EXT2 stands for "Extended Filesyste...

Read more...

Changed in update-manager:
status: Incomplete → Confirmed

Hello,

I am a Turkish Kubuntu user, and I have had this problem since at
least Kubuntu 6.10. I have upgraded from 6.10 to 7.04 to 7.10 to 8.04
and this problem has persisted. The only difference is that the packages
that are shown to be ready for upgrade are: e2fsprogs, initscripts and
nfs-kernel-server.

Here's something new: When one forces apt to refresh its package
caches, the problem does not show up until the next time updated
packages are released by (K)ubuntu.

Here's how I force apt to refresh its package cache:
    sudo rm -vf /var/cache/apt/*.bin
    sudo apt-get update

If needed, I can post my "/var/cache/apt/*.bin" files before and after
apt's package cache files are refreshed.

Regards,

situert

M. Vefa Bicakci (mvb) wrote :

Important update:

Sorry; I have forgotten one very important detail...

The temporary "fix" I have reported in my previous post only works if
one runs "apt-get update" under the "C" locale.

So the correct command lines are:
    sudo rm -vf /var/cache/apt/*.bin
    LANG=C LC_ALL=C sudo apt-get update

K. Deniz Ogut (kdenizogut) wrote :

Below is the translation of a workaround posted by user "erginemr" in the Forum area of Ubuntu Turkey at page http://www.ubuntu-tr.org/index.php?topic=948.15

I hope it is helpful for the real solution.

"... Anyway, I found a 'temporary' solution for this issue.What you should do is to intervene Debian package database manually to increase the sub-version numbers of these packages so to cheat Ubuntu in a way to ensure it that there's a new package installed in the system:

*** WARNING: Valid only for HARDY HERON (v.8.04) ***

1. The database which installed packeges are listed: /var/lib/dpkg/status

First of all make a copy of the file to be on the safe side:
sudo cp /var/lib/dpkg/status /var/lib/dpkg/status.bak

2. Open the file with Gnome Editor:
gksudo gedit /var/lib/dpkg/status

3. Search for this line: Package: e2fsprogs
and change this line :Version: 1.40.8-2ubuntu2
as this:Version: 1.40.8-2ubuntu2.1

4. Search for this line: Package: initscripts
and change this line:Version: 2.86ds1-14.1ubuntu45
as this:Version: 2.86ds1-14.1ubuntu45.1

5. Save the file. By using the code below, refresh the software sources:
sudo aptitude update

From now on -either via Synaptic or Update Manager- you shuld see that all your packages are up to date. Our fake version number increase is very small so that if and when there's a real update for these two packages, the update will come with a greater version number and package manager will recognise it."

M. Vefa Bicakci (mvb) wrote :
Download full text (7.9 KiB)

Important Update: The Cause and The Solution!

Hello,

As I have noted before, this problem manifests itself in Kubuntu too.
So this problem is not rooted in the "update-manager" which is Ubuntu
and GNOME specific.

Fortunately, I have found the solution to this problem. The actual problem
is in the "apt-get" program and "libapt-pkg" library included in the "apt"
package.

The root cause of this bug is the following: when "apt" and/or "libapt-pkg"
process in the Turkish locale packages whose information contains the letters
"i" or "I", they get confused because the Turkish "i"s have different
capitalization rules compared to the English "i". In summary, the following
is valid in the Turkish locale: "i" -> "İ" and "ı" -> "I", whereas in the
English locale: "i" -> "I". So,

=== 8< ===
strcasecmp("wip", "WIP")
=== >8 ===

does /NOT/ return "0" in the Turkish locale. Similarly,

=== 8< ===
toupper('i') != 'I'
tolower('I') != 'i'
=== >8 ===

in the Turkish locale. In tr_TR.UTF-8, the "toupper('i')" and "tolower('I')"
simply return "i" and "I", respectively. This is because "toupper" and
"tolower" functions can only return one byte characters and not multi-byte
UTF-8 characters.

I came to the conclusion that this problem had to do with the Turkish "i"s
after examining the headers of the affected packages (which are e2fsprogs,
initscripts and nfs-kernel-server.) To be specific, let's look at their
"Replaces" and "Requires" headers:

=== 8< ===
e2fsprogs: Replaces: hurd (<= 20040301-1), libblkid1 (<< 1.38+1.39-WIP-2005.12.10-2),
                     libuuid1 (<< 1.38+1.39-WIP-2005.12.10-2)

initscripts: Depends: debianutils (>= 2.13.1),e2fsprogs (>= 1.32+1.33-WIP-2003.04.14-1),
                      libc6 (>= 2.4), lsb-base (>= 3.0-6), mount (>= 2.11x-1),
                      passwd, sysvutils

nfs-kernel-server: Depends: libblkid1 (>= 1.39+1.40-WIP-2006.11.14+dfsg-2), libc6 (>= 2.4),
                            libcomerr2 (>= 1.33-3), libgssglue1, libkrb53 (>= 1.6.dfsg.2),
                            libldap-2.4-2 (>= 2.4.7), libnfsidmap2, librpcsecgss3, libwrap0,
                            lsb-base (>= 1.3-9ubuntu3), nfs-common (>= 1:1.0.8-1), ucf
=== >8 ===

As you can see all of these headers contain the string "WIP" which
contains the capital "I". I am kind of experienced in seeing the
malfunction of GNU/Linux programs in the Turkish locale because of
the differences of the Turkish "i"s compared to the English "i".
And because of this, I thought that this piece of information could
be the key.

Most of the time, a program uses "toupper()", "tolower()" or "strcasecmp()"
in the Turkish locale and expects that it behaves as it does in the English
or C locale. However, this is not case because of the Turkish "i"s.

A quick look at "apt-pkg/deb/deblistparser.cc" confirms my guess:

=== 8< ===
191 unsigned short debListParser::VersionHash()
192 {
193 const char *Sections[] ={"Installed-Size",
194 "Depends",
195 "Pre-Depends",
196 // "Suggests",
197 // "Recommends",
198 "Conflicts",
199 ...

Read more...

M. Vefa Bicakci (mvb) wrote :
M. Vefa Bicakci (mvb) wrote :
M. Vefa Bicakci (mvb) wrote :

Sorry, I did not choose "This attachment is a patch" option.

M. Vefa Bicakci (mvb) wrote :
M. Vefa Bicakci (mvb) wrote :

Okay, this is the binary package built from the source patched with
the "full" patch. If you install this package, the problem goes away.

M. Vefa Bicakci (mvb) wrote :

As I have noted before, this bug is not in update-manager or adept.
It is in the apt-get program and/or the libapt-pkg library. (Hence the
"apt" package.)

M. Vefa Bicakci (mvb) on 2008-09-13
description: updated
istblacken (behlulkahyaoglu) wrote :
Download full text (3.7 KiB)

@M.V Bıçakçı
i used your patch and it broke my update manager, synaptic and gdebi installer. i used force install since it is an i386 package and i am using 64 bit os. now can you tell me how to revert the changes back. if i type update manager in terminal i get this output:
~~
  Traceback (most recent call last):
  File "/usr/bin/update-manager", line 33, in <module>
    from UpdateManager.UpdateManager import UpdateManager
  File "/usr/lib/python2.5/site-packages/UpdateManager/UpdateManager.py", line 38, in <module>
    import apt
  File "/usr/lib/python2.5/site-packages/apt/__init__.py", line 2, in <module>
    import apt_pkg
ImportError: libapt-pkg-libc6.8-6.so.4.6: cannot open shared object file: No such file or directory
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/apport_python_hook.py", line 38, in apport_excepthook
    from apport.packaging_impl import impl as packaging
  File "/usr/lib/python2.5/site-packages/apport/__init__.py", line 1, in <module>
    from apport.report import Report
  File "/usr/lib/python2.5/site-packages/apport/report.py", line 21, in <module>
    import fileutils
  File "/usr/lib/python2.5/site-packages/apport/fileutils.py", line 16, in <module>
    from packaging_impl import impl as packaging
  File "/usr/lib/python2.5/site-packages/apport/packaging_impl.py", line 18, in <module>
    import apt
  File "/usr/lib/python2.5/site-packages/apt/__init__.py", line 2, in <module>
    import apt_pkg
ImportError: libapt-pkg-libc6.8-6.so.4.6: cannot open shared object file: No such file or directory

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/update-manager", line 33, in <module>
    from UpdateManager.UpdateManager import UpdateManager
  File "/usr/lib/python2.5/site-packages/UpdateManager/UpdateManager.py", line 38, in <module>
    import apt
  File "/usr/lib/python2.5/site-packages/apt/__init__.py", line 2, in <module>
    import apt_pkg
ImportError: libapt-pkg-libc6.8-6.so.4.6: cannot open shared object file: No such file or directory

if i type synaptic:
~~synaptic: error while loading shared libraries: libapt-pkg-libc6.8-6.so.4.6: cannot open shared object file: No such file or directory

if i type gdebi:
~~Traceback (most recent call last):
  File "/usr/bin/gdebi", line 29, in <module>
    import apt
  File "/usr/lib/python2.5/site-packages/apt/__init__.py", line 2, in <module>
    import apt_pkg
ImportError: libapt-pkg-libc6.8-6.so.4.6: cannot open shared object file: No such file or directory
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/apport_python_hook.py", line 38, in apport_excepthook
    from apport.packaging_impl import impl as packaging
  File "/usr/lib/python2.5/site-packages/apport/__init__.py", line 1, in <module>
    from apport.report import Report
  File "/usr/lib/python2.5/site-packages/apport/report.py", line 21, in <module>
    import fileutils
  File "/usr/lib/python2.5/site-packages/apport/fileutils.py", line 16, in <module>
    from packaging_impl import impl as packaging
  File "/usr/lib/python2.5/site-packages/apport/packaging_impl.py", line 18, i...

Read more...

M. Vefa Bicakci (mvb) wrote :

@istblacken

Dear Behlul Kahyaoglu,

First things first... The patched package was made for Ubuntu Hardy (8.04 LTS). I am sorry that I have
not made this clear. A quick look at your error messages reveals that you are using Ubuntu Intrepid (8.10)
- synaptic is looking for libapt-pkg-libc6.8-6.so.4.6, which is the version used in Intrepid, not Hardy. This
is probably why you had problems.

So, let's get you out of this situation.

Do the following:

$ cd /tmp
$ wget http://fr.archive.ubuntu.com/ubuntu/pool/main/a/apt/apt_0.7.14ubuntu6_amd64.deb
$ sudo su -
# cd /tmp
# dpkg --force-all -i ./apt_0.7.14*.deb
# exit
$ ...

Hopefully, this will fix your system. If it does not, we can make an appointment and talk over IRC,
which would be a much better way for me to help you.

Regards,

M. Vefa Bicakci

M. Vefa Bicakci (mvb) wrote :

@istblacken

Dear Behlul Kahyaoglu,

One more thing: You might need to run "ldconfig" after you run "dpkg --force-all -i ...".

Regards,

M. Vefa Bicakci

Alex1024 (aneptun) wrote :

this bug continues in 8.10 intrepid...
Is the turkish verison of e2fsprogs and initscripts differrent? Or why the problem is continued since 2 years?

istblacken (behlulkahyaoglu) wrote :

yes it is still an issue in 8.10 intrepid.

@Dear M.Vefa Bıçakçı
could you make your patch compatible with intrepid and 64 bit os? is it possible ? because i don't think any of the developers other than you are paying attention to this bug since it continues for more than 2 years.
Best regards

M. Vefa Bicakci (mvb) wrote :

Again, this bug is in the "libapt-pkg" library and "apt-get" program.
This problem occurs with KDE/Kubuntu when one uses adept too, which again confirms this.

Changed in update-manager:
status: New → Invalid
M. Vefa Bicakci (mvb) wrote :

@istblacken

Dear Behlul Kahyaoglu,

I will try to use the PPA function of Launchpad this weekend. Hopefully, this way
I will be able to have the patched apt package built for 32-bit and 64-bit versions
of Hardy and Intrepid, without the need to install all of these on my computer.

If I succeed, all a Turkish user of Ubuntu will have to do is to add my PPA repository
to his/her /etc/apt/sources.list.

Regards,

M. Vefa Bicakci

M. Vefa Bicakci (mvb) on 2008-11-15
description: updated
M. Vefa Bicakci (mvb) wrote :

Hello,

I am pleased to announce that I have set up my PPA repository which now
contains the patched versions of "apt" and friends.

So, if you are a user of the Turkish locale, and you would like this bug to
go away, all you have to do is the following:

1) a) If you are using "Hardy" (8.04 LTS), then append to your /etc/sources.list file
the following lines:

=== 8< ===
deb http://ppa.launchpad.net/mvb/ubuntu hardy main
deb-src http://ppa.launchpad.net/mvb/ubuntu hardy main
=== >8 ===

1) b) If you are using "Intrepid" (8.10), then append to your /etc/sources.list file
the following lines:

=== 8< ===
deb http://ppa.launchpad.net/mvb/ubuntu intrepid main
deb-src http://ppa.launchpad.net/mvb/ubuntu intrepid main
=== >8 ===

2) Use your favorite package manager (Synaptic, Adept, aptitude, etc.)
to do the equivalent of:

=== 8< ===
sudo apt-get update
sudo apt-get dist-upgrade
=== >8 ===

3) Close your package manager, and run the following commands:

=== 8< ===
sudo rm -v /var/cache/apt/*.bin
sudo apt-get update
=== >8 ===

Now, our main objective should be to get the patch I wrote merged into apt.

Regards,

M. Vefa Bicakci

Note 1: In order for the changes to the libraries go fully into effect, you might
need to log out and log back in (or reboot) after you have completed the steps
outlined above. (This is required because "update-notifier" will continue to
use the older version of libapt-pkg until "update-notifier" is restarted.)

Note 2: Attached is a newer version of the patch.

istblacken (behlulkahyaoglu) wrote :

@M.V Bicakci
Your patch worked fine for intrepid but now i am on jaunty (9.04) and this bug still continues.. if it is possible can you update your patch for jaunty and using the PPA would be easier. Thanks in advance.

M. Vefa Bicakci (mvb) wrote :

@istblacken

Dear Behlul Kahyaoglu,

I have good news and bad news for you.

The bad news: Unfortunately, I won't have the time to upload Jaunty-compatible packages
to my PPA until the 23rd of April.

The good news: I will upload the Jaunty-compatible packages as soon as possible after
the 23rd of April.

Please note that my not having time and the release date of Jaunty are not connected.
It is just that I have some important things to do until that date.

Sorry about that.

Regards,

M. Vefa Bicakci

M. Vefa Bicakci (mvb) wrote :

Hello all,

Today I had some time to prepare "apt" packages for 9.04 (Jaunty).
I am pleased to announce that my PPA now contains the packages
for "apt" and friends for Jaunty.

Please let me know if you have any problems with these packages.

Regards,

M. Vefa Bicakci

Michael Vogt (mvo) on 2009-04-23
Changed in apt (Ubuntu Jaunty):
status: Confirmed → In Progress
Launchpad Janitor (janitor) wrote :
Download full text (10.0 KiB)

This bug was fixed in the package apt - 0.7.23.1ubuntu1

---------------
apt (0.7.23.1ubuntu1) karmic; urgency=low

  [ Matt Zimmerman ]
  * apt-pkg/deb/dpkgpm.cc:
    - Suppress apport reports on dpkg short reads (these I/O errors are not
      generally indicative of a bug in the packaging)

  [ Loïc Minier ]
  * cmdline/apt-key:
    - Emit a warning if removed keys keyring is missing and skip associated
      checks (LP: #218971)

  [ Brian Murray ]
  * cmdline/apt-get.cc:
    - typo fix (LP: #370094)

  [ Michael Vogt ]
  * apt-pkg/deb/dpkgpm.cc:
    - when tcgetattr() returns non-zero skip all pty magic
      (thanks to Simon Richter, closes: #509866)
  * apt-inst/contrib/arfile.cc:
    - show propper error message for Invalid archive members
  * apt-pkg/acquire-worker.cc:
    - show error details of failed methods
  * apt-pkg/contrib/fileutl.cc:
    - if a process aborts with signal, show signal number
  * methods/http.cc:
    - ignore SIGPIPE, we deal with EPIPE from write in
      HttpMethod::ServerDie() (LP: #385144)
  * debian/apt.cron.daily:
    - if the timestamp is too far in the future, delete it
      (LP: #135262)

  [ Merge ]
  * merged from debian, reverted the libdlopen-udev branch
    because its too late in the release process for this now
  * not merged the proxy behaviour change from 0.7.23 (that will
    be part of lucid)

apt (0.7.23.1) unstable; urgency=low

  [ Michael Vogt ]
  * apt-pkg/pkgcache.cc:
    - do not set internel "needs-configure" state for packages in
      triggers-pending state. dpkg will deal with the trigger and
      it if does it before we trigger it, dpkg will error out
      (LP: #414631)
  * apt-pkg/acquire-item.cc:
    - do not segfault on invalid items (closes: #544080)

apt (0.7.23) unstable; urgency=low

  [ David Kalnischkies ]
  * cmdline/apt-get.cc:
    - add APT::Get::HideAutoRemove=small to display only a short line
      instead of the full package list. (Closes: #537450)
    - ShowBroken() in build-dep (by Mike O'Connor, Closes: #145916)
    - check for statfs.f_type (by Robert Millan, Closes: #509313)
    - correct the order of picked package binary vs source in source
    - use SourceVersion instead of the BinaryVersion to get the source
      Patch by Matt Kraai, thanks! (Closes: #382826)
    - add pkg/archive and codename in source (Closes: #414105, #441178)
  * apt-pkg/contrib/strutl.cc:
    - enable thousand separator according to the current locale
      (by Luca Bruno, Closes: #223712)
  * doc/apt.conf.5.xml:
    - mention the apt.conf.d dir (by Vincent McIntyre, Closes: #520831)
  * apt-inst/contrib/arfile.cc:
    - use sizeof instead strlen (by Marius Vollmer, Closes: #504325)
  * doc/apt-mark.8.xml:
    - improve manpage based on patch by Carl Chenet (Closes: #510286)
  * apt-pkg/acquire-item.cc:
    - use configsettings for dynamic compression type use and order.
      Based on a patch by Jyrki Muukkonen, thanks! (LP: #71746)
  * apt-pkg/aptconfiguration.cc:
    - add default configuration for compression types and add lzma
      support. Order is now bzip2, lzma, gzip, none (Closes: #510526)
  * ftparchive/writer.cc:
    - add lzma support also here, patch for this (and...

Changed in apt (Ubuntu):
status: In Progress → Fix Released
Alex Valavanis (valavanisalex) wrote :

Intrepid Ibex reached end-of-life on 30 April 2010 so I am closing the
report. The bug has been fixed in newer releases of Ubuntu.

Changed in apt (Ubuntu Intrepid):
status: New → Invalid
Changed in update-manager (Ubuntu Intrepid):
status: New → Invalid
Alex Valavanis (valavanisalex) wrote :

Jaunty reached end-of-life on 23 October 2010, so this bug will not be fixed in that version of Ubuntu. It has been fixed in newer versions.

Changed in apt (Ubuntu Jaunty):
assignee: Michael Vogt (mvo) → nobody
status: In Progress → Won't Fix
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers