0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

cadaver で Synology の WebDAV にアクセスする

Last updated at Posted at 2021-03-03

Ubuntu 20.10 で確認しました。
Synology に、WebDAV Server がインストールされ、ルーターの設定も完了しているものとします。

クライアントを Ubuntu にインストール

sudo apt install cadaver

tmp01.txt というファイルがあるフォルダーで、それを、Synology にアップロードします。

$ cadaver https://example.synology.me:5006
Authentication required for SYNO_WebDAV Storage on server `example.synology.me':
Username: scott
Password: 
dav:/> cd homes/scott/tmp
dav:/homes/scott/tmp/> put tmp01.txt
Uploading tmp01.txt to `/homes/uchida/tmp/tmp01.txt':
Progress: [=============================>] 100.0% of 29 bytes succeeded.
dav:/homes/scott/tmp/> quit

tmp02.txt というファイルを Synology からダウンロードします。

$ cadaver https://example.synology.me:5006
Authentication required for SYNO_WebDAV Storage on server `example.synology.me':
Username: scott
Password: 
dav:/> cd homes/scott/tmp
dav:/homes/scott/tmp/> get tmp02.txt
Enter local filename for `/homes/uchida/tmp/tmp02.txt': ./tmp02.txt
Downloading `/homes/scott/tmp/tmp02.txt' to ./tmp02.txt:
Progress: [=============================>] 100.0% of 20 bytes succeeded.
dav:/homes/scott/tmp/> quit

Username と Password の省略
$HOME/.netrc に次のように書き込みます。

$HOME/.netrc
machine example.synology.me
  login scott
  password secret
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?