Google-drive-ocamlfuse: E: Unable to locate package google-drive-ocamlfuse

Created on 18 Sep 2018  路  17Comments  路  Source: astrada/google-drive-ocamlfuse

Hi,

The following always works on Collaboratory, Google Drive. However, past couple of hours today, it has been generating error. Please help. Thank you very much.

!apt-get install -y -qq software-properties-common python-software-properties module-init-tools
!add-apt-repository -y ppa:alessandro-strada/ppa 2>&1 > /dev/null
!apt-get update -qq 2>&1 > /dev/null
!apt-get -y install -qq google-drive-ocamlfuse fuse
from google.colab import auth
auth.authenticate_user()
from oauth2client.client import GoogleCredentials
creds = GoogleCredentials.get_application_default()
import getpass
!google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret} < /dev/null 2>&1 | grep URL
vcode = getpass.getpass()
!echo {vcode} | google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret}

The error I get is:

gpg: keybox '/tmp/tmpyyi9ene9/pubring.gpg' created
gpg: /tmp/tmpyyi9ene9/trustdb.gpg: trustdb created
gpg: key AD5F235DF639B041: public key "Launchpad PPA for Alessandro Strada" imported
gpg: Total number processed: 1
gpg:               imported: 1
Warning: apt-key output should not be parsed (stdout is not a terminal)
E: Unable to locate package google-drive-ocamlfuse
路路路路路路路路路路
/bin/bash: google-drive-ocamlfuse: command not found

Most helpful comment

Hope this works for you, too. Otherwise just change your machine type (amd, arm, i386 etc..)

!apt-get install -y -qq software-properties-common python-software-properties module-init-tools
#!add-apt-repository -y ppa:alessandro-strada/ppa 2>&1 > /dev/null
#!apt-get update -qq 2>&1 > /dev/null
#!apt-get -y install -qq google-drive-ocamlfuse fuse
!wget https://launchpad.net/~alessandro-strada/+archive/ubuntu/google-drive-ocamlfuse-beta/+build/15331130/+files/google-drive-ocamlfuse_0.7.0-0ubuntu1_amd64.deb
!dpkg -i google-drive-ocamlfuse_0.7.0-0ubuntu1_amd64.deb
!apt-get install -f
!apt-get -y install -qq fuse
from google.colab import auth
auth.authenticate_user()
from oauth2client.client import GoogleCredentials
creds = GoogleCredentials.get_application_default()
import getpass
!google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret} < /dev/null 2>&1 | grep URL
vcode = getpass.getpass()
!echo {vcode} | google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret}

All 17 comments

I removed packages for zesty and artful, since they have reached end of life (https://wiki.ubuntu.com/Releases). If you cannot upgrade to bionic, you should download the package from the ppa (e.g. amd64) and install it with dpkg --install.

Hi, thank you for your note. This is a bit confusing, since I am new to it. Should I be making a change to the below code?

!apt-get install -y -qq software-properties-common python-software-properties module-init-tools
!add-apt-repository -y ppa:alessandro-strada/ppa 2>&1 > /dev/null
!apt-get update -qq 2>&1 > /dev/null
!apt-get -y install -qq google-drive-ocamlfuse fuse
from google.colab import auth
auth.authenticate_user()
from oauth2client.client import GoogleCredentials
creds = GoogleCredentials.get_application_default()
import getpass
!google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret} < /dev/null 2>&1 | grep URL
vcode = getpass.getpass()
!echo {vcode} | google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret}

As per this link, this is what we are supposed to do for running or Importing .py Files with Google Colab:

_Run these codes first in order to install the necessary libraries and perform authorization._

!apt-get install -y -qq software-properties-common python-software-properties module-init-tools
!add-apt-repository -y ppa:alessandro-strada/ppa 2>&1 > /dev/null
!apt-get update -qq 2>&1 > /dev/null
!apt-get -y install -qq google-drive-ocamlfuse fuse
from google.colab import auth
auth.authenticate_user()
from oauth2client.client import GoogleCredentials
creds = GoogleCredentials.get_application_default()
import getpass
!google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret} < /dev/null 2>&1 | grep URL
vcode = getpass.getpass()
!echo {vcode} | google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret}

