mv: rename src to src-no: Operation not supported

Hello.

can someone tell me why I can't rename the src folder ? When I try to do that,it gives the error "operation not supported". I've messed up its content and I would like to copy and paste the content I have on another FreeBSD system,which works good. (the two installations are both based on the 13.1-RELEASE)

Code:
mario@marietto:/mnt/freebsd-zfs/usr # mv src src-no
mv: rename src to src-no: Operation not supported
 
I've been able to rename the src directory to src-no with this command :

Code:
zfs rename zroot/usr/src zroot/usr/src-no

but for some unknown reason,now I have an empty folder located on /usr called src-. Wnen I try to remove it,it says : error removing file : device busy. Why ? How can I remove this empty directory ?
 
There is also the possibility they are ZFS datasets.
 
------> if you really want to delete them, destroy the ZFS dataset and recreate them.

I'm frozen here. I'm not sure if I can destroy the ZFS dataset on the main FreeBSD system.
 
I've been able to rename the src directory to src-no with this command :

Code:
zfs rename zroot/usr/src zroot/usr/src-no

but for some unknown reason,now I have an empty folder located on /usr called src-. Wnen I try to remove it,it says : error removing file : device busy. Why ? How can I remove this empty directory ?
Do you have another mountpoint just below the one you just umounted? In this case you might want to try a df | grep <MOUNTPOINT>. If you see the same mountpoint more than once you have them stacked over each other.
 
but for some unknown reason,now I have an empty folder located on /usr called src-. Wnen I try to remove it,it says : error removing file : device busy. Why ? How can I remove this empty directory ?
The error message sounds like trying to remove a ZFS datasets mount point with rm(1).

------> if you really want to delete them, destroy the ZFS dataset and recreate them.

I'm frozen here. I'm not sure if I can destroy the ZFS dataset on the main FreeBSD system.
Sure you can. You would be destroying a dataset ( zroot/usr/src- ), unimportant to the "main FreeBSD system" (which is a different dataset under many others, when installed Root-on-ZFS by the FreeBSD installer).
 
Back
Top