ovh / svfs

The Swift Virtual File System
Other
374 stars 54 forks source link

Mounting hubiC on boot via fstab does not work #119

Closed 1f5 closed 7 years ago

1f5 commented 7 years ago

Context

Steps to reproduce this issue :

  1. Put authentication credentials in /etc/svfs.yaml
  2. mount -t svfs -o container=default hubic /media/hubic/
  3. Copy fstab entry from /etc/mtab to /etc/fstab Looks like this: hubic /media/hubic fuse.svfs rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other 0 0
  4. umount hubic
  5. mount -av

Results you expected :

I expect hubic to be mounted the same way like when mounted by hand.

Results you observed :

mount -av does not work and throws an error message. Rebooting fails with the given fstab entry.

Debug log :

mount -av output:

/proc                    : already mounted
/                        : ignored
Error: unknown command "hubic" for ""
Run ' --help' for usage.
FATA[2017-01-17T18:36:57+01:00] unknown command "hubic" for ""

Additional information :

Adding _netdev to the fstab entry does not seem to help.

daavve commented 7 years ago

I made my fstab look like this:

storage /mnt/storage svfs username=,tenant=,region=BHS1,rw,_netdev 1

Works for me.

1f5 commented 7 years ago

Still not works for me. Are you sure that username and tenant are left empty?

Error now is: Usage: mount.svfs device mountpoint [-o option=value,[option=value]...]

xlucas commented 7 years ago

@1f5 You have to fill them with relevant informations.

1f5 commented 7 years ago

Sorry, i still don't get it. What is my username and tenant on hubiC?

xlucas commented 7 years ago

@1f5 On hubic you have to use hubic_token and hubic_auth mount options. These are generated from the hubic-application script which is bundled with packages.

Check out the project docs for in-depth usage details with various products including HubiC.

Notmarrco commented 7 years ago

Hi,

I had the same issue : hubic wasn't mounted on boot, and it even stopped the booting process.

I tried the mount -av command that @1f5 mentioned, and it fails likewise.

After further investigating it seems that the "-v" arg is responsible for the "Usage: mount.svfs ..." error message, because it adds an arg to the mount.svfs call here https://github.com/ovh/svfs/blob/master/scripts/mount.svfs#L56 . With mount -a hubic svfs is mounted correctly.

@xlucas Should I open another issue ? the mount -a command can also accept "-fFnr..." and it will fail the same.

And for my issue with error on boot I will try with _netdev to see if it works better. TBC