Thank you very much.

@sagar-m those two code snippets are identical. Anyway, @astrada, would you mind being more specific about the dpkg --install method?

@daniel-leonard-robinson yes you are right, they are identical. I was merely making the point, that I am following a tutorial, and this is what the step was. Please note the line above the duplicate code, it is "Run these codes first in order to install the necessary libraries and perform authorization."

Please can @daniel-leonard-robinson or @astrada share the complete steps, how I can continue in Google Colab, as before, without breaking. Thank you very much.

Hope this works for you, too. Otherwise just change your machine type (amd, arm, i386 etc..)

!apt-get install -y -qq software-properties-common python-software-properties module-init-tools
#!add-apt-repository -y ppa:alessandro-strada/ppa 2>&1 > /dev/null
#!apt-get update -qq 2>&1 > /dev/null
#!apt-get -y install -qq google-drive-ocamlfuse fuse
!wget https://launchpad.net/~alessandro-strada/+archive/ubuntu/google-drive-ocamlfuse-beta/+build/15331130/+files/google-drive-ocamlfuse_0.7.0-0ubuntu1_amd64.deb
!dpkg -i google-drive-ocamlfuse_0.7.0-0ubuntu1_amd64.deb
!apt-get install -f
!apt-get -y install -qq fuse
from google.colab import auth
auth.authenticate_user()
from oauth2client.client import GoogleCredentials
creds = GoogleCredentials.get_application_default()
import getpass
!google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret} < /dev/null 2>&1 | grep URL
vcode = getpass.getpass()
!echo {vcode} | google-drive-ocamlfuse -headless -id={creds.client_id} -secret={creds.client_secret}

@daniel-leonard-robinson that worked beautifully. Relieved! I noticed that you commented out three lines and added three lines. Do you mind, explaining what these new lines are doing? On the whole, I don't know what these codes are doing. Thank you very much. Appreciate it.

I made an answer here too: https://stackoverflow.com/a/52387195/3477932

wget will download the .deb file, dpkg -i will attempt to install it, and apt-get install -f will re-attempt to install it but fix the dependencies. Lastly, fuse still needs to be installed.

@daniel-leonard-robinson thanks for the explanation of your updated lines. And what are the rest of the lines doing? Thank you again. I mean what is the purpose of these lines of code.

@astrada :$ wget https://launchpad.net/~alessandro-strada/+archive/ubuntu/google-drive-ocamlfuse-beta/+build/15331130/+files/google-drive-ocamlfuse_0.7.0-0ubuntu1_amd64.deb returns following error:

--2019-09-20 12:44:45--  https://launchpad.net/~alessandro-strada/+archive/ubuntu/google-drive-ocamlfuse-beta/+build/15331130/+files/google-drive-ocamlfuse_0.7.0-0ubuntu1_amd64.deb
Resolving launchpad.net (launchpad.net)... 91.189.89.222, 91.189.89.223, 2001:67c:1560:8003::8004, ...
Connecting to launchpad.net (launchpad.net)|91.189.89.222|:443... connected.
HTTP request sent, awaiting response... 404 Not Found
2019-09-20 12:44:46 ERROR 404: Not Found.

@avatar-lavventura: You are trying to fetch a very old version. Here you can find the latest version.

I don't know why but ubuntu is unable to locate the google-drive-ocamlfuse package.

$ sudo add-apt-repository ppa:alessandro-strada/google-drive-ocamlfuse-beta
$ sudo apt-get update
$ sudo apt install google-drive-ocamlfuse
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package google-drive-ocamlfuse

Which version of ubuntu?

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 17.10
Release:    17.10
Codename:   artful

artful reached end of life on July 19 2018, so I can't upload new packages for that distro. If you cannot upgrade, try manually installing the bionic one.

Upgrading ubuntu to 18.04 solved the problem

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kevinjpickard picture kevinjpickard  路  3Comments

xxx31fr picture xxx31fr  路  3Comments

kellnerp picture kellnerp  路  7Comments

OneCDOnly picture OneCDOnly  路  7Comments

acardona picture acardona  路  3Comments