Page 1 of 3 123 LastLast
Results 1 to 10 of 28

Thread: E: Sub-process /usr/bin/dpkg returned an error code (2)

Hybrid View

  1. #1
    Join Date
    Mar 2013
    Beans
    31

    Talking E: Sub-process /usr/bin/dpkg returned an error code (2)

    Hello everyone,

    I've encountered this problem when running the code below. I've included the output from terminal.
    Code:
    sudo apt-get update && sudo apt-get upgrade
    Before that, I was trying to remove WINE. I had installed in order to try a few games but nothing worked.

    Code:
    $ sudo apt-get update && sudo apt-get upgrade
    Hit http://dl.google.com stable Release.gpg
    Hit http://dl.google.com stable Release                                                                                                   
    Hit http://us.archive.ubuntu.com raring Release.gpg                                                                                       
    Get:1 http://security.ubuntu.com raring-security Release.gpg [933 B]                                                                      
    Get:2 http://us.archive.ubuntu.com raring-updates Release.gpg [933 B]                                                                     
    Hit http://deb.playonlinux.com precise Release.gpg                                                                                        
    Hit http://archive.canonical.com raring Release.gpg                                                                                       
    Get:3 http://security.ubuntu.com raring-security Release [40.8 kB]                                                                        
    Hit http://us.archive.ubuntu.com raring-backports Release.gpg                                                                             
    Hit http://ppa.launchpad.net raring Release.gpg                                                                                           
    Hit http://dl.google.com stable/main i386 Packages                                                                                        
    Hit http://extras.ubuntu.com raring Release.gpg                                                                                           
    Hit http://us.archive.ubuntu.com raring Release                                                                                           
    Hit http://download.opensuse.org ./ Release.gpg                                                                                           
    Hit http://deb.playonlinux.com precise Release                                                                                            
    Hit http://archive.canonical.com raring Release.gpg                                                                                       
    Hit http://ppa.launchpad.net raring Release                                                                                               
    Hit http://extras.ubuntu.com raring Release                                                                                               
    Get:4 http://us.archive.ubuntu.com raring-updates Release [40.8 kB]                                                                      
    Ign http://dl.google.com stable/main Translation-en_US                                                                                    
    Ign http://dl.google.com stable/main Translation-en                                                                                       
    Hit http://archive.canonical.com raring Release                                                                                           
    Get:5 http://security.ubuntu.com raring-security/main Sources [37.1 kB]                                                                   
    Hit http://deb.playonlinux.com precise/main i386 Packages                                                                                 
    Hit http://ppa.launchpad.net raring/main Sources                                                                                          
    Hit http://extras.ubuntu.com raring/main Sources                                                                                          
    Hit https://download.01.org Ubuntu Release.gpg                                                                                            
    Hit http://us.archive.ubuntu.com raring-backports Release                                                                                 
    Hit http://archive.canonical.com raring Release                                                                                           
    Hit https://download.01.org Ubuntu Release                                                                                                
    Get:6 http://security.ubuntu.com raring-security/restricted Sources [14 B]                                                                
    Hit http://download.opensuse.org ./ Release                                                                                               
    Hit http://us.archive.ubuntu.com raring/main Sources                                                                                      
    Hit http://ppa.launchpad.net raring/main i386 Packages                                                                                    
    Hit http://extras.ubuntu.com raring/main i386 Packages                                                                                    
    Get:7 http://security.ubuntu.com raring-security/universe Sources [8,832 B]                                                               
    Hit http://us.archive.ubuntu.com raring/restricted Sources                                                                                
    Hit http://archive.canonical.com raring/partner Sources                                                                                   
    Hit https://download.01.org Ubuntu/13.04 i386 Packages                                                                                    
    Get:8 http://security.ubuntu.com raring-security/multiverse Sources [2,264 B]                                                             
    Hit http://us.archive.ubuntu.com raring/universe Sources                                                                                  
    Hit http://archive.canonical.com raring/partner i386 Packages                                                                             
    Get:9 http://security.ubuntu.com raring-security/main i386 Packages [96.2 kB]                                                           
    Hit http://us.archive.ubuntu.com raring/multiverse Sources                                                                                
    Hit http://download.opensuse.org ./ Packages                                                                                              
    Hit http://us.archive.ubuntu.com raring/main i386 Packages                                                                                
    Hit http://us.archive.ubuntu.com raring/restricted i386 Packages                                                                          
    Hit http://us.archive.ubuntu.com raring/universe i386 Packages                                                                            
    Hit http://us.archive.ubuntu.com raring/multiverse i386 Packages                                                                          
    Hit http://archive.canonical.com raring/partner Sources                                                                                   
    Get:10 http://security.ubuntu.com raring-security/restricted i386 Packages [14 B]                                                         
    Hit http://us.archive.ubuntu.com raring/main Translation-en                                                                               
    Get:11 http://security.ubuntu.com raring-security/universe i386 Packages [33.9 kB]                                                        
    Hit http://archive.canonical.com raring/partner i386 Packages                                                                             
    Hit http://download.opensuse.org  Release.gpg                                                                                             
    Get:12 http://security.ubuntu.com raring-security/multiverse i386 Packages [3,871 B]                                                      
    Hit http://us.archive.ubuntu.com raring/multiverse Translation-en                                                                         
    Hit http://security.ubuntu.com raring-security/main Translation-en                                                                        
    Hit http://us.archive.ubuntu.com raring/restricted Translation-en                                                                       
    Ign http://ppa.launchpad.net raring/main Translation-en_US                                                                              
    Hit http://security.ubuntu.com raring-security/multiverse Translation-en                                          
    Hit http://us.archive.ubuntu.com raring/universe Translation-en                                                                           
    Ign http://deb.playonlinux.com precise/main Translation-en_US                                                                             
    Ign http://ppa.launchpad.net raring/main Translation-en                                                                                   
    Ign http://extras.ubuntu.com raring/main Translation-en_US                                                                              
    Hit http://security.ubuntu.com raring-security/restricted Translation-en                                          
    Get:13 http://us.archive.ubuntu.com raring-updates/main Sources [62.0 kB]                                         
    Ign http://extras.ubuntu.com raring/main Translation-en                                                                                   
    Ign http://deb.playonlinux.com precise/main Translation-en                                                                                
    Hit http://security.ubuntu.com raring-security/universe Translation-en                                                      
    Get:14 http://us.archive.ubuntu.com raring-updates/restricted Sources [14 B]                                       
    Get:15 http://us.archive.ubuntu.com raring-updates/universe Sources [70.9 kB]                                      
    Get:16 http://us.archive.ubuntu.com raring-updates/multiverse Sources [2,264 B]                                    
    Get:17 http://us.archive.ubuntu.com raring-updates/main i386 Packages [157 kB]                          
    Hit http://download.opensuse.org  Release                                                        
    Ign http://security.ubuntu.com raring-security/main Translation-en_US                                                       
    Ign http://security.ubuntu.com raring-security/multiverse Translation-en_US                           
    Ign http://download.opensuse.org ./ Translation-en_US                                                 
    Ign http://security.ubuntu.com raring-security/restricted Translation-en_US                           
    Ign http://download.opensuse.org ./ Translation-en                                                                                        
    Ign http://security.ubuntu.com raring-security/universe Translation-en_US                                                                 
    Get:18 http://us.archive.ubuntu.com raring-updates/restricted i386 Packages [14 B]                                                        
    Get:19 http://us.archive.ubuntu.com raring-updates/universe i386 Packages [138 kB]                                                        
    Ign http://archive.canonical.com raring/partner Translation-en_US                                                                         
    Ign http://archive.canonical.com raring/partner Translation-en                                                                            
    Get:20 http://us.archive.ubuntu.com raring-updates/multiverse i386 Packages [3,871 B]                                                     
    Ign http://archive.canonical.com raring/partner Translation-en_US                                                                         
    Ign http://archive.canonical.com raring/partner Translation-en                                                                            
    Hit http://us.archive.ubuntu.com raring-updates/main Translation-en                                                                       
    Hit http://us.archive.ubuntu.com raring-updates/multiverse Translation-en                                                                 
    Hit http://us.archive.ubuntu.com raring-updates/restricted Translation-en                                                                 
    Hit http://download.opensuse.org  Packages                                                                                                
    Hit http://us.archive.ubuntu.com raring-updates/universe Translation-en                                                                   
    Hit http://us.archive.ubuntu.com raring-backports/main Sources                                                                            
    Hit http://us.archive.ubuntu.com raring-backports/restricted Sources                                                                      
    Hit http://us.archive.ubuntu.com raring-backports/universe Sources                                                                        
    Hit http://us.archive.ubuntu.com raring-backports/multiverse Sources                                                                      
    Hit http://us.archive.ubuntu.com raring-backports/main i386 Packages                                                                      
    Hit http://us.archive.ubuntu.com raring-backports/restricted i386 Packages                                                                
    Hit http://us.archive.ubuntu.com raring-backports/universe i386 Packages                                                                  
    Hit http://us.archive.ubuntu.com raring-backports/multiverse i386 Packages                                                                
    Hit http://us.archive.ubuntu.com raring-backports/main Translation-en                                                                     
    Hit http://us.archive.ubuntu.com raring-backports/multiverse Translation-en                                                               
    Hit http://us.archive.ubuntu.com raring-backports/restricted Translation-en                                                               
    Ign https://download.01.org Ubuntu/13.04 Translation-en_US                                                                                
    Hit http://us.archive.ubuntu.com raring-backports/universe Translation-en                                                                 
    Ign https://download.01.org Ubuntu/13.04 Translation-en                                                                                   
    Ign http://us.archive.ubuntu.com raring/main Translation-en_US                                                                            
    Ign http://us.archive.ubuntu.com raring/multiverse Translation-en_US                                                                      
    Ign http://us.archive.ubuntu.com raring/restricted Translation-en_US                                                                      
    Ign http://us.archive.ubuntu.com raring/universe Translation-en_US                                                                        
    Ign http://us.archive.ubuntu.com raring-updates/main Translation-en_US                                                                    
    Ign http://us.archive.ubuntu.com raring-updates/multiverse Translation-en_US                                                              
    Ign http://us.archive.ubuntu.com raring-updates/restricted Translation-en_US                                                              
    Ign http://us.archive.ubuntu.com raring-updates/universe Translation-en_US                                                                
    Ign http://us.archive.ubuntu.com raring-backports/main Translation-en_US                                                                  
    Ign http://us.archive.ubuntu.com raring-backports/multiverse Translation-en_US                                                            
    Ign http://us.archive.ubuntu.com raring-backports/restricted Translation-en_US                                                            
    Ign http://download.opensuse.org  Translation-en_US                                                                                       
    Ign http://us.archive.ubuntu.com raring-backports/universe Translation-en_US                                                              
    Ign http://download.opensuse.org  Translation-en                                                                                          
    Fetched 700 kB in 11s (58.7 kB/s)                                                                                                         
    Reading package lists... Done
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following packages have been kept back:
      intel-linux-graphics-installer libopenscenegraph80
    The following packages will be upgraded:
      activity-log-manager-common activity-log-manager-control-center apport apport-gtk bamfdaemon command-not-found command-not-found-data
      gir1.2-dbusmenu-glib-0.4 gir1.2-dbusmenu-gtk-0.4 gnome-control-center-unity gnome-screenshot google-chrome-stable libbamf3-1
      libdbusmenu-glib4 libdbusmenu-gtk3-4 libdbusmenu-gtk4 libdvdnav4 libplymouth2 libunity-2d-private0 libunity-core-6.0-5 libwhoopsie0
      lsb-base lsb-release passwd plymouth plymouth-label plymouth-theme-ubuntu-logo plymouth-theme-ubuntu-text python-apport
      python-problem-report python3-apport python3-commandnotfound python3-problem-report unity unity-2d unity-2d-common unity-2d-panel
      unity-2d-shell unity-2d-spread unity-common unity-lens-applications unity-services whoopsie
    43 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
    Need to get 0 B/47.4 MB of archives.
    After this operation, 3,360 kB of additional disk space will be used.
    Do you want to continue [Y/n]? y
    Extracting templates from packages: 100%
    dpkg: parse error, in file '/var/lib/dpkg/status' near line 4794 package 'wine1.6-i386':
     `Depends' field, invalid package name `wine1.6:any': character `:' not allowed (only letters, digits and characters `-+._')
    E: Sub-process /usr/bin/dpkg returned an error code (2)
    If anyone can help: I'd really appreciate it.
    Thanks1.

  2. #2
    Join Date
    Apr 2011
    Location
    Mystletainn Kick!
    Beans
    13,614
    Distro
    Ubuntu

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Open up gedit and then select Open, then select file system, then select var, then lib, the dpkg, then status.
    Now go to the menu listing "Search", then go to "Go to Line".
    Type in line 4794.
    Now copy that line and post it.

    It seems from the error message that there is a character problem in that line, so posting the iine will help confirm it.
    Splat Double Splat Triple Splat
    Earn Your Keep
    Don't mind me, I'm only passing through.
    Once in a blue moon, I'm actually helpful
    .

  3. #3
    Join Date
    Mar 2013
    Beans
    31

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Quote Originally Posted by deadflowr View Post
    Open up gedit and then select Open, then select file system, then select var, then lib, the dpkg, then status.
    Now go to the menu listing "Search", then go to "Go to Line".
    Type in line 4794.
    Now copy that line and post it.

    It seems from the error message that there is a character problem in that line, so posting the iine will help confirm it.
    I did as you asked. There were two files with the name status. status and status-old.
    From status:
    Code:
    /etc/sane.d/artec_eplus48u.conf 3672fe16e6b14a124ad74acd47941be9
    From status-old:
    Code:
    /etc/sane.d/artec_eplus48u.conf 3672fe16e6b14a124ad74acd47941be9
    The lines appear the same to me.

  4. #4
    Join Date
    Apr 2011
    Location
    Mystletainn Kick!
    Beans
    13,614
    Distro
    Ubuntu

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    No matter. It was worth a shot to see the problem but alas I became stumped by it.

    Look at this from Ask Ubuntu on how to try to fix this error problem
    http://askubuntu.com/questions/4834/...kg-status-file

    Basically, though, it calls for you to move an old backup copy into the existing files place.
    Splat Double Splat Triple Splat
    Earn Your Keep
    Don't mind me, I'm only passing through.
    Once in a blue moon, I'm actually helpful
    .

  5. #5
    Join Date
    Jul 2010
    Location
    ozarks, Arkansas, USA
    Beans
    14,193
    Distro
    Xubuntu 22.04 Jammy Jellyfish

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Sky001; Hi !

    This to me indicates there are still some remnants of "wine" left on the system"
    dpkg: parse error, in file '/var/lib/dpkg/status' near line 4794 package 'wine1.6-i386':
    `Depends' field, invalid package name `wine1.6:any': character `:' not allowed (only letters, digits and characters `-+._')
    What means have you employed to this time to remove "Wine" ?

    this could now be a long row to hoe
    THE current(cy) in Documentation:
    https://help.ubuntu.com/community/PopularPages

    Happy ubuntu'n !

  6. #6
    Join Date
    Mar 2013
    Beans
    31

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    to remove wine, I used sudo apt-get remove wine && sudo apt-get purge wine.

  7. #7
    Join Date
    Mar 2013
    Beans
    31

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Quote Originally Posted by deadflowr View Post
    No matter. It was worth a shot to see the problem but alas I became stumped by it.

    Look at this from Ask Ubuntu on how to try to fix this error problem
    http://askubuntu.com/questions/4834/...kg-status-file

    Basically, though, it calls for you to move an old backup copy into the existing files place.
    I tried following the instructions in the link.

    At the first stage:
    Code:
    sudo apt-get install pcregrep
    pcregrep -nM '\n\s*\n[^P]+' /var/lib/dpkg/status
    My terminal result:
    Code:
    sudo apt-get install pcregrep
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following packages were automatically installed and are no longer required:
      gnome-exe-thumbnailer libcapi20-3 libnss-winbind libosmesa6 libpam-winbind linux-headers-3.8.0-26 linux-headers-3.8.0-26-generic
      linux-image-3.8.0-26-generic linux-image-extra-3.8.0-26-generic p7zip ttf-droid ttf-liberation ttf-umefont ttf-unfonts-core winbind
      wine-gecko1.4 wine-gecko2.21 wine-mono0.0.8 wine1.5 wine1.6 wine1.6-i386 winetricks
    Use 'apt-get autoremove' to remove them.
    The following NEW packages will be installed:
      pcregrep
    0 upgraded, 1 newly installed, 0 to remove and 45 not upgraded.
    Need to get 0 B/26.2 kB of archives.
    After this operation, 74.8 kB of additional disk space will be used.
    dpkg: parse error, in file '/var/lib/dpkg/status' near line 4794 package 'wine1.6-i386':
     `Depends' field, invalid package name `wine1.6:any': character `:' not allowed (only letters, digits and characters `-+._')
    E: Sub-process /usr/bin/dpkg returned an error code (2)

  8. #8
    Join Date
    Mar 2013
    Beans
    31

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Here you go.
    Code:
    $ ls -la /etc/apt/sources.list.d
    total 44
    drwxr-xr-x 2 root root 4096 Aug  5 17:17 .
    drwxr-xr-x 6 root root 4096 Aug  5 17:27 ..
    -rw-r--r-- 1 root root  176 Aug  5 11:52 google-chrome.list
    -rw-r--r-- 1 root root  211 Jul 21 21:13 google-chrome.list.distUpgrade
    -rw-r--r-- 1 root root  176 Aug  5 11:52 google-chrome.list.save
    -rw-r--r-- 1 root root   87 Aug  5 11:52 intellinuxgraphics.list
    -rw-r--r-- 1 root root   87 Aug  5 11:52 intellinuxgraphics.list.save
    -rw-r--r-- 1 root root   45 Jul  3 15:35 playonlinux.list
    -rw-r--r-- 1 root root  132 Aug  5 11:52 ubuntu-wine-ppa-raring.list
    -rw-r--r-- 1 root root  134 Aug  5 11:52 ubuntu-wine-ppa-raring.list.save
    -rw-r--r-- 1 root root   88 Aug  5 17:17 vegastrike-data.list
    Edit: I've tried to install the ppa-purge and the same error came about. See below
    Code:
    ~$ ppa-purge
    The program 'ppa-purge' is currently not installed. You can install it by typing:
    sudo apt-get install ppa-purge
    saipal@saipal-HP-Compaq-tc4400-EN357UT-ABA:~$ sudo apt-get install ppa-purge
    [sudo] password for saipal: 
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following packages were automatically installed and are no longer required:
      gnome-exe-thumbnailer libcapi20-3 libnss-winbind libosmesa6 libpam-winbind linux-headers-3.8.0-26 linux-headers-3.8.0-26-generic
      linux-image-3.8.0-26-generic linux-image-extra-3.8.0-26-generic p7zip ttf-droid ttf-liberation ttf-umefont ttf-unfonts-core winbind
      wine-gecko1.4 wine-gecko2.21 wine-mono0.0.8 wine1.5 wine1.6 wine1.6-i386 winetricks
    Use 'apt-get autoremove' to remove them.
    The following extra packages will be installed:
      aptitude aptitude-common libcwidget3
    Suggested packages:
      aptitude-doc-en aptitude-doc tasksel debtags libcwidget-dev
    The following NEW packages will be installed:
      aptitude aptitude-common libcwidget3 ppa-purge
    0 upgraded, 4 newly installed, 0 to remove and 45 not upgraded.
    Need to get 2,480 kB of archives.
    After this operation, 10.1 MB of additional disk space will be used.
    Do you want to continue [Y/n]? y
    Get:1 http://us.archive.ubuntu.com/ubuntu/ raring/main aptitude-common all 0.6.8.1-2ubuntu2 [669 kB]
    Get:2 http://us.archive.ubuntu.com/ubuntu/ raring/main libcwidget3 i386 0.5.16-3.4ubuntu1 [381 kB]
    Get:3 http://us.archive.ubuntu.com/ubuntu/ raring/main aptitude i386 0.6.8.1-2ubuntu2 [1,423 kB]
    Get:4 http://us.archive.ubuntu.com/ubuntu/ raring/universe ppa-purge all 0.2.8+bzr57 [5,704 B]
    Fetched 2,480 kB in 3s (813 kB/s)
    dpkg: parse error, in file '/var/lib/dpkg/status' near line 4794 package 'wine1.6-i386':
     `Depends' field, invalid package name `wine1.6:any': character `:' not allowed (only letters, digits and characters `-+._')
    E: Sub-process /usr/bin/dpkg returned an error code (2)
    Last edited by Sky001; August 25th, 2013 at 10:44 PM.

  9. #9
    Join Date
    Jul 2010
    Location
    ozarks, Arkansas, USA
    Beans
    14,193
    Distro
    Xubuntu 22.04 Jammy Jellyfish

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Sky001; Well, well
    do:
    Code:
    sudo apt-get install ppa-purge
    sudo ppa-purge ppa:ubuntu-wine-ppa-raring
    ls -la /etc/apt/sources.list.d
    and let us see then where you stand.

    ain't nothing but a thing
    THE current(cy) in Documentation:
    https://help.ubuntu.com/community/PopularPages

    Happy ubuntu'n !

  10. #10
    Join Date
    Mar 2013
    Beans
    31

    Re: E: Sub-process /usr/bin/dpkg returned an error code (2)

    Quote Originally Posted by Bashing-om View Post
    Sky001; Well, well
    do:
    Code:
    sudo apt-get install ppa-purge
    sudo ppa-purge ppa:ubuntu-wine-ppa-raring
    ls -la /etc/apt/sources.list.d
    and let us see then where you stand.
    ain't nothing but a thing
    I ran the code you gave me 3 times. Why did it abort?

    Code:
     sudo apt-get install ppa-purge
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following packages were automatically installed and are no longer required:
      gnome-exe-thumbnailer libcapi20-3 libnss-winbind libosmesa6 libpam-winbind linux-headers-3.8.0-26 linux-headers-3.8.0-26-generic
      linux-image-3.8.0-26-generic linux-image-extra-3.8.0-26-generic p7zip ttf-droid ttf-liberation ttf-umefont ttf-unfonts-core winbind
      wine-gecko1.4 wine-gecko2.21 wine-mono0.0.8 wine1.5 wine1.6 wine1.6-i386 winetricks
    Use 'apt-get autoremove' to remove them.
    The following extra packages will be installed:
      aptitude aptitude-common libcwidget3
    Suggested packages:
      aptitude-doc-en aptitude-doc tasksel debtags libcwidget-dev
    The following NEW packages will be installed:
      aptitude aptitude-common libcwidget3 ppa-purge
    0 upgraded, 4 newly installed, 0 to remove and 45 not upgraded.
    Need to get 0 B/2,480 kB of archives.
    After this operation, 10.1 MB of additional disk space will be used.
    Do you want to continue [Y/n]? y
    Abort.

Page 1 of 3 123 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •