# CernVM-FS through SSH tunnel

**URL:** <https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232>\
**Category:** Client\
**Created:** [October 7, 2022, 11:02am UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232 "2022-10-07T11:02:37Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![fred\_iter](https://cernvm-forum.cern.ch/letter_avatar_proxy/v4/letter/f/e0b2c6/32.png) [@fred\_iter](https://cernvm-forum.cern.ch/u/fred_iter)\
**Post date:** [October 7, 2022, 11:02am UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/1 "2022-10-07T11:02:37Z")

</div>

Hello,

Do you know if it’s possible to reach a basic install of CernVM-FS (stratum 0) throught a ssh tunnel ?  
Ours is not reachable directly.  
I’ve redirected the remote port to a local with $ssh -f [myuser@myfrontend.mydomain.com](mailto:myuser@myfrontend.mydomain.com) -L 8080:mycvmfsserver:80 -N  
Then set 127.0.0.1:8080 in my config.g .conf file.  
I’m able to get the content of [http://127.0.0.1:8080/cvmfs/imas.iter.org/.cvmfspublished](http://127.0.0.1:8080/cvmfs/imas.iter.org/.cvmfspublished)  
But no mount, and probe result is “… Failed!”  
Manual mount (-t cvmfs) is asking for PROXY variable. If empty, or set, it parse files, then fail to initialize root catalog;

Thank you for your advices.

Regards.

---

<div class="post-metadata">

**Author:** ![jakob](https://cernvm-forum.cern.ch/user_avatar/cernvm-forum.cern.ch/jakob/32/10_2.png) [@jakob](https://cernvm-forum.cern.ch/u/jakob)\
**Post date:** [October 7, 2022, 3:13pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/2 "2022-10-07T15:13:55Z")

</div>

Tunneling should certainly be possible. The proxy error is unrelated, I think. Have you tried setting  
`CVMFS_HTTP_PROXY=DIRECT` in the config.d conf file?

---

<div class="post-metadata">

**Author:** ![fred\_iter](https://cernvm-forum.cern.ch/letter_avatar_proxy/v4/letter/f/e0b2c6/32.png) [@fred\_iter](https://cernvm-forum.cern.ch/u/fred_iter)\
**Post date:** [October 7, 2022, 5:53pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/3 "2022-10-07T17:53:10Z")

</div>

Hi,  
yes CVMFS\_HTTP\_PROXY=DIRECT is set.

Please find bellow a manual mount try:

 ![image](https://cernvm-forum.cern.ch/uploads/default/original/1X/027daf9698441e0572fe5d7b9ea252f8b772f096.png)

Best regards.

---

<div class="post-metadata">

**Author:** ![jakob](https://cernvm-forum.cern.ch/user_avatar/cernvm-forum.cern.ch/jakob/32/10_2.png) [@jakob](https://cernvm-forum.cern.ch/u/jakob)\
**Post date:** [October 8, 2022, 11:52am UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/4 "2022-10-08T11:52:45Z")

</div>

It may be the repository public key then. I’d recommend to store it in a subdirectory of /etc/cvmfs/keys and to set `CVMFS_KEYS_DIR=<path>` in the config.d conf file.

The syslog should contain more information why the root file catalog cannot be loaded.

---

<div class="post-metadata">

**Author:** ![fred\_iter](https://cernvm-forum.cern.ch/letter_avatar_proxy/v4/letter/f/e0b2c6/32.png) [@fred\_iter](https://cernvm-forum.cern.ch/u/fred_iter)\
**Post date:** [October 11, 2022, 12:03pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/5 "2022-10-11T12:03:20Z")

</div>

Thanks, but it’s already set:

![image](https://cernvm-forum.cern.ch/uploads/default/original/1X/74769524bcf58fa8d32d80352c71206de6fbe9ad.png)

I’ ll dig in the logs.

---

<div class="post-metadata">

**Author:** ![fred\_iter](https://cernvm-forum.cern.ch/letter_avatar_proxy/v4/letter/f/e0b2c6/32.png) [@fred\_iter](https://cernvm-forum.cern.ch/u/fred_iter)\
**Post date:** [October 11, 2022, 12:21pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/6 "2022-10-11T12:21:16Z")

</div>

Jakob, I sent you the debug log in MP 🥺

---

<div class="post-metadata">

**Author:** ![jakob](https://cernvm-forum.cern.ch/user_avatar/cernvm-forum.cern.ch/jakob/32/10_2.png) [@jakob](https://cernvm-forum.cern.ch/u/jakob)\
**Post date:** [October 11, 2022, 10:32pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/7 "2022-10-11T22:32:43Z")

</div>

Thanks! I got the debug logs. It’s certainly an issue with the public key, according to the logs. Are you sure that the key (`/etc/cmvfs/keys/<reponame>.pub`) on the client and the key used on the server are identical?

---

<div class="post-metadata">

**Author:** ![fred\_iter](https://cernvm-forum.cern.ch/letter_avatar_proxy/v4/letter/f/e0b2c6/32.png) [@fred\_iter](https://cernvm-forum.cern.ch/u/fred_iter)\
**Post date:** [October 12, 2022, 1:41pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/8 "2022-10-12T13:41:24Z")

</div>

Yes, and to be sure the key was scp from the server.

---

<div class="post-metadata">

**Author:** ![jakob](https://cernvm-forum.cern.ch/user_avatar/cernvm-forum.cern.ch/jakob/32/10_2.png) [@jakob](https://cernvm-forum.cern.ch/u/jakob)\
**Post date:** [October 14, 2022, 9:49pm UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/9 "2022-10-14T21:49:20Z")

</div>

Hm, then my only other explanation is that the whitelist got corrupted. You can try running `cvmfs_server resign` on the publisher. You can also send me the result of

- `curl http://127.0.0.1:8080/cvmfs/<reponame>/.cvmfswhitelist`
- `curl http://127.0.0.1:8080/cvmfs/<reponame>/.cvmfspublished`
- and the public key

in a private message.

---

<div class="post-metadata">

**Author:** ![fred\_iter](https://cernvm-forum.cern.ch/letter_avatar_proxy/v4/letter/f/e0b2c6/32.png) [@fred\_iter](https://cernvm-forum.cern.ch/u/fred_iter)\
**Post date:** [October 17, 2022, 7:42am UTC](https://cernvm-forum.cern.ch/t/cernvm-fs-through-ssh-tunnel/232/10 "2022-10-17T07:42:36Z")

</div>

Ok thanks I’ll check that,  
but the resign is done regularly via a cron job. And local/direct users don’t have any problem.

Regards
