Quantcast
Channel: Active questions tagged zfs - Server Fault
Viewing all articles
Browse latest Browse all 138

Bash script error when trying to create a snapshot

$
0
0

I am trying to create a snapshot using Bash script as below but error occurred.

Environment: FreeBSD,Version: 13.2,Script: Bash

#!/usr/local/bin/bashname="17102023_1234"zfs snapshot data/library@$name

run this simple bash script but received error as shown below.

' in named character ''data/library@17102023_1234

It works when I put '17102023_1234' after @ instead of variable.

Any help is appreciated.Thanks.


Viewing all articles
Browse latest Browse all 138

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>