How can I unpack Google Chrome on Ubuntu (stable version) without having an unpacking issue

807 Views Asked by At

Good day, when I'm trying to install Google Chrome on Ubuntu, it throw a dpkg-deb: error saying it cannot unpack the .deb file.

I'm following this guideline (without installing OpenJDK): https://tecadmin.net/setup-selenium-chromedriver-on-ubuntu/ And I managed to make it 2/3 days ago, but since that time, I guess a new version of chrome has been added, and once I reproduce installation on a new instance, I have the following error (that did not happen yesterday):

ubuntu@ip-172-31-5-107:~$ sudo apt -y install google-chrome-stable
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following NEW packages will be installed:
  google-chrome-stable
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 94.3 MB of archives.
After this operation, 322 MB of additional disk space will be used.
Get:1 http://dl.google.com/linux/chrome/deb stable/main amd64 google-chrome-stable amd64 114.0.5735.198-1 [94.3 MB]
Fetched 94.3 MB in 1s (65.4 MB/s)               
(Reading database ... 110879 files and directories currently installed.)
Preparing to unpack .../google-chrome-stable_114.0.5735.198-1_amd64.deb ...
Unpacking google-chrome-stable (114.0.5735.198-1) ...
dpkg-deb: error: <decompress> subprocess was killed by signal (Killed)
dpkg: error processing archive /var/cache/apt/archives/google-chrome-stable_114.0.5735.198-1_amd64.deb (--unpack):
 cannot copy extracted data for './opt/google/chrome/chrome' to '/opt/google/chrome/chrome.dpkg-new': unexpected end of file or stream
Errors were encountered while processing:
 /var/cache/apt/archives/google-chrome-stable_114.0.5735.198-1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Here is my Ubuntu release info:

No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04.2 LTS
Release:    22.04
Codename:   jammy

I tried to download DEB file and upload on the server througout SFTP to unpack it from the computer, I tried to dowload it with wget and unpack it, but nothing to do, the issue is still happenning: I cannot unpack this chrome DEB file.

I tried to run many commands offered by peoples who experienced this issue across forums: https://askubuntu.com/questions/1011008/dpkg-error-cannot-copy-extracted-data-for-unexpected-end-of-file-or-stream https://ubuntuforums.org/showthread.php?t=2433266

I tried touching to the dpkg config and even reseting the whole ubuntu softwares & dependencies thanks to the guideline below: https://linuxhint.com/fix-broken-ubuntu-without-reinstalling/

But still no changes and I cannot install or run Google Chrome.

My goal is to install Google Chrome and its drivers, so I guess if I can run google-chrome --version and see it is installed, I should be able to continue (as the first server I've set up).

Thank you in advance for your time & help!

0

There are 0 best solutions